Repository navigation
feat(circuits): release 0.15.0 with memo-bound transfer/unshield v2 beside v1, and multi-version build tooling - #21
Merged
Conversation
…eside v1, and multi-version build tooling
…y fees are claimed publicly
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Releases
@orbinum/circuits0.15.0. It ships memo-bound v2 oftransferandunshieldalongside the published v1, with v2 active, and removes the unusedvalue_proofcircuit. The chain activates v2 and retires v1 in the runtime spec 16 upgrade, using keys embedded in the runtime.Ceremony (v2):
pot16_final.ptau, with fresh random entropy for each circuit.0x39c0d3042e4de951d72540b487175894ae4e3092237c4d71833e2884acb1f6ec, with 2^10 iterations.vk_hash(unchanged)vk_hash0x4f93eaab…4f210x8eb9dbb295ce10498fbe7088a4b0f327a675094d657170725d027707116345250x9928482f…945e0x729c4cced3306e89d0dd977448768cc9c39cc806a393dea8cd8fe2946eb19babv1 artifacts and their manifest entries are byte-identical to 0.14.0.
Type of Change
Related Issue
None. This is part of the runtime spec 16 release (memo binding and public relay fee claims).
Changes Made
Circuits
memo_hash = blake2_256(SCALE(memos)) mod ris the new last public input oftransferandunshield(v2). Until now a copier could swap the encrypted memos of a pending spend and make its notes unrecoverable. Transfer hashes both output memos, in order; unshield hashes its change memo, which is empty for a total unshield.value_proofremoved. Relay fees are claimed publicly since spec 16 (no note, no proof), so circuit id 6 has no caller; no node or client ever proved it. Its source, tests, fixture, manifest entry and docs are gone. Packages up to 0.14.0 keep its artifacts.Multi-version tooling
The build assumed one version per circuit, so a rotation broke the tree:
ROTATE_VERSIONfor circuits listed inROTATE_CIRCUIT, under_v{n}names. Before, compiling overwrote the v1 wasm and r1cs and deleted<circuit>_js/.pnpm run manifestwithout rotation keeps every version. It used to rebuild each circuit as a single v1 entry, so the CI regeneration check would have dropped v2.ROTATE_CIRCUITaccepts a comma-separated list. Circuits not being rotated keep their published entry.transfer/unshieldtests compile intobuild/test-circuits/, so they no longer corrupt the published artifacts.rotation.testrotates to the version after the highest one in the manifest.npm package
getCircuitPaths(circuit, version?)returns the active version by default, together with itsversion. Before, it always returned the v1 paths."transfer" | "unshield".Docs
docs/RELEASE.md: how to build and publish a rotation.value_proofremoved.CHANGELOG.md: new 0.15.0 section.Testing
test:strict243 passing, 0 failing, 0 pendingrelease:restore→ v1 canonical;release:verifypasses before and after the test suitepnpm run check: lint, typecheck, format, circom lintbuild-all --compile-only→release:verify): v2 compiles deterministicallyembed-v2.sh): hashes match the manifestsetCode→ spec 16 upgrade 35/35, relay suite 114/114, memo clients 32/32Circuit Changes
Affected Circuits:
Constraint Count Impact:
memo_hash_sq <== memo_hash * memo_hash, which keeps the input from being optimized away.Performance Impact
Benchmarks: not measured. The change is one constraint per circuit, so no measurable change in proving or verification time is expected.
Breaking Changes
@orbinum/proof-generator^7.2.0.@orbinum/wallet-sdkmust bumpCIRCUITS_PACKAGE_VERSIONto0.15.0.value_proofis no longer in the package.getCircuitPaths("value_proof")throws.getCircuitPathsdefaults to the active version (v2). Callers that need v1 pass1.Checklist
Additional Notes
Build & TestandCanonical vk_hashfail with a 404 for the v2 keys. CI restores keys from npmlatest, and v2 only exists on the release machine until it is published.docs/RELEASE.md): publish 0.15.0 from this branch, re-run CI, then merge without squashing so the tagv0.15.0stays onmain.setCode.