[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2010-10-30 Thread Raymond Hettinger
Raymond Hettinger added the comment: Backported to 2.7 See r85966 -- resolution: -> fixed status: open -> closed ___ Python tracker ___ _

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2010-10-29 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- priority: normal -> high ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2010-10-29 Thread Benjamin Peterson
Benjamin Peterson added the comment: Upon further consideration, I think this could be backported. -- assignee: benjamin.peterson -> rhettinger resolution: wont fix -> status: closed -> open ___ Python tracker ___

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2010-08-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: I think we should close it. -- resolution: -> wont fix status: open -> closed ___ Python tracker ___ ___

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2010-06-22 Thread Raymond Hettinger
Raymond Hettinger added the comment: Benjamin, it's a little late for this one for 2.7. Do you prefer to close it forever or to treat it as a bug fix for 2.7.1? -- assignee: rhettinger -> benjamin.peterson nosy: +benjamin.peterson ___ Python tracke

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2010-05-20 Thread Skip Montanaro
Changes by Skip Montanaro : -- nosy: -skip.montanaro ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2009-09-21 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- versions: -Python 3.1 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2009-05-26 Thread Raymond Hettinger
Raymond Hettinger added the comment: r72961 Fixed for Py3.1. Leaving open until backported to 2.7. -- priority: critical -> normal versions: +Python 3.1 ___ Python tracker ___ _

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2009-05-26 Thread Raymond Hettinger
Raymond Hettinger added the comment: Skip, the json API for 2.7/3.1 includes an object_pairs_hook that allows an OrderedDict to be generated from a json file. The OP is pointing out that the latest C upgrade prevents round-tripping while preserving order. Use cases for that were discussed in t

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2009-05-26 Thread Skip Montanaro
Skip Montanaro added the comment: I can't see that the order of keys should matter for language-neutral serialization libs like json or xmlrpclib. You're quite possibly going to be communicating with something on the other end which doesn't have an OrderedDict-like class. Why add the extra com

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2009-05-26 Thread Robert Lehmann
Robert Lehmann added the comment: This only seems to be the case with the C implementation of json (_json). >>> json.encoder.c_make_encoder = None >>> json.dumps(OrderedDict(items)) '{"one": 1, "two": 2, "three": 3, "four": 4, "five": 5}' I think the culprit is encoder_listencode_dict (Module

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2009-05-25 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- priority: -> critical ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2009-05-25 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- assignee: -> rhettinger nosy: +rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue6105] json.dumps doesn't respect OrderedDict's iteration order

2009-05-25 Thread Wang Chun
New submission from Wang Chun : PEP-0372 and Issue 5381 both say json.dumps respect OrderedDict's iteration order, but the example in them do not work on my latest trunk build. $ uname -a Linux 12.38 2.6.18-128.el5 #1 SMP Wed Dec 17 11:41:38 EST 2008 x86_64 x86_64 x86_64 GNU/Linux $ python2.7