-
Notifications
You must be signed in to change notification settings - Fork 2k
Enabling "conda run" to display real time output for the subprocess #10270
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enabling "conda run" to display real time output for the subprocess #10270
Conversation
FIX: inline p.poll() check Added unit tests for subprocess_call() with live stream Removed comment + minor changes
|
Hi @chenghlee, could you please take a look on this PR? |
mingwandroid
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. I'd probably say it should be the default to be honest with you. Also, can you handle stdin here? Seems like it should be possible.
|
I think this should be the default too. I didn't make it, because I wasn't sure if would be desirable to break the current behaviour, so I opted for keeping it backwards compatible. But I guess the impact of the change is not big. |
I agree that @mingwandroid suggestion can be addressed after as the modification to also support the stdin will be a bit more complicated to implement. And I also agree with @mingwandroid that it should be the default behaviour. |
|
Thanks for the feedback @marcelotrevisani and @mingwandroid. As part of this PR, can you please confirm if I should:
Please let me know and I will happily make the changes. Thank you. |
I believe that is a question for @chenghlee or @mingwandroid |
|
just one thing, could you please resolve the conflicts with your PR? |
For now (i.e., the 4.9.0 release), let's just leave it as is (i.e., option 3 -- do nothing), since this is a new behavior and I want to avoid any surprises for current users. I agree that that |
|
Once I'll unbreak the CI system, I'll review and merge this PR. Expect that to happen sometime later today. |
|
Pardon the naive question but what is the point of |
This enables the command
conda runto display the live output from the subprocess's stdout and stderr, in real time.The current behaviour-- which prints the stdout and stderr only after the process has finished --remains unchanged.
The
conda runcommand now can take a flag--live-streamwhich would flip the behaviour to provide the real time output.I believe this is related to: #9412