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
v3 polls vote and close from a browser: voteCastHomomorphic_8 and tallyDecrypt_8 now prove via the regular loadKeys path; no more server-only close-poll workflow. Closes #3.
Root cause: gnark-crypto ecc/<curve>/twistededwards/point.go::PointExtended.Add reads curveParams.D without the initOnce.Do(initCurveParams) call its sibling Add/MixedAdd entry points all have. Anything that loads keys and proves — without first compiling a circuit in the same process — read curveParams.D == 0, mis-computed the scalar-mul hint, and tripped the in-circuit scalarMulFakeGLV check (constraint not satisfied). Latent on amd64; surfaced in the wasm browser flow because the browser only loads, never compiles. Full chase in docs/wasm-prove-bug.md.
In-process workaround, no fork: one line at the top of cmd/prover-wasm/main.go::main — _ = babyjubjub.GetEdwardsCurve() — arms gnark-crypto's sync.Once for the rest of the process. The Go server doesn't need it (frontend.Compile runs at startup and trips the same init).
CI green again: the Go-touching jobs all needed make wasm before make build / go vet / go test (the //go:embed all:*.wasm directive in public/embed.go requires the artifact to exist). Race-detector test pass split on -short so it doesn't time out under gnark's heavy ZK Setup.
Regression test: prover/wasm32_loadkeys_only_test.go re-execs go test in a subprocess to reproduce the bug deterministically — pre-fix it fails at constraint not satisfied; post-fix it passes. Wired into make test-wasm-prove alongside the wasm-side node repro.
Commits
b2e4bc2 ci: race-detector on -short, separate full pass without race
2e600e2 ci: bump race-test timeout to 30m, drop v3+prod from playwright
cbb918b ci: build wasm prover before vet/build/test/playwright jobs
472b76d fix: drop the gnark-crypto fork — workaround in our wasm main is enough