Apr-26-2017, 05:31 AM
Where do you get the error, specifically? You should be able to just .encode() the input to get a bytes object.
for line in sys.stdin: do_something(line.encode())
documentation for raw bytes
|
|
Messages In This Thread |
documentation for raw bytes - by Skaperen - Apr-26-2017, 04:55 AM
RE: documentation for raw bytes - by nilamo - Apr-26-2017, 05:31 AM
RE: documentation for raw bytes - by Skaperen - Apr-26-2017, 06:01 AM
RE: documentation for raw bytes - by volcano63 - Apr-26-2017, 06:25 PM
RE: documentation for raw bytes - by Ofnuts - Apr-26-2017, 09:24 PM
|