cultnet error contract: one message_invalid code replaces malformed_document_put/delete #41

Merged
libby merged 2 commits from libby/error-message-invalid into main 2026-11-08 09:17:52 +00:00
Member

Closes follow-up for cross-runtime malformed_document_put / malformed_document_delete. Contract chosen: fold into one message_invalid (Q6-A of docs/cultnet-error-contract-cut.md), not two new per-operation codes, because the peer already knows which operation it sent and the code needs to be added to the closed enum either way. Touches write-refusal paths: do not merge until Heimdall has said so.

  • Schema (both copies): message_invalid in the code enum; details.field names the request field (message when the frame is unreadable).
  • C#: CultNetErrorMessage.ForMessageInvalid; the three codeless "requires a subscriptionId or messageId" sites use it.
  • Rust: CultNetErrorCode::MessageInvalid. TS: cultNetMessageInvalidError, code list. Python: message_invalid_error, code lists.
  • cultmesh-py and cultmesh-ts malformed put/delete/shard-field refusals now emit it; the out-of-enum codes and TS text-prefix hack are gone.
  • Parity: one captured vector (error-vectors.json) checked by the C# test (real serializer bytes), the Rust case, the TS factory test and the Python builder test.
  • Verified locally: C# CultNetSchemaContractTests, Subscription and RemoteWrite filters; cultnet-rs error_message + schema discovery; cultmesh-rs cargo check; cultnet-ts (280 pass, 1 esbuild failure also failing on main); cultmesh-ts 177 pass; cultnet-py error/core tests; cultmesh-py write-authority and cultmesh suites.
  • Not done: no C# test drives the subscription-id site itself; Python ENOSPC store failure still reports as message_invalid (server fault reported as peer's, pre-existing, noted in the cut doc). Rust cultmesh-rs RUDP server still refuses silently. CHANGELOG line in cultmesh-ts will conflict trivially with #40.
  • No tag, no publish. Semver bumps left to the release owner.

🤖 Generated with Claude Code

Closes follow-up for cross-runtime `malformed_document_put` / `malformed_document_delete`. Contract chosen: **fold into one `message_invalid`** (Q6-A of `docs/cultnet-error-contract-cut.md`), not two new per-operation codes, because the peer already knows which operation it sent and the code needs to be added to the closed enum either way. Touches write-refusal paths: **do not merge until Heimdall has said so.** - Schema (both copies): `message_invalid` in the `code` enum; `details.field` names the request field (`message` when the frame is unreadable). - C#: `CultNetErrorMessage.ForMessageInvalid`; the three codeless "requires a subscriptionId or messageId" sites use it. - Rust: `CultNetErrorCode::MessageInvalid`. TS: `cultNetMessageInvalidError`, code list. Python: `message_invalid_error`, code lists. - cultmesh-py and cultmesh-ts malformed put/delete/shard-field refusals now emit it; the out-of-enum codes and TS text-prefix hack are gone. - Parity: one captured vector (`error-vectors.json`) checked by the C# test (real serializer bytes), the Rust case, the TS factory test and the Python builder test. - Verified locally: C# CultNetSchemaContractTests, Subscription and RemoteWrite filters; cultnet-rs error_message + schema discovery; cultmesh-rs cargo check; cultnet-ts (280 pass, 1 esbuild failure also failing on main); cultmesh-ts 177 pass; cultnet-py error/core tests; cultmesh-py write-authority and cultmesh suites. - Not done: no C# test drives the subscription-id site itself; Python `ENOSPC` store failure still reports as `message_invalid` (server fault reported as peer's, pre-existing, noted in the cut doc). Rust cultmesh-rs RUDP server still refuses silently. CHANGELOG line in cultmesh-ts will conflict trivially with #40. - No tag, no publish. Semver bumps left to the release owner. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
cultnet error contract: one message_invalid code replaces malformed_document_put/delete
Some checks failed
CultMesh QUIC native / Build win32-x64 (pull_request) Has been skipped
CultMesh QUIC native / Build linux-x64 (pull_request) Has been skipped
CultMesh QUIC native / Release native binaries (pull_request) Has been skipped
CultMesh portability and performance / ubuntu-latest reactive semantics and leases (pull_request) Failing after 4m54s
CultMesh QUIC native / Verify committed binaries match SHA256SUMS (pull_request) Successful in 49s
0cfd319b5e
Q6-A of docs/cultnet-error-contract-cut.md. message_invalid joins the closed
cultnet.error.v0 code enum (both schema copies), with details.field naming the
request field at fault ("message" when the whole frame cannot be read).
C# ForMessageInvalid, Rust CultNetErrorCode::MessageInvalid, TS
cultNetMessageInvalidError and Python message_invalid_error all write the same
captured bytes (error-vectors.json plus the C# and Rust cases). cultmesh-py and
cultmesh-ts refuse malformed puts and deletes with it; the C# subscription
servers use it for the missing subscriptionId.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
libby force-pushed libby/error-message-invalid from 0cfd319b5e
Some checks failed
CultMesh QUIC native / Build win32-x64 (pull_request) Has been skipped
CultMesh QUIC native / Build linux-x64 (pull_request) Has been skipped
CultMesh QUIC native / Release native binaries (pull_request) Has been skipped
CultMesh portability and performance / ubuntu-latest reactive semantics and leases (pull_request) Failing after 4m54s
CultMesh QUIC native / Verify committed binaries match SHA256SUMS (pull_request) Successful in 49s
to a558f3ad3b
Some checks failed
CultMesh QUIC native / Build win32-x64 (pull_request) Has been skipped
CultMesh QUIC native / Build linux-x64 (pull_request) Has been skipped
CultMesh QUIC native / Release native binaries (pull_request) Has been skipped
CultMesh portability and performance / ubuntu-latest reactive semantics and leases (pull_request) Failing after 4m43s
CultMesh QUIC native / Verify committed binaries match SHA256SUMS (pull_request) Successful in 51s
2026-11-08 09:17:38 +00:00
Compare
libby merged commit a95b43d48f into main 2026-11-08 09:17:52 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
GameCult/CultLib!41
No description provided.