From b743c9a43e4b5271ff856fbad87266f249e8801c Mon Sep 17 00:00:00 2001 From: Luke Parker Date: Fri, 15 Aug 2025 15:26:16 -0400 Subject: [PATCH] Update Rust version This causes the Serai node to compile and run again. --- .github/nightly-version | 2 +- .github/workflows/lint.yml | 2 +- Cargo.toml | 22 ++++++++++++++++++++-- deny.toml | 1 + rust-toolchain.toml | 2 +- 5 files changed, 24 insertions(+), 5 deletions(-) diff --git a/.github/nightly-version b/.github/nightly-version index e67d5713..45e51c4c 100644 --- a/.github/nightly-version +++ b/.github/nightly-version @@ -1 +1 @@ -nightly-2024-09-01 +nightly-2025-08-01 diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index eae3c59a..fd63493c 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -26,7 +26,7 @@ jobs: uses: ./.github/actions/build-dependencies - name: Install nightly rust - run: rustup toolchain install ${{ steps.nightly.outputs.version }} --profile minimal -t wasm32v1-none -c clippy + run: rustup toolchain install ${{ steps.nightly.outputs.version }} --profile minimal -t wasm32v1-none -c rust-src -c clippy - name: Run Clippy run: cargo +${{ steps.nightly.outputs.version }} clippy --all-features --all-targets -- -D warnings -A clippy::items_after_test_module diff --git a/Cargo.toml b/Cargo.toml index e0911b41..6361422d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -154,6 +154,7 @@ directories-next = { path = "patches/directories-next" } [workspace.lints.clippy] unwrap_or_default = "allow" +manual_is_multiple_of = "allow" borrow_as_ptr = "deny" cast_lossless = "deny" cast_possible_truncation = "deny" @@ -178,14 +179,14 @@ large_stack_arrays = "deny" linkedlist = "deny" macro_use_imports = "deny" manual_instant_elapsed = "deny" -manual_let_else = "deny" +# TODO manual_let_else = "deny" manual_ok_or = "deny" manual_string_new = "deny" map_unwrap_or = "deny" match_bool = "deny" match_same_arms = "deny" missing_fields_in_debug = "deny" -needless_continue = "deny" +# TODO needless_continue = "deny" needless_pass_by_value = "deny" ptr_cast_constness = "deny" range_minus_one = "deny" @@ -202,3 +203,20 @@ unnested_or_patterns = "deny" unused_async = "deny" unused_self = "deny" zero_sized_map_values = "deny" + +# TODO: These were incurred when updating Rust as necessary for compilation, yet aren't being fixed +# at this time due to the impacts it'd have throughout the repository (when this isn't actively the +# primary branch, `next` is) +needless_continue = "allow" +needless_lifetimes = "allow" +useless_conversion = "allow" +empty_line_after_doc_comments = "allow" +manual_div_ceil = "allow" +manual_let_else = "allow" +unnecessary_map_or = "allow" +result_large_err = "allow" +unneeded_struct_pattern = "allow" +[workspace.lints.rust] +mismatched_lifetime_syntaxes = "allow" +unused_attributes = "allow" +unused-parens = "allow" diff --git a/deny.toml b/deny.toml index 881761c8..cc2f2c3d 100644 --- a/deny.toml +++ b/deny.toml @@ -106,4 +106,5 @@ allow-git = [ "https://github.com/monero-oxide/monero-oxide", "https://github.com/serai-dex/substrate-bip39", "https://github.com/serai-dex/substrate", + "https://github.com/serai-dex/polkadot-sdk", ] diff --git a/rust-toolchain.toml b/rust-toolchain.toml index 7ed4c04e..cdd2b730 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,5 +1,5 @@ [toolchain] -channel = "1.82" +channel = "1.89" targets = ["wasm32v1-none"] profile = "minimal" components = ["rust-src", "rustfmt", "clippy"]