Hello all,
Last few months I've been checking out zsh with its many benefits, however did anyone run into this:

You know how you can get a semi interactive shell on a remote host using:


Code:
python3 -c 'import pty; pty.spawn("/bin/bash")'
then make it interactive
Code:
CTRL-Z
stty raw -echo
fg
When doing this using zsh as a starting point, it messes up the whole terminal, the only way out is to close the terminal.
Why? Is this because you can't forward keyboard hotkeys from a zsh to a bash?
A workaround seems to be, to switch to bash, even before setting up a listener and accepting a connection, but if you forget this you'll have to start over.

Does anyone know of a more elegant way?