You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not 100% sure, but I know there are a number of differences between v1 and v2 so the circuits will not work off the bat -- for instance, public and private variables need different keywords now, and public variables must be passed in through a constructor. Did you make those changes when you updated the circuits to v2?
I have reworked the build script and updated Circom to v2. Now the verification of
hash-check-bits
returns “Invalid Proof”.The commands being run are:
circom "circuits/hash-check-bits/circuit.circom" --r1cs --wasm --sym
npx snarkjs r1cs info "build/circuits/hash-check-bits/circuit.r1cs"
npx snarkjs groth16 setup "build/circuits/hash-check-bits/circuit.r1cs" "build/ptaus/pot20_final.ptau" "build/keys/hash-check-bits/circuit_0000.zkey"
npx snarkjs zkey contribute "build/keys/hash-check-bits/circuit_0000.zkey" "build/keys/hash-check-bits/circuit.zkey" --name="First Contribution" -e="1636810974283"
npx snarkjs zkey export verificationkey "build/keys/hash-check-bits/circuit.zkey" "build/keys/hash-check-bits/verification_key.json"
node "build/circuits/hash-check-bits/circuit_js/generate_witness.js" "build/circuits/hash-check-bits/circuit_js/circuit.wasm" "circuits/hash-check-bits/input.json" "build/circuits/hash-check-bits/witness.wtns"
npx snarkjs groth16 prove "build/keys/hash-check-bits/circuit.zkey" "build/circuits/hash-check-bits/witness.wtns" "build/circuits/hash-check-bits/proof.json" "build/circuits/hash-check-bits/public.json"
npx snarkjs groth16 verify "build/keys/hash-check-bits/verification_key.json" "build/circuits/hash-check-bits/public.json" "build/circuits/hash-check-bits/proof.json"
The text was updated successfully, but these errors were encountered: