In Python 3 the behavior of os.read() has changed to return a bytestring rather than a string, so this line returns an error if the user enters input from the terminal while a chain is running:
TypeError: Can't convert 'bytes' object to str implicitly
For Python 3, the fix is just to add .decode() to the end of that line, e.g.
input += os.read(sock,4096).decode()
but I don't know how to do that in a way that won't break Python 2.
In Python 3 the behavior of os.read() has changed to return a bytestring rather than a string, so this line returns an error if the user enters input from the terminal while a chain is running:
TypeError: Can't convert 'bytes' object to str implicitly
For Python 3, the fix is just to add
.decode()
to the end of that line, e.g.but I don't know how to do that in a way that won't break Python 2.