I have been pointed at:

https://github.com/nostr-protocol/nips/issues/225#issuecomment-1419008389

which explains the reasoning. I can actually accept that it prevents hashing ambiguities of objects which is something I have had to deal with in other contexts.

Reply to this note

Please Login to reply.

Discussion

JSON was a really bad choice for the data interchange format for multiple reasons imo but it’s likely too late now…

last year i made a demo babby-tier "social network" on top of IPFS pubsub, I used msgpack which worked great.

Yeah msgpack would have been better, anything with a binary field type would be better honestly.

i was autistically focused at the time about my data structures hashing deterministically but what i found was people saying "don't do it" or "it's basically impossible anyway" I don't believe it's "impossible" but basically they all concluded, just hash what you got because the deterministic object structure for hashing isn't actually critical.