From b027f8de0b18c67dbed210b81fa9bc894c505874 Mon Sep 17 00:00:00 2001 From: Patrick Kunzmann Date: Thu, 16 Apr 2026 16:45:12 +0200 Subject: [PATCH 1/2] Ensure same toolchain version is used locally and in CI --- .github/workflows/test_and_deploy.yml | 2 +- rust-toolchain.toml | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 rust-toolchain.toml diff --git a/.github/workflows/test_and_deploy.yml b/.github/workflows/test_and_deploy.yml index b03edc679..307df3e90 100644 --- a/.github/workflows/test_and_deploy.yml +++ b/.github/workflows/test_and_deploy.yml @@ -40,7 +40,7 @@ jobs: - uses: actions/checkout@v4 - uses: actions-rs/toolchain@v1 with: - toolchain: stable + toolchain: 1.95.0 override: true components: rustfmt, clippy - uses: actions/setup-python@v5 diff --git a/rust-toolchain.toml b/rust-toolchain.toml new file mode 100644 index 000000000..6360c1888 --- /dev/null +++ b/rust-toolchain.toml @@ -0,0 +1,3 @@ +[toolchain] +channel = "1.95.0" +components = ["rustfmt", "clippy"] From bf57a90c12ada34884fc62c7712933ee1f292d20 Mon Sep 17 00:00:00 2001 From: Patrick Kunzmann Date: Thu, 16 Apr 2026 16:45:19 +0200 Subject: [PATCH 2/2] Fix lint --- src/rust/structure/celllist.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rust/structure/celllist.rs b/src/rust/structure/celllist.rs index b57637b23..73291d02c 100644 --- a/src/rust/structure/celllist.rs +++ b/src/rust/structure/celllist.rs @@ -198,7 +198,7 @@ impl CellGrid { let mut data: Vec = vec![T::default(); total_count]; // Third iteration: Fill the data vector - for (position, element) in positions.iter().zip(elements.into_iter()) { + for (position, element) in positions.iter().zip(elements) { let linear_idx = position[0] * stride_i + position[1] * stride_j + position[2]; let end_idx = linear_idx * 2 + 1; let current_index = offsets[end_idx];