Comment 1 for bug 1644387

Tim Burke (1-tim-z) wrote :

Correction: operators won't be able to read py3-generated builders under (some versions of) py2.

$ python2.7.10 -c 'import array, pickle, os, sys; pickle.dump(array.array("I", [0, 0, 0]), os.fdopen(1, "wb"), protocol=2)' | python3.6.0 -c 'import pickle, os, sys; print(pickle.load(os.fdopen(0, "rb")))'
array('I', [0, 0, 0])

$ python3.6.0 -c 'import array, pickle, os, sys; pickle.dump(array.array("I", [0, 0, 0]), os.fdopen(1, "wb"), protocol=2)' | python2.7.10 -c 'import pickle, os, sys; print(pickle.load(os.fdopen(0, "rb")))'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/pickle.py", line 1378, in load
    return Unpickler(file).load()
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/pickle.py", line 858, in load
    dispatch[key](self)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/pickle.py", line 1133, in load_reduce
    value = func(*args)
TypeError: must be char, not unicode

$ python3.6.0 -c 'import array, pickle, os, sys; pickle.dump(array.array("I", [0, 0, 0]), os.fdopen(1, "wb"), protocol=2)' | python2.7.13 -c 'import pickle, os, sys; print(pickle.load(os.fdopen(0, "rb")))'
array('I', [0L, 0L, 0L])