Skip to content

CI: Fix bitrot job #4111

CI: Fix bitrot job

CI: Fix bitrot job #4111

GitHub Actions / Clippy (beta) failed Jul 7, 2025 in 3s

Clippy (beta)

1 error, 193 warnings

Details

Results

Message level Amount
Internal compiler error 0
Error 1
Warning 193
Note 0
Help 0

Versions

  • rustc 1.89.0-beta.3 (b5e10d8c0 2025-07-02)
  • cargo 1.89.0-beta.3 (c24e10642 2025-06-23)
  • clippy 0.1.89 (b5e10d8c00 2025-07-02)

Annotations

Check failure on line 460 in halo2_gadgets/src/utilities.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

the method `next_u64` exists for struct `rand::rngs::OsRng`, but its trait bounds were not satisfied

error[E0599]: the method `next_u64` exists for struct `rand::rngs::OsRng`, but its trait bounds were not satisfied
   --> halo2_gadgets/src/utilities.rs:460:27
    |
460 |             let int = rng.next_u64();
    |                           ^^^^^^^^
    |
   ::: /home/runner/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/rand_core-0.6.4/src/os.rs:48:1
    |
48  | pub struct OsRng;
    | ---------------- doesn't satisfy `rand::rngs::OsRng: lazy_static::__Deref`, `rand::rngs::OsRng: proptest::prelude::RngCore` or `rand::rngs::OsRng: std::ops::DerefMut`
    |
    = note: the following trait bounds were not satisfied:
            `rand::rngs::OsRng: std::ops::DerefMut`
            which is required by `rand::rngs::OsRng: proptest::prelude::RngCore`
            `rand::rngs::OsRng: lazy_static::__Deref`
            which is required by `rand::rngs::OsRng: proptest::prelude::RngCore`
    = help: items from traits can only be used if the trait is in scope
help: trait `RngCore` which provides `next_u64` is implemented but not in scope; perhaps you want to import it
    |
242 +     use rand::RngCore;
    |

Check warning on line 127 in halo2_gadgets/benches/poseidon.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

the borrowed expression implements the required traits

warning: the borrowed expression implements the required traits
   --> halo2_gadgets/benches/poseidon.rs:127:25
    |
127 |         val.pow_vartime(&[5])
    |                         ^^^^ help: change this to: `[5]`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrows_for_generic_args
    = note: `-W clippy::needless-borrows-for-generic-args` implied by `-W clippy::all`
    = help: to override `-W clippy::all` add `#[allow(clippy::needless_borrows_for_generic_args)]`

Check warning on line 127 in halo2_gadgets/src/utilities.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

use of `default` to create a unit struct

warning: use of `default` to create a unit struct
   --> halo2_gadgets/src/utilities.rs:127:23
    |
127 |             _phantom: PhantomData::default(),
    |                       ^^^^^^^^^^^-----------
    |                                  |
    |                                  help: remove this call to `default`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#default_constructed_unit_structs

Check warning on line 118 in halo2_gadgets/src/utilities.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

use of `default` to create a unit struct

warning: use of `default` to create a unit struct
   --> halo2_gadgets/src/utilities.rs:118:23
    |
118 |             _phantom: PhantomData::default(),
    |                       ^^^^^^^^^^^-----------
    |                                  |
    |                                  help: remove this call to `default`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#default_constructed_unit_structs

Check warning on line 103 in halo2_gadgets/src/utilities.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

use of `default` to create a unit struct

warning: use of `default` to create a unit struct
   --> halo2_gadgets/src/utilities.rs:103:23
    |
103 |             _phantom: PhantomData::default(),
    |                       ^^^^^^^^^^^-----------
    |                                  |
    |                                  help: remove this call to `default`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#default_constructed_unit_structs

Check warning on line 375 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:375:16
    |
375 |             || format!("2^(-{})", num_bits),
    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
375 -             || format!("2^(-{})", num_bits),
375 +             || format!("2^(-{num_bits})"),
    |

Check warning on line 366 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:366:16
    |
366 |             || format!("element * 2^({}-{})", K, num_bits),
    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
366 -             || format!("element * 2^({}-{})", K, num_bits),
366 +             || format!("element * 2^({K}-{num_bits})"),
    |

Check warning on line 331 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:331:16
    |
331 |             || format!("Range check {:?} bits", num_bits),
    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
331 -             || format!("Range check {:?} bits", num_bits),
331 +             || format!("Range check {num_bits:?} bits"),
    |

Check warning on line 307 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:307:16
    |
307 |             || format!("Range check {:?} bits", num_bits),
    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
307 -             || format!("Range check {:?} bits", num_bits),
307 +             || format!("Range check {num_bits:?} bits"),
    |

Check warning on line 188 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/utilities/lookup_range_check.rs:188:16
    |
188 |             || format!("{:?} words range check", num_words),
    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
188 -             || format!("{:?} words range check", num_words),
188 +             || format!("{num_words:?} words range check"),
    |

Check warning on line 52 in halo2_gadgets/src/utilities/lookup_range_check.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

use of `default` to create a unit struct

warning: use of `default` to create a unit struct
  --> halo2_gadgets/src/utilities/lookup_range_check.rs:52:27
   |
52 |                 _phantom: PhantomData::default(),
   |                           ^^^^^^^^^^^-----------
   |                                      |
   |                                      help: remove this call to `default`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#default_constructed_unit_structs

Check warning on line 135 in halo2_gadgets/src/sinsemilla.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sinsemilla.rs:135:47
    |
135 |                         layouter.namespace(|| format!("message piece {}", i)),
    |                                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
