pytest: fix test_bitcoin_backend_gianttx flake.
What changed, and why it matters
This is a one-line change to a test file. It widens the expected log message pattern in a flaky test so that either 'fundpsbt' or 'signpsbt' slow operations are accepted, rather than only 'fundpsbt'. It does not change production code, user behavior, or security boundaries.
No security action needed. This is a test-only flake fix.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The commit modifies tests/test_plugin.py in test_bitcoin_backend_gianttx. The broken_log regex is changed from ‘Request fundpsbt took’ to ‘That’s weird: Request .*psbt took’, allowing the test to pass when signpsbt is the slow PSBT operation. This is purely a test-flake fix with no functional code changes.
Changed components
tests/test_plugin.pyInspect captured patch +1 / −1
diff --git a/tests/test_plugin.py b/tests/test_plugin.py
index f51e45c..d62ccf7 100644
--- a/tests/test_plugin.py
+++ b/tests/test_plugin.py
@@ -1904,7 +1904,7 @@ def test_bitcoin_backend(node_factory, bitcoind):
def test_bitcoin_backend_gianttx(node_factory, bitcoind):
"""Test that a giant tx doesn't crash bcli"""
# This complains about how long fundpsbt took.
- l1 = node_factory.get_node(start=False, broken_log='Request fundpsbt took')
+ l1 = node_factory.get_node(start=False, broken_log="That's weird: Request .*psbt took")
# With memleak we spend far too much time gathering backtraces.
if "LIGHTNINGD_DEV_MEMLEAK" in l1.daemon.env:
del l1.daemon.env["LIGHTNINGD_DEV_MEMLEAK"]
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.