Skip to content

Commit

Permalink
Bump Rust to 1.79 and fix lint (#5060)
Browse files Browse the repository at this point in the history
# Motivation

The automatic [Rust version
upgrade](#5051) failed because
of a [lint
error](https://github.com/dfinity/nns-dapp/actions/runs/9510216178/job/26214335680?pr=5051).

# Changes

1. Bump Rust to 1.79.0
2. Fix the lint error.

# Tests

`scripts/lint-rs` passes

# Todos

- [ ] Add entry to changelog (if necessary).
not necessary
  • Loading branch information
dskloetd authored Jun 17, 2024
1 parent 8105945 commit 567083b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion rs/backend/src/accounts_store/schema/proxy/migration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ impl AccountsDbAsProxy {
/// - This may be no larger than `Self::MIGRATION_STEP_SIZE_MAX`. If it is larger, it will be reduced.
pub fn step_migration(&mut self, step_size: u32) {
// Ensure that the step size is modest:
let step_size = step_size.min(Self::MIGRATION_STEP_SIZE_MAX).max(1);
let step_size = step_size.clamp(1, Self::MIGRATION_STEP_SIZE_MAX);
if let Some(migration) = &mut self.migration {
if let Some(next_to_migrate) = &migration.next_to_migrate {
println!("Stepping migration: {:?} -> {:?}", self.authoritative_db, migration.db);
Expand Down
2 changes: 1 addition & 1 deletion rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[toolchain]
# Please, from time to time, update this to the latest stable version on Rust Forge: https://forge.rust-lang.org/
channel = "1.78.0"
channel = "1.79.0"
components = ["rustfmt", "clippy"]
targets = [ "wasm32-unknown-unknown"]

0 comments on commit 567083b

Please sign in to comment.