Skip to content

Commit

Permalink
chore: update rust toolchain (#266)
Browse files Browse the repository at this point in the history
* chore: fix link (#256)

* chore: update `snark-verifier` git tag in `zkevm-hashes`

* chore: update rust toolchain

* chore: fix clippy

* chore: update should_panic message

* chore: switch to community-edition

---------

Co-authored-by: yanziseeker <[email protected]>
  • Loading branch information
jonathanpwang and AdventureSeeker987 authored Mar 22, 2024
1 parent d9a1f91 commit a471b14
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 11 deletions.
2 changes: 1 addition & 1 deletion halo2-base/src/gates/flex_gate/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ impl<F: ScalarField> FlexGateConfig<F> {
Self {
basic_gates,
constants,
/// Warning: this needs to be updated if you create more advice columns after this `FlexGateConfig` is created
// Warning: this needs to be updated if you create more advice columns after this `FlexGateConfig` is created
max_rows: (1 << params.k) - meta.minimum_rows(),
}
}
Expand Down
8 changes: 4 additions & 4 deletions halo2-base/src/poseidon/hasher/tests/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,18 @@ mod state;
fn test_mds() {
let spec = OptimizedPoseidonSpec::<Fr, 3, 2>::new::<8, 57, 0>();

let mds = vec![
vec![
let mds = [
[
"7511745149465107256748700652201246547602992235352608707588321460060273774987",
"10370080108974718697676803824769673834027675643658433702224577712625900127200",
"19705173408229649878903981084052839426532978878058043055305024233888854471533",
],
vec![
[
"18732019378264290557468133440468564866454307626475683536618613112504878618481",
"20870176810702568768751421378473869562658540583882454726129544628203806653987",
"7266061498423634438633389053804536045105766754026813321943009179476902321146",
],
vec![
[
"9131299761947733513298312097611845208338517739621853568979632113419485819303",
"10595341252162738537912664445405114076324478519622938027420701542910180337937",
"11597556804922396090267472882856054602429588299176362916247939723151043581408",
Expand Down
8 changes: 6 additions & 2 deletions halo2-ecc/src/secp256k1/tests/ecdsa_tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,18 @@ fn custom_parameters_ecdsa(sk: u64, msg_hash: u64, k: u64) -> ECDSAInput {
}

#[test]
#[should_panic(expected = "assertion failed: `(left == right)`")]
#[should_panic(
expected = "assertion `left == right` failed\n left: 0x0000000000000000000000000000000000000000000000000000000000000000\n right: 0x0000000000000000000000000000000000000000000000000000000000000001"
)]
fn test_ecdsa_msg_hash_zero() {
let input = custom_parameters_ecdsa(random::<u64>(), 0, random::<u64>());
run_test(input);
}

#[test]
#[should_panic(expected = "assertion failed: `(left == right)`")]
#[should_panic(
expected = "assertion `left == right` failed\n left: 0x0000000000000000000000000000000000000000000000000000000000000000\n right: 0x0000000000000000000000000000000000000000000000000000000000000001"
)]
fn test_ecdsa_private_key_zero() {
let input = custom_parameters_ecdsa(0, random::<u64>(), random::<u64>());
run_test(input);
Expand Down
4 changes: 2 additions & 2 deletions hashes/zkevm/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "zkevm-hashes"
version = "0.2.1"
version = "0.2.2"
authors = ["Privacy Scaling Explorations Team", "Taiko Labs", "Intrinsic Technologies"]
license = "MIT OR Apache-2.0"
edition = "2021"
Expand All @@ -23,7 +23,7 @@ rayon = "1.8"
sha3 = "0.10.8"
# always included but without features to use Native poseidon and get CircuitExt trait
# snark-verifier-sdk = { version = "=0.1.7", default-features = false }
snark-verifier-sdk = { version = "=0.1.7", git = "https://github.com/axiom-crypto/snark-verifier.git", tag = "v0.1.7-git", default-features = false }
snark-verifier-sdk = { git = "https://github.com/axiom-crypto/snark-verifier.git", branch = "community-edition", default-features = false }
getset = "0.1.2"
type-map = "0.5.0"

Expand Down
2 changes: 1 addition & 1 deletion hashes/zkevm/src/keccak/component/circuit/tests/shard.rs
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ fn test_prove_shard_circuit_commit() {
circuit.set_base_circuit_break_points(break_points);

let circuit_outputs = multi_inputs_to_circuit_outputs::<Fr>(&inputs, circuit_params.capacity());
let instances = vec![vec![calculate_circuit_outputs_commit(&circuit_outputs)]];
let instances = [[calculate_circuit_outputs_commit(&circuit_outputs)]];

let proof = gen_proof_with_instances(
&params,
Expand Down
2 changes: 1 addition & 1 deletion rust-toolchain
Original file line number Diff line number Diff line change
@@ -1 +1 @@
nightly-2023-08-12
nightly-2024-02-08

0 comments on commit a471b14

Please sign in to comment.