Python Forum

Full Version: subprocess and tty input
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I'm writing a script that launches a process via Popen that reads a password from the tty rather than stdin. Is there a way to send that string? There is something called Pexpect is that right solution? TIA.
you may want to look at https://pypi.org/project/autologin/
Thanks for the suggestion. However, I think pexpect is doing mostly what I want. I am having an issue collecting the command output but I will open a new thread for that.