From 139d21173bd7bd73f437b581ff4fef7570e2fc4d Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Tue, 15 Apr 2025 14:08:29 +0930 Subject: [PATCH] pytest: fix test_recover_plugin flake It can try to reconnect while we're explicitly connecting: ``` 2025-04-15T03:40:53.9184103Z > l2.rpc.connect(l1.info['id'], 'localhost', l1.port) 2025-04-15T03:40:53.9184311Z 2025-04-15T03:40:53.9184401Z tests/test_misc.py:3078: ... 2025-04-15T03:40:53.9206302Z > raise RpcError(method, payload, resp['error']) 2025-04-15T03:40:53.9207225Z E pyln.client.lightning.RpcError: RPC call failed: method: connect, payload: {'id': '0266e4598d1d3c415f572a8488830b60f7e744ed9235eb0b1ba93283b315c03518', 'host': 'localhost', 'port': 45219}, error: {'code': 402, 'message': 'disconnected during connection'} ``` Signed-off-by: Rusty Russell --- tests/test_misc.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tests/test_misc.py b/tests/test_misc.py index 22645af690..a8547e0c7f 100644 --- a/tests/test_misc.py +++ b/tests/test_misc.py @@ -3048,7 +3048,8 @@ def test_recover_plugin(node_factory, bitcoind): feerates=(7500, 7500, 7500, 7500), options={ 'log-level': 'info', - 'experimental-peer-storage': None + 'experimental-peer-storage': None, + 'dev-no-reconnect': None, }, ) l2 = node_factory.get_node( @@ -3058,7 +3059,8 @@ def test_recover_plugin(node_factory, bitcoind): allow_bad_gossip=True, options={ 'log-level': 'info', - 'experimental-peer-storage': None + 'experimental-peer-storage': None, + 'dev-no-reconnect': None, }, )