Skip to content

Commit 531a033

Browse files
committed
Merge #13421: qa: Remove portseed_offset from test runner
fa6edfe qa: Remove portseed_offset from test runner (MarcoFalke) Pull request description: The portseed_offset is no longer needed in the test runner, since we already kill leftover processes (see #12904). This "fixes" #10869 because we deterministically pick ports starting at 11000 Tree-SHA512: 1ee22e19e02acd3afadc7c6a2b391fd3b5cfcec22c0fe194f3207251e7b1264a04e47d90a3ff8be4aca7d0ec33219a2f5855076acb3565291767939bc2f2fa17
2 parents 6e249e4 + fa6edfe commit 531a033

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

test/functional/test_runner.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -419,18 +419,14 @@ def __init__(self, num_tests_parallel, tests_dir, tmpdir, test_list=None, flags=
419419
self.test_list = test_list
420420
self.flags = flags
421421
self.num_running = 0
422-
# In case there is a graveyard of zombie bitcoinds, we can apply a
423-
# pseudorandom offset to hopefully jump over them.
424-
# (625 is PORT_RANGE/MAX_NODES)
425-
self.portseed_offset = int(time.time() * 1000) % 625
426422
self.jobs = []
427423

428424
def get_next(self):
429425
while self.num_running < self.num_jobs and self.test_list:
430426
# Add tests
431427
self.num_running += 1
432428
test = self.test_list.pop(0)
433-
portseed = len(self.test_list) + self.portseed_offset
429+
portseed = len(self.test_list)
434430
portseed_arg = ["--portseed={}".format(portseed)]
435431
log_stdout = tempfile.SpooledTemporaryFile(max_size=2**16)
436432
log_stderr = tempfile.SpooledTemporaryFile(max_size=2**16)

0 commit comments

Comments
 (0)