Skip to content

fix: search for all note nonces instead of just the one for the note index#21438

Merged
nventuro merged 1 commit intomerge-train/fairiesfrom
nico/f-428-fix-note-discovery-to-try-all-possible-indices-when
Mar 12, 2026
Merged

fix: search for all note nonces instead of just the one for the note index#21438
nventuro merged 1 commit intomerge-train/fairiesfrom
nico/f-428-fix-note-discovery-to-try-all-possible-indices-when

Conversation

@nventuro
Copy link
Contributor

We now search in all indices instead of just the one for the corresponding note hash.

Copy link
Contributor

@sirasistant sirasistant left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@nventuro nventuro enabled auto-merge (squash) March 12, 2026 17:32
@nventuro nventuro merged commit 910d230 into merge-train/fairies Mar 12, 2026
16 of 20 checks passed
@nventuro nventuro deleted the nico/f-428-fix-note-discovery-to-try-all-possible-indices-when branch March 12, 2026 17:37
@AztecBot
Copy link
Collaborator

❌ Failed to cherry-pick to v4-next due to conflicts. (🤖) View backport run.

AztecBot pushed a commit that referenced this pull request Mar 12, 2026
…index (#21438)

We now search in all indices instead of just the one for the
corresponding note hash.
AztecBot pushed a commit that referenced this pull request Mar 12, 2026
…index (#21438)

We now search in all indices instead of just the one for the
corresponding note hash.
nventuro added a commit that referenced this pull request Mar 12, 2026
…index (backport #21438) (#21440)

## Summary
Backport of #21438
to `v4-next`.

Cherry-pick applied cleanly with no conflicts.

## Changes
- Search all possible note hash indices for nonces instead of just the
one corresponding to the note hash index
- Add `bvec_filter` helper for filtering `BoundedVec`
- Add tests for misaligned nonces, out-of-bounds indices, and duplicate
unique note hashes

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

---------

Co-authored-by: Nicolás Venturo <nicolas.venturo@gmail.com>
ludamad pushed a commit that referenced this pull request Mar 12, 2026
…index (backport #21438) (#21440)

## Summary
Backport of #21438
to `v4-next`.

Cherry-pick applied cleanly with no conflicts.

## Changes
- Search all possible note hash indices for nonces instead of just the
one corresponding to the note hash index
- Add `bvec_filter` helper for filtering `BoundedVec`
- Add tests for misaligned nonces, out-of-bounds indices, and duplicate
unique note hashes

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

---------

Co-authored-by: Nicolás Venturo <nicolas.venturo@gmail.com>
github-merge-queue bot pushed a commit that referenced this pull request Mar 13, 2026
BEGIN_COMMIT_OVERRIDE
fix: skip oracle version check for pinned protocol contracts (#21349)
fix: not reusing tags of partially reverted txs (#20817)
feat: move storage_slot from partial commitment to completion hash
(#21351)
feat: offchain reception (#20893)
fix: handle workspace members in needsRecompile crate collection
(#21284)
fix(aztec-nr): return Option from decode functions and fix event
commitment capacity (#21264)
fix: handle bad note lengths on compute_note_hash_and_nullifier (#21271)
fix: address review feedback from PRs #21284 and #21237 (#21369)
fix: claim contract & improve nullif docs (#21234)
feat!: auto-enqueue public init nullifier for contracts with public
functions (#20775)
fix: search for all note nonces instead of just the one for the note
index (#21438)
fix: set anvilSlotsInAnEpoch in e2e_offchain_payment to prevent
finalization race (#21452)
fix: complete legacy oracle mappings for all pinned contracts (#21404)
fix: correct inverted constrained encryption check in message delivery
(#21399)
feat!: improve L2ToL1MessageWitness API (#21231)
END_COMMIT_OVERRIDE
nventuro added a commit that referenced this pull request Mar 18, 2026
This should fix the performance regression from
#21438. Marked as a
breaking change since some contracts might call `attempt_note_discovery`
manually.

Fixes F-344.
Fixes #11157

---------

Co-authored-by: AztecBot <tech@aztec-labs.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants