What is Nostr?
Nicolas Martyanoff /
npub1dkg…54dt
2024-12-08 17:02:39
in reply to nevent1q…xadt

Nicolas Martyanoff on Nostr: nprofile1q…5fkdz In Go the parser does part of the validation (at least structure ...

nprofile1qy2hwumn8ghj7un9d3shjtnddaehgu3wwp6kyqpq8emgmtyn75h2w5e5m2pzt6djhukhgtwmshhe05dd7hj94j90xe2qv5fkdz (nprofile…fkdz) In Go the parser does part of the validation (at least structure and types) because decoding is done to a specific data type: the parser maps decoded values to the type you decode to.

On the one hand, this is very convenient. On the other hand, you lose a lot of control on validation.

encoding/json/v2 is supposed to fix that, but as usual with large proposals in the open source world, the discussion is running in circle for 1+ year.
Author Public Key
npub1dkg70vzk4vvfsc5cup9gkfu2tcrs5unysl7npfvegf78nkuswr5skh54dt