Skip to content

feat!: auto-enqueue public init nullifier for contracts with public functions (#20775) [v4-next backport]#21417

Closed
AztecBot wants to merge 3 commits intobackport-to-v4-next-stagingfrom
claudebox/backport-20775-auto-enqueue-init-nullifier
Closed

feat!: auto-enqueue public init nullifier for contracts with public functions (#20775) [v4-next backport]#21417
AztecBot wants to merge 3 commits intobackport-to-v4-next-stagingfrom
claudebox/backport-20775-auto-enqueue-init-nullifier

Conversation

@AztecBot
Copy link
Collaborator

Summary

Backport of #20775 to v4-next.

Contract initialization now emits two separate nullifiers (private + public) instead of one, fixing a race condition where public functions could be called before initialization completes.

Cherry-pick conflicts resolved

  • migration_notes.md: Added new migration notes section (empty on v4-next)
  • aztec.nr: Adapted imports for v4-next (no offchain_receive module)
  • constants.nr: Added DOM_SEP__PUBLIC_INITIALIZATION_NULLIFIER
  • constants_tests.nr: Adjusted HashedValueTester counts to <51, 44> (v4-next lacks SINGLE_USE_CLAIM_NULLIFIER that next has)
  • e2e_ha_full.test.ts: Dropped reloadKeystore test context (doesn't exist on v4-next)

Commit structure

  1. Cherry-pick with conflict markers (for reviewer visibility)
  2. Conflict resolution
  3. Build fix: adjust HashedValueTester counts for v4-next

ClaudeBox log: https://claudebox.work/s/486d6d3ab82ec418?run=1

@AztecBot AztecBot added the claudebox Owned by claudebox. it can push to this PR. label Mar 12, 2026
@ludamad ludamad force-pushed the backport-to-v4-next-staging branch from 5c50c04 to 4eb8703 Compare March 12, 2026 19:33
nchamo and others added 3 commits March 12, 2026 15:39
…with public functions (#20775)

Cherry-pick of cee97a1 with conflict markers preserved for reviewer visibility.
Resolved conflicts in:
- docs/docs-developers/docs/resources/migration_notes.md: added new migration notes section
- noir-projects/aztec-nr/aztec/src/macros/aztec.nr: adapted imports for v4-next (no offchain_receive)
- noir-projects/noir-protocol-circuits/crates/types/src/constants.nr: added DOM_SEP__PUBLIC_INITIALIZATION_NULLIFIER
- noir-projects/noir-protocol-circuits/crates/types/src/constants_tests.nr: updated HashedValueTester counts
- yarn-project/end-to-end/src/composed/ha/e2e_ha_full.test.ts: dropped reloadKeystore test (not on v4-next)
v4-next has one fewer domain separator (no SINGLE_USE_CLAIM_NULLIFIER)
than next did before the PR, so the counts are <51, 44> instead of <52, 45>.
@ludamad ludamad force-pushed the claudebox/backport-20775-auto-enqueue-init-nullifier branch from 030fdfe to 1f468dd Compare March 12, 2026 19:39
@ludamad
Copy link
Collaborator

ludamad commented Mar 12, 2026

Closing as duplicate — superseded by a newer attempt.

@ludamad ludamad closed this Mar 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

claudebox Owned by claudebox. it can push to this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants