Filed unassigned; recording only, not claiming. Measured while implementing #11049 (the published-prose half of the same semantics correction). Out of scope there: that card's triage fixed the file surface at exactly content/docs/protocol/objectql/state-machine.mdx + skills/objectstack-automation/SKILL.md, and these are runtime source files.
Same defect class as #11049, one layer down. Two dispatcher call sites compute:
constnext=from===undefined ? null : legalNextStates(schema,field,from);
so next: null has two causes — no state_machine rule governs the field, and the caller omitted ?from=. The comment immediately above each of those lines names only the first.
1. packages/runtime/src/domains/meta.ts:233-234
// hard-coding the transition table. Returns next: null when no FSM
// governs the field, next: [] for a declared dead-end state.
2. packages/rest/src/rest-server.ts:6274-6277
// `next: null` = no FSM governs the field; `next: []` =
// a declared dead end. Same three-valued answer the
// dispatcher gives, because a UI asking "where can this
// record go" must be able to tell those apart.
The second is the sharper miss: it asserts a three-valued answer (null / [] / list) and justifies the tri-state on the grounds that a UI must tell the cases apart — while the line it annotates collapses a fourth input condition (from absent) onto the same null. A maintainer reading that comment to decide whether a UI can distinguish "no FSM" from "no from" gets the wrong answer from the comment and the right one only from the expression beneath it.
The correct semantics are already asserted in docs/qa/platform-checklist/areas/api-backend.json: "?from omitted returns next:null (no from ⇒ no transition table), a field with no FSM returns next:null".
Suggested fix: name both causes in each comment, matching the prose landed by #11049. Low severity — comments only, no behavior change — but both sit on the exact line that makes them wrong, so they are the first thing a reader consults.
Related: #11049 (published-prose half), #10178 (route-spelling half).
Filed unassigned; recording only, not claiming. Measured while implementing #11049 (the published-prose half of the same semantics correction). Out of scope there: that card's triage fixed the file surface at exactly
content/docs/protocol/objectql/state-machine.mdx+skills/objectstack-automation/SKILL.md, and these are runtime source files.Same defect class as #11049, one layer down. Two dispatcher call sites compute:
so
next: nullhas two causes — nostate_machinerule governs the field, and the caller omitted?from=. The comment immediately above each of those lines names only the first.1.
packages/runtime/src/domains/meta.ts:233-2342.
packages/rest/src/rest-server.ts:6274-6277The second is the sharper miss: it asserts a three-valued answer (
null/[]/ list) and justifies the tri-state on the grounds that a UI must tell the cases apart — while the line it annotates collapses a fourth input condition (fromabsent) onto the samenull. A maintainer reading that comment to decide whether a UI can distinguish "no FSM" from "nofrom" gets the wrong answer from the comment and the right one only from the expression beneath it.The correct semantics are already asserted in
docs/qa/platform-checklist/areas/api-backend.json: "?from omitted returns next:null (no from ⇒ no transition table), a field with no FSM returns next:null".Suggested fix: name both causes in each comment, matching the prose landed by #11049. Low severity — comments only, no behavior change — but both sit on the exact line that makes them wrong, so they are the first thing a reader consults.
Related: #11049 (published-prose half), #10178 (route-spelling half).