Skip to content

Commit 2311d3a

Browse files
committed
system_test: Don't treat empty lines as EOF in process output
1 parent 6e4402c commit 2311d3a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

system_test/db/infra.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,13 +77,15 @@ def run_cmd(cmd, env_vars={}, silent=True, silent_error=None) -> str:
7777
for fd, e in events:
7878
fdobj = fd_map[fd]
7979
instr = fdobj["stream"]
80-
line = instr.readline().rstrip("\n")
80+
line = instr.readline()
8181

8282
if not line:
8383
if exited is not None:
8484
fdobj["eof"] = True
8585
continue
8686

87+
line = line.rstrip()
88+
8789
fdobj["eof"] = False
8890
output_lines.append(line)
8991
if not fdobj["silent"]:

0 commit comments

Comments
 (0)