We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a0b1e57 commit fa4535dCopy full SHA for fa4535d
test/functional/combine_logs.py
@@ -6,8 +6,8 @@
6
7
import argparse
8
from collections import defaultdict, namedtuple
9
-import glob
10
import heapq
+import itertools
11
import os
12
import re
13
import sys
@@ -49,7 +49,10 @@ def read_logs(tmp_dir):
49
for each of the input log files."""
50
51
files = [("test", "%s/test_framework.log" % tmp_dir)]
52
- for i, logfile in enumerate(glob.glob("%s/node*/regtest/debug.log" % tmp_dir)):
+ for i in itertools.count():
53
+ logfile = "{}/node{}/regtest/debug.log".format(tmp_dir, i)
54
+ if not os.path.isfile(logfile):
55
+ break
56
files.append(("node%d" % i, logfile))
57
58
return heapq.merge(*[get_log_events(source, f) for source, f in files])
0 commit comments