diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 433c4f44ea0..c816e4c011b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,7 +24,7 @@ jobs: rust: - "stable" - "nightly" - - "1.79" # MSRV + - "1.81" # MSRV flags: # No features - "--no-default-features" @@ -34,7 +34,7 @@ jobs: - "--all-features" exclude: # All features on MSRV - - rust: "1.79" # MSRV + - rust: "1.81" # MSRV flags: "--all-features" steps: - uses: actions/checkout@v4 @@ -53,14 +53,14 @@ jobs: cache-on-failure: true # Only run tests on latest stable and above - name: Install cargo-nextest - if: ${{ matrix.rust != '1.79' }} # MSRV + if: ${{ matrix.rust != '1.81' }} # MSRV uses: taiki-e/install-action@nextest - name: build - if: ${{ matrix.rust == '1.79' }} # MSRV + if: ${{ matrix.rust == '1.81' }} # MSRV run: cargo build --workspace ${{ matrix.flags }} - name: test shell: bash - if: ${{ matrix.rust != '1.79' }} # MSRV + if: ${{ matrix.rust != '1.81' }} # MSRV run: cargo nextest run --workspace ${{ matrix.flags }} doctest: diff --git a/Cargo.toml b/Cargo.toml index 65ab7623c32..cb798c194ac 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -5,7 +5,7 @@ resolver = "2" [workspace.package] version = "0.5.4" edition = "2021" -rust-version = "1.79" +rust-version = "1.81" authors = ["Alloy Contributors"] license = "MIT OR Apache-2.0" homepage = "https://github.com/alloy-rs/alloy" diff --git a/README.md b/README.md index c3eeecec195..c360b2111eb 100644 --- a/README.md +++ b/README.md @@ -124,7 +124,7 @@ When updating this, also update: - .github/workflows/ci.yml --> -The current MSRV (minimum supported rust version) is 1.79. +The current MSRV (minimum supported rust version) is 1.81. Alloy will keep a rolling MSRV policy of **at least** two versions behind the latest stable release (so if the latest stable release is 1.58, we would diff --git a/clippy.toml b/clippy.toml index f1acf4b1122..8c0bc009eb0 100644 --- a/clippy.toml +++ b/clippy.toml @@ -1 +1 @@ -msrv = "1.79" +msrv = "1.81" diff --git a/crates/eips/src/eip1898.rs b/crates/eips/src/eip1898.rs index 8d0cbd6864a..79154b18670 100644 --- a/crates/eips/src/eip1898.rs +++ b/crates/eips/src/eip1898.rs @@ -259,8 +259,7 @@ impl Display for HexStringMissingPrefixError { } } -#[cfg(feature = "std")] -impl std::error::Error for HexStringMissingPrefixError {} +impl core::error::Error for HexStringMissingPrefixError {} /// A Block Identifier. /// @@ -781,8 +780,7 @@ impl fmt::Display for ParseBlockHashOrNumberError { } } -#[cfg(feature = "std")] -impl std::error::Error for ParseBlockHashOrNumberError {} +impl core::error::Error for ParseBlockHashOrNumberError {} impl FromStr for HashOrNumber { type Err = ParseBlockHashOrNumberError; diff --git a/crates/eips/src/eip4844/trusted_setup_points.rs b/crates/eips/src/eip4844/trusted_setup_points.rs index d3795e89074..50b5e916580 100644 --- a/crates/eips/src/eip4844/trusted_setup_points.rs +++ b/crates/eips/src/eip4844/trusted_setup_points.rs @@ -131,5 +131,4 @@ impl fmt::Display for KzgErrors { } } -#[cfg(feature = "std")] -impl std::error::Error for KzgErrors {} +impl core::error::Error for KzgErrors {} diff --git a/crates/rpc-types-engine/src/error.rs b/crates/rpc-types-engine/src/error.rs index 9867e3a23c1..b114be7bcf0 100644 --- a/crates/rpc-types-engine/src/error.rs +++ b/crates/rpc-types-engine/src/error.rs @@ -120,5 +120,4 @@ pub enum PayloadValidationError { }, } -#[cfg(feature = "std")] -impl std::error::Error for PayloadValidationError {} +impl core::error::Error for PayloadValidationError {} diff --git a/crates/rpc-types-engine/src/forkchoice.rs b/crates/rpc-types-engine/src/forkchoice.rs index 142d31b1c65..6c13d2856ba 100644 --- a/crates/rpc-types-engine/src/forkchoice.rs +++ b/crates/rpc-types-engine/src/forkchoice.rs @@ -85,8 +85,7 @@ pub enum ForkchoiceUpdateError { UnknownFinalBlock, } -#[cfg(feature = "std")] -impl std::error::Error for ForkchoiceUpdateError {} +impl core::error::Error for ForkchoiceUpdateError {} #[cfg(feature = "jsonrpsee-types")] impl From for jsonrpsee_types::error::ErrorObject<'static> { diff --git a/crates/rpc-types-eth/src/filter.rs b/crates/rpc-types-eth/src/filter.rs index 659e6a7cd10..ab203fb9791 100644 --- a/crates/rpc-types-eth/src/filter.rs +++ b/crates/rpc-types-eth/src/filter.rs @@ -165,8 +165,7 @@ pub enum FilterBlockError { }, } -#[cfg(feature = "std")] -impl std::error::Error for FilterBlockError {} +impl core::error::Error for FilterBlockError {} /// Represents the target range of blocks for the filter #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash)]