Skip to content

Commit 77697b8

Browse files
committed
test: Do not connect the nodes in parallel
1 parent 17c065d commit 77697b8

File tree

1 file changed

+3
-15
lines changed

1 file changed

+3
-15
lines changed

test/functional/test_framework/test_framework.py

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
# file COPYING or http://www.opensource.org/licenses/mit-license.php.
55
"""Base class for RPC testing."""
66

7-
from concurrent.futures import ThreadPoolExecutor
87
from enum import Enum
98
from io import BytesIO
109
import logging
@@ -373,22 +372,11 @@ def disconnect_nodes_helper(from_connection, node_num):
373372
disconnect_nodes_helper(self.nodes[a], b)
374373

375374
def connect_nodes_clique(self, nodes):
376-
# max_workers should be the maximum number of nodes that we have in the same functional test,
377-
# 15 seems to be a good upper bound
378-
parallel_exec = ThreadPoolExecutor(max_workers=15)
379375
l = len(nodes)
380-
381-
def connect_nodes_clique_internal(a):
382-
for b in range(0, l):
383-
self.connect_nodes(a, b)
384-
jobs = []
385376
for a in range(l):
386-
jobs.append(parallel_exec.submit(connect_nodes_clique_internal, a))
387-
388-
for job in jobs:
389-
job.result()
390-
jobs.clear()
391-
parallel_exec.shutdown()
377+
for b in range(a, l):
378+
self.connect_nodes(a, b)
379+
self.connect_nodes(b, a)
392380

393381
def split_network(self):
394382
"""

0 commit comments

Comments
 (0)