[Tutor] Subprocess communications query
William Ray Wing
wrw at mac.com
Wed Dec 11 18:49:38 CET 2013
On Dec 10, 2013, at 2:28 PM, Reuben <reuben.dlink at gmail.com> wrote:
> Hi,
>
> There exists two Linux machines A and B. Machine B contains python script which needs to be run e.g. Test.py
>
> In order to run that script, machine A needs to telnet into machine B and then execute "python Test.py"
>
> How can this be implemented? Is subprocess library to be used?if yes, an example would help
>
> Regards,
> Reuben
>
> _______________________________________________
> Tutor maillist - Tutor at python.org
> To unsubscribe or change subscription options:
> https://mail.python.org/mailman/listinfo/tutor
Check out pexpect here: http://pexpect.sourceforge.net/pexpect.html
Should do exactly what you want, and Googling for pexpect examples will turn up lots of stuff.
-Bill
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20131211/a9a2101a/attachment.html>
More information about the Tutor
mailing list