Skip to content

Conversation

@jpraynaud
Copy link
Member

@jpraynaud jpraynaud commented Aug 8, 2025

Content

This PR includes fixes to the new clippy warnings appeared with the release of Rust 1.89.

Pre-submit checklist

  • Branch
    • Crates versions are updated (if relevant)
    • Commit sequence broadly makes sense
    • Key commits have useful messages
  • PR
    • All check jobs of the CI have succeeded
    • Self-reviewed the diff
    • Useful pull request description
    • Reviewer requested

* mithril-dmq from `0.1.6` to `0.1.7`
* mithril-persistence from `0.2.57` to `0.2.58`
* mithril-aggregator from `0.7.78` to `0.7.79`
* mithril-client-cli from `0.12.24` to `0.12.25`
* mithril-client from `0.12.25` to `0.12.26`
* mithril-common from `0.6.13` to `0.6.14`
* mithril-stm from `0.4.10` to `0.4.11`
* mithril-end-to-end from `0.4.98` to `0.4.99`
@jpraynaud jpraynaud self-assigned this Aug 8, 2025
@jpraynaud jpraynaud requested review from Copilot and rezabaram August 8, 2025 10:17
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR addresses Rust 1.89 clippy warnings across multiple Mithril project crates. The changes primarily focus on modernizing Rust syntax and improving code quality according to newer clippy lints.

Key changes include:

  • Using std::slice::from_ref() instead of creating single-element slices
  • Adopting let-else chains to reduce nested if statements
  • Adding explicit lifetime annotations where needed

Reviewed Changes

Copilot reviewed 33 out of 34 changed files in this pull request and generated no comments.

Show a summary per file
File Description
mithril-test-lab/mithril-end-to-end/src/stress_test/fake_signer.rs Replace slice creation with std::slice::from_ref()
mithril-stm/README.md Remove redundant function wrapper in documentation example
mithril-common/src/crypto_helper/merkle_map.rs Refactor nested if statements using let-else chains
mithril-common/src/certificate_chain/certificate_verifier.rs Simplify conditional logic with let-else pattern
mithril-client/src/file_downloader/http.rs Fix type coercion for feedback receiver
mithril-client/src/feedback.rs Fix type coercion for feedback receiver
mithril-client/src/certificate_client/verify.rs Refactor nested if statements using let-else chains
mithril-client-cli/src/utils/feedback_receiver.rs Fix type coercion for feedback receiver
mithril-client-cli/src/utils/archive_unpacker/zip_unpacker.rs Refactor nested if statements using let-else chains
mithril-aggregator/tests/prove_transactions.rs Replace slice creation with std::slice::from_ref()
mithril-aggregator/src/tools/file_archiver/appender.rs Add #[cfg(test)] attributes to test-only code
mithril-aggregator/src/tools/file_archiver/api.rs Refactor nested if statements using let-else chains
mithril-aggregator/src/store/epoch_settings_storer.rs Add #[cfg(test)] attributes to test-only code
mithril-aggregator/src/services/stake_distribution.rs Add explicit lifetime annotation
mithril-aggregator/src/services/message.rs Replace slice creation with std::slice::from_ref()
mithril-aggregator/src/services/certifier/buffered_certifier.rs Refactor nested if statements using let-else chains
mithril-aggregator/src/services/aggregator_client.rs Remove unused test code
mithril-aggregator/src/http_server/validators/prover_transactions_hash_validator.rs Replace slice creation with std::slice::from_ref()
mithril-aggregator/src/file_uploaders/cloud_uploader/api.rs Refactor nested if statements using let-else chains
mithril-aggregator/src/dependency_injection/builder/support/sqlite.rs Refactor nested if statements using let-else chains
internal/mithril-persistence/src/sqlite/connection_pool.rs Add explicit lifetime annotation
internal/mithril-persistence/src/sqlite/connection_extensions.rs Add explicit lifetime annotations
internal/mithril-persistence/src/database/version_checker.rs Add explicit lifetime annotation
internal/mithril-dmq/src/consumer/pallas.rs Add explicit lifetime annotation
Various Cargo.toml files Version bumps across multiple crates

@github-actions
Copy link

github-actions bot commented Aug 8, 2025

Test Results

    4 files  ±0    158 suites  ±0   22m 35s ⏱️ -32s
2 152 tests ±0  2 152 ✅ ±0  0 💤 ±0  0 ❌ ±0 
6 602 runs  ±0  6 602 ✅ ±0  0 💤 ±0  0 ❌ ±0 

Results for commit e5d2384. ± Comparison against base commit 72050f3.

@jpraynaud jpraynaud temporarily deployed to testing-preview August 8, 2025 10:31 — with GitHub Actions Inactive
@jpraynaud jpraynaud merged commit de4de82 into main Aug 8, 2025
70 of 71 checks passed
@jpraynaud jpraynaud deleted the jpraynaud/fix-rust-1.89 branch August 8, 2025 11:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants