Hello Aztec community,
I have several questions
Here’s a function to check whether a value is in the hash’s integrity:
fn main(hash: pub Field, a: Field, b: Field, c: Field, d: Field) {
let hashPoseidon = std::hash::poseidon::bn254::hash_4([a, b, c, d]);
std::println(hashPoseidon);
assert(hash == hashPoseidon);
}
Am I using the most efficient hash function? (Compared to pedersen)
This function works very well with nargo test, prove, verify, but it’s only when I generate a proof with JS.
Sometimes i have this message:
“Error: the string “Error calling
foreign_call_callback
: Unknown” was thrown, throw an Error”
And sometimes I am told that the constraints are not respected.
What should I send? a hexadecimal string? a bigInt? an uint8Array?
I have an older version of JS-project that uses:
"@noir-lang/acvm_js": "git+https://git@github.com/noir-lang/acvm-simulator-wasm.git#b9d9ca9dfc5140839f23998d9466307215607c42"
What do you recommend? I’m stuck
Thank in advance.