[issue14455] plistlib unable to read json and binary plist files

Ronald Oussoren report at bugs.python.org
Wed Jan 15 14:21:01 CET 2014


Ronald Oussoren added the comment:

However, I have no idea how to write that file using Apple's APIs. 

I'd prefer to either be compatible with Apple's API (current behavior), or just outright reject values that cannot be represented as a 64-bit signed integer.  

The file you generated happens to work, but as there is no way to create such as file using a public API there is little reason to expect that this will keep functioning in the future.  

The CFBinaryPlist code appears to be shared between support for binary plists and keyed archiving (more or less Cocoa's equivalent for pickle) and supports other values that cannot be put in plist files, such as sets.  The original patch supported sets in the binary plist reader and writer, I ripped that out because such objects cannot be serialised using Apple's plist APIs.

Keep in mind that this module is intended for interop with Apple's data format.

----------

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


More information about the Python-bugs-list mailing list