Why should you have to rigorously store exactly the same string every single time?

The fact that people keep running into this issue shows that not taking round tripping into account is nuts.

Bitcoin does _not_ work this way. Serialization is tightly defined and you can easily and reliably re-serialize data structures reliably.

Reply to this note

Please Login to reply.

Discussion

Yess, I was just trying to get around the issues in the current scheme,

but nip01 actually specifies the order of the keys in the event structure right? I think it is at least a little detailed on how to avoid ambiguity in the serialization infact the event id is a sha256 of a JSON array and not an object, it also details on how to escape special characters, whuch should resolve most of the ambiguities right?

Most isn't good enough... Anyway binary serialization schemes are far better choices for this.