[Python-Dev] backwards and forwards compatibility, the exact contents of pickle files, and IntEnum
Antoine Pitrou
solipsis at pitrou.net
Sun Mar 15 16:10:51 CET 2015
More information about the Python-Dev mailing list
Sun Mar 15 16:10:51 CET 2015
- Previous message (by thread): [Python-Dev] backwards and forwards compatibility, the exact contents of pickle files, and IntEnum
- Next message (by thread): [Python-Dev] PEP 489: Redesigning extension module loading
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Sat, 14 Mar 2015 22:52:17 -0700 Ethan Furman <ethan at stoneleaf.us> wrote: > I'm not sure exactly how to phrase this inquiry, so please bear with me. > > What exactly does backwards compatibility mean as far as pickle goes? We have the various protocols, we have the > contents of pickle files created at those protocols, and we have different versions of Python. > > Should a pickle file created in Python 3.4 with protocol 3 and the contents of socket.AF_INET be unpicklable with a > Python 3.3 system? Because currently it cannot be as socket.AF_INET became an IntEnum in 3.4. > > I'm thinking the answer is yes, it should be. I agree with you that this should not break. > So, the final question: Do the contents of a pickle file at a certain protocol have to be the some between versions, or > is it enough if unpickling them returns the correct object? It's certainly enough if unpickling returns the correct object. Exact serialization is an implementation detail. Regards Antoine.
- Previous message (by thread): [Python-Dev] backwards and forwards compatibility, the exact contents of pickle files, and IntEnum
- Next message (by thread): [Python-Dev] PEP 489: Redesigning extension module loading
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-Dev mailing list