From 152a2dcdefa6ec744db5b106d5c0a8c5b8aca416 Mon Sep 17 00:00:00 2001 From: Martin Zumsande Date: Tue, 28 Jan 2025 17:18:00 -0500 Subject: [PATCH] test: fix intermittent timeout in p2p_1p1c_network.py The timeout is due to outstanding txrequests with python peers. Fix this by disconnecting these peers after they send their txns, they aren't needed after this point anyway. --- test/functional/p2p_1p1c_network.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/functional/p2p_1p1c_network.py b/test/functional/p2p_1p1c_network.py index 2f6e3eeb700..e48e5b88b67 100755 --- a/test/functional/p2p_1p1c_network.py +++ b/test/functional/p2p_1p1c_network.py @@ -144,6 +144,11 @@ def run_test(self): for tx in transactions_to_presend[i]: peer.send_and_ping(msg_tx(tx)) + # Disconnect python peers to clear outstanding orphan requests with them, avoiding timeouts. + # We are only interested in the syncing behavior between real nodes. + for i in range(self.num_nodes): + self.nodes[i].disconnect_p2ps() + self.log.info("Submit full packages to node0") for package_hex in packages_to_submit: submitpackage_result = self.nodes[0].submitpackage(package_hex)