135 -                         layouter.namespace(|| format!("message piece {}", i)),
135 +                         layouter.namespace(|| format!("message piece {i}")),
    |

Check warning on line 195 in halo2_gadgets/src/sinsemilla/primitives.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sinsemilla/primitives.rs:195:24
    |
195 |         let r_prefix = format!("{}-r", domain);
    |                        ^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
195 -         let r_prefix = format!("{}-r", domain);
195 +         let r_prefix = format!("{domain}-r");
    |

Check warning on line 194 in halo2_gadgets/src/sinsemilla/primitives.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sinsemilla/primitives.rs:194:24
    |
194 |         let m_prefix = format!("{}-M", domain);
    |                        ^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
194 -         let m_prefix = format!("{}-M", domain);
194 +         let m_prefix = format!("{domain}-M");
    |

Check warning on line 161 in halo2_gadgets/src/sinsemilla/merkle.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sinsemilla/merkle.rs:161:39
    |
161 |                 layouter.namespace(|| format!("MerkleCRH({}, left, right)", l)),
    |                                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
161 -                 layouter.namespace(|| format!("MerkleCRH({}, left, right)", l)),
161 +                 layouter.namespace(|| format!("MerkleCRH({l}, left, right)")),
    |

Check warning on line 328 in halo2_gadgets/src/sinsemilla/merkle/chip.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sinsemilla/merkle/chip.rs:328:28
    |
328 |                         || format!("l {}", l),
    |                            ^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
328 -                         || format!("l {}", l),
328 +                         || format!("l {l}"),
    |

Check warning on line 301 in halo2_gadgets/src/sinsemilla/merkle/chip.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sinsemilla/merkle/chip.rs:301:35
    |
301 |             layouter.namespace(|| format!("hash at l = {}", l)),
    |                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
301 -             layouter.namespace(|| format!("hash at l = {}", l)),
301 +             layouter.namespace(|| format!("hash at l = {l}")),
    |

Check warning on line 177 in halo2_gadgets/src/sha256/table16/message_schedule/subregion3.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sha256/table16/message_schedule/subregion3.rs:177:20
    |
177 |                 || format!("carry_{}", new_word_idx),
    |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
177 -                 || format!("carry_{}", new_word_idx),
177 +                 || format!("carry_{new_word_idx}"),
    |

Check warning on line 171 in halo2_gadgets/src/sha256/table16/message_schedule/subregion3.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sha256/table16/message_schedule/subregion3.rs:171:20
    |
171 |                 || format!("W_{}", new_word_idx),
    |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
171 -                 || format!("W_{}", new_word_idx),
171 +                 || format!("W_{new_word_idx}"),
    |

Check warning on line 261 in halo2_gadgets/src/sha256/table16/message_schedule/subregion2.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sha256/table16/message_schedule/subregion2.rs:261:20
    |
261 |                 || format!("carry_{}", new_word_idx),
    |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
261 -                 || format!("carry_{}", new_word_idx),
261 +                 || format!("carry_{new_word_idx}"),
    |

Check warning on line 255 in halo2_gadgets/src/sha256/table16/message_schedule/subregion2.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sha256/table16/message_schedule/subregion2.rs:255:20
    |
255 |                 || format!("W_{}", new_word_idx),
    |                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
255 -                 || format!("W_{}", new_word_idx),
255 +                 || format!("W_{new_word_idx}"),
    |

Check warning on line 173 in halo2_gadgets/src/sha256/table16/message_schedule/schedule_util.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sha256/table16/message_schedule/schedule_util.rs:173:16
    |
173 |             || format!("W_{}", word_idx),
    |                ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
173 -             || format!("W_{}", word_idx),
173 +             || format!("W_{word_idx}"),
    |

Check warning on line 168 in halo2_gadgets/src/sha256/table16/message_schedule/schedule_util.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sha256/table16/message_schedule/schedule_util.rs:168:51
    |
168 |             AssignedBits::<16>::assign(region, || format!("W_{}_hi", word_idx), a_4, row, w_hi_val)?
    |                                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
168 -             AssignedBits::<16>::assign(region, || format!("W_{}_hi", word_idx), a_4, row, w_hi_val)?
168 +             AssignedBits::<16>::assign(region, || format!("W_{word_idx}_hi"), a_4, row, w_hi_val)?
    |

Check warning on line 164 in halo2_gadgets/src/sha256/table16/message_schedule/schedule_util.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

variables can be used directly in the `format!` string

warning: variables can be used directly in the `format!` string
   --> halo2_gadgets/src/sha256/table16/message_schedule/schedule_util.rs:164:51
    |
164 |             AssignedBits::<16>::assign(region, || format!("W_{}_lo", word_idx), a_3, row, w_lo_val)?
    |                                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
    |
164 -             AssignedBits::<16>::assign(region, || format!("W_{}_lo", word_idx), a_3, row, w_lo_val)?
164 +             AssignedBits::<16>::assign(region, || format!("W_{word_idx}_lo"), a_3, row, w_lo_val)?
    |

Check warning on line 284 in halo2_gadgets/src/sha256/table16/compression/compression_gates.rs

See this annotation in the file changed.

@github-actions github-actions / Clippy (beta)

very complex type used. Consider factoring parts into `type` definitions

warning: very complex type used. Consider factoring parts into `type` definitions
   --> halo2_gadgets/src/sha256/table16/compression/compression_gates.rs:280:10
    |
280 |       ) -> Constraints<
    |  __________^
281 | |         F,
282 | |         (&'static str, Expression<F>),
283 | |         impl Iterator<Item = (&'static str, Expression<F>)>,
284 | |     > {
    | |_____^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity