Interacting with external program -pty?

Niklas.Blomberg at hassle.se.astra.com Niklas.Blomberg at hassle.se.astra.com
Tue Jan 18 07:17:36 EST 2000


Dear all,

I would appreciate some advice on how to script an external interactive
process(program) using python. In addition to sending commands (which is
straightforward) I need to be able to capture the output (which can be
extensive) for further downstream processing. Since the program expects a
terminal pipes don't work - the output is buffered - I have started to look
at the pty module. This is uncharted territory for me and any advice both on
possible solutions and perhaps availiable example code would be most
appreciated.

I'll be happy to post a summary.

Thanks,
Niklas

-----
Niklas Blomberg
AstraZeneca Structural Chemistry Laboratory
niklas.blomberg at astrazeneca.com






More information about the Python-list mailing list