Python Pexpect Spawn Object Flush August 06, 2024 Post a Comment I have a script where i am creating a spawn object using pexpect. The code looks like this: self.rshcmd='rsh 192.X.X.X' self.pipe1 = pexpect.spawn(command=self.rshcmd, logfile=sys.Solution 1: Dochild.send(cmd) child.pexpect(cmd) child.send('\n') Copyinstead of child.sendline(cmd) CopyThis will solve your problem. (but when sending password do child.sendline(passwrd) ) Share Post a Comment for "Python Pexpect Spawn Object Flush"
Post a Comment for "Python Pexpect Spawn Object Flush"