Skip to content

Commit a5c232a

Browse files
committed
attach /dev/null to STDIN on run_shell_cmd without input content
1 parent a5e0937 commit a5c232a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

easybuild/tools/run.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -496,7 +496,7 @@ def to_cmd_str(cmd):
496496
executable, shell = None, False
497497

498498
stderr_handle = subprocess.PIPE if split_stderr else subprocess.STDOUT
499-
stdin_handle = subprocess.PIPE if stdin or qa_patterns else None
499+
stdin_handle = subprocess.PIPE if stdin or qa_patterns else subprocess.DEVNULL
500500

501501
log_msg = f"Running {interactive_msg}shell command '{cmd_str}' in {work_dir}"
502502
if thread_id:

0 commit comments

Comments
 (0)