(original) (raw)
changeset: 99965:270add17f203 branch: 3.5 parent: 99963:59cb8811286a user: Serhiy Storchaka storchaka@gmail.com date: Mon Jan 18 21:35:22 2016 +0200 files: Lib/_compat_pickle.py Misc/NEWS description: Issue #26013: Added compatibility with broken protocol 2 pickles created in old Python 3 versions (3.4.3 and lower). diff -r 59cb8811286a -r 270add17f203 Lib/_compat_pickle.py --- a/Lib/_compat_pickle.py Mon Jan 18 19:39:26 2016 +0200 +++ b/Lib/_compat_pickle.py Mon Jan 18 21:35:22 2016 +0200 @@ -177,6 +177,13 @@ 'DocXMLRPCServer': 'xmlrpc.server', 'SimpleHTTPServer': 'http.server', 'CGIHTTPServer': 'http.server', + # For compatibility with broken pickles saved in old Python 3 versions + 'UserDict': 'collections', + 'UserList': 'collections', + 'UserString': 'collections', + 'whichdb': 'dbm', + 'StringIO': 'io', + 'cStringIO': 'io', }) REVERSE_IMPORT_MAPPING.update({ diff -r 59cb8811286a -r 270add17f203 Misc/NEWS --- a/Misc/NEWS Mon Jan 18 19:39:26 2016 +0200 +++ b/Misc/NEWS Mon Jan 18 21:35:22 2016 +0200 @@ -44,6 +44,9 @@ Library ------- +- Issue #26013: Added compatibility with broken protocol 2 pickles created + in old Python 3 versions (3.4.3 and lower). + - Issue #25850: Use cross-compilation by default for 64-bit Windows. - Issue #17633: Improve zipimport's support for namespace packages. /storchaka@gmail.com