[issue6784] byte/unicode pickle incompatibilities between python2 and python3

Merlijn van Deen report at bugs.python.org
Sat Dec 7 00:22:12 CET 2013


Merlijn van Deen added the comment:

I have fixed most of the nits in this patch, except for:

1) the intermediate bytes object being created; inlining is an option, as storchaka suggested, but I'd rather have you decide what it should become before implementing it;

2) make clinic gives me 

./python -E ./Tools/clinic/clinic.py --make
Error in file "./Modules/_pickle.c" on line 6611:
Checksum mismatch!
Expected: bed0d8bbe1c647960ccc6f997b33bf33935fa56f
Computed: 58dcccb705487695fec30980f566027bc68d9c69
make: *** [clinic] Error 255

and I have no clue how to fix that -- the clinic docs are sparse, to say the least;

3) The tests are still in their own test case; please decide between the two of you what is the best solution;

4) I have grouped the test cases: test_load_python2_str_as_bytes (which checks protocols 0, 1, and 2), test_load_python2_unicode_as_str and test_load_long_python2_str_as_bytes;

5) I have moved the commands to create the shown pickled versions from docstrings to comments. If you think they are not useful, I'll remove them, but I found them pretty useful while shortening the strings.

----------
Added file: http://bugs.python.org/file33016/bytestrpickle.diff

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue6784>
_______________________________________


More information about the Python-bugs-list mailing list