How can I pass a specific key combination to a spawned / child process using the pexpect module? I am using telnet and have to send Ctrl + Z to the remote server.
Tpx
use sendcontrol ()
eg:
p = pexpect.spawn(your_cmd_here) p.sendcontrol('z')