chore: Accumulated backports to v5-next - #25113
Merged
Merged
Conversation
## Motivation Follow-up to #25074 and #25076 in the effort to reduce PXE↔node RPC traffic. Two calls per sent tx were guaranteed wasted: a pre-send `getTxReceipt` used only to reject settled duplicates, which the node's tx validation already rejects via its double-spend check, and the first receipt poll of `.wait()`, issued immediately after `sendTx` when the tx cannot have been mined yet. ## The change - `BaseWallet.sendTx` no longer reads the receipt before sending; duplicate submissions are rejected by the node instead. - `WaitOpts` gains `initialDelay`: seconds to sleep before the first receipt poll. The wallet defaults it to the poll interval, so the first poll now happens where the second poll used to. Environments where receipts are available immediately after sending (e.g. automine) can pass `initialDelay: 0`. - The delay counts against `timeout` (the deadline is fixed before sleeping) and does not consume the DROPPED-receipt grace period, which starts at the first poll. Wallet benchmark results: | | Before → After | |---|---| | `getTxReceipt` calls | 40 → 32 (−20.0%) | | Total node RPC calls | 232 → 224 (−3.4%) | | Node RPC round trips | 163 → 156 (−4.3%) |
nchamo
approved these changes
Aug 5, 2026
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.
BEGIN_COMMIT_OVERRIDE
feat(aztec.js): delay first receipt poll after sending a tx (#25089)
feat(pxe): hash-pinned node read cache (#24969)
feat(pxe): hash-pinned node read cache (backport #24969) (#25114)
feat(pxe): cache tag log queries bounded at the anchor block (#25074)
refactor(pxe): serve note and event validation from cached tx data (#25076)
END_COMMIT_OVERRIDE