Running External Programs from Within Python

RayS rays at blue-cove.com
Sun Feb 1 04:48:33 EST 2004


Hi Cameron,

>Before we provide more details, though, you go
>first; specifically, are you thinking of your bi-directional
>pipe as a batch operation, or a programmatic one?

Interactive/programmatic...

>Do you
>know at the time you launch the Fortran-coded application
>all the input it'll need?

Usually not. It's a balance solution routine that requires some interaction 
from the engineers; the Fortran has a three layer menu, and produces both 
screen output and files. There is an intermediary result which has to be 
looked at by the user to decide on the final balance, otherwise I would 
change the code to just run from arg[] values.
One of its problems is that there is minimal error checking, and a bad 
input requires  the user to start over!
 From the popen() docs, it seemed as though Windows could not have both 
read and write ability over a pipe.

Ray





More information about the Python-list mailing list