From 7bb1733569b43e79475bd4e8b4ec4ee165408592 Mon Sep 17 00:00:00 2001 From: Meta Vens Date: Mon, 19 Oct 2026 15:53:10 +0200 Subject: [PATCH] cultnet-ts README: the decoder follows the reference's acceptance Co-Authored-By: Claude Opus 5.5 --- packages/cultnet-ts/README.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/packages/cultnet-ts/README.md b/packages/cultnet-ts/README.md index a47c02b8..ca0db88d 100644 --- a/packages/cultnet-ts/README.md +++ b/packages/cultnet-ts/README.md @@ -140,9 +140,16 @@ imports no `node:` module, so a browser bundle can take it. object reorders integer-like keys, and the entry order is the wire bytes. Duplicate keys, integers a JS number cannot hold exactly, and payloads nested past the shared depth limit are refused. +- The decoder reads what MessagePack-CSharp reads and refuses what it refuses: + nil in a string, tag or metadata slot is `null` and is written back as nil, + a missing trailing slot takes the reference's default, extra slots and trailing + bytes are skipped, a float-encoded integer is refused, and invalid UTF-8 + decodes to U+FFFD. A nil `chunks` is refused, as the reference's + `ValidateManifest` refuses it. `content-acceptance-vectors.json` is the + reference's own verdict on each of those shapes. - Bytes and keys are held to files the C# reference writes (`contracts/cultmesh/content-vectors.cs-written.json`, - `cdn-record-key-vectors.json`) and to `content-vectors.rs-written.json`. + `cdn-record-key-vectors.json`, `content-acceptance-vectors.json`) and to `content-vectors.rs-written.json`. The TypeScript-written `content-vectors.ts-written.json` is judged by the C# reference. Regenerate it with `npm run build --workspace packages/cultnet-ts` and `node scripts/write-cultmesh-content-vectors.mjs`; never edit it by hand.