Pexpect: SSH, Command and Password

Ganesan Rajagopal rganesan at myrealbox.com
Wed Apr 4 08:14:56 EDT 2007


>>>>> "Gil" == Gil H <gil.horen at gmail.com> writes:

> class SSH:
>         def __init__(self, user, password, host):
>                 self.child = pexpect.spawn("ssh %s@%s"%(user, host))

Try adding the following line here

    self.child.logfile = sys.stdout

That should give you some clue.

Ganesan


-- 
Ganesan Rajagopal




More information about the Python-list mailing list