[Python-ideas] shutil.run (Was: shutil.runret and shutil.runout)

Devin Jeanpierre jeanpierreda at gmail.com
Wed May 23 08:49:46 CEST 2012


On Tue, May 22, 2012 at 5:41 PM, Nick Coghlan <ncoghlan at gmail.com> wrote:
> Having dealt with long running child processes lately, I can also say that
> producing output line-by-line would be on my personal list of requirements.

You can do that with subprocess, right? Just have to be sure to close
stdin/stderr and read p.stdout with readline() repeatedly...

I think you might be able to even have the other file descriptors be
inputting/outputting if you use threads, but I'm scared of
experimenting with these things -- experiments don't tell you that it
doesn't work on an OS you don't have.

-- Devin



More information about the Python-ideas mailing list