You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jul 13, 2021. It is now read-only.
ProcessHelper.run_subprocess currently returns return value of a command that it executes. However if anybody wants to get standard output of the command, the only option is to save it to a file and then read this file. This seems ridiculous to me.
Update the run_subprocess so it returns the captured standard output into alongside the return value, for example in a tuple. Then no temp file is needed just to read the command output.
The text was updated successfully, but these errors were encountered:
Is the helper even necessary, though? Why not just use Python's standard lib?
It does some juggling with coding and stuff, but I'm not sure why/if it's really needed. I just used subprocess.Popen directly (maybe even should have used subprocess.check_output but I thought I need the other one to pass environment) and it worked just fine.
ProcessHelper.run_subprocess currently returns return value of a command that it executes. However if anybody wants to get standard output of the command, the only option is to save it to a file and then read this file. This seems ridiculous to me.
Update the run_subprocess so it returns the captured standard output into alongside the return value, for example in a tuple. Then no temp file is needed just to read the command output.
The text was updated successfully, but these errors were encountered: