do I need popen or something else

HardYards admin at hardyards.info
Fri Dec 13 06:41:59 EST 2002


The problem is that I have a program that performs a lot of numerical
computation and as it runs through it tells the user what it is doing.
(If it's a real big run - it's a batch job - but that is a different
question)

Because of the humungous files that it produces I would like to wrap
it in a python script that runs it and when it is finished zips up the
output files.

This way the python/VTK program I have put together for displaying
them can simply unzip them and we are away.  The alternative is to
link zlib into my c code - but that is not tidy..

Anyway going through the python groups it looks like I need 

popen("myappname.exe")

the trouble is that popen seems to want the app to finish before it
sends back any output - or am I missing something.

What I want is a way to execute the program and direct output to
stdout in real time



More information about the Python-list mailing list