test(payjoin): stop the fixture burning testnet funds at 1000 sat/vB - #2588
Merged
Conversation
The funded Payjoin fixture broadcast every transaction at 1000 sat/vB: the payjoin itself, and a drain-consolidation of each wallet before it. That is roughly 650k sats per run, on every run, of every open pull request. The fixture wallets emptied faster than they could be refilled, and once the balance landed just under what the next transaction needed the test failed and turned every open PR in the repository red. The failure that surfaced this was 341 sats short — 0.00119159 BTC available of 0.00119500 BTC needed. Nothing needed that fee rate. None of the assertions wait for a confirmation: the happy path waits for `PayjoinStatus.completed`, which is the protocol exchange with the receiver, and the expiry test waits for a session to lapse. `coins_test.dart` already spends on testnet at 2 sat/vB. Set to 10 sat/vB. Checked against mempool.space on 2026-08-10: testnet3 — which is what `ApiServiceConstants.testnetMempoolUrlPath` points at — and testnet4 both report 1 sat/vB across every tier, `fastestFee` included, so there is no backlog to outbid. Ten times that leaves a wide margin for testnet3's bursty block production, where the 20-minute difficulty reset makes intervals erratic and a transaction left unconfirmed between runs is what would corrupt the next run's UTXO set. Cost per run drops from about 650k sats to about 6.5k. The consolidation itself is kept: the skipped `supports concurrent Payjoins backed by distinct UTXOs` test documents that it exists to sidestep an upstream receiver-selection bug. It is no longer expensive, so it is no longer the problem.
|
Claude finished @ethicnology's task in 1m 37s —— View job Review: PR #2588 — payjoin fixture fee rate 1000 → 10 sat/vB
SummaryLGTM — no correctness bugs, security issues, or regressions found. The change is test-only, touches exactly the two places that broadcast at 1000 sat/vB, and the reasoning in the PR description holds up against the code. Note: I can't post formal inline review comments (my GitHub App permissions only allow updating this single comment), so findings are referenced by file/line here instead. What I verified
Minor, non-blocking
|
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.
The funded Payjoin fixture broadcast every transaction at 1000 sat/vB: the payjoin itself, and a drain-consolidation of each wallet before it. That is roughly 650k sats per run, on every run, of every open pull request. The fixture wallets emptied faster than they could be refilled, and once the balance landed just under what the next transaction needed the test failed and turned every open PR in the repository red. The failure that surfaced this was 341 sats short — 0.00119159 BTC available of 0.00119500 BTC needed.
Nothing needed that fee rate. None of the assertions wait for a confirmation: the happy path waits for
PayjoinStatus.completed, which is the protocol exchange with the receiver, and the expiry test waits for a session to lapse.coins_test.dartalready spends on testnet at 2 sat/vB.Set to 10 sat/vB. Checked against mempool.space on 2026-08-10: testnet3 — which is what
ApiServiceConstants.testnetMempoolUrlPathpoints at — and testnet4 both report 1 sat/vB across every tier,fastestFeeincluded, so there is no backlog to outbid. Ten times that leaves a wide margin for testnet3's bursty block production, where the 20-minute difficulty reset makes intervals erratic and a transaction left unconfirmed between runs is what would corrupt the next run's UTXO set.Cost per run drops from about 650k sats to about 6.5k.
The consolidation itself is kept: the skipped
supports concurrent Payjoins backed by distinct UTXOstest documents that it exists to sidestep an upstream receiver-selection bug. It is no longer expensive, so it is no longer the problem.