Talking through pipes interactively (on win32)

Brian Kelley bkelley at
Mon Nov 10 15:18:37 CET 2003

Jane Austine wrote:
> I need to control a command line program via python.

wxPython has a wxProcess class that makes this fairly easy.  It is also 
portable between unix and windows (not macosX) the downside is that you 
need to run it in a wxWindows GUI environment.

The other potential is to figure out how to use win32 Processes which 
are fairly hairy.  The technical issue at hand is that under win32 you 
can't use python's select library on file objects or standard in or 
standard out pipes which makes controlling them fairly difficult.

You can see a good demo of wxProcess in the wxPython demo.  The upside 
is that wxProcess doesn't require a gui to be visible, just a wxPython 
application environment, the downside is that wxPython is fairly large.

Hope this helps.

More information about the Python-list mailing list