From 2abcd8108e205802f73f2401c349d32d0f59f448 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Mon, 19 Jun 2023 17:20:09 +0930 Subject: [PATCH] pytest: fix race in test_penalty_rbf_normal We re-enable sendrawtransaction then mine a block to kick off RBF, but there's a race where it can get a tx in that block, and then we timeout waiting for both txs to get into the next block. Signed-off-by: Rusty Russell --- tests/test_closing.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/test_closing.py b/tests/test_closing.py index 2c450bd5f..623b74d7c 100644 --- a/tests/test_closing.py +++ b/tests/test_closing.py @@ -1652,7 +1652,9 @@ def test_penalty_rbf_normal(node_factory, bitcoind, executor, chainparams): # high-fee censored transactions, and fresh, non-censoring # hashpower arises, evicting the censor. l2.daemon.rpcproxy.mock_rpc('sendrawtransaction', None) - bitcoind.generate_block(1) + + # Make sure we don't mine any though! + bitcoind.generate_block(1, needfeerate=10000000) # This triggers the final RBF attempt start = l2.daemon.logsearch_start