pub fn normalize_extra(
extra: Map<String, Value>,
) -> Result<Map<String, Value>, String>Expand description
Canonicalize and bounds-check the extra bag — the write-time gate.
On overflow the build is rejected loudly rather than truncated quietly:
extra is authored (unlike the derived lists, which are capped with
truncated set, because they can be re-derived), so cutting it would
silently ship a card that no longer says what the publisher wrote — and,
since the bag folds into the content hash, “what I wrote” and “what hashed”
would diverge invisibly. Only the author can decide what to trim.