fix(test): use checkpointed chain tip for e2e_p2p PXEs to avoid reorg race#22685
Merged
PhilWindle merged 1 commit intonextfrom Apr 23, 2026
Merged
fix(test): use checkpointed chain tip for e2e_p2p PXEs to avoid reorg race#22685PhilWindle merged 1 commit intonextfrom
PhilWindle merged 1 commit intonextfrom
Conversation
Maddiaa0
approved these changes
Apr 21, 2026
Contributor
|
Should we move it to the merge-train? |
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
Sets
syncChainTip: 'checkpointed'on the PXE instances used bysubmitTransactions/prepareTransactionsine2e_p2p/shared.tsand the cross-chain bridge PXE ine2e_p2p/add_rollup.test.ts. This matches the config already used by the mainP2PNetworkTestPXE and makes the remaining test-local PXEs immune to the archiver's "slot ended without being checkpointed" prune.Why
e2e_p2p/rediscovery.test.tsflaked onnextwith:CI log: http://ci.aztec-labs.com/90332e178cf20a05
Mechanism:
anchorBlockStoreadvances on every new proposed block (defaultsyncChainTip: 'proposed'). Each#executePrivate/#executeUtilitycall captures the current anchor and passes the block hash down intogetPrivateLogsByTags(referenceBlock).pruneUncheckpointedBlockscorrectly drops block 2 from the node's local chain.sync_stateutility still holds block 2's hash asreferenceBlock.getPrivateLogsByTagsthen throwsBlock <hash> not found in the node. This might indicate a reorg has occurred., which bubbles up and fails the test.With
syncChainTip: 'checkpointed', the PXE only advances its anchor onchain-checkpointedevents, so an uncheckpointed-then-pruned block can never become the reference for a sync_state query.The main test PXE in
P2PNetworkTest.setup()is already configured this way (p2p_network.ts:364, added in #22399) — this PR extends the same setting to the transient PXEs thatsubmitTransactions/prepareTransactions/ the bridging helper spin up.Notes
BlockReorgedErrorfrom the node + retry with refreshed anchor inContractSyncService. That's tracked separately.e2e_p2p/*.test.tsis already covered by thee2e-p2p-epoch-flakespattern in.test_patterns.yml, so this doesn't change CI pass/fail gating — it just reduces the flake rate.Full analysis: https://gist.github.com/AztecBot/bd68e0650e379f9c3e4e62a91ff2da13
ClaudeBox log: https://claudebox.work/s/66ccc62a64c65de9?run=4