fix(pxe): cap fresh secret pending tag indexes to the probed window (port #24667) - #24977
Merged
Conversation
…24667) We essentially have an off by one error for the starting finalized index for a fresh secret. - With nothing finalized on a secret, the store permitted pending indexes `0..WINDOW_LEN`, but sender sync only probes `[0, WINDOW_LEN)` and only advances the window after a finalization. - A pending tx at index `WINDOW_LEN` from another store sharing the secret (second PXE, or restored state) was therefore outside the initial probe, so the next locally picked index could reuse its onchain tag. Fix: cap fresh secrets at `0..WINDOW_LEN - 1`, the same `WINDOW_LEN` indexes allowed after any finalization. Every absolute window bound (sender permit, sender probe, recipient scan) now comes from one helper, `unfinalizedTaggingIndexesWindowEnd`, which also aligns the recipient's fresh-secret scan instead of leaving it one index wider than anything a sender can create. Behavior change: fresh secrets hit the "tagging window length configured too low" error at index `WINDOW_LEN`, one index earlier, and the recipient no longer scans index `WINDOW_LEN` for fresh secrets. Tests: the updated store and recipient sync tests are red on base and green with the fix; the existing straddle test pins the sender probe boundary. --------- Co-authored-by: AztecBot <tech@aztec-labs.com>
vezenovm
marked this pull request as ready for review
July 24, 2026 21:49
vezenovm
approved these changes
Jul 24, 2026
rangozd
pushed a commit
to rangozd/aztec-packages
that referenced
this pull request
Aug 5, 2026
BEGIN_COMMIT_OVERRIDE fix(foundation): always include a result key in json-rpc responses (AztecProtocol#24840) fix(pxe): cap fresh secret pending tag indexes to the probed window (port AztecProtocol#24667) (AztecProtocol#24977) fix(archiver): resolve L2-to-L1 witness from a single store snapshot (AztecProtocol#24754) fix(sequencer): stop signalling already-executed governance payloads (AztecProtocol#24764) fix(archiver): clean up removed blocks from raw rows and ownership-check tx-effect deletes (AztecProtocol#24765) fix(node): warm KZG trusted setup at startup (AztecProtocol#24775) feat(prover-node): stop caching checkpoint txs; re-fetch from the pool for failure upload (A-1216) (AztecProtocol#24983) fix(sequencer): log tx failure reason at warn when dropping from mempool (AztecProtocol#25000) feat(prover-client): stop duplicating broker job inputs/results in memory (A-1215) (AztecProtocol#24990) fix(prover-client): don't retain inline job inputs in the facade without a failed-proof store (A-1517) (AztecProtocol#25027) END_COMMIT_OVERRIDE
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.
Summary
Port of #24667 to
nextviaport-to-next-staging.unfinalizedTaggingIndexesWindowEndand used it for sender pending bounds plus sender/recipient scan windows.nextwindow length and recipient sync structure while adapting fresh-secret bounds to[0, WINDOW_LEN).Conflicts resolved
constants.ts: keptnext'sUNFINALIZED_TAGGING_INDEXES_WINDOW_LEN = MAX_PRIVATE_LOGS_PER_TXand added the shared helper.nextimplementation, without pulling in source-branch-only constrained probe changes.WINDOW_LENfresh pending indexes and rejection atWINDOW_LEN.Testing
JEST_MAX_WORKERS=1 yarn workspace @aztec/pxe test src/storage/tagging_store/sender_tagging_store.test.ts src/tagging/recipient_sync/sync_tagged_private_logs.test.tspassed: 61 tests.yarn buildwas attempted but this partial checkout is missing generated dependency outputs such as@aztec/l1-artifacts; the failure was in setup dependencies, not the PXE changes.Created by claudebox · group:
slackbot· Slack thread