Get Stdout from external script startet through python
Alex Martelli
aleax at aleax.it
Sun Nov 17 17:32:23 EST 2002
<posted & mailed>
Christian Rapp wrote:
> I need to start an external script from inside python. This works just
So you're presumably using os.system?
> fine. The called script produces some output on StandardOut, that I need
> within the python-script. How do I get this Output into python?
> Any suggestions? Please answer!
import os
flob = os.popen("whatever and args")
thedata = flob.read()
flob.close()
Alex
More information about the Python-list
mailing list