[Python-ideas] shutil.runret and shutil.runout

Nick Coghlan ncoghlan at gmail.com
Fri Feb 24 13:41:50 CET 2012


On Fri, Feb 24, 2012 at 10:13 PM, Mike Meyer <mwm at mired.org> wrote:
> Oddly enough, I read the Julia docs on external commands between my
> first answer and your reply, and their solution is both as simple as
> what you want, and safe.

That *is* rather nice, although they never get around to actually
explaining *how* to capture the output from the child processes
(http://julialang.org/manual/running-external-programs/, for anyone
else that's interested).

It should definitely be possible to implement something along those
lines as a third party library on top of subprocess (although it would
be a lot more complicated than Shell Command is).

Kenneth Reitz (author of "requests") has also spent some time
tinkering with subprocess invocation API design concepts:
https://github.com/kennethreitz/envoy

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia



More information about the Python-ideas mailing list