Add interact support for posix in Python3