No prob.
I remember the dict key stuff.
At the time I wasn't interested, but maybe it'd make it easier
on you if we turned your dict keys patch into an optional feature
that could be turned on/off at en/decode time, defaulting to off?
Then your dependency would be part of the official release,
tested, etc.
The referencing code needs a rework too. We want to be able to
reconstruct refs into array elements, and presumably it'd be
better if we were able to do so for any arbitrary objects as
keys, not just dicts, but dicts are a good starting point.
Let me know if you were able to port your patch to the latest
jsonpickle, it sounds useful. Once it's well tested then the
work of getting it to support refs like the following would be
something to think about:
class A(object):
pass
a = A()
a.items = [A(), A(), A()]
a.first = a.items[0]
a.stuff = {a.first: a.first}
a.morestuff = {a.stuff: a.stuff}
pickle = jsonpickle.encode(a)
b = jsonpickle.decode(pickle)
item = b.items[0]
self.assertEqual(b.first, item)
self.assertEqual(b.stuff[b.first], item)
self.assertEqual(b.morestuff[b.stuff][b.first], item)
John Paulett and I both keep jsonpickle repos on github:
http://github.com/johnpaulett/jsonpickle
http://github.com/davvid/jsonpickle
--
David