Repository navigation
fix(pm): dispatch-gates names check:error-status-conformance for a file that binds an HTTP status, judged from content - #22329
Merged
objectstack-fleet[bot] merged 6 commits intoOct 8, 2026
Conversation
…e to the dispatch derivation Claude-Session: https://claude.ai/code/session_0115N1oNnQS5WqofZ2DzaT3q Co-authored-by: Claude <noreply@anthropic.com>
…ow to DECLARED-NARROWER Claude-Session: https://claude.ai/code/session_0115N1oNnQS5WqofZ2DzaT3q Co-authored-by: Claude <noreply@anthropic.com>
…, so a rename elsewhere cannot red this gate Claude-Session: https://claude.ai/code/session_0115N1oNnQS5WqofZ2DzaT3q Co-authored-by: Claude <noreply@anthropic.com>
…ror-status-derivation
…oot worklist to their main bytes The ROOT_DIR_WATCH_HINTS declaration, its self-test battery 29 and the REFUSE-WIDE to DECLARED-NARROWER re-decision are withdrawn: the seat verdict on the card routes the family through the content trigger in dispatch-gates instead, so the REFUSE-WIDE row stands as recorded. Reverts 21b4403, 38eaa64 and 9903181. Claude-Session: https://claude.ai/code/session_0115N1oNnQS5WqofZ2DzaT3q Co-authored-by: Claude <noreply@anthropic.com>
…le that binds an HTTP status, judged from content A sibling CHANGE_KIND_GATES entry with its own predicate, emitsAnHttpStatus: a status or statusCode bound to a 4xx/5xx value, the positional sendError door, or a SCREAMING_SNAKE status constant. Measured at the bytes of main 28bff18, it reaches all 128 files that carry a derived producer, while the ADR-0112 code predicate misses 19 of them (86 sites), so the gate does not simply join the vocabulary entry. The gate's REFUSE-WIDE bare-root row stands as recorded. Self-test cases pin the PR #22311 emit site, the docs-only, README and no-emission controls, and the rendered line. Claude-Session: https://claude.ai/code/session_0115N1oNnQS5WqofZ2DzaT3q Co-authored-by: Claude <noreply@anthropic.com>
objectstack-fleet
Bot
deleted the
claude/issue-22320-error-status-derivation
branch
October 8, 2026 19:34
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #22320
Clause-②: no
What
scripts/pm/dispatch-gates.mjsnow namescheck:error-status-conformancefor a file that binds an HTTP status to an error response, judged from the file's CONTENT. That is the route the seat verdict on the card chose: theCHANGE_KIND_GATEScontent trigger that already reachescheck:dispatcher-error-vocabulary, another REFUSE-WIDE gate.scripts/pm/dispatch-gates.mjshas three changes:emitsAnHttpStatus, with three limbs. (1)status/statusCodebound to a 4xx/5xx literal or a SCREAMING_SNAKE name. (2) The positionalsendError(res, STATUS, …)door. (3) A SCREAMING_SNAKE constant bound to a 4xx/5xx literal.CHANGE_KIND_GATESentry naming the gate, with its deletion criterion.scripts/check-error-status-conformance.mjsandscripts/pm/bare-root-worklist.mjsare back to theirmainbytes. The round-1ROOT_DIR_WATCH_HINTSdeclaration, its self-test battery and the REFUSE-WIDE to DECLARED-NARROWER re-decision are reverted by a new commit (11e2a5299b); history is not rewritten.git diff origin/mainon both files is empty, so neither needed a touch, and the gate's REFUSE-WIDE row stands as recorded.Sibling entry or join? Measured
Measured at
11e2a5299b, whose bytes equalmain28bff18d0c. Each file was run through the gate's own deriver (deriveRuntimeStatuses) one at a time:stampsAnErrorCodeLiteral) missesemitsAnHttpStatusmissesThe two questions diverge, so the gate gets a sibling entry with its own predicate rather than joining the code entry. All 19 misses fall into two shapes:
settings-routes.tsandshare-link-routes.tscallsendError(res, 403, 'SETTINGS_FORBIDDEN', …), with nocodetoken near the code.turso-driver.tsandfilter-refusal.tswriteerr.code = StandardErrorCode.enum.X; err.status = 400.Precision and residues on the same tree:
emitsAnHttpStatusmatches 185 of the 3247 non-test TypeScript files, every one inside the gate's own scanned population, and 128 of them carry a producer (69%). The code predicate names 283 files for its own gate.anonymous-deny.ts,upload-ownership.tsandwebhook-secret.ts. The fourth,packages/mcp/src/metadata-completeness.ts, declares only a CODE constant, so the code entry reaches it and this one does not. A code-constant limb would have cost 45 more matches (185 to 230) for that one file, and the entry declines that trade. The docblock records both residues.The harm, reproduced on the same paths
Command:
node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack PATH. Before is11e2a5299b(the bytes ofmain28bff18d0c); after is head28bf1d4448. Every run exited 0.packages/services/service-storage/src/storage-routes.ts(the PR #22311 emit site)pnpm check:error-status-conformancecontent/docs/ai/agents.mdx(docs-only control)packages/services/service-storage/README.mdpackages/services/service-storage/src/index.ts(a.tswith no status and no code)discoverFamilies()gives byte-identical records, atmainand at head, for every family whose files includedispatch-gates.mjsorcheck-dispatch-gates.mjs. So none of the new path strings in the self-test, or in the module-bodywhy, became a hint.Pins (dispatch-gates self-test, 1976 to 2011 cases)
.tswith no status and no code, a test file, a.d.ts, a non-TS file, and an unreadable path.index.tsare not reached; the barrel is reached by neither content entry. Discrimination holds at 185 of 3247.whystates REFUSE-WIDE, DOCUMENTING as the repair, the ⛔ MAINTAINER-ONLY baseline remedy, and "needs NO build". Through the whole table, the specimen derives the gate and the docs-only, README and barrel paths do not. An undiscoverable name renders STALE.check:error-status-conformanceis a live family.Ablations
All three ran through
scripts/ablation-replace.mjsagainst committed head28bf1d4448, with the dispatch-gates self-test as the wrapped command. Each run was stopped once the status section and the first case after it had streamed, by killing only the wrapper's own descendants. Each mutation was proven on disk (anchor 1 to 0, blob changed). Each restore was proven byblob == HEAD(5447f770ee5c) and an emptygit diff HEAD.matches: () => false, the base behaviour): 7 red, the rendered half. Those are the section, the runnable line, the threewhypins, "through the whole table, the specimen derives the status gate", and STALE. The negatives stay green..ts, live barrel, and barrel through the table. The discrimination case also reds, at 3247 of 3247..d.ts, non-TS, docs and README stay green.Gates (all at head
28bf1d4448)node scripts/pm/dispatch-gates.mjs --commands --repo objectstack-ai/objectstack(no paths; change set from the merge base28bff18d0, one file) derived 29 commands. All 29 exited 0, with exit codes captured before any pipe.--ranreconciliation: "29 derived famil(ies) accounted for — 29 run, 0 NOT-MEASURED (a DERIVED zero — all 29 recorded an exit code and none of them is 3)".pnpm check:pm-dispatch-gates: "dispatch-gates self-test: 2011 cases pass", exit 0. It ran detached, 1111s, before the ablations, on the clean tree.node scripts/pm/bare-root-worklist.mjs --self-test(it imports the derivation's predicates) passed with OK.pnpm check:error-status-conformancepassed.eslint --no-inline-config --format json scripts/pm/dispatch-gates.mjsreturned 1 file, 0 errors and 0 warnings.eslint.config.mjsenables no type-aware linting (noparserOptions.project), so this diff cannot move the verdict on any untouched file. The fullpnpm lintis left to CI.Acceptance notes
mainwas merged once (591dc5ad2a, to28bff18d0c). It has since moved one commit, toe36ee5351b(fix(service-storage)!: the chunked completion assembles the parts the upload holds, and a re-sent chunk is counted once (#22313) #22330). That commit touches nothing underscripts/. It does edit the live specimen, and on its bytes the specimen still matchesemitsAnHttpStatusand the barrelindex.tsstill matches neither predicate, so the branch was not merged again. CI runs the merge ref.4e4111ca0, for the storage-routes path,check:error-code-casing,check:engine-double-contractandcheck:authz-resolverwere also roster-silent and underived. None has a measured consumer, so none is touched or filed. If one gains a consumer, the same content-trigger route applies.StandardErrorCode.enum.Xassignment form, because its SCREAMING_SNAKE limb requires the name to start the value. Whethercheck:dispatcher-error-vocabularycan fail on that form is not measured here.skip-changeset: rootscripts/publishes nothing.Generated by Claude Code