I chose to use pickle (+base64+TCP sockets) to communicate data between my python3 code and legacy python2 code, but I am having trouble with datetime
objects:<
The workaround is to use the encoding="bytes"
like this:
pickled_bytes = bytes(pickled_str, encoding='latin1') # If your input is a string(not my case)
data = pickle.loads(pickled_bytes, encoding='bytes')
(Thanks to Tim Peters for the suggestion)
Issue still opened at http://bugs.python.org/issue22005 as to why this is required.