Python 3: Plist as OrderedDict

Gnarlodious gnarlodious at gmail.com
Mon Feb 8 23:02:30 EST 2010


I am trying to read a *.plist into Python 3's OrderedDict but can't
figure it out. Saying something like this:

from plistlib import readPlist
dict=readPlist('/path/file.plist')
--> arbitrarily ordered dictionary compared to the XML file

from collections import OrderedDict
OrderedDict(readPlist('/path/file.plist'))
--> essentially does the same thing as the previous
readPlist seems to do the scrambling, is this a non-implementation in
Python 3.1?

I "upgraded" to Py3 to have OrderedDict, so please don't say it is
impossible...

-- Gnarlie



More information about the Python-list mailing list