Skip to content

Commit

Permalink
only add stdin to non-blocking channels if there is content for it
Browse files Browse the repository at this point in the history
  • Loading branch information
lexming committed Dec 22, 2024
1 parent 8131448 commit 24b22a8
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions easybuild/tools/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -514,9 +514,12 @@ def to_cmd_str(cmd):

if qa_patterns:
# make stdout, stderr, stdin non-blocking files
channels = [proc.stdout, proc.stdin]
channels = [proc.stdout]
if stdin:
channels.append(proc.stdin)
if split_stderr:
channels += proc.stderr
channels.append(proc.stderr)

for channel in channels:
fd = channel.fileno()
flags = fcntl.fcntl(fd, fcntl.F_GETFL)
Expand Down

0 comments on commit 24b22a8

Please sign in to comment.