[squeak-dev] Re: JSON "object"s are *unordered*

Tony Garnock-Jones tonyg at lshift.net
Tue Jan 12 20:30:41 UTC 2010


Colin Putney wrote:
> I think it was for testing.

Yeah, I've suffered from similar issues trying to test the other JSON
libraries I've written over the years. There's also another legit(ish)
reason to want a consistent serialisation order: canonicalisation for
signing. I don't know of anyone doing that, yet, though :-)

Perhaps I'll change it, then, so that it uses a Dictionary internally,
and add some way of serializing to JSON with keys in *sorted* order,
which then gives a kind of canonical form for the tests... I'll take a
look this weekend, if I get time.

> That was meant to be a private change though, not sure
> how it got pushed upstream.

Hmm, it could easily have been something *I* did actually: I can't
remember where I found the .avi.24 that I merged with .ul.15. Perhaps it
was from some unrelated repository. :-( If so, then sorry, all, for the
hassle!

Regards,
  Tony



More information about the Squeak-dev mailing list