From 5e9ec098d25ed66bfa5b68936b0a9a2895b7d9f3 Mon Sep 17 00:00:00 2001 From: ethanoroshiba Date: Fri, 6 Dec 2024 10:40:04 -0600 Subject: [PATCH 01/10] bump msrv --- .github/workflows/reusable-build.yml | 2 +- .github/workflows/test.yml | 2 +- crates/astria-bridge-contracts/Cargo.toml | 2 +- crates/astria-bridge-withdrawer/Cargo.toml | 2 +- crates/astria-build-info/Cargo.toml | 2 +- crates/astria-cli/Cargo.toml | 2 +- crates/astria-composer/Cargo.toml | 2 +- .../src/executor/bundle_factory/mod.rs | 4 ++-- crates/astria-conductor/Cargo.toml | 2 +- crates/astria-conductor/src/block_cache.rs | 2 +- crates/astria-conductor/src/celestia/reporting.rs | 6 +++--- crates/astria-conductor/src/executor/mod.rs | 2 ++ crates/astria-conductor/src/sequencer/reporting.rs | 4 ++-- crates/astria-config/Cargo.toml | 2 +- crates/astria-core-address/src/lib.rs | 2 +- crates/astria-core-crypto/Cargo.toml | 2 +- crates/astria-core/Cargo.toml | 2 +- crates/astria-core/src/generated/mod.rs | 3 ++- crates/astria-core/src/primitive/v1/asset/denom.rs | 10 +++++----- crates/astria-core/src/protocol/genesis/v1.rs | 6 ------ crates/astria-eyre/Cargo.toml | 2 +- crates/astria-grpc-mock-test/Cargo.toml | 2 +- crates/astria-grpc-mock-test/src/lib.rs | 3 ++- crates/astria-grpc-mock/Cargo.toml | 2 +- crates/astria-grpc-mock/src/mock_server.rs | 7 ++++--- crates/astria-merkle/Cargo.toml | 2 +- crates/astria-merkle/src/audit.rs | 4 ++-- crates/astria-merkle/src/lib.rs | 4 ++-- crates/astria-sequencer-client/Cargo.toml | 2 +- crates/astria-sequencer-relayer/Cargo.toml | 2 +- .../src/relayer/write/conversion.rs | 3 ++- .../src/relayer/write/mod.rs | 2 ++ .../blackbox/helpers/mock_sequencer_server.rs | 2 ++ crates/astria-sequencer-utils/Cargo.toml | 2 +- crates/astria-sequencer-utils/src/blob_parser.rs | 14 +++++++------- crates/astria-sequencer/Cargo.toml | 2 +- .../src/accounts/storage/values.rs | 4 ++-- .../src/app/storage/values/block_height.rs | 2 +- .../src/app/storage/values/block_timestamp.rs | 2 +- .../src/app/storage/values/chain_id.rs | 4 ++-- .../src/app/storage/values/revision_number.rs | 2 +- .../src/app/storage/values/storage_version.rs | 2 +- .../src/authority/storage/values.rs | 4 ++-- .../src/bridge/storage/values/address_bytes.rs | 2 +- .../src/bridge/storage/values/block_height.rs | 2 +- .../bridge/storage/values/ibc_prefixed_denom.rs | 2 +- .../src/bridge/storage/values/rollup_id.rs | 2 +- .../src/bridge/storage/values/transaction_id.rs | 2 +- .../src/grpc/storage/values/block_hash.rs | 2 +- .../src/grpc/storage/values/rollup_ids.rs | 2 +- .../src/grpc/storage/values/rollup_transactions.rs | 2 +- .../grpc/storage/values/sequencer_block_header.rs | 6 +++--- crates/astria-sequencer/src/ibc/storage/values.rs | 4 ++-- crates/astria-sequencer/src/mempool/mod.rs | 2 +- crates/astria-sequencer/src/storage/keys.rs | 8 ++++---- .../astria-sequencer/src/storage/stored_value.rs | 2 +- crates/astria-telemetry/Cargo.toml | 2 +- crates/astria-telemetry/src/display.rs | 4 ++-- crates/astria-telemetry/src/metrics/factories.rs | 6 +++--- crates/astria-test-utils/Cargo.toml | 2 +- rust-toolchain.toml | 2 +- 61 files changed, 97 insertions(+), 93 deletions(-) diff --git a/.github/workflows/reusable-build.yml b/.github/workflows/reusable-build.yml index 3d4c52c6d9..fedbd889ca 100644 --- a/.github/workflows/reusable-build.yml +++ b/.github/workflows/reusable-build.yml @@ -14,7 +14,7 @@ env: REGISTRY: ghcr.io FULL_REF: ${{ inputs.tag && format('refs/tags/{0}', inputs.tag) || github.ref }} # This must match the entry in rust-toolchain.toml at the repository root - RUSTUP_TOOLCHAIN: "1.81.0" + RUSTUP_TOOLCHAIN: "1.83.0" jobs: upload-binaries: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 0ebe04560b..12aa27d1bd 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -4,7 +4,7 @@ env: RUSTFLAGS: "-D warnings -D unreachable-pub --cfg tokio_unstable" # This must match the entry in rust-toolchain.toml at the repository root - RUSTUP_TOOLCHAIN: "1.81.0" + RUSTUP_TOOLCHAIN: "1.83.0" on: pull_request: merge_group: diff --git a/crates/astria-bridge-contracts/Cargo.toml b/crates/astria-bridge-contracts/Cargo.toml index ef6ce29f7f..98c7f22c83 100644 --- a/crates/astria-bridge-contracts/Cargo.toml +++ b/crates/astria-bridge-contracts/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-bridge-contracts" version = "0.1.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/crates/astria-bridge-withdrawer/Cargo.toml b/crates/astria-bridge-withdrawer/Cargo.toml index f5f50a2cc4..103f23ae8e 100644 --- a/crates/astria-bridge-withdrawer/Cargo.toml +++ b/crates/astria-bridge-withdrawer/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-bridge-withdrawer" version = "1.0.1" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" license = "MIT OR Apache-2.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" diff --git a/crates/astria-build-info/Cargo.toml b/crates/astria-build-info/Cargo.toml index ceab67fe22..a6b7434702 100644 --- a/crates/astria-build-info/Cargo.toml +++ b/crates/astria-build-info/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-build-info" version = "0.1.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/crates/astria-cli/Cargo.toml b/crates/astria-cli/Cargo.toml index eabf1c69b2..0dd1fca9fa 100644 --- a/crates/astria-cli/Cargo.toml +++ b/crates/astria-cli/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-cli" version = "0.5.1" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" license = "MIT OR Apache-2.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" diff --git a/crates/astria-composer/Cargo.toml b/crates/astria-composer/Cargo.toml index 5c62d2de7d..ac17b45de7 100644 --- a/crates/astria-composer/Cargo.toml +++ b/crates/astria-composer/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-composer" version = "1.0.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" license = "MIT OR Apache-2.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" diff --git a/crates/astria-composer/src/executor/bundle_factory/mod.rs b/crates/astria-composer/src/executor/bundle_factory/mod.rs index f35eb89d95..81652d86b9 100644 --- a/crates/astria-composer/src/executor/bundle_factory/mod.rs +++ b/crates/astria-composer/src/executor/bundle_factory/mod.rs @@ -36,7 +36,7 @@ enum SizedBundleError { pub(super) struct SizedBundleReport<'a>(pub(super) &'a SizedBundle); -impl<'a> Serialize for SizedBundleReport<'a> { +impl Serialize for SizedBundleReport<'_> { fn serialize(&self, serializer: S) -> Result where S: serde::Serializer, @@ -277,7 +277,7 @@ pub(super) struct NextFinishedBundle<'a> { bundle_factory: &'a mut BundleFactory, } -impl<'a> NextFinishedBundle<'a> { +impl NextFinishedBundle<'_> { pub(super) fn pop(self) -> SizedBundle { self.bundle_factory .finished diff --git a/crates/astria-conductor/Cargo.toml b/crates/astria-conductor/Cargo.toml index 8dc3f608a8..7934612df9 100644 --- a/crates/astria-conductor/Cargo.toml +++ b/crates/astria-conductor/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-conductor" version = "1.0.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" license = "MIT OR Apache-2.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" diff --git a/crates/astria-conductor/src/block_cache.rs b/crates/astria-conductor/src/block_cache.rs index 344d2bbec5..2f6e1b8046 100644 --- a/crates/astria-conductor/src/block_cache.rs +++ b/crates/astria-conductor/src/block_cache.rs @@ -120,7 +120,7 @@ pin_project! { } } -impl<'a, T> Future for NextBlock<'a, T> { +impl Future for NextBlock<'_, T> { type Output = Option; fn poll( diff --git a/crates/astria-conductor/src/celestia/reporting.rs b/crates/astria-conductor/src/celestia/reporting.rs index cd16454b6f..684be8a326 100644 --- a/crates/astria-conductor/src/celestia/reporting.rs +++ b/crates/astria-conductor/src/celestia/reporting.rs @@ -12,7 +12,7 @@ use super::{ }; pub(super) struct ReportReconstructedBlocks<'a>(pub(super) &'a ReconstructedBlocks); -impl<'a> Serialize for ReportReconstructedBlocks<'a> { +impl Serialize for ReportReconstructedBlocks<'_> { fn serialize(&self, serializer: S) -> Result where S: serde::Serializer, @@ -26,7 +26,7 @@ impl<'a> Serialize for ReportReconstructedBlocks<'a> { } struct ReportReconstructedBlocksSeq<'a>(&'a [ReconstructedBlock]); -impl<'a> Serialize for ReportReconstructedBlocksSeq<'a> { +impl Serialize for ReportReconstructedBlocksSeq<'_> { fn serialize(&self, serializer: S) -> Result where S: serde::Serializer, @@ -40,7 +40,7 @@ impl<'a> Serialize for ReportReconstructedBlocksSeq<'a> { } struct ReportReconstructedBlock<'a>(&'a ReconstructedBlock); -impl<'a> Serialize for ReportReconstructedBlock<'a> { +impl Serialize for ReportReconstructedBlock<'_> { fn serialize(&self, serializer: S) -> Result where S: serde::Serializer, diff --git a/crates/astria-conductor/src/executor/mod.rs b/crates/astria-conductor/src/executor/mod.rs index 8c3155ca8b..1d5bed113e 100644 --- a/crates/astria-conductor/src/executor/mod.rs +++ b/crates/astria-conductor/src/executor/mod.rs @@ -153,6 +153,8 @@ impl Handle { Ok(()) } + // TODO(search_here): box the large variant to avoid large error size + #[expect(clippy::result_large_err, reason = "should be fixed")] pub(crate) fn try_send_firm_block( &self, block: ReconstructedBlock, diff --git a/crates/astria-conductor/src/sequencer/reporting.rs b/crates/astria-conductor/src/sequencer/reporting.rs index 779eb5762e..25dafd3a31 100644 --- a/crates/astria-conductor/src/sequencer/reporting.rs +++ b/crates/astria-conductor/src/sequencer/reporting.rs @@ -13,7 +13,7 @@ use serde::ser::{ }; pub(super) struct ReportFilteredSequencerBlock<'a>(pub(super) &'a FilteredSequencerBlock); -impl<'a> Serialize for ReportFilteredSequencerBlock<'a> { +impl Serialize for ReportFilteredSequencerBlock<'_> { fn serialize(&self, serializer: S) -> Result where S: serde::Serializer, @@ -27,7 +27,7 @@ impl<'a> Serialize for ReportFilteredSequencerBlock<'a> { struct ReportRollups<'a>(&'a IndexMap); -impl<'a> Serialize for ReportRollups<'a> { +impl Serialize for ReportRollups<'_> { fn serialize(&self, serializer: S) -> Result where S: serde::Serializer, diff --git a/crates/astria-config/Cargo.toml b/crates/astria-config/Cargo.toml index 6672b75287..a8642f478b 100644 --- a/crates/astria-config/Cargo.toml +++ b/crates/astria-config/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-config" version = "0.1.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" license = "MIT OR Apache-2.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" diff --git a/crates/astria-core-address/src/lib.rs b/crates/astria-core-address/src/lib.rs index 3685222d87..43bbe74960 100644 --- a/crates/astria-core-address/src/lib.rs +++ b/crates/astria-core-address/src/lib.rs @@ -214,7 +214,7 @@ impl Builder { } } -impl<'a, 'b, TFormat, TBytesIter> Builder, WithPrefix<'b>> +impl Builder, WithPrefix<'_>> where TBytesIter: IntoIterator, TBytesIter::IntoIter: ExactSizeIterator, diff --git a/crates/astria-core-crypto/Cargo.toml b/crates/astria-core-crypto/Cargo.toml index 4e8b94bf7c..264cff2dfa 100644 --- a/crates/astria-core-crypto/Cargo.toml +++ b/crates/astria-core-crypto/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-core-crypto" version = "0.1.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" license = "MIT OR Apache-2.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" diff --git a/crates/astria-core/Cargo.toml b/crates/astria-core/Cargo.toml index b816e3fdf5..7003f1d9f6 100644 --- a/crates/astria-core/Cargo.toml +++ b/crates/astria-core/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-core" version = "0.1.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" license = "MIT OR Apache-2.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" diff --git a/crates/astria-core/src/generated/mod.rs b/crates/astria-core/src/generated/mod.rs index 41e186e2d7..1fef28c5e7 100644 --- a/crates/astria-core/src/generated/mod.rs +++ b/crates/astria-core/src/generated/mod.rs @@ -2,7 +2,8 @@ unreachable_pub, clippy::pedantic, clippy::needless_borrows_for_generic_args, - clippy::arithmetic_side_effects + clippy::arithmetic_side_effects, + clippy::needless_lifetimes )] //! Files generated using [`tonic-build`] and [`buf`] via the [`tools/protobuf-compiler`] //! build tool. diff --git a/crates/astria-core/src/primitive/v1/asset/denom.rs b/crates/astria-core/src/primitive/v1/asset/denom.rs index e28159fbc7..f8e5b17bf8 100644 --- a/crates/astria-core/src/primitive/v1/asset/denom.rs +++ b/crates/astria-core/src/primitive/v1/asset/denom.rs @@ -99,13 +99,13 @@ impl From for Denom { } } -impl<'a> From<&'a IbcPrefixed> for Denom { +impl From<&IbcPrefixed> for Denom { fn from(value: &IbcPrefixed) -> Self { Self::IbcPrefixed(*value) } } -impl<'a> From<&'a TracePrefixed> for Denom { +impl From<&TracePrefixed> for Denom { fn from(value: &TracePrefixed) -> Self { Self::TracePrefixed(value.clone()) } @@ -117,7 +117,7 @@ impl From for IbcPrefixed { } } -impl<'a> From<&'a TracePrefixed> for IbcPrefixed { +impl From<&TracePrefixed> for IbcPrefixed { fn from(value: &TracePrefixed) -> Self { value.to_ibc_prefixed() } @@ -129,13 +129,13 @@ impl From for IbcPrefixed { } } -impl<'a> From<&'a Denom> for IbcPrefixed { +impl From<&Denom> for IbcPrefixed { fn from(value: &Denom) -> Self { value.to_ibc_prefixed() } } -impl<'a> From<&'a IbcPrefixed> for IbcPrefixed { +impl From<&IbcPrefixed> for IbcPrefixed { fn from(value: &IbcPrefixed) -> Self { *value } diff --git a/crates/astria-core/src/protocol/genesis/v1.rs b/crates/astria-core/src/protocol/genesis/v1.rs index 168998a521..a7f8966161 100644 --- a/crates/astria-core/src/protocol/genesis/v1.rs +++ b/crates/astria-core/src/protocol/genesis/v1.rs @@ -147,12 +147,6 @@ impl Protobuf for GenesisAppState { type Error = GenesisAppStateError; type Raw = raw::GenesisAppState; - // TODO (https://github.com/astriaorg/astria/issues/1580): remove this once Rust is upgraded to/past 1.83 - #[expect( - clippy::allow_attributes, - clippy::allow_attributes_without_reason, - reason = "false positive on `allowed_fee_assets` due to \"allow\" in the name" - )] fn try_from_raw_ref(raw: &Self::Raw) -> Result { let Self::Raw { address_prefixes, diff --git a/crates/astria-eyre/Cargo.toml b/crates/astria-eyre/Cargo.toml index 6ee2bb106a..e0a63967e3 100644 --- a/crates/astria-eyre/Cargo.toml +++ b/crates/astria-eyre/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-eyre" version = "0.1.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/crates/astria-grpc-mock-test/Cargo.toml b/crates/astria-grpc-mock-test/Cargo.toml index 1767b42a7f..be5638119d 100644 --- a/crates/astria-grpc-mock-test/Cargo.toml +++ b/crates/astria-grpc-mock-test/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-grpc-mock-test" version = "0.1.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/crates/astria-grpc-mock-test/src/lib.rs b/crates/astria-grpc-mock-test/src/lib.rs index 6dad4f20cb..c1f9a2287e 100644 --- a/crates/astria-grpc-mock-test/src/lib.rs +++ b/crates/astria-grpc-mock-test/src/lib.rs @@ -8,7 +8,8 @@ #[expect( clippy::allow_attributes, clippy::allow_attributes_without_reason, - reason = "cannot prevent generated files from having allow attributes" + clippy::needless_lifetimes, + reason = "cannot prevent generated files from having allow attributes or specific lifetimes" )] pub mod health { include!("generated/grpc.health.v1.rs"); diff --git a/crates/astria-grpc-mock/Cargo.toml b/crates/astria-grpc-mock/Cargo.toml index 97f7c6a5b8..cb66c612d8 100644 --- a/crates/astria-grpc-mock/Cargo.toml +++ b/crates/astria-grpc-mock/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-grpc-mock" version = "0.1.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/crates/astria-grpc-mock/src/mock_server.rs b/crates/astria-grpc-mock/src/mock_server.rs index dcbad3d806..4f78077e07 100644 --- a/crates/astria-grpc-mock/src/mock_server.rs +++ b/crates/astria-grpc-mock/src/mock_server.rs @@ -178,7 +178,7 @@ impl MockServer { if let VerificationOutcome::Failure(failed_verifications) = self.state.read().await.verify() { let received_requests_message = - received_requests_message(&self.state.read().await.received_requests); + received_requests_message(self.state.read().await.received_requests.as_ref()); let verifications_errors: String = failed_verifications.iter().fold(String::new(), |mut s, m| { @@ -366,7 +366,8 @@ impl Drop for MockGuard { if report.is_satisfied() { state.mock_set.deactivate(*mock_id); } else { - let received_requests_message = received_requests_message(&state.received_requests); + let received_requests_message = + received_requests_message(state.received_requests.as_ref()); let verifications_error = format!("- {}\n", report.error_message()); let error_message = format!( @@ -385,7 +386,7 @@ impl Drop for MockGuard { } fn received_requests_message( - received_requests: &Option>, + received_requests: Option<&Vec<(&'static str, MockRequest)>>, ) -> String { if let Some(received_requests) = received_requests { if received_requests.is_empty() { diff --git a/crates/astria-merkle/Cargo.toml b/crates/astria-merkle/Cargo.toml index 19af2d1aa3..be01e6458c 100644 --- a/crates/astria-merkle/Cargo.toml +++ b/crates/astria-merkle/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-merkle" version = "1.0.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" license = "MIT OR Apache-2.0" repository = "https://github.com/astriaorg/astria" homepage = "https://astria.org" diff --git a/crates/astria-merkle/src/audit.rs b/crates/astria-merkle/src/audit.rs index ce524e0a74..b8b99329fd 100644 --- a/crates/astria-merkle/src/audit.rs +++ b/crates/astria-merkle/src/audit.rs @@ -141,7 +141,7 @@ impl<'a, TLeaf, TRoot> Audit<'a, TLeaf, TRoot> { } } -impl<'a, TRoot> Audit<'a, WithLeafHash, TRoot> { +impl Audit<'_, WithLeafHash, TRoot> { /// Reconstruct the root hash using the leaf hash stored in the [`WithLeafHash`] state. /// /// # Examples @@ -171,7 +171,7 @@ impl<'a, TRoot> Audit<'a, WithLeafHash, TRoot> { } } -impl<'a> Audit<'a, WithLeafHash, WithRoot> { +impl Audit<'_, WithLeafHash, WithRoot> { /// Check if the leaf is included in the tree using the internal proof. /// /// This method reconstructs a Merkle tree root starting from the diff --git a/crates/astria-merkle/src/lib.rs b/crates/astria-merkle/src/lib.rs index 9ca82b184a..2da5206752 100644 --- a/crates/astria-merkle/src/lib.rs +++ b/crates/astria-merkle/src/lib.rs @@ -184,7 +184,7 @@ pub struct LeafBuilder<'a> { hasher: Option, } -impl<'a> LeafBuilder<'a> { +impl LeafBuilder<'_> { /// Takes ownership of the builder, dropping it. /// /// This method causes the leaf builder to go out of scope, causing it @@ -232,7 +232,7 @@ impl<'a> LeafBuilder<'a> { } } -impl<'a> Drop for LeafBuilder<'a> { +impl Drop for LeafBuilder<'_> { fn drop(&mut self) { let Self { tree, diff --git a/crates/astria-sequencer-client/Cargo.toml b/crates/astria-sequencer-client/Cargo.toml index 1fa879ff12..1807b11c6c 100644 --- a/crates/astria-sequencer-client/Cargo.toml +++ b/crates/astria-sequencer-client/Cargo.toml @@ -3,7 +3,7 @@ name = "astria-sequencer-client" version = "0.1.0" edition = "2021" license = "MIT OR Apache-2.0" -rust-version = "1.81.0" +rust-version = "1.83.0" repository = "https://github.com/astriaorg/astria" homepage = "https://astria.org" diff --git a/crates/astria-sequencer-relayer/Cargo.toml b/crates/astria-sequencer-relayer/Cargo.toml index a0eed0eb64..1d0589e932 100644 --- a/crates/astria-sequencer-relayer/Cargo.toml +++ b/crates/astria-sequencer-relayer/Cargo.toml @@ -3,7 +3,7 @@ name = "astria-sequencer-relayer" version = "1.0.0" edition = "2021" license = "MIT OR Apache-2.0" -rust-version = "1.81.0" +rust-version = "1.83.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" homepage = "https://astria.org" diff --git a/crates/astria-sequencer-relayer/src/relayer/write/conversion.rs b/crates/astria-sequencer-relayer/src/relayer/write/conversion.rs index 82d425ff89..ad00a3cbd0 100644 --- a/crates/astria-sequencer-relayer/src/relayer/write/conversion.rs +++ b/crates/astria-sequencer-relayer/src/relayer/write/conversion.rs @@ -387,7 +387,7 @@ pin_project! { } } -impl<'a> Future for TakeSubmission<'a> { +impl Future for TakeSubmission<'_> { type Output = Option; fn poll(self: Pin<&mut Self>, _: &mut std::task::Context<'_>) -> Poll { @@ -441,6 +441,7 @@ fn sequencer_namespace(metadata: &SubmittedMetadata) -> Namespace { ) } +#[expect(clippy::ref_option, reason = "necessary for serde impl")] fn serialize_opt_namespace( namespace: &Option, serializer: S, diff --git a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs index bed9880a20..81db1ff239 100644 --- a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs +++ b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs @@ -93,6 +93,8 @@ impl BlobSubmitterHandle { /// Send a block to the blob submitter immediately. /// /// This is a thin wrapper around [`mpsc::Sender::try_send`]. + // TODO(search_here) + #[expect(clippy::result_large_err, reason = "should be fixed")] pub(super) fn try_send( &self, block: SequencerBlock, diff --git a/crates/astria-sequencer-relayer/tests/blackbox/helpers/mock_sequencer_server.rs b/crates/astria-sequencer-relayer/tests/blackbox/helpers/mock_sequencer_server.rs index 33ff34d989..a12b02e52b 100644 --- a/crates/astria-sequencer-relayer/tests/blackbox/helpers/mock_sequencer_server.rs +++ b/crates/astria-sequencer-relayer/tests/blackbox/helpers/mock_sequencer_server.rs @@ -96,6 +96,8 @@ impl MockSequencerServer { } } +// TODO(search_here): box enum variants to avoid large sizes +#[expect(clippy::large_enum_variant, reason = "should be fixed")] pub enum SequencerBlockToMount { GoodAtHeight(u32), BadAtHeight(u32), diff --git a/crates/astria-sequencer-utils/Cargo.toml b/crates/astria-sequencer-utils/Cargo.toml index 9f0bed5d91..d9d1f2f95c 100644 --- a/crates/astria-sequencer-utils/Cargo.toml +++ b/crates/astria-sequencer-utils/Cargo.toml @@ -3,7 +3,7 @@ name = "astria-sequencer-utils" version = "0.1.0" edition = "2021" license = "MIT OR Apache-2.0" -rust-version = "1.81.0" +rust-version = "1.83.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" homepage = "https://astria.org" diff --git a/crates/astria-sequencer-utils/src/blob_parser.rs b/crates/astria-sequencer-utils/src/blob_parser.rs index 6fb450ff90..131677019d 100644 --- a/crates/astria-sequencer-utils/src/blob_parser.rs +++ b/crates/astria-sequencer-utils/src/blob_parser.rs @@ -488,17 +488,17 @@ impl Display for RollupTransaction { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { colored_ln(f, "hash", &self.hash)?; colored_ln(f, "nonce", &self.nonce)?; - colored_ln(f, "block hash", none_or_value(&self.block_hash))?; - colored_ln(f, "block number", none_or_value(&self.block_number))?; + colored_ln(f, "block hash", none_or_value(self.block_hash.as_ref()))?; + colored_ln(f, "block number", none_or_value(self.block_number.as_ref()))?; colored_ln( f, "transaction index", - none_or_value(&self.transaction_index), + none_or_value(self.transaction_index.as_ref()), )?; colored_ln(f, "from", &self.from)?; - colored_ln(f, "to", none_or_value(&self.to))?; + colored_ln(f, "to", none_or_value(self.to.as_ref()))?; colored_ln(f, "value", &self.value)?; - colored_ln(f, "gas price", none_or_value(&self.gas_price))?; + colored_ln(f, "gas price", none_or_value(self.gas_price.as_ref()))?; colored_ln(f, "gas", &self.gas)?; colored_ln(f, "input", &self.input)?; colored_ln(f, "v", self.v)?; @@ -788,10 +788,10 @@ fn indent<'a, 'b>(f: &'a mut Formatter<'b>) -> indenter::Indented<'a, Formatter< indented(f).with_str(" ") } -fn none_or_value(maybe_value: &Option) -> String { +fn none_or_value(maybe_value: Option<&T>) -> String { maybe_value .as_ref() - .map_or("none".to_string(), T::to_string) + .map_or("none".to_string(), |o| o.to_string()) } fn colored_label(f: &mut Formatter<'_>, label: &str) -> fmt::Result { diff --git a/crates/astria-sequencer/Cargo.toml b/crates/astria-sequencer/Cargo.toml index 999bd4c547..d63ac2eeac 100644 --- a/crates/astria-sequencer/Cargo.toml +++ b/crates/astria-sequencer/Cargo.toml @@ -3,7 +3,7 @@ name = "astria-sequencer" version = "1.0.0" edition = "2021" license = "MIT OR Apache-2.0" -rust-version = "1.81.0" +rust-version = "1.83.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" homepage = "https://astria.org" diff --git a/crates/astria-sequencer/src/accounts/storage/values.rs b/crates/astria-sequencer/src/accounts/storage/values.rs index ca5f7b3977..9a771823ae 100644 --- a/crates/astria-sequencer/src/accounts/storage/values.rs +++ b/crates/astria-sequencer/src/accounts/storage/values.rs @@ -28,7 +28,7 @@ impl From for u128 { } } -impl<'a> From for crate::storage::StoredValue<'a> { +impl From for crate::storage::StoredValue<'_> { fn from(balance: Balance) -> Self { crate::storage::StoredValue::Accounts(Value(ValueImpl::Balance(balance))) } @@ -61,7 +61,7 @@ impl From for u32 { } } -impl<'a> From for crate::storage::StoredValue<'a> { +impl From for crate::storage::StoredValue<'_> { fn from(nonce: Nonce) -> Self { crate::storage::StoredValue::Accounts(Value(ValueImpl::Nonce(nonce))) } diff --git a/crates/astria-sequencer/src/app/storage/values/block_height.rs b/crates/astria-sequencer/src/app/storage/values/block_height.rs index 29b5298a47..c07102a4da 100644 --- a/crates/astria-sequencer/src/app/storage/values/block_height.rs +++ b/crates/astria-sequencer/src/app/storage/values/block_height.rs @@ -24,7 +24,7 @@ impl From for u64 { } } -impl<'a> From for crate::storage::StoredValue<'a> { +impl From for crate::storage::StoredValue<'_> { fn from(block_height: BlockHeight) -> Self { crate::storage::StoredValue::App(Value(ValueImpl::BlockHeight(block_height))) } diff --git a/crates/astria-sequencer/src/app/storage/values/block_timestamp.rs b/crates/astria-sequencer/src/app/storage/values/block_timestamp.rs index 23aa4cddf3..6a28e3d087 100644 --- a/crates/astria-sequencer/src/app/storage/values/block_timestamp.rs +++ b/crates/astria-sequencer/src/app/storage/values/block_timestamp.rs @@ -49,7 +49,7 @@ impl BorshDeserialize for BlockTimestamp { } } -impl<'a> From for crate::storage::StoredValue<'a> { +impl From for crate::storage::StoredValue<'_> { fn from(block_timestamp: BlockTimestamp) -> Self { crate::storage::StoredValue::App(Value(ValueImpl::BlockTimestamp(block_timestamp))) } diff --git a/crates/astria-sequencer/src/app/storage/values/chain_id.rs b/crates/astria-sequencer/src/app/storage/values/chain_id.rs index 0547029db4..237f204ec8 100644 --- a/crates/astria-sequencer/src/app/storage/values/chain_id.rs +++ b/crates/astria-sequencer/src/app/storage/values/chain_id.rs @@ -30,13 +30,13 @@ impl<'a> From> for tendermint::chain::Id { } } -impl<'a> BorshSerialize for ChainId<'a> { +impl BorshSerialize for ChainId<'_> { fn serialize(&self, writer: &mut W) -> std::io::Result<()> { self.0.as_str().serialize(writer) } } -impl<'a> BorshDeserialize for ChainId<'a> { +impl BorshDeserialize for ChainId<'_> { fn deserialize_reader(reader: &mut R) -> std::io::Result { let chain_id_str = String::deserialize_reader(reader)?; let chain_id = diff --git a/crates/astria-sequencer/src/app/storage/values/revision_number.rs b/crates/astria-sequencer/src/app/storage/values/revision_number.rs index d238b5b5ee..93e5c42a92 100644 --- a/crates/astria-sequencer/src/app/storage/values/revision_number.rs +++ b/crates/astria-sequencer/src/app/storage/values/revision_number.rs @@ -24,7 +24,7 @@ impl From for u64 { } } -impl<'a> From for crate::storage::StoredValue<'a> { +impl From for crate::storage::StoredValue<'_> { fn from(revision_number: RevisionNumber) -> Self { crate::storage::StoredValue::App(Value(ValueImpl::RevisionNumber(revision_number))) } diff --git a/crates/astria-sequencer/src/app/storage/values/storage_version.rs b/crates/astria-sequencer/src/app/storage/values/storage_version.rs index 933f76b8fb..53e7a6f9ab 100644 --- a/crates/astria-sequencer/src/app/storage/values/storage_version.rs +++ b/crates/astria-sequencer/src/app/storage/values/storage_version.rs @@ -24,7 +24,7 @@ impl From for u64 { } } -impl<'a> From for crate::storage::StoredValue<'a> { +impl From for crate::storage::StoredValue<'_> { fn from(storage_version: StorageVersion) -> Self { crate::storage::StoredValue::App(Value(ValueImpl::StorageVersion(storage_version))) } diff --git a/crates/astria-sequencer/src/authority/storage/values.rs b/crates/astria-sequencer/src/authority/storage/values.rs index 1c2aaaa4a1..a2e1a30957 100644 --- a/crates/astria-sequencer/src/authority/storage/values.rs +++ b/crates/astria-sequencer/src/authority/storage/values.rs @@ -36,7 +36,7 @@ enum ValueImpl<'a> { #[derive(BorshSerialize, BorshDeserialize)] pub(in crate::authority) struct AddressBytes<'a>(Cow<'a, [u8; ADDRESS_LEN]>); -impl<'a> Debug for AddressBytes<'a> { +impl Debug for AddressBytes<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { write!(f, "{}", base64(self.0.as_slice())) } @@ -75,7 +75,7 @@ impl<'a> TryFrom> for AddressBytes<'a> { #[derive(BorshSerialize, BorshDeserialize)] struct VerificationKey<'a>(Cow<'a, [u8; 32]>); -impl<'a> Debug for VerificationKey<'a> { +impl Debug for VerificationKey<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { write!(f, "{}", base64(self.0.as_slice())) } diff --git a/crates/astria-sequencer/src/bridge/storage/values/address_bytes.rs b/crates/astria-sequencer/src/bridge/storage/values/address_bytes.rs index 73d1d016f0..d420cf3336 100644 --- a/crates/astria-sequencer/src/bridge/storage/values/address_bytes.rs +++ b/crates/astria-sequencer/src/bridge/storage/values/address_bytes.rs @@ -24,7 +24,7 @@ use crate::accounts::AddressBytes as DomainAddressBytes; #[derive(BorshSerialize, BorshDeserialize)] pub(in crate::bridge) struct AddressBytes<'a>(Cow<'a, [u8; ADDRESS_LEN]>); -impl<'a> Debug for AddressBytes<'a> { +impl Debug for AddressBytes<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { write!(f, "{}", base64(self.0.as_slice())) } diff --git a/crates/astria-sequencer/src/bridge/storage/values/block_height.rs b/crates/astria-sequencer/src/bridge/storage/values/block_height.rs index 1fe4edf48c..3c88824ac7 100644 --- a/crates/astria-sequencer/src/bridge/storage/values/block_height.rs +++ b/crates/astria-sequencer/src/bridge/storage/values/block_height.rs @@ -36,7 +36,7 @@ impl From for u64 { } } -impl<'a> From for crate::storage::StoredValue<'a> { +impl From for crate::storage::StoredValue<'_> { fn from(block_height: BlockHeight) -> Self { crate::storage::StoredValue::Bridge(Value(ValueImpl::BlockHeight(block_height))) } diff --git a/crates/astria-sequencer/src/bridge/storage/values/ibc_prefixed_denom.rs b/crates/astria-sequencer/src/bridge/storage/values/ibc_prefixed_denom.rs index 725af800d4..db8b23f91d 100644 --- a/crates/astria-sequencer/src/bridge/storage/values/ibc_prefixed_denom.rs +++ b/crates/astria-sequencer/src/bridge/storage/values/ibc_prefixed_denom.rs @@ -23,7 +23,7 @@ use super::{ #[derive(BorshSerialize, BorshDeserialize)] pub(in crate::bridge) struct IbcPrefixedDenom<'a>(Cow<'a, [u8; 32]>); -impl<'a> Debug for IbcPrefixedDenom<'a> { +impl Debug for IbcPrefixedDenom<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { write!(f, "{}", base64(self.0.as_slice())) } diff --git a/crates/astria-sequencer/src/bridge/storage/values/rollup_id.rs b/crates/astria-sequencer/src/bridge/storage/values/rollup_id.rs index 5a67daf7fb..dff8246b16 100644 --- a/crates/astria-sequencer/src/bridge/storage/values/rollup_id.rs +++ b/crates/astria-sequencer/src/bridge/storage/values/rollup_id.rs @@ -23,7 +23,7 @@ use super::{ #[derive(BorshSerialize, BorshDeserialize)] pub(in crate::bridge) struct RollupId<'a>(Cow<'a, [u8; 32]>); -impl<'a> Debug for RollupId<'a> { +impl Debug for RollupId<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { write!(f, "{}", base64(self.0.as_slice())) } diff --git a/crates/astria-sequencer/src/bridge/storage/values/transaction_id.rs b/crates/astria-sequencer/src/bridge/storage/values/transaction_id.rs index fa12a21f43..d752d3c635 100644 --- a/crates/astria-sequencer/src/bridge/storage/values/transaction_id.rs +++ b/crates/astria-sequencer/src/bridge/storage/values/transaction_id.rs @@ -26,7 +26,7 @@ use super::{ #[derive(BorshSerialize, BorshDeserialize)] pub(in crate::bridge) struct TransactionId<'a>(Cow<'a, [u8; TRANSACTION_ID_LEN]>); -impl<'a> Debug for TransactionId<'a> { +impl Debug for TransactionId<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { write!(f, "{}", hex(self.0.as_slice())) } diff --git a/crates/astria-sequencer/src/grpc/storage/values/block_hash.rs b/crates/astria-sequencer/src/grpc/storage/values/block_hash.rs index 4c772091ca..dea59d835a 100644 --- a/crates/astria-sequencer/src/grpc/storage/values/block_hash.rs +++ b/crates/astria-sequencer/src/grpc/storage/values/block_hash.rs @@ -22,7 +22,7 @@ use super::{ #[derive(BorshSerialize, BorshDeserialize)] pub(in crate::grpc) struct BlockHash<'a>(Cow<'a, [u8; 32]>); -impl<'a> Debug for BlockHash<'a> { +impl Debug for BlockHash<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { write!(f, "{}", base64(self.0.as_slice())) } diff --git a/crates/astria-sequencer/src/grpc/storage/values/rollup_ids.rs b/crates/astria-sequencer/src/grpc/storage/values/rollup_ids.rs index 05575132af..d2bb6f6079 100644 --- a/crates/astria-sequencer/src/grpc/storage/values/rollup_ids.rs +++ b/crates/astria-sequencer/src/grpc/storage/values/rollup_ids.rs @@ -23,7 +23,7 @@ use super::{ #[derive(BorshSerialize, BorshDeserialize)] pub(super) struct RollupId<'a>(Cow<'a, [u8; 32]>); -impl<'a> Debug for RollupId<'a> { +impl Debug for RollupId<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { write!(f, "{}", base64(self.0.as_slice())) } diff --git a/crates/astria-sequencer/src/grpc/storage/values/rollup_transactions.rs b/crates/astria-sequencer/src/grpc/storage/values/rollup_transactions.rs index f54947e033..733c6f8be0 100644 --- a/crates/astria-sequencer/src/grpc/storage/values/rollup_transactions.rs +++ b/crates/astria-sequencer/src/grpc/storage/values/rollup_transactions.rs @@ -32,7 +32,7 @@ pub(in crate::grpc) struct RollupTransactions<'a> { proof: Proof<'a>, } -impl<'a> Debug for RollupTransactions<'a> { +impl Debug for RollupTransactions<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { f.debug_struct("RollupTransactions") .field("rollup_id", &self.rollup_id) diff --git a/crates/astria-sequencer/src/grpc/storage/values/sequencer_block_header.rs b/crates/astria-sequencer/src/grpc/storage/values/sequencer_block_header.rs index 0c53040cca..3c6f6ab622 100644 --- a/crates/astria-sequencer/src/grpc/storage/values/sequencer_block_header.rs +++ b/crates/astria-sequencer/src/grpc/storage/values/sequencer_block_header.rs @@ -45,13 +45,13 @@ impl<'a> From> for tendermint::chain::Id { } } -impl<'a> BorshSerialize for ChainId<'a> { +impl BorshSerialize for ChainId<'_> { fn serialize(&self, writer: &mut W) -> std::io::Result<()> { self.0.as_str().serialize(writer) } } -impl<'a> BorshDeserialize for ChainId<'a> { +impl BorshDeserialize for ChainId<'_> { fn deserialize_reader(reader: &mut R) -> std::io::Result { let chain_id_str = String::deserialize_reader(reader)?; let chain_id = @@ -106,7 +106,7 @@ pub(in crate::grpc) struct SequencerBlockHeader<'a> { proposer_address: [u8; ADDRESS_LEN], } -impl<'a> Debug for SequencerBlockHeader<'a> { +impl Debug for SequencerBlockHeader<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { f.debug_struct("SequencerBlockHeader") .field("chain_id", &self.chain_id) diff --git a/crates/astria-sequencer/src/ibc/storage/values.rs b/crates/astria-sequencer/src/ibc/storage/values.rs index f1a0783f89..ad35125058 100644 --- a/crates/astria-sequencer/src/ibc/storage/values.rs +++ b/crates/astria-sequencer/src/ibc/storage/values.rs @@ -41,7 +41,7 @@ impl From for u128 { } } -impl<'a> From for crate::storage::StoredValue<'a> { +impl From for crate::storage::StoredValue<'_> { fn from(balance: Balance) -> Self { crate::storage::StoredValue::Ibc(Value(ValueImpl::Balance(balance))) } @@ -61,7 +61,7 @@ impl<'a> TryFrom> for Balance { #[derive(BorshSerialize, BorshDeserialize)] pub(in crate::ibc) struct AddressBytes<'a>(Cow<'a, [u8; ADDRESS_LEN]>); -impl<'a> Debug for AddressBytes<'a> { +impl Debug for AddressBytes<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { write!(f, "{}", base64(self.0.as_slice())) } diff --git a/crates/astria-sequencer/src/mempool/mod.rs b/crates/astria-sequencer/src/mempool/mod.rs index 68579620f4..2271f281dd 100644 --- a/crates/astria-sequencer/src/mempool/mod.rs +++ b/crates/astria-sequencer/src/mempool/mod.rs @@ -112,7 +112,7 @@ struct ContainedTxLock<'a> { txs: RwLockWriteGuard<'a, HashSet<[u8; 32]>>, } -impl<'a> ContainedTxLock<'a> { +impl ContainedTxLock<'_> { fn add(&mut self, id: [u8; 32]) { if !self.txs.insert(id) { self.mempool.metrics.increment_internal_logic_error(); diff --git a/crates/astria-sequencer/src/storage/keys.rs b/crates/astria-sequencer/src/storage/keys.rs index edf0333ba8..fba71e6beb 100644 --- a/crates/astria-sequencer/src/storage/keys.rs +++ b/crates/astria-sequencer/src/storage/keys.rs @@ -30,7 +30,7 @@ impl<'a, T> AccountPrefixer<'a, T> { } } -impl<'a, T: AddressBytes> Display for AccountPrefixer<'a, T> { +impl Display for AccountPrefixer<'_, T> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { use base64::{ display::Base64Display, @@ -46,13 +46,13 @@ impl<'a, T: AddressBytes> Display for AccountPrefixer<'a, T> { #[cfg_attr(test, derive(Debug, PartialEq))] pub(crate) struct Asset<'a>(Cow<'a, IbcPrefixed>); -impl<'a> Asset<'a> { +impl Asset<'_> { pub(crate) fn get(self) -> IbcPrefixed { self.0.into_owned() } } -impl<'a> Display for Asset<'a> { +impl Display for Asset<'_> { fn fmt(&self, f: &mut Formatter<'_>) -> fmt::Result { self.0.fmt(f) } @@ -67,7 +67,7 @@ where } } -impl<'a> FromStr for Asset<'a> { +impl FromStr for Asset<'_> { type Err = ParseIbcPrefixedError; fn from_str(s: &str) -> Result { diff --git a/crates/astria-sequencer/src/storage/stored_value.rs b/crates/astria-sequencer/src/storage/stored_value.rs index 07164615e7..3fe203521b 100644 --- a/crates/astria-sequencer/src/storage/stored_value.rs +++ b/crates/astria-sequencer/src/storage/stored_value.rs @@ -21,7 +21,7 @@ pub(crate) enum StoredValue<'a> { Grpc(crate::grpc::storage::Value<'a>), } -impl<'a> StoredValue<'a> { +impl StoredValue<'_> { pub(crate) fn serialize(&self) -> Result> { borsh::to_vec(&self).wrap_err("failed to serialize stored value") } diff --git a/crates/astria-telemetry/Cargo.toml b/crates/astria-telemetry/Cargo.toml index 7cc30072a5..cb17bdcc92 100644 --- a/crates/astria-telemetry/Cargo.toml +++ b/crates/astria-telemetry/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-telemetry" version = "0.1.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" license = "MIT OR Apache-2.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" diff --git a/crates/astria-telemetry/src/display.rs b/crates/astria-telemetry/src/display.rs index 3a1c9b98e5..c132f0c516 100644 --- a/crates/astria-telemetry/src/display.rs +++ b/crates/astria-telemetry/src/display.rs @@ -97,7 +97,7 @@ pub struct Json<'a, T>(&'a T); // NOTE: This implementation is lifted straight from serde_json: // https://docs.rs/serde_json/1.0.114/src/serde_json/value/mod.rs.html#197 -impl<'a, T> Display for Json<'a, T> +impl Display for Json<'_, T> where T: serde::Serialize, { @@ -106,7 +106,7 @@ where inner: &'a mut Formatter<'b>, } - impl<'a, 'b> io::Write for WriterFormatter<'a, 'b> { + impl io::Write for WriterFormatter<'_, '_> { fn write(&mut self, buf: &[u8]) -> io::Result { // NOTE: Same argument for safety as in // https://docs.rs/serde_json/1.0.114/src/serde_json/value/mod.rs.html#229 diff --git a/crates/astria-telemetry/src/metrics/factories.rs b/crates/astria-telemetry/src/metrics/factories.rs index a3abc3b85c..bdd1549265 100644 --- a/crates/astria-telemetry/src/metrics/factories.rs +++ b/crates/astria-telemetry/src/metrics/factories.rs @@ -176,7 +176,7 @@ trait RegisterMetric { fn metric_type() -> &'static str; } -impl<'a> RegisterMetric for Factory<'a, Counter> { +impl RegisterMetric for Factory<'_, Counter> { fn register_metric(&self, key: &Key) -> Counter { let ignored_metadata = Metadata::new("", metrics::Level::ERROR, None); Counter::new(self.recorder.register_counter(key, &ignored_metadata)) @@ -187,7 +187,7 @@ impl<'a> RegisterMetric for Factory<'a, Counter> { } } -impl<'a> RegisterMetric for Factory<'a, Gauge> { +impl RegisterMetric for Factory<'_, Gauge> { fn register_metric(&self, key: &Key) -> Gauge { let ignored_metadata = Metadata::new("", metrics::Level::ERROR, None); Gauge::new(self.recorder.register_gauge(key, &ignored_metadata)) @@ -198,7 +198,7 @@ impl<'a> RegisterMetric for Factory<'a, Gauge> { } } -impl<'a> RegisterMetric for Factory<'a, Histogram> { +impl RegisterMetric for Factory<'_, Histogram> { fn register_metric(&self, key: &Key) -> Histogram { let ignored_metadata = Metadata::new("", metrics::Level::ERROR, None); Histogram::new(self.recorder.register_histogram(key, &ignored_metadata)) diff --git a/crates/astria-test-utils/Cargo.toml b/crates/astria-test-utils/Cargo.toml index 854cdd4b03..e7a551c1d6 100644 --- a/crates/astria-test-utils/Cargo.toml +++ b/crates/astria-test-utils/Cargo.toml @@ -2,7 +2,7 @@ name = "astria-test-utils" version = "0.1.0" edition = "2021" -rust-version = "1.81.0" +rust-version = "1.83.0" license = "MIT OR Apache-2.0" readme = "README.md" repository = "https://github.com/astriaorg/astria" diff --git a/rust-toolchain.toml b/rust-toolchain.toml index dd2691e044..3a6eabc898 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,3 +1,3 @@ [toolchain] -channel = "1.81.0" +channel = "1.83.0" components = ["cargo", "clippy", "rust-std", "rustc"] From 6e5813dfb3239c78b878d341bbedd1d805388422 Mon Sep 17 00:00:00 2001 From: ethanoroshiba Date: Fri, 6 Dec 2024 11:04:24 -0600 Subject: [PATCH 02/10] update changelogs, add issue links --- crates/astria-bridge-withdrawer/CHANGELOG.md | 4 ++++ crates/astria-cli/CHANGELOG.md | 1 + crates/astria-composer/CHANGELOG.md | 1 + crates/astria-conductor/CHANGELOG.md | 1 + crates/astria-conductor/src/executor/mod.rs | 2 +- crates/astria-core/CHANGELOG.md | 1 + crates/astria-sequencer-relayer/CHANGELOG.md | 1 + crates/astria-sequencer-relayer/src/relayer/write/mod.rs | 2 +- .../tests/blackbox/helpers/mock_sequencer_server.rs | 2 +- crates/astria-sequencer/CHANGELOG.md | 1 + 10 files changed, 13 insertions(+), 3 deletions(-) diff --git a/crates/astria-bridge-withdrawer/CHANGELOG.md b/crates/astria-bridge-withdrawer/CHANGELOG.md index e298881919..d21d4ee034 100644 --- a/crates/astria-bridge-withdrawer/CHANGELOG.md +++ b/crates/astria-bridge-withdrawer/CHANGELOG.md @@ -11,6 +11,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [1.0.1] - 2024-11-01 +### Changed + +- Bump MSRV to 1.83.0 [#1857](https://github.com/astriaorg/astria/pull/1857). + ### Fixed - Set `batch_total_settled_value` metric to 0 when no withdrawals are settled [#1778](https://github.com/astriaorg/astria/pull/1768) diff --git a/crates/astria-cli/CHANGELOG.md b/crates/astria-cli/CHANGELOG.md index 8bb8637b8f..8508558da3 100644 --- a/crates/astria-cli/CHANGELOG.md +++ b/crates/astria-cli/CHANGELOG.md @@ -20,6 +20,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +- Bump MSRV to 1.83.0 [#1857](https://github.com/astriaorg/astria/pull/1857). - Removed default values from `--sequencer.chain-id` and `--sequencer-url` arguments [#1792](https://github.com/astriaorg/astria/pull/1792) diff --git a/crates/astria-composer/CHANGELOG.md b/crates/astria-composer/CHANGELOG.md index e430c3d066..dd50bdc9f8 100644 --- a/crates/astria-composer/CHANGELOG.md +++ b/crates/astria-composer/CHANGELOG.md @@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +- Bump MSRV to 1.83.0 [#1857](https://github.com/astriaorg/astria/pull/1857). - Bump penumbra dependencies [#1740](https://github.com/astriaorg/astria/pull/1740). ## [1.0.0-rc.2] - 2024-10-23 diff --git a/crates/astria-conductor/CHANGELOG.md b/crates/astria-conductor/CHANGELOG.md index eb75e304d5..62a9c54424 100644 --- a/crates/astria-conductor/CHANGELOG.md +++ b/crates/astria-conductor/CHANGELOG.md @@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +- Bump MSRV to 1.83.0 [#1857](https://github.com/astriaorg/astria/pull/1857). - Bump penumbra dependencies [#1740](https://github.com/astriaorg/astria/pull/1740). ## [1.0.0-rc.2] - 2024-10-23 diff --git a/crates/astria-conductor/src/executor/mod.rs b/crates/astria-conductor/src/executor/mod.rs index 1d5bed113e..bbd2ad64ed 100644 --- a/crates/astria-conductor/src/executor/mod.rs +++ b/crates/astria-conductor/src/executor/mod.rs @@ -153,7 +153,7 @@ impl Handle { Ok(()) } - // TODO(search_here): box the large variant to avoid large error size + // TODO(https://github.com/astriaorg/astria/issues/1858): box the large variant to avoid large error size #[expect(clippy::result_large_err, reason = "should be fixed")] pub(crate) fn try_send_firm_block( &self, diff --git a/crates/astria-core/CHANGELOG.md b/crates/astria-core/CHANGELOG.md index 0477f1767c..a563133ad1 100644 --- a/crates/astria-core/CHANGELOG.md +++ b/crates/astria-core/CHANGELOG.md @@ -18,6 +18,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +- Bump MSRV to 1.83.0 [#1857](https://github.com/astriaorg/astria/pull/1857). - Moved `astria_core::crypto` to `astria-core-crypto` and reexported `astria_core_crypto as crypto` (this change is transparent) [#1800](https://github.com/astriaorg/astria/pull/1800/) diff --git a/crates/astria-sequencer-relayer/CHANGELOG.md b/crates/astria-sequencer-relayer/CHANGELOG.md index 63d39156ac..b4e9a8e29a 100644 --- a/crates/astria-sequencer-relayer/CHANGELOG.md +++ b/crates/astria-sequencer-relayer/CHANGELOG.md @@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +- Bump MSRV to 1.83.0 [#1857](https://github.com/astriaorg/astria/pull/1857). - Bump penumbra dependencies [#1740](https://github.com/astriaorg/astria/pull/1740). ## [1.0.0-rc.2] - 2024-10-23 diff --git a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs index 81db1ff239..c967ab5fbe 100644 --- a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs +++ b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs @@ -93,7 +93,7 @@ impl BlobSubmitterHandle { /// Send a block to the blob submitter immediately. /// /// This is a thin wrapper around [`mpsc::Sender::try_send`]. - // TODO(search_here) + // TODO(https://github.com/astriaorg/astria/issues/1860) #[expect(clippy::result_large_err, reason = "should be fixed")] pub(super) fn try_send( &self, diff --git a/crates/astria-sequencer-relayer/tests/blackbox/helpers/mock_sequencer_server.rs b/crates/astria-sequencer-relayer/tests/blackbox/helpers/mock_sequencer_server.rs index a12b02e52b..9a1405bc2a 100644 --- a/crates/astria-sequencer-relayer/tests/blackbox/helpers/mock_sequencer_server.rs +++ b/crates/astria-sequencer-relayer/tests/blackbox/helpers/mock_sequencer_server.rs @@ -96,7 +96,7 @@ impl MockSequencerServer { } } -// TODO(search_here): box enum variants to avoid large sizes +// TODO(https://github.com/astriaorg/astria/issues/1859): box enum variants to avoid large sizes #[expect(clippy::large_enum_variant, reason = "should be fixed")] pub enum SequencerBlockToMount { GoodAtHeight(u32), diff --git a/crates/astria-sequencer/CHANGELOG.md b/crates/astria-sequencer/CHANGELOG.md index 3fffea9a55..dc18afbc3d 100644 --- a/crates/astria-sequencer/CHANGELOG.md +++ b/crates/astria-sequencer/CHANGELOG.md @@ -11,6 +11,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changed +- Bump MSRV to 1.83.0 [#1857](https://github.com/astriaorg/astria/pull/1857). - Index all event attributes [#1786](https://github.com/astriaorg/astria/pull/1786). - Consolidate action handling to single module [#1759](https://github.com/astriaorg/astria/pull/1759). - Ensure all deposit assets are trace prefixed [#1807](https://github.com/astriaorg/astria/pull/1807). From d6accdc0752a1e1ef3700a386fc06d5c2bfee89a Mon Sep 17 00:00:00 2001 From: ethanoroshiba Date: Wed, 11 Dec 2024 10:22:37 -0600 Subject: [PATCH 03/10] ci update, rust fmt changes --- .github/workflows/lint.yml | 4 +- crates/astria-conductor/src/block_cache.rs | 4 +- .../src/celestia/block_verifier.rs | 10 +- crates/astria-core/src/primitive/v1/u128.rs | 20 +-- crates/astria-merkle/src/audit.rs | 40 +++-- crates/astria-merkle/src/lib.rs | 22 ++- .../astria-sequencer-client/src/tests/http.rs | 16 +- .../impls/bridge_sudo_change.rs | 14 +- .../src/action_handler/mod.rs | 2 +- .../src/app/benchmark_and_test_utils.rs | 4 +- .../src/app/tests_app/mempool.rs | 84 +++++----- .../astria-sequencer/src/app/tests_app/mod.rs | 110 ++++++------- .../src/app/tests_breaking_changes.rs | 54 +++---- .../src/app/tests_execute_transaction.rs | 150 ++++++++---------- .../src/bridge/storage/keys.rs | 6 +- crates/astria-sequencer/src/fees/tests.rs | 82 +++++----- crates/astria-sequencer/src/mempool/mod.rs | 10 +- .../src/mempool/transactions_container.rs | 10 +- .../astria-sequencer/src/service/consensus.rs | 62 ++++---- .../src/transaction/checks.rs | 9 +- crates/astria-test-utils/src/mock/geth.rs | 2 +- justfile | 4 +- rustfmt.toml | 2 +- 23 files changed, 307 insertions(+), 414 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 4388d2e707..2f676e8cd6 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -70,10 +70,10 @@ jobs: - uses: actions/checkout@v4 - uses: dtolnay/rust-toolchain@master with: - toolchain: nightly-2024-09-15 + toolchain: nightly-2024-10-11 components: rustfmt - name: run rustfmt - run: cargo +nightly-2024-09-15 fmt --all -- --check + run: cargo +nightly-2024-10-11 fmt --all -- --check toml: runs-on: ubuntu-22.04 diff --git a/crates/astria-conductor/src/block_cache.rs b/crates/astria-conductor/src/block_cache.rs index 2f6e1b8046..799b31eb2d 100644 --- a/crates/astria-conductor/src/block_cache.rs +++ b/crates/astria-conductor/src/block_cache.rs @@ -105,7 +105,9 @@ impl BlockCache { pub(crate) enum Error { #[error("block at sequencer height {height} already in cache")] Occupied { height: u64 }, - #[error("block too old: expect sequencer height {current_height} or newer, got {block_height}")] + #[error( + "block too old: expect sequencer height {current_height} or newer, got {block_height}" + )] Old { block_height: u64, current_height: u64, diff --git a/crates/astria-conductor/src/celestia/block_verifier.rs b/crates/astria-conductor/src/celestia/block_verifier.rs index 7b580b954e..b7d9e206ea 100644 --- a/crates/astria-conductor/src/celestia/block_verifier.rs +++ b/crates/astria-conductor/src/celestia/block_verifier.rs @@ -529,11 +529,9 @@ mod tests { &tendermint::chain::Id::try_from("test-chain-g3ejvw").unwrap(), ); assert!(result.is_err()); - assert!( - result - .unwrap_err() - .to_string() - .contains("commit voting power is less than 2/3 of total voting power") - ); + assert!(result + .unwrap_err() + .to_string() + .contains("commit voting power is less than 2/3 of total voting power")); } } diff --git a/crates/astria-core/src/primitive/v1/u128.rs b/crates/astria-core/src/primitive/v1/u128.rs index 581f5b5ecc..e6a0edd145 100644 --- a/crates/astria-core/src/primitive/v1/u128.rs +++ b/crates/astria-core/src/primitive/v1/u128.rs @@ -3,24 +3,8 @@ use crate::generated::astria::primitive::v1::Uint128; impl From for Uint128 { fn from(primitive: u128) -> Self { - let [ - h0, - h1, - h2, - h3, - h4, - h5, - h6, - h7, - l0, - l1, - l2, - l3, - l4, - l5, - l6, - l7, - ] = primitive.to_be_bytes(); + let [h0, h1, h2, h3, h4, h5, h6, h7, l0, l1, l2, l3, l4, l5, l6, l7] = + primitive.to_be_bytes(); let lo = u64::from_be_bytes([l0, l1, l2, l3, l4, l5, l6, l7]); let hi = u64::from_be_bytes([h0, h1, h2, h3, h4, h5, h6, h7]); Self { diff --git a/crates/astria-merkle/src/audit.rs b/crates/astria-merkle/src/audit.rs index b8b99329fd..0963f72230 100644 --- a/crates/astria-merkle/src/audit.rs +++ b/crates/astria-merkle/src/audit.rs @@ -189,16 +189,14 @@ impl Audit<'_, WithLeafHash, WithRoot> { /// tree.build_leaf().write(&[4, 2]).write(b"answer"); /// let root = tree.root(); /// let proof = tree.construct_proof(3).expect("leaf 4 is inside the tree"); - /// assert!( - /// proof - /// .audit() - /// .with_root(root) - /// .with_leaf_builder() - /// .write(&[4, 2]) - /// .write(b"answer") - /// .finish_leaf() - /// .perform() - /// ); + /// assert!(proof + /// .audit() + /// .with_root(root) + /// .with_leaf_builder() + /// .write(&[4, 2]) + /// .write(b"answer") + /// .finish_leaf() + /// .perform()); /// ``` #[must_use = "verify the audit result"] pub fn perform(&self) -> bool { @@ -497,18 +495,16 @@ impl Proof { /// .write(b"42"); /// let root = tree.root(); /// let proof = tree.construct_proof(3).expect("leaf 4 is in the tree"); - /// assert!( - /// proof - /// .audit() - /// .with_root(root) - /// .with_leaf_builder() - /// .write(&[42; 1]) - /// .write(&[1, 1]) - /// .write(&vec![42; 3]) - /// .write(b"42") - /// .finish_leaf() - /// .perform() - /// ); + /// assert!(proof + /// .audit() + /// .with_root(root) + /// .with_leaf_builder() + /// .write(&[42; 1]) + /// .write(&[1, 1]) + /// .write(&vec![42; 3]) + /// .write(b"42") + /// .finish_leaf() + /// .perform()); /// ``` #[must_use = "an audit must be performed to be useful"] pub fn audit(&self) -> Audit { diff --git a/crates/astria-merkle/src/lib.rs b/crates/astria-merkle/src/lib.rs index 2da5206752..4d89f12955 100644 --- a/crates/astria-merkle/src/lib.rs +++ b/crates/astria-merkle/src/lib.rs @@ -39,18 +39,16 @@ //! .construct_proof(4) //! .expect("leaf 5 must be inside the tree"); //! -//! assert!( -//! proof -//! .audit() -//! .with_root(root) -//! .with_leaf_builder() -//! .write(&[42; 1]) -//! .write(&[1, 1]) -//! .write(&vec![42; 3]) -//! .write(b"42") -//! .finish_leaf() -//! .perform() -//! ); +//! assert!(proof +//! .audit() +//! .with_root(root) +//! .with_leaf_builder() +//! .write(&[42; 1]) +//! .write(&[1, 1]) +//! .write(&vec![42; 3]) +//! .write(b"42") +//! .finish_leaf() +//! .perform()); //! ``` //! //! # Indexing scheme diff --git a/crates/astria-sequencer-client/src/tests/http.rs b/crates/astria-sequencer-client/src/tests/http.rs index 92f02124cd..9f0cca97da 100644 --- a/crates/astria-sequencer-client/src/tests/http.rs +++ b/crates/astria-sequencer-client/src/tests/http.rs @@ -151,15 +151,13 @@ fn create_signed_transaction() -> Transaction { .unwrap(); let alice_key = SigningKey::from(alice_secret_bytes); - let actions = vec![ - Transfer { - to: bob_address(), - amount: 333_333, - asset: "nria".parse().unwrap(), - fee_asset: "nria".parse().unwrap(), - } - .into(), - ]; + let actions = vec![Transfer { + to: bob_address(), + amount: 333_333, + asset: "nria".parse().unwrap(), + fee_asset: "nria".parse().unwrap(), + } + .into()]; TransactionBody::builder() .actions(actions) .chain_id("test") diff --git a/crates/astria-sequencer/src/action_handler/impls/bridge_sudo_change.rs b/crates/astria-sequencer/src/action_handler/impls/bridge_sudo_change.rs index 6bdb3ee4f4..a5d64ee703 100644 --- a/crates/astria-sequencer/src/action_handler/impls/bridge_sudo_change.rs +++ b/crates/astria-sequencer/src/action_handler/impls/bridge_sudo_change.rs @@ -140,14 +140,12 @@ mod tests { fee_asset: asset.clone(), }; - assert!( - action - .check_and_execute(state) - .await - .unwrap_err() - .to_string() - .contains("unauthorized for bridge sudo change action") - ); + assert!(action + .check_and_execute(state) + .await + .unwrap_err() + .to_string() + .contains("unauthorized for bridge sudo change action")); } #[tokio::test] diff --git a/crates/astria-sequencer/src/action_handler/mod.rs b/crates/astria-sequencer/src/action_handler/mod.rs index 09bde22b0e..0921cb82ec 100644 --- a/crates/astria-sequencer/src/action_handler/mod.rs +++ b/crates/astria-sequencer/src/action_handler/mod.rs @@ -45,7 +45,7 @@ pub(crate) trait ActionHandler { async fn check_stateless(&self) -> astria_eyre::eyre::Result<()>; async fn check_and_execute(&self, mut state: S) - -> astria_eyre::eyre::Result<()>; + -> astria_eyre::eyre::Result<()>; } async fn execute_transfer( diff --git a/crates/astria-sequencer/src/app/benchmark_and_test_utils.rs b/crates/astria-sequencer/src/app/benchmark_and_test_utils.rs index e2852fd225..79e8a896ea 100644 --- a/crates/astria-sequencer/src/app/benchmark_and_test_utils.rs +++ b/crates/astria-sequencer/src/app/benchmark_and_test_utils.rs @@ -129,8 +129,8 @@ pub(crate) fn default_fees() -> astria_core::protocol::genesis::v1::GenesisFees } } -pub(crate) fn proto_genesis_state() --> astria_core::generated::astria::protocol::genesis::v1::GenesisAppState { +pub(crate) fn proto_genesis_state( +) -> astria_core::generated::astria::protocol::genesis::v1::GenesisAppState { use astria_core::generated::astria::protocol::genesis::v1::{ GenesisAppState, IbcParameters, diff --git a/crates/astria-sequencer/src/app/tests_app/mempool.rs b/crates/astria-sequencer/src/app/tests_app/mempool.rs index adc304d585..f08d10d97e 100644 --- a/crates/astria-sequencer/src/app/tests_app/mempool.rs +++ b/crates/astria-sequencer/src/app/tests_app/mempool.rs @@ -54,13 +54,11 @@ async fn trigger_cleaning() { // create tx which will cause mempool cleaning flag to be set let tx_trigger = TransactionBody::builder() - .actions(vec![ - FeeChange::Transfer(TransferFeeComponents { - base: 10, - multiplier: 0, - }) - .into(), - ]) + .actions(vec![FeeChange::Transfer(TransferFeeComponents { + base: 10, + multiplier: 0, + }) + .into()]) .chain_id("test") .try_build() .unwrap() @@ -150,13 +148,11 @@ async fn do_not_trigger_cleaning() { // create tx which will fail execution and not trigger flag // (wrong sudo signer) let tx_fail = TransactionBody::builder() - .actions(vec![ - FeeChange::Transfer(TransferFeeComponents { - base: 10, - multiplier: 0, - }) - .into(), - ]) + .actions(vec![FeeChange::Transfer(TransferFeeComponents { + base: 10, + multiplier: 0, + }) + .into()]) .chain_id("test") .try_build() .unwrap() @@ -221,15 +217,13 @@ async fn maintenance_recosting_promotes() { // create tx which will not be included in block due to // having insufficient funds (transaction will be recosted to enable) let tx_fail_recost_funds = TransactionBody::builder() - .actions(vec![ - Transfer { - to: astria_address_from_hex_string(CAROL_ADDRESS), - amount: 1u128, - asset: nria().into(), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![Transfer { + to: astria_address_from_hex_string(CAROL_ADDRESS), + amount: 1u128, + asset: nria().into(), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap() @@ -251,13 +245,11 @@ async fn maintenance_recosting_promotes() { // create tx which will enable recost tx to pass let tx_recost = TransactionBody::builder() - .actions(vec![ - FeeChange::Transfer(TransferFeeComponents { - base: 10, - multiplier: 0, - }) - .into(), - ]) + .actions(vec![FeeChange::Transfer(TransferFeeComponents { + base: 10, + multiplier: 0, + }) + .into()]) .chain_id("test") .try_build() .unwrap() @@ -401,15 +393,13 @@ async fn maintenance_funds_added_promotes() { // create tx that will not be included in block due to // having no funds (will be sent transfer to then enable) let tx_fail_transfer_funds = TransactionBody::builder() - .actions(vec![ - Transfer { - to: astria_address_from_hex_string(BOB_ADDRESS), - amount: 10u128, - asset: nria().into(), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![Transfer { + to: astria_address_from_hex_string(BOB_ADDRESS), + amount: 10u128, + asset: nria().into(), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap() @@ -431,15 +421,13 @@ async fn maintenance_funds_added_promotes() { // create tx which will enable no funds to pass let tx_fund = TransactionBody::builder() - .actions(vec![ - Transfer { - to: astria_address_from_hex_string(CAROL_ADDRESS), - amount: 22u128, - asset: nria().into(), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![Transfer { + to: astria_address_from_hex_string(CAROL_ADDRESS), + amount: 22u128, + asset: nria().into(), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap() diff --git a/crates/astria-sequencer/src/app/tests_app/mod.rs b/crates/astria-sequencer/src/app/tests_app/mod.rs index b91e107105..25e3253c63 100644 --- a/crates/astria-sequencer/src/app/tests_app/mod.rs +++ b/crates/astria-sequencer/src/app/tests_app/mod.rs @@ -244,15 +244,13 @@ async fn app_transfer_block_fees_to_sudo() { let bob_address = astria_address_from_hex_string(BOB_ADDRESS); let amount = 333_333; let tx = TransactionBody::builder() - .actions(vec![ - Transfer { - to: bob_address, - amount, - asset: nria().into(), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![Transfer { + to: bob_address, + amount, + asset: nria().into(), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap(); @@ -589,28 +587,24 @@ async fn app_prepare_proposal_cometbft_max_bytes_overflow_ok() { // create txs which will cause cometBFT overflow let alice = get_alice_signing_key(); let tx_pass = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from([1u8; 32]), - data: Bytes::copy_from_slice(&[1u8; 100_000]), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from([1u8; 32]), + data: Bytes::copy_from_slice(&[1u8; 100_000]), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap() .sign(&alice); let tx_overflow = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from([1u8; 32]), - data: Bytes::copy_from_slice(&[1u8; 100_000]), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from([1u8; 32]), + data: Bytes::copy_from_slice(&[1u8; 100_000]), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .nonce(1) .try_build() @@ -679,27 +673,23 @@ async fn app_prepare_proposal_sequencer_max_bytes_overflow_ok() { // create txs which will cause sequencer overflow (max is currently 256_000 bytes) let alice = get_alice_signing_key(); let tx_pass = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from([1u8; 32]), - data: Bytes::copy_from_slice(&[1u8; 200_000]), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from([1u8; 32]), + data: Bytes::copy_from_slice(&[1u8; 200_000]), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap() .sign(&alice); let tx_overflow = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from([1u8; 32]), - data: Bytes::copy_from_slice(&[1u8; 100_000]), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from([1u8; 32]), + data: Bytes::copy_from_slice(&[1u8; 100_000]), + fee_asset: nria().into(), + } + .into()]) .nonce(1) .chain_id("test") .try_build() @@ -768,27 +758,23 @@ async fn app_process_proposal_sequencer_max_bytes_overflow_fail() { // create txs which will cause sequencer overflow (max is currently 256_000 bytes) let alice = get_alice_signing_key(); let tx_pass = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from([1u8; 32]), - data: Bytes::copy_from_slice(&[1u8; 200_000]), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from([1u8; 32]), + data: Bytes::copy_from_slice(&[1u8; 200_000]), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap() .sign(&alice); let tx_overflow = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from([1u8; 32]), - data: Bytes::copy_from_slice(&[1u8; 100_000]), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from([1u8; 32]), + data: Bytes::copy_from_slice(&[1u8; 100_000]), + fee_asset: nria().into(), + } + .into()]) .nonce(1) .chain_id("test") .try_build() @@ -834,12 +820,10 @@ async fn app_process_proposal_transaction_fails_to_execute_fails() { // create txs which will cause transaction execution failure let alice = get_alice_signing_key(); let tx_fail = TransactionBody::builder() - .actions(vec![ - SudoAddressChange { - new_address: astria_address_from_hex_string(BOB_ADDRESS), - } - .into(), - ]) + .actions(vec![SudoAddressChange { + new_address: astria_address_from_hex_string(BOB_ADDRESS), + } + .into()]) .chain_id("test") .try_build() .unwrap() diff --git a/crates/astria-sequencer/src/app/tests_breaking_changes.rs b/crates/astria-sequencer/src/app/tests_breaking_changes.rs index dd1c14c4d4..33553e77d7 100644 --- a/crates/astria-sequencer/src/app/tests_breaking_changes.rs +++ b/crates/astria-sequencer/src/app/tests_breaking_changes.rs @@ -259,24 +259,20 @@ async fn app_execute_transaction_with_every_action_snapshot() { .unwrap(); let tx_sudo_ibc = TransactionBody::builder() - .actions(vec![ - IbcSudoChange { - new_address: bob_address, - } - .into(), - ]) + .actions(vec![IbcSudoChange { + new_address: bob_address, + } + .into()]) .nonce(2) .chain_id("test") .try_build() .unwrap(); let tx_sudo = TransactionBody::builder() - .actions(vec![ - SudoAddressChange { - new_address: bob_address, - } - .into(), - ]) + .actions(vec![SudoAddressChange { + new_address: bob_address, + } + .into()]) .nonce(3) .chain_id("test") .try_build() @@ -299,16 +295,14 @@ async fn app_execute_transaction_with_every_action_snapshot() { app.execute_transaction(signed_tx_sudo).await.unwrap(); let tx = TransactionBody::builder() - .actions(vec![ - InitBridgeAccount { - rollup_id, - asset: nria().into(), - fee_asset: nria().into(), - sudo_address: None, - withdrawer_address: None, - } - .into(), - ]) + .actions(vec![InitBridgeAccount { + rollup_id, + asset: nria().into(), + fee_asset: nria().into(), + sudo_address: None, + withdrawer_address: None, + } + .into()]) .chain_id("test") .try_build() .unwrap(); @@ -345,15 +339,13 @@ async fn app_execute_transaction_with_every_action_snapshot() { app.execute_transaction(signed_tx).await.unwrap(); let tx_bridge = TransactionBody::builder() - .actions(vec![ - BridgeSudoChange { - bridge_address, - new_sudo_address: Some(bob_address), - new_withdrawer_address: Some(bob_address), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![BridgeSudoChange { + bridge_address, + new_sudo_address: Some(bob_address), + new_withdrawer_address: Some(bob_address), + fee_asset: nria().into(), + } + .into()]) .nonce(2) .chain_id("test") .try_build() diff --git a/crates/astria-sequencer/src/app/tests_execute_transaction.rs b/crates/astria-sequencer/src/app/tests_execute_transaction.rs index 011d789270..86991412e7 100644 --- a/crates/astria-sequencer/src/app/tests_execute_transaction.rs +++ b/crates/astria-sequencer/src/app/tests_execute_transaction.rs @@ -116,15 +116,13 @@ async fn app_execute_transaction_transfer() { let bob_address = astria_address_from_hex_string(BOB_ADDRESS); let value = 333_333; let tx = TransactionBody::builder() - .actions(vec![ - Transfer { - to: bob_address, - amount: value, - asset: nria().into(), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![Transfer { + to: bob_address, + amount: value, + asset: nria().into(), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap(); @@ -180,15 +178,13 @@ async fn app_execute_transaction_transfer_not_native_token() { // transfer funds from Alice to Bob; use native token for fee payment let bob_address = astria_address_from_hex_string(BOB_ADDRESS); let tx = TransactionBody::builder() - .actions(vec![ - Transfer { - to: bob_address, - amount: value, - asset: test_asset(), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![Transfer { + to: bob_address, + amount: value, + asset: test_asset(), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap(); @@ -252,15 +248,13 @@ async fn app_execute_transaction_transfer_balance_too_low_for_fee() { // 0-value transfer; only fee is deducted from sender let tx = TransactionBody::builder() - .actions(vec![ - Transfer { - to: bob, - amount: 0, - asset: nria().into(), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![Transfer { + to: bob, + amount: 0, + asset: nria().into(), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap(); @@ -293,14 +287,12 @@ async fn app_execute_transaction_sequence() { let fee = calculate_rollup_data_submission_fee_from_state(&data, &app.state).await; let tx = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), - data, - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), + data, + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap(); @@ -329,14 +321,12 @@ async fn app_execute_transaction_invalid_fee_asset() { let data = Bytes::from_static(b"hello world"); let tx = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), - data, - fee_asset: test_asset(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), + data, + fee_asset: test_asset(), + } + .into()]) .chain_id("test") .try_build() .unwrap(); @@ -827,14 +817,12 @@ async fn app_execute_transaction_invalid_nonce() { let data = Bytes::from_static(b"hello world"); let tx = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), - data, - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), + data, + fee_asset: nria().into(), + } + .into()]) .nonce(1) .chain_id("test") .try_build() @@ -876,14 +864,12 @@ async fn app_execute_transaction_invalid_chain_id() { // create tx with invalid nonce 1 let data = Bytes::from_static(b"hello world"); let tx = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), - data, - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), + data, + fee_asset: nria().into(), + } + .into()]) .chain_id("wrong-chain") .try_build() .unwrap(); @@ -931,15 +917,13 @@ async fn app_stateful_check_fails_insufficient_total_balance() { // transfer just enough to cover single sequence fee with data let signed_tx = TransactionBody::builder() - .actions(vec![ - Transfer { - to: keypair_address, - amount: fee, - asset: nria().into(), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![Transfer { + to: keypair_address, + amount: fee, + asset: nria().into(), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap() @@ -977,14 +961,12 @@ async fn app_stateful_check_fails_insufficient_total_balance() { // build single transfer to see passes let signed_tx_pass = TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), - data, - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), + data, + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap() @@ -1261,15 +1243,13 @@ async fn transaction_execution_records_fee_event() { let bob_address = astria_address_from_hex_string(BOB_ADDRESS); let value = 333_333; let tx = TransactionBody::builder() - .actions(vec![ - Transfer { - to: bob_address, - amount: value, - asset: nria().into(), - fee_asset: nria().into(), - } - .into(), - ]) + .actions(vec![Transfer { + to: bob_address, + amount: value, + asset: nria().into(), + fee_asset: nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap(); diff --git a/crates/astria-sequencer/src/bridge/storage/keys.rs b/crates/astria-sequencer/src/bridge/storage/keys.rs index a8618637b4..a98181ff10 100644 --- a/crates/astria-sequencer/src/bridge/storage/keys.rs +++ b/crates/astria-sequencer/src/bridge/storage/keys.rs @@ -119,10 +119,8 @@ mod tests { fn bridge_account_prefix_should_be_prefix_of_relevant_keys() { assert!(rollup_id(&address()).starts_with(BRIDGE_ACCOUNT_PREFIX)); assert!(asset_id(&address()).starts_with(BRIDGE_ACCOUNT_PREFIX)); - assert!( - bridge_account_withdrawal_event(&address(), "the-event") - .starts_with(BRIDGE_ACCOUNT_PREFIX) - ); + assert!(bridge_account_withdrawal_event(&address(), "the-event") + .starts_with(BRIDGE_ACCOUNT_PREFIX)); assert!( last_transaction_id_for_bridge_account(&address()).starts_with(BRIDGE_ACCOUNT_PREFIX) ); diff --git a/crates/astria-sequencer/src/fees/tests.rs b/crates/astria-sequencer/src/fees/tests.rs index ca43c492c9..9d594ea5a4 100644 --- a/crates/astria-sequencer/src/fees/tests.rs +++ b/crates/astria-sequencer/src/fees/tests.rs @@ -88,15 +88,13 @@ async fn ensure_correct_block_fees_transfer() { let alice = get_alice_signing_key(); let bob_address = astria_address_from_hex_string(BOB_ADDRESS); - let actions = vec![ - Transfer { - to: bob_address, - amount: 1000, - asset: nria().into(), - fee_asset: nria().into(), - } - .into(), - ]; + let actions = vec![Transfer { + to: bob_address, + amount: 1000, + asset: nria().into(), + fee_asset: nria().into(), + } + .into()]; let tx = TransactionBody::builder() .actions(actions) @@ -129,14 +127,12 @@ async fn ensure_correct_block_fees_sequence() { let alice = get_alice_signing_key(); let data = b"hello world".to_vec(); - let actions = vec![ - RollupDataSubmission { - rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), - data: data.clone().into(), - fee_asset: nria().into(), - } - .into(), - ]; + let actions = vec![RollupDataSubmission { + rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), + data: data.clone().into(), + fee_asset: nria().into(), + } + .into()]; let tx = TransactionBody::builder() .actions(actions) @@ -169,16 +165,14 @@ async fn ensure_correct_block_fees_init_bridge_acct() { let alice = get_alice_signing_key(); - let actions = vec![ - InitBridgeAccount { - rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), - asset: nria().into(), - fee_asset: nria().into(), - sudo_address: None, - withdrawer_address: None, - } - .into(), - ]; + let actions = vec![InitBridgeAccount { + rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), + asset: nria().into(), + fee_asset: nria().into(), + sudo_address: None, + withdrawer_address: None, + } + .into()]; let tx = TransactionBody::builder() .actions(actions) @@ -230,16 +224,14 @@ async fn ensure_correct_block_fees_bridge_lock() { .put_bridge_account_ibc_asset(&bridge_address, nria()) .unwrap(); - let actions = vec![ - BridgeLock { - to: bridge_address, - amount: 1, - asset: nria().into(), - fee_asset: nria().into(), - destination_chain_address: rollup_id.to_string(), - } - .into(), - ]; + let actions = vec![BridgeLock { + to: bridge_address, + amount: 1, + asset: nria().into(), + fee_asset: nria().into(), + destination_chain_address: rollup_id.to_string(), + } + .into()]; let tx = TransactionBody::builder() .actions(actions) @@ -296,15 +288,13 @@ async fn ensure_correct_block_fees_bridge_sudo_change() { .await .unwrap(); - let actions = vec![ - BridgeSudoChange { - bridge_address, - new_sudo_address: None, - new_withdrawer_address: None, - fee_asset: nria().into(), - } - .into(), - ]; + let actions = vec![BridgeSudoChange { + bridge_address, + new_sudo_address: None, + new_withdrawer_address: None, + fee_asset: nria().into(), + } + .into()]; let tx = TransactionBody::builder() .actions(actions) diff --git a/crates/astria-sequencer/src/mempool/mod.rs b/crates/astria-sequencer/src/mempool/mod.rs index 2271f281dd..c266f7b685 100644 --- a/crates/astria-sequencer/src/mempool/mod.rs +++ b/crates/astria-sequencer/src/mempool/mod.rs @@ -1040,12 +1040,10 @@ mod tests { ); // Check the pending nonce for an address with no txs is `None`. - assert!( - mempool - .pending_nonce(astria_address_from_hex_string(CAROL_ADDRESS).as_bytes()) - .await - .is_none() - ); + assert!(mempool + .pending_nonce(astria_address_from_hex_string(CAROL_ADDRESS).as_bytes()) + .await + .is_none()); } #[tokio::test] diff --git a/crates/astria-sequencer/src/mempool/transactions_container.rs b/crates/astria-sequencer/src/mempool/transactions_container.rs index 95d17b00c1..0ffdf5461f 100644 --- a/crates/astria-sequencer/src/mempool/transactions_container.rs +++ b/crates/astria-sequencer/src/mempool/transactions_container.rs @@ -958,12 +958,10 @@ mod tests { let ttx = MockTTXBuilder::new().nonce(0).build(); let priority = ttx.priority(1); - assert!( - priority - .unwrap_err() - .to_string() - .contains("less than current account nonce") - ); + assert!(priority + .unwrap_err() + .to_string() + .contains("less than current account nonce")); } // From https://doc.rust-lang.org/std/cmp/trait.PartialOrd.html diff --git a/crates/astria-sequencer/src/service/consensus.rs b/crates/astria-sequencer/src/service/consensus.rs index a0b6a4a5ae..d46941c1d3 100644 --- a/crates/astria-sequencer/src/service/consensus.rs +++ b/crates/astria-sequencer/src/service/consensus.rs @@ -238,14 +238,12 @@ mod tests { fn make_unsigned_tx() -> TransactionBody { TransactionBody::builder() - .actions(vec![ - RollupDataSubmission { - rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), - data: Bytes::from_static(b"hello world"), - fee_asset: crate::benchmark_and_test_utils::nria().into(), - } - .into(), - ]) + .actions(vec![RollupDataSubmission { + rollup_id: RollupId::from_unhashed_bytes(b"testchainid"), + data: Bytes::from_static(b"hello world"), + fee_asset: crate::benchmark_and_test_utils::nria().into(), + } + .into()]) .chain_id("test") .try_build() .unwrap() @@ -340,30 +338,26 @@ mod tests { async fn process_proposal_fail_missing_action_commitment() { let (mut consensus_service, _) = new_consensus_service(None).await; let process_proposal = new_process_proposal_request(vec![]); - assert!( - consensus_service - .handle_process_proposal(process_proposal) - .await - .err() - .unwrap() - .to_string() - .contains("no transaction commitment in proposal") - ); + assert!(consensus_service + .handle_process_proposal(process_proposal) + .await + .err() + .unwrap() + .to_string() + .contains("no transaction commitment in proposal")); } #[tokio::test] async fn process_proposal_fail_wrong_commitment_length() { let (mut consensus_service, _) = new_consensus_service(None).await; let process_proposal = new_process_proposal_request(vec![[0u8; 16].to_vec().into()]); - assert!( - consensus_service - .handle_process_proposal(process_proposal) - .await - .err() - .unwrap() - .to_string() - .contains("transaction commitment must be 32 bytes") - ); + assert!(consensus_service + .handle_process_proposal(process_proposal) + .await + .err() + .unwrap() + .to_string() + .contains("transaction commitment must be 32 bytes")); } #[tokio::test] @@ -373,15 +367,13 @@ mod tests { [99u8; 32].to_vec().into(), [99u8; 32].to_vec().into(), ]); - assert!( - consensus_service - .handle_process_proposal(process_proposal) - .await - .err() - .unwrap() - .to_string() - .contains("transaction commitment does not match expected") - ); + assert!(consensus_service + .handle_process_proposal(process_proposal) + .await + .err() + .unwrap() + .to_string() + .contains("transaction commitment does not match expected")); } #[tokio::test] diff --git a/crates/astria-sequencer/src/transaction/checks.rs b/crates/astria-sequencer/src/transaction/checks.rs index 3e00c7b0f4..e406525abd 100644 --- a/crates/astria-sequencer/src/transaction/checks.rs +++ b/crates/astria-sequencer/src/transaction/checks.rs @@ -427,10 +427,9 @@ mod tests { .await .err() .unwrap(); - assert!( - err.root_cause() - .to_string() - .contains(&other_asset.to_ibc_prefixed().to_string()) - ); + assert!(err + .root_cause() + .to_string() + .contains(&other_asset.to_ibc_prefixed().to_string())); } } diff --git a/crates/astria-test-utils/src/mock/geth.rs b/crates/astria-test-utils/src/mock/geth.rs index 4551f6e2c7..f82da647f0 100644 --- a/crates/astria-test-utils/src/mock/geth.rs +++ b/crates/astria-test-utils/src/mock/geth.rs @@ -120,7 +120,7 @@ mod __rpc_traits { pub trait Geth { #[subscription(name = "eth_subscribe", item = Transaction, unsubscribe = "eth_unsubscribe")] async fn eth_subscribe(&self, target: String, full_txs: Option) - -> SubscriptionResult; + -> SubscriptionResult; #[method(name = "net_version")] async fn net_version(&self) -> Result; diff --git a/justfile b/justfile index e6ac8d0884..b3cdd49156 100644 --- a/justfile +++ b/justfile @@ -89,11 +89,11 @@ _fmt-all: [no-exit-message] _fmt-rust: - cargo +nightly-2024-09-15 fmt --all + cargo +nightly-2024-10-11 fmt --all [no-exit-message] _lint-rust: - cargo +nightly-2024-09-15 fmt --all -- --check + cargo +nightly-2024-10-11 fmt --all -- --check cargo clippy -- --warn clippy::pedantic cargo dylint --all diff --git a/rustfmt.toml b/rustfmt.toml index 48a4537a5f..bde71e9a14 100644 --- a/rustfmt.toml +++ b/rustfmt.toml @@ -11,7 +11,7 @@ imports_granularity = "Crate" group_imports = "StdExternalCrate" reorder_impl_items = true edition = "2021" -version = "Two" +style_edition = "2018" use_field_init_shorthand = true condense_wildcard_suffixes = true unstable_features = true From 26b19fde22c060cf55f1fa4d9d371c2dea072fff Mon Sep 17 00:00:00 2001 From: ethanoroshiba Date: Wed, 18 Dec 2024 09:35:44 -0600 Subject: [PATCH 04/10] fix custom lints --- .github/workflows/test.yml | 2 +- lint/tracing_debug_field/rust-toolchain | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 956e3a9851..01b5c8295f 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -250,7 +250,7 @@ jobs: - uses: dtolnay/rust-toolchain@master with: # This has to match `rust-toolchain` in the rust-toolchain file of the dylint lints - toolchain: nightly-2024-09-05 + toolchain: nightly-2024-10-11 components: "clippy, llvm-tools-preview, rustc-dev, rust-src" - uses: Swatinem/rust-cache@v2.7.3 with: diff --git a/lint/tracing_debug_field/rust-toolchain b/lint/tracing_debug_field/rust-toolchain index 44bc11be7c..28992a45f1 100644 --- a/lint/tracing_debug_field/rust-toolchain +++ b/lint/tracing_debug_field/rust-toolchain @@ -1,3 +1,3 @@ [toolchain] -channel = "nightly-2024-09-05" +channel = "nightly-2024-10-11" components = ["llvm-tools-preview", "rustc-dev"] From abf945535c5549a4f0d358d5e3d258602fb3957c Mon Sep 17 00:00:00 2001 From: ethanoroshiba Date: Wed, 18 Dec 2024 10:45:31 -0600 Subject: [PATCH 05/10] bump versions, remove expect attribute --- .github/workflows/test.yml | 2 +- Cargo.lock | 460 ++++++++++-------- .../src/relayer/write/mod.rs | 2 - lint/tracing_debug_field/Cargo.toml | 6 +- 4 files changed, 251 insertions(+), 219 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 01b5c8295f..2b4e6f1351 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -256,7 +256,7 @@ jobs: with: cache-provider: "buildjet" - name: install cargo-dylint and dylint-link - run: cargo install cargo-dylint@3.2.0 dylint-link@3.2.0 --locked + run: cargo install cargo-dylint@3.3.0 dylint-link@3.3.0 --locked - uses: arduino/setup-protoc@v3 with: version: "24.4" diff --git a/Cargo.lock b/Cargo.lock index 130b3bff21..f3d652e40b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1,6 +1,6 @@ # This file is automatically @generated by Cargo. # It is not intended for manual editing. -version = 3 +version = 4 [[package]] name = "Inflector" @@ -323,7 +323,7 @@ checksum = "7abe79b0e4288889c4574159ab790824d0033b9fdcb2a112a3182fac2e514565" dependencies = [ "num-bigint", "num-traits", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "syn 1.0.109", ] @@ -415,7 +415,7 @@ version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ae3281bc6d0fd7e549af32b52511e1302185bd688fd3359fa36423346ff682ea" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "syn 1.0.109", ] @@ -510,7 +510,7 @@ dependencies = [ "serde", "serde_json", "tendermint", - "thiserror", + "thiserror 1.0.63", "tracing", ] @@ -624,7 +624,7 @@ dependencies = [ "tempfile", "tendermint", "tendermint-rpc", - "thiserror", + "thiserror 1.0.63", "tokio", "tokio-stream", "tokio-test", @@ -676,7 +676,7 @@ dependencies = [ "sha2 0.10.8", "tendermint", "tendermint-rpc", - "thiserror", + "thiserror 1.0.63", "tokio", "tokio-stream", "tokio-util 0.7.11", @@ -727,7 +727,7 @@ dependencies = [ "tempfile", "tendermint", "tendermint-proto", - "thiserror", + "thiserror 1.0.63", "tonic 0.10.2", "tracing", ] @@ -738,7 +738,7 @@ version = "0.1.0" dependencies = [ "astria-core-consts", "bech32 0.11.0", - "thiserror", + "thiserror 1.0.63", ] [[package]] @@ -754,7 +754,7 @@ dependencies = [ "ed25519-consensus", "rand 0.8.5", "sha2 0.10.8", - "thiserror", + "thiserror 1.0.63", "zeroize", ] @@ -855,7 +855,7 @@ dependencies = [ "sha2 0.10.8", "tendermint", "tendermint-proto", - "thiserror", + "thiserror 1.0.63", "tokio", "tonic 0.10.2", "tower", @@ -884,7 +884,7 @@ dependencies = [ "tendermint", "tendermint-proto", "tendermint-rpc", - "thiserror", + "thiserror 1.0.63", "tokio", "tokio-stream", "tokio-test", @@ -936,7 +936,7 @@ dependencies = [ "tendermint", "tendermint-config", "tendermint-rpc", - "thiserror", + "thiserror 1.0.63", "tokio", "tokio-stream", "tokio-test", @@ -989,7 +989,7 @@ dependencies = [ "serde", "serde_json", "serde_with", - "thiserror", + "thiserror 1.0.63", "tokio", "tracing", "tracing-opentelemetry", @@ -1057,9 +1057,9 @@ version = "0.3.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -1068,9 +1068,9 @@ version = "0.1.81" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6e0c28dcc82d7c8ead5cb13beb15405b57b8546e93215673ff8ca0349a028107" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -1130,9 +1130,9 @@ version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3c87f3f15e7794432337fc718554eaa4dc8f04c9677a950ffe366f20a162ae42" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -1300,12 +1300,12 @@ dependencies = [ "lazycell", "peeking_take_while", "prettyplease", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "regex", "rustc-hash", "shlex", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -1431,7 +1431,7 @@ dependencies = [ "cid", "dashmap", "multihash", - "thiserror", + "thiserror 1.0.63", ] [[package]] @@ -1453,9 +1453,9 @@ checksum = "c3ef8005764f53cd4dca619f5bf64cafd4664dada50ece25e4d81de54c80cc0b" dependencies = [ "once_cell", "proc-macro-crate 3.1.0", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", "syn_derive", ] @@ -1497,7 +1497,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "40723b8fb387abc38f4f4a37c09073622e41dd12327033091ef8950659e6dc0c" dependencies = [ "memchr", - "regex-automata 0.4.7", + "regex-automata 0.4.9", "serde", ] @@ -1574,7 +1574,21 @@ dependencies = [ "semver 1.0.23", "serde", "serde_json", - "thiserror", + "thiserror 1.0.63", +] + +[[package]] +name = "cargo_metadata" +version = "0.19.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8769706aad5d996120af43197bf46ef6ad0fda35216b4505f926a365a232d924" +dependencies = [ + "camino", + "cargo-platform", + "semver 1.0.23", + "serde", + "serde_json", + "thiserror 2.0.8", ] [[package]] @@ -1619,7 +1633,7 @@ dependencies = [ "http 0.2.12", "jsonrpsee", "serde", - "thiserror", + "thiserror 1.0.63", "tracing", ] @@ -1694,7 +1708,7 @@ dependencies = [ "serde", "serde_repr", "sha2 0.10.8", - "thiserror", + "thiserror 1.0.63", ] [[package]] @@ -1816,7 +1830,7 @@ version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "471df7896633bfc1e7d3da5b598422891e4cb8931210168ec63ea586e285803f" dependencies = [ - "thiserror", + "thiserror 1.0.63", ] [[package]] @@ -1839,9 +1853,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "501d359d5f3dcaf6ecdeee48833ae73ec6e42723a1e52419c79abf9507eec0a0" dependencies = [ "heck 0.5.0", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -1853,7 +1867,7 @@ checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" [[package]] name = "clippy_config" version = "0.1.83" -source = "git+https://github.com/rust-lang/rust-clippy?rev=a95afe2d0a2051d97b723b0b197393b7811bc4e4#a95afe2d0a2051d97b723b0b197393b7811bc4e4" +source = "git+https://github.com/rust-lang/rust-clippy?rev=8b075fc63429b4ebec78bd1ee81bb78a4639ab02#8b075fc63429b4ebec78bd1ee81bb78a4639ab02" dependencies = [ "itertools 0.12.1", "serde", @@ -1863,7 +1877,7 @@ dependencies = [ [[package]] name = "clippy_utils" version = "0.1.83" -source = "git+https://github.com/rust-lang/rust-clippy?rev=a95afe2d0a2051d97b723b0b197393b7811bc4e4#a95afe2d0a2051d97b723b0b197393b7811bc4e4" +source = "git+https://github.com/rust-lang/rust-clippy?rev=8b075fc63429b4ebec78bd1ee81bb78a4639ab02#8b075fc63429b4ebec78bd1ee81bb78a4639ab02" dependencies = [ "arrayvec 0.7.6", "clippy_config", @@ -1931,7 +1945,7 @@ dependencies = [ "k256", "serde", "sha2 0.10.8", - "thiserror", + "thiserror 1.0.63", ] [[package]] @@ -1947,7 +1961,7 @@ dependencies = [ "pbkdf2 0.12.2", "rand 0.8.5", "sha2 0.10.8", - "thiserror", + "thiserror 1.0.63", ] [[package]] @@ -1967,7 +1981,7 @@ dependencies = [ "serde_derive", "sha2 0.10.8", "sha3", - "thiserror", + "thiserror 1.0.63", ] [[package]] @@ -2101,7 +2115,7 @@ version = "0.2.32" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c7f6ff08fd20f4f299298a28e2dfa8a8ba1036e6cd2460ac1de7b425d76f2500" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "unicode-xid 0.2.5", ] @@ -2302,9 +2316,9 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -2338,10 +2352,10 @@ checksum = "95133861a8032aaea082871032f5815eb9e98cef03fa916ab4500513994df9e5" dependencies = [ "fnv", "ident_case", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "strsim", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -2352,7 +2366,7 @@ checksum = "d336a2a514f6ccccaa3e09b02d41d35330c07ddf03a62165fcec10bb561c7806" dependencies = [ "darling_core", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -2456,7 +2470,7 @@ dependencies = [ "blake2b_simd 1.0.2", "decaf377", "rand_core 0.6.4", - "thiserror", + "thiserror 1.0.63", ] [[package]] @@ -2468,7 +2482,7 @@ dependencies = [ "decaf377", "hex", "rand_core 0.6.4", - "thiserror", + "thiserror 1.0.63", "zeroize", "zeroize_derive", ] @@ -2487,7 +2501,7 @@ dependencies = [ "hex", "rand_core 0.6.4", "serde", - "thiserror", + "thiserror 1.0.63", "zeroize", ] @@ -2517,7 +2531,7 @@ version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fcc3dd5e9e9c0b295d6e1e4d811fb6f157d5ffd784b8d202fc62eac8035a770b" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "syn 1.0.109", ] @@ -2528,9 +2542,9 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0a6433aac097572ea8ccc60b3f2e756c661c9aeed9225cdd4d0cb119cb7ff6ba" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -2539,9 +2553,9 @@ version = "0.99.18" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5f33878137e4dafd7fa914ad4e259e18a4e8e532b9617a2d0150262bf53abfce" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -2625,9 +2639,9 @@ version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -2650,9 +2664,9 @@ version = "0.1.14" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "27540baf49be0d484d8f0130d7d8da3011c32a44d4fc873368154f1510e574a2" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -2678,13 +2692,13 @@ checksum = "92773504d58c093f6de2459af4af33faa518c13451eb8f2b5698ed3d36e7c813" [[package]] name = "dylint" -version = "3.2.0" +version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60c66a33f0ecdb430682ffd8fa085ad57d0df028c9edaebb16e1b31b8c0240b8" +checksum = "b8b1c23bc7c6694e47c35bb4685e91b11464eb4373e0ca4b139d26b548c7acc6" dependencies = [ "ansi_term", "anyhow", - "cargo_metadata", + "cargo_metadata 0.19.1", "dirs", "dylint_internal", "is-terminal", @@ -2699,14 +2713,14 @@ dependencies = [ [[package]] name = "dylint_internal" -version = "3.2.0" +version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d30490df8338ad9f2c9b2e5766632083cd4b08f12b93994042c020e1c4604381" +checksum = "26fe025af824ecd9be633f23ad98363b954237f314b05acf2e8dc52258dea349" dependencies = [ "ansi_term", "anyhow", "bitflags 2.6.0", - "cargo_metadata", + "cargo_metadata 0.19.1", "git2", "home", "if_chain", @@ -2716,33 +2730,33 @@ dependencies = [ "regex", "rust-embed", "serde", - "thiserror", + "thiserror 2.0.8", "toml 0.8.19", ] [[package]] name = "dylint_linting" -version = "3.2.0" +version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82b1935d10c8bbfa22ee0b54ef6c05bbb432d36dd048f2723a2a5dfefa77e414" +checksum = "bc26e4dd700f99c321fe55282ac658fdebe224d6b0c6f955ecc5b6248f2ce981" dependencies = [ - "cargo_metadata", + "cargo_metadata 0.19.1", "dylint_internal", "paste", "rustversion", "serde", - "thiserror", + "thiserror 2.0.8", "toml 0.8.19", ] [[package]] name = "dylint_testing" -version = "3.2.0" +version = "3.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee051ff840d2cdc82574ce73c604bc01c0e204ec07ae8b297530b494dd0df319" +checksum = "3a5ea6be2adc417abf2ad958cc5f2ff0c17a4fcbd78f97de3472fb1218fe93dc" dependencies = [ "anyhow", - "cargo_metadata", + "cargo_metadata 0.19.1", "compiletest_rs", "dylint", "dylint_internal", @@ -2793,7 +2807,7 @@ dependencies = [ "hex", "rand_core 0.6.4", "sha2 0.9.9", - "thiserror", + "thiserror 1.0.63", "zeroize", ] @@ -2874,9 +2888,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "aa18ce2bc66555b3218614519ac839ddb759a7d6720732f979ef8d13be147ecd" dependencies = [ "once_cell", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -2929,12 +2943,12 @@ dependencies = [ [[package]] name = "errno" -version = "0.3.9" +version = "0.3.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d" dependencies = [ "libc", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -2955,7 +2969,7 @@ dependencies = [ "serde_json", "sha2 0.10.8", "sha3", - "thiserror", + "thiserror 1.0.63", "uuid 0.8.2", ] @@ -2972,7 +2986,7 @@ dependencies = [ "serde", "serde_json", "sha3", - "thiserror", + "thiserror 1.0.63", "uint", ] @@ -3049,7 +3063,7 @@ dependencies = [ "pin-project", "serde", "serde_json", - "thiserror", + "thiserror 1.0.63", ] [[package]] @@ -3064,12 +3078,12 @@ dependencies = [ "ethers-core", "eyre", "prettyplease", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "regex", "serde", "serde_json", - "syn 2.0.75", + "syn 2.0.90", "toml 0.8.19", "walkdir", ] @@ -3084,10 +3098,10 @@ dependencies = [ "const-hex", "ethers-contract-abigen", "ethers-core", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "serde_json", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -3098,7 +3112,7 @@ checksum = "82d80cc6ad30b14a48ab786523af33b37f28a8623fc06afd55324816ef18fb1f" dependencies = [ "arrayvec 0.7.6", "bytes", - "cargo_metadata", + "cargo_metadata 0.18.1", "chrono", "const-hex", "elliptic-curve", @@ -3113,9 +3127,9 @@ dependencies = [ "serde", "serde_json", "strum", - "syn 2.0.75", + "syn 2.0.90", "tempfile", - "thiserror", + "thiserror 1.0.63", "tiny-keccak", "unicode-xid 0.2.5", ] @@ -3139,7 +3153,7 @@ dependencies = [ "reqwest", "serde", "serde_json", - "thiserror", + "thiserror 1.0.63", "tokio", "tracing", "tracing-futures", @@ -3172,7 +3186,7 @@ dependencies = [ "reqwest", "serde", "serde_json", - "thiserror", + "thiserror 1.0.63", "tokio", "tokio-tungstenite", "tracing", @@ -3199,7 +3213,7 @@ dependencies = [ "ethers-core", "rand 0.8.5", "sha2 0.10.8", - "thiserror", + "thiserror 1.0.63", "tracing", ] @@ -3266,9 +3280,9 @@ dependencies = [ [[package]] name = "fastrand" -version = "2.1.0" +version = "2.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9fc0510504f03c51ada170672ac806f1f105a88aa97a5281117e1ddc3368e51a" +checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" [[package]] name = "fastrlp" @@ -3403,7 +3417,7 @@ dependencies = [ "rand_core 0.6.4", "serde", "serdect", - "thiserror", + "thiserror 1.0.63", "thiserror-nostd-notrait", "visibility", "zeroize", @@ -3531,9 +3545,9 @@ version = "0.3.31" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -3665,8 +3679,8 @@ dependencies = [ "aho-corasick", "bstr", "log", - "regex-automata 0.4.7", - "regex-syntax 0.8.4", + "regex-automata 0.4.9", + "regex-syntax 0.8.5", ] [[package]] @@ -4513,9 +4527,9 @@ version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1ec89e9337638ecdc08744df490b221a7399bf8d164eb52a665454e60e075ad6" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -4599,7 +4613,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "11d7a9f6330b71fea57921c9b61c47ee6e84f72d394754eff6163ae67e7395eb" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "syn 1.0.109", ] @@ -4797,7 +4811,7 @@ dependencies = [ "num-traits", "serde", "sha2 0.10.8", - "thiserror", + "thiserror 1.0.63", "tracing", ] @@ -4847,7 +4861,7 @@ dependencies = [ "pin-project", "rustls-native-certs", "soketto", - "thiserror", + "thiserror 1.0.63", "tokio", "tokio-rustls", "tokio-util 0.7.11", @@ -4875,7 +4889,7 @@ dependencies = [ "serde", "serde_json", "soketto", - "thiserror", + "thiserror 1.0.63", "tokio", "tracing", ] @@ -4893,7 +4907,7 @@ dependencies = [ "jsonrpsee-types", "serde", "serde_json", - "thiserror", + "thiserror 1.0.63", "tokio", "tower", "tracing", @@ -4908,7 +4922,7 @@ checksum = "29110019693a4fa2dbda04876499d098fa16d70eba06b1e6e2b3f1b251419515" dependencies = [ "heck 0.4.1", "proc-macro-crate 1.3.1", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "syn 1.0.109", ] @@ -4928,7 +4942,7 @@ dependencies = [ "serde", "serde_json", "soketto", - "thiserror", + "thiserror 1.0.63", "tokio", "tokio-stream", "tokio-util 0.7.11", @@ -4946,7 +4960,7 @@ dependencies = [ "beef", "serde", "serde_json", - "thiserror", + "thiserror 1.0.63", "tracing", ] @@ -5014,9 +5028,9 @@ checksum = "830d08ce1d1d941e6b30645f1a0eb5643013d835ce3779a5fc208261dbe10f55" [[package]] name = "libc" -version = "0.2.158" +version = "0.2.168" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8adc4bb1803a324070e64a98ae98f38934d91957a99cfb3a43dcbc01bc56439" +checksum = "5aaeb2981e0606ca11d79718f8bb01164f1d6ed75080182d3abf017e6d244b6d" [[package]] name = "libgit2-sys" @@ -5069,7 +5083,7 @@ dependencies = [ "multihash", "quick-protobuf", "sha2 0.10.8", - "thiserror", + "thiserror 1.0.63", "tracing", ] @@ -5238,7 +5252,7 @@ dependencies = [ "metrics 0.23.0", "metrics-util", "quanta", - "thiserror", + "thiserror 1.0.63", "tokio", "tracing", ] @@ -5334,7 +5348,7 @@ dependencies = [ "rustc_version 0.4.0", "smallvec", "tagptr", - "thiserror", + "thiserror 1.0.63", "triomphe", "uuid 1.10.0", ] @@ -5452,7 +5466,7 @@ version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "876a53fff98e03a936a674b29568b0e605f06b29372c2489ff4de23f1949743d" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "syn 1.0.109", ] @@ -5502,9 +5516,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "af1844ef2428cc3e1cb900be36181049ef3d3193c63e43026cfe202983b27a56" dependencies = [ "proc-macro-crate 3.1.0", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -5533,9 +5547,9 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.19.0" +version = "1.20.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" +checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" [[package]] name = "opaque-debug" @@ -5563,7 +5577,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "003b2be5c6c53c1cfeb0a238b8a1c3915cd410feb684457a36c10038f764bb1c" dependencies = [ "bytes", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "syn 1.0.109", ] @@ -5597,7 +5611,7 @@ dependencies = [ "js-sys", "once_cell", "pin-project-lite", - "thiserror", + "thiserror 1.0.63", "urlencoding", ] @@ -5615,7 +5629,7 @@ dependencies = [ "opentelemetry-semantic-conventions", "opentelemetry_sdk", "prost", - "thiserror", + "thiserror 1.0.63", "tokio", "tonic 0.11.0", ] @@ -5670,7 +5684,7 @@ dependencies = [ "ordered-float", "percent-encoding", "rand 0.8.5", - "thiserror", + "thiserror 1.0.63", "tokio", "tokio-stream", ] @@ -5723,7 +5737,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d830939c76d294956402033aee57a6da7b438f2294eb94864c37b0569053a42c" dependencies = [ "proc-macro-crate 3.1.0", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "syn 1.0.109", ] @@ -5836,10 +5850,10 @@ version = "0.2.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4bab5b985dc082b345f812b7df84e1bef27e7207b39e448439ba8bd69c93f147" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "proc-macro2-diagnostics", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -5865,7 +5879,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bdad6a1d9cf116a059582ce415d5f5566aabcd4008646779dab7fdc2a9a9d426" dependencies = [ "peg-runtime", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", ] @@ -5919,7 +5933,7 @@ dependencies = [ "serde", "serde_with", "sha2 0.10.8", - "thiserror", + "thiserror 1.0.63", "tracing", ] @@ -6000,7 +6014,7 @@ dependencies = [ "regex", "serde", "sha2 0.10.8", - "thiserror", + "thiserror 1.0.63", "tracing", ] @@ -6036,7 +6050,7 @@ dependencies = [ "regex", "serde", "sha2 0.10.8", - "thiserror", + "thiserror 1.0.63", "tracing", ] @@ -6130,7 +6144,7 @@ dependencies = [ "poseidon377", "rand 0.8.5", "serde", - "thiserror", + "thiserror 1.0.63", "tracing", ] @@ -6183,7 +6197,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cd53dff83f26735fdc1ca837098ccf133605d794cdae66acfc2bfac3ec809d95" dependencies = [ "memchr", - "thiserror", + "thiserror 1.0.63", "ucd-trie", ] @@ -6222,9 +6236,9 @@ version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -6394,8 +6408,8 @@ version = "0.2.20" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5f12335488a2f3b0a83b14edad48dca9879ce89b2edd10e80237e4e852dd645e" dependencies = [ - "proc-macro2 1.0.86", - "syn 2.0.75", + "proc-macro2 1.0.92", + "syn 2.0.90", ] [[package]] @@ -6438,7 +6452,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" dependencies = [ "proc-macro-error-attr", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "version_check", ] @@ -6449,7 +6463,7 @@ version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "version_check", ] @@ -6465,9 +6479,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.86" +version = "1.0.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" +checksum = "37d3544b3f2748c54e147655edb5025752e2303145b5aefb3c3ea2c78b973bb0" dependencies = [ "unicode-ident", ] @@ -6478,9 +6492,9 @@ version = "0.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "af066a9c399a26e020ada66a034357a868728e72cd426f3adcd35f80d88d88c8" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", "version_check", "yansi", ] @@ -6497,7 +6511,7 @@ dependencies = [ "rand 0.8.5", "rand_chacha 0.3.1", "rand_xorshift", - "regex-syntax 0.8.4", + "regex-syntax 0.8.5", "unarray", ] @@ -6528,7 +6542,7 @@ dependencies = [ "prost", "prost-types", "regex", - "syn 2.0.75", + "syn 2.0.90", "tempfile", ] @@ -6540,9 +6554,9 @@ checksum = "81bddcdb20abf9501610992b6759a4c888aef7d1a7247ef75e2404275ac24af1" dependencies = [ "anyhow", "itertools 0.12.1", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -6584,7 +6598,7 @@ version = "1.0.36" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0fa76aaf39101c457836aec0ce2316dbdc3ab723cdda1c6bd4e6ad4208acaca7" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", ] [[package]] @@ -6734,19 +6748,19 @@ checksum = "ba009ff324d1fc1b900bd1fdb31564febe58a8ccc8a6fdbb93b543d33b13ca43" dependencies = [ "getrandom 0.2.15", "libredox", - "thiserror", + "thiserror 1.0.63", ] [[package]] name = "regex" -version = "1.10.6" +version = "1.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4219d74c6b67a3654a9fbebc4b419e22126d13d2f3c4a07ee0cb61ff79a79619" +checksum = "b544ef1b4eac5dc2db33ea63606ae9ffcfac26c1416a2806ae0bf5f56b201191" dependencies = [ "aho-corasick", "memchr", - "regex-automata 0.4.7", - "regex-syntax 0.8.4", + "regex-automata 0.4.9", + "regex-syntax 0.8.5", ] [[package]] @@ -6760,13 +6774,13 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.7" +version = "0.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" +checksum = "809e8dc61f6de73b46c85f4c96486310fe304c434cfa43669d7b40f711150908" dependencies = [ "aho-corasick", "memchr", - "regex-syntax 0.8.4", + "regex-syntax 0.8.5", ] [[package]] @@ -6783,9 +6797,9 @@ checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" [[package]] name = "regex-syntax" -version = "0.8.4" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" +checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" [[package]] name = "reqwest" @@ -6901,7 +6915,7 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e33d7b2abe0c340d8797fe2907d3f20d3b5ea5908683618bfe80df7f621f672a" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "syn 1.0.109", ] @@ -6969,10 +6983,10 @@ version = "8.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6125dbc8867951125eec87294137f4e9c2c96566e61bf72c45095a7c77761478" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "rust-embed-utils", - "syn 2.0.75", + "syn 2.0.90", "walkdir", ] @@ -7041,21 +7055,21 @@ checksum = "70f5b7fc8060f4f8373f9381a630304b42e1183535d9beb1d3f596b236c9106a" dependencies = [ "serde", "serde_json", - "thiserror", + "thiserror 1.0.63", "tracing", ] [[package]] name = "rustix" -version = "0.38.34" +version = "0.38.42" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70dc5ec042f7a43c4a73241207cecc9873a06d45debb38b329f8541d85c2730f" +checksum = "f93dc38ecbab2eb790ff964bb77fa94faf256fd3e73285fd7ba0903b76bedb85" dependencies = [ "bitflags 2.6.0", "errno", "libc", "linux-raw-sys", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -7197,7 +7211,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2d35494501194174bda522a32605929eefc9ecf7e0a326c26db1fdd85881eb62" dependencies = [ "proc-macro-crate 3.1.0", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "syn 1.0.109", ] @@ -7339,9 +7353,9 @@ version = "1.0.208" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "24008e81ff7613ed8e5ba0cfaf24e2c2f1e5b8a0495711e44fcd4882fca62bcf" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -7374,7 +7388,7 @@ checksum = "c7715380eec75f029a4ef7de39a9200e0a63823176b759d055b613f5a87df6a6" dependencies = [ "percent-encoding", "serde", - "thiserror", + "thiserror 1.0.63", ] [[package]] @@ -7383,9 +7397,9 @@ version = "0.1.19" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c64451ba24fc7a6a2d60fc75dd9c83c90903b19028d4eff35e88fc1e86564e9" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -7434,9 +7448,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a8fee4991ef4f274617a51ad4af30519438dacb2f56ac773b08a1922ff743350" dependencies = [ "darling", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -7568,7 +7582,7 @@ checksum = "adc4e5204eb1910f40f9cfa375f6f05b68c3abac4b6fd879c8ff5e7ae8a0a085" dependencies = [ "num-bigint", "num-traits", - "thiserror", + "thiserror 1.0.63", "time", ] @@ -7699,10 +7713,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4c6bee85a5a24955dc440386795aa378cd9cf82acd5f764469152d2270e581be" dependencies = [ "heck 0.5.0", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "rustversion", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -7732,18 +7746,18 @@ version = "1.0.109" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "unicode-ident", ] [[package]] name = "syn" -version = "2.0.75" +version = "2.0.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6af063034fc1935ede7be0122941bafa9bacb949334d090b77ca98b5817c7d9" +checksum = "919d3b74a5dd0ccd15aeb8f93e7006bd9e14c295087c9896a110f490752bcf31" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", "unicode-ident", ] @@ -7755,9 +7769,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1329189c02ff984e9736652b1631330da25eaa6bc639089ed4915d25446cbe7b" dependencies = [ "proc-macro-error", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -7772,9 +7786,9 @@ version = "0.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -7812,12 +7826,12 @@ checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" [[package]] name = "tempfile" -version = "3.12.0" +version = "3.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04cbcdd0c794ebb0d4cf35e88edd2f7d2c4c3e9a5a6dab322839b321c6a87a64" +checksum = "28cce251fcbc87fac86a866eeb0d6c2d536fc16d06f184bb61aeae11aa4cee0c" dependencies = [ "cfg-if", - "fastrand 2.1.0", + "fastrand 2.3.0", "once_cell", "rustix", "windows-sys 0.59.0", @@ -7924,7 +7938,7 @@ dependencies = [ "tendermint", "tendermint-config", "tendermint-proto", - "thiserror", + "thiserror 1.0.63", "time", "tokio", "tracing", @@ -7991,7 +8005,16 @@ version = "1.0.63" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0342370b38b6a11b6cc11d6a805569958d54cfa061a29969c3b5ce2ea405724" dependencies = [ - "thiserror-impl", + "thiserror-impl 1.0.63", +] + +[[package]] +name = "thiserror" +version = "2.0.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "08f5383f3e0071702bf93ab5ee99b52d26936be9dedd9413067cbdcddcb6141a" +dependencies = [ + "thiserror-impl 2.0.8", ] [[package]] @@ -8000,9 +8023,20 @@ version = "1.0.63" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a4558b58466b9ad7ca0f102865eccc95938dca1a74a856f2b57b6629050da261" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", + "quote", + "syn 2.0.90", +] + +[[package]] +name = "thiserror-impl" +version = "2.0.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f2f357fcec90b3caef6623a099691be676d033b40a058ac95d2a6ade6fa0c943" +dependencies = [ + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -8020,9 +8054,9 @@ version = "1.0.57" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "585e5ef40a784ce60b49c67d762110688d211d395d39e096be204535cf64590e" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -8137,9 +8171,9 @@ version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -8363,10 +8397,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "be4ef6dd70a610078cb4e338a0f79d06bc759ff1b22d2120c2ff02ae264ba9c2" dependencies = [ "prettyplease", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "prost-build", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -8430,7 +8464,7 @@ checksum = "b882e5e82ee7440a08335f4d5a2edd9f7678b2cba73eac4826b53c22fd76fdd3" dependencies = [ "futures", "pin-project", - "thiserror", + "thiserror 1.0.63", "tokio", "tokio-util 0.7.11", "tower", @@ -8485,9 +8519,9 @@ version = "0.1.27" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -8638,7 +8672,7 @@ dependencies = [ "rand 0.8.5", "rustls", "sha1", - "thiserror", + "thiserror 1.0.63", "url", "utf-8", ] @@ -8832,7 +8866,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e27d6bdd219887a9eadd19e1c34f32e47fa332301184935c6d9bca26f3cca525" dependencies = [ "anyhow", - "cargo_metadata", + "cargo_metadata 0.18.1", "cfg-if", "git2", "regex", @@ -8853,9 +8887,9 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d674d135b4a8c1d7e813e2f8d1c9a58308aee4a680323066025e53132218bd91" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -8924,9 +8958,9 @@ dependencies = [ "bumpalo", "log", "once_cell", - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", "wasm-bindgen-shared", ] @@ -8958,9 +8992,9 @@ version = "0.2.93" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "afc340c74d9005395cf9dd098506f7f44e38f2b4a21c6aaacf9a105ea5e1e836" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", "wasm-bindgen-backend", "wasm-bindgen-shared", ] @@ -9329,7 +9363,7 @@ dependencies = [ "pharos", "rustc_version 0.4.0", "send_wrapper 0.6.0", - "thiserror", + "thiserror 1.0.63", "wasm-bindgen", "wasm-bindgen-futures", "web-sys", @@ -9368,9 +9402,9 @@ version = "0.7.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2380878cad4ac9aac1e2435f3eb4020e8374b5f13c296cb75b4620ff8e229154" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", "synstructure", ] @@ -9390,9 +9424,9 @@ version = "0.7.35" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -9410,9 +9444,9 @@ version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "595eed982f7d355beb85837f651fa22e90b3c044842dc7f2c2842c086f295808" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", "synstructure", ] @@ -9431,9 +9465,9 @@ version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] @@ -9453,9 +9487,9 @@ version = "0.10.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6eafa6dfb17584ea3e2bd6e76e0cc15ad7af12b09abdd1ca55961bed9b1063c6" dependencies = [ - "proc-macro2 1.0.86", + "proc-macro2 1.0.92", "quote", - "syn 2.0.75", + "syn 2.0.90", ] [[package]] diff --git a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs index c967ab5fbe..bed9880a20 100644 --- a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs +++ b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs @@ -93,8 +93,6 @@ impl BlobSubmitterHandle { /// Send a block to the blob submitter immediately. /// /// This is a thin wrapper around [`mpsc::Sender::try_send`]. - // TODO(https://github.com/astriaorg/astria/issues/1860) - #[expect(clippy::result_large_err, reason = "should be fixed")] pub(super) fn try_send( &self, block: SequencerBlock, diff --git a/lint/tracing_debug_field/Cargo.toml b/lint/tracing_debug_field/Cargo.toml index cfd3a0f183..8a853918c5 100644 --- a/lint/tracing_debug_field/Cargo.toml +++ b/lint/tracing_debug_field/Cargo.toml @@ -13,12 +13,12 @@ name = "ui" path = "ui/main.rs" [dependencies] -clippy_utils = { git = "https://github.com/rust-lang/rust-clippy", rev = "a95afe2d0a2051d97b723b0b197393b7811bc4e4" } -dylint_linting = "3.2.0" +clippy_utils = { git = "https://github.com/rust-lang/rust-clippy", rev = "8b075fc63429b4ebec78bd1ee81bb78a4639ab02" } +dylint_linting = "3.3.0" if_chain = "1.0.2" [dev-dependencies] -dylint_testing = "3.2.0" +dylint_testing = "3.3.0" tracing = "0.1" [package.metadata.rust-analyzer] From 93aedaadb6e9f7c342368d01bd070b4a91b62096 Mon Sep 17 00:00:00 2001 From: ethanoroshiba Date: Wed, 18 Dec 2024 11:22:10 -0600 Subject: [PATCH 06/10] bump docker version, add dep --- containerfiles/Dockerfile | 2 +- lint/tracing_debug_field/rust-toolchain | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/containerfiles/Dockerfile b/containerfiles/Dockerfile index f5fefa9845..036132f63c 100644 --- a/containerfiles/Dockerfile +++ b/containerfiles/Dockerfile @@ -1,4 +1,4 @@ -FROM --platform=$BUILDPLATFORM rust:1.81-bookworm AS rust +FROM --platform=$BUILDPLATFORM rust:1.83-bookworm AS rust WORKDIR /build/ diff --git a/lint/tracing_debug_field/rust-toolchain b/lint/tracing_debug_field/rust-toolchain index 28992a45f1..0bac976ca4 100644 --- a/lint/tracing_debug_field/rust-toolchain +++ b/lint/tracing_debug_field/rust-toolchain @@ -1,3 +1,3 @@ [toolchain] channel = "nightly-2024-10-11" -components = ["llvm-tools-preview", "rustc-dev"] +components = ["llvm-tools-preview", "rustc-dev", "rust-src"] From 92883c790552408b40ed9c2c4951d07448ad773a Mon Sep 17 00:00:00 2001 From: ethanoroshiba Date: Fri, 20 Dec 2024 10:02:37 -0600 Subject: [PATCH 07/10] fix clippy versions --- .github/workflows/lint.yml | 2 +- .github/workflows/test.yml | 2 +- Cargo.lock | 4 ++-- crates/astria-sequencer-relayer/src/relayer/write/mod.rs | 2 ++ justfile | 6 +++--- lint/tracing_debug_field/Cargo.toml | 2 +- lint/tracing_debug_field/rust-toolchain | 2 +- 7 files changed, 11 insertions(+), 9 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 60e8763853..3e491caed5 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -72,7 +72,7 @@ jobs: uses: taiki-e/install-action@just - uses: dtolnay/rust-toolchain@master with: - toolchain: nightly-2024-10-11 + toolchain: nightly-2024-10-03 components: rustfmt - name: run rustfmt run: just lint rust-fmt diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2b4e6f1351..10849db975 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -250,7 +250,7 @@ jobs: - uses: dtolnay/rust-toolchain@master with: # This has to match `rust-toolchain` in the rust-toolchain file of the dylint lints - toolchain: nightly-2024-10-11 + toolchain: nightly-2024-10-03 components: "clippy, llvm-tools-preview, rustc-dev, rust-src" - uses: Swatinem/rust-cache@v2.7.3 with: diff --git a/Cargo.lock b/Cargo.lock index f3d652e40b..cf483afff4 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1867,7 +1867,7 @@ checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" [[package]] name = "clippy_config" version = "0.1.83" -source = "git+https://github.com/rust-lang/rust-clippy?rev=8b075fc63429b4ebec78bd1ee81bb78a4639ab02#8b075fc63429b4ebec78bd1ee81bb78a4639ab02" +source = "git+https://github.com/rust-lang/rust-clippy?rev=aa0d551351a9c15d8a95fdb3e2946b505893dda8#aa0d551351a9c15d8a95fdb3e2946b505893dda8" dependencies = [ "itertools 0.12.1", "serde", @@ -1877,7 +1877,7 @@ dependencies = [ [[package]] name = "clippy_utils" version = "0.1.83" -source = "git+https://github.com/rust-lang/rust-clippy?rev=8b075fc63429b4ebec78bd1ee81bb78a4639ab02#8b075fc63429b4ebec78bd1ee81bb78a4639ab02" +source = "git+https://github.com/rust-lang/rust-clippy?rev=aa0d551351a9c15d8a95fdb3e2946b505893dda8#aa0d551351a9c15d8a95fdb3e2946b505893dda8" dependencies = [ "arrayvec 0.7.6", "clippy_config", diff --git a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs index bed9880a20..c967ab5fbe 100644 --- a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs +++ b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs @@ -93,6 +93,8 @@ impl BlobSubmitterHandle { /// Send a block to the blob submitter immediately. /// /// This is a thin wrapper around [`mpsc::Sender::try_send`]. + // TODO(https://github.com/astriaorg/astria/issues/1860) + #[expect(clippy::result_large_err, reason = "should be fixed")] pub(super) fn try_send( &self, block: SequencerBlock, diff --git a/justfile b/justfile index 0e45bfddb6..4044ee87af 100644 --- a/justfile +++ b/justfile @@ -91,7 +91,7 @@ _fmt-all: [no-exit-message] _fmt-rust: - cargo +nightly-2024-10-11 fmt --all + cargo +nightly-2024-10-03 fmt --all [no-exit-message] _lint-rust: @@ -103,7 +103,7 @@ _lint-rust: [no-exit-message] _lint-rust-fmt: - cargo +nightly-2024-10-11 fmt --all -- --check + cargo +nightly-2024-10-03 fmt --all -- --check [no-exit-message] _lint-rust-clippy: @@ -114,7 +114,7 @@ _lint-rust-clippy: [no-exit-message] _lint-rust-clippy-custom: - cargo +nightly-2024-10-11 clippy --all-targets --all-features \ + cargo +nightly-2024-10-03 clippy --all-targets --all-features \ -p tracing_debug_field \ -- --warn clippy::pedantic --deny warnings diff --git a/lint/tracing_debug_field/Cargo.toml b/lint/tracing_debug_field/Cargo.toml index 8a853918c5..2c758c9450 100644 --- a/lint/tracing_debug_field/Cargo.toml +++ b/lint/tracing_debug_field/Cargo.toml @@ -13,7 +13,7 @@ name = "ui" path = "ui/main.rs" [dependencies] -clippy_utils = { git = "https://github.com/rust-lang/rust-clippy", rev = "8b075fc63429b4ebec78bd1ee81bb78a4639ab02" } +clippy_utils = { git = "https://github.com/rust-lang/rust-clippy", rev = "aa0d551351a9c15d8a95fdb3e2946b505893dda8" } dylint_linting = "3.3.0" if_chain = "1.0.2" diff --git a/lint/tracing_debug_field/rust-toolchain b/lint/tracing_debug_field/rust-toolchain index 0bac976ca4..986c56ee64 100644 --- a/lint/tracing_debug_field/rust-toolchain +++ b/lint/tracing_debug_field/rust-toolchain @@ -1,3 +1,3 @@ [toolchain] -channel = "nightly-2024-10-11" +channel = "nightly-2024-10-03" components = ["llvm-tools-preview", "rustc-dev", "rust-src"] From 54c80e483e97a583af9383faaaee973c1e24f9ba Mon Sep 17 00:00:00 2001 From: ethanoroshiba Date: Fri, 20 Dec 2024 11:21:43 -0600 Subject: [PATCH 08/10] test result size --- crates/astria-sequencer-relayer/src/relayer/write/mod.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs index c967ab5fbe..4977600f5e 100644 --- a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs +++ b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs @@ -649,3 +649,8 @@ fn report_exit(reason: &eyre::Result<&str>, message: &str) { Err(error) => error!(%error, message), } } + +#[test] +fn wtf() { + assert_eq!(320, size_of::>>()); +} From 2a855c3f5cc4cd1dc6ce24d04429b530cf6e6a98 Mon Sep 17 00:00:00 2001 From: ethanoroshiba Date: Fri, 20 Dec 2024 11:45:17 -0600 Subject: [PATCH 09/10] remove size test, add clippy version command --- crates/astria-sequencer-relayer/src/relayer/write/mod.rs | 5 ----- justfile | 1 + 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs index 4977600f5e..c967ab5fbe 100644 --- a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs +++ b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs @@ -649,8 +649,3 @@ fn report_exit(reason: &eyre::Result<&str>, message: &str) { Err(error) => error!(%error, message), } } - -#[test] -fn wtf() { - assert_eq!(320, size_of::>>()); -} diff --git a/justfile b/justfile index 4044ee87af..39c3f0284f 100644 --- a/justfile +++ b/justfile @@ -107,6 +107,7 @@ _lint-rust-fmt: [no-exit-message] _lint-rust-clippy: + cargo clippy --version cargo clippy --all-targets --all-features \ -- --warn clippy::pedantic --warn clippy::arithmetic-side-effects \ --warn clippy::allow_attributes --warn clippy::allow_attributes_without_reason \ From 5fa71b23800398a16a885532b9cefa8ed458a03c Mon Sep 17 00:00:00 2001 From: ethanoroshiba Date: Fri, 20 Dec 2024 12:10:13 -0600 Subject: [PATCH 10/10] remove unnecessary expect --- crates/astria-sequencer-relayer/src/relayer/write/mod.rs | 2 -- 1 file changed, 2 deletions(-) diff --git a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs index e61dd60e27..aebb0debd4 100644 --- a/crates/astria-sequencer-relayer/src/relayer/write/mod.rs +++ b/crates/astria-sequencer-relayer/src/relayer/write/mod.rs @@ -93,8 +93,6 @@ impl BlobSubmitterHandle { /// Send a block to the blob submitter immediately. /// /// This is a thin wrapper around [`mpsc::Sender::try_send`]. - // TODO(https://github.com/astriaorg/astria/issues/1860) - #[expect(clippy::result_large_err, reason = "should be fixed")] pub(super) fn try_send( &self, block: Box,