Skip to content

docs(pm): drop the stale shadowing claim from dispatch-gates' selfTest comment - #15345

Merged
os-steve merged 1 commit into
mainfrom
claude/issue-14991-dispatch-gates-shadowed-comment
Sep 4, 2026
Merged

docs(pm): drop the stale shadowing claim from dispatch-gates' selfTest comment#15345
os-steve merged 1 commit into
mainfrom
claude/issue-14991-dispatch-gates-shadowed-comment

Conversation

@claude

@claude claude Bot commented Sep 4, 2026

Copy link
Copy Markdown
Contributor

Fixes #14991

What

scripts/pm/dispatch-gates.mjs carried a five-line comment inside selfTest(), immediately above the tierOwnAbs / tierOwnRel pair, whose first sentence went stale once PR #14988 replaced the five named node:path imports with one namespace binding (import * as nodePath from 'node:path', L420). With that binding shape, no module-scope relative exists for the const relative = [...] fixture (a string-array .join('\n'), still at L12679) to shadow.

Verified on this branch's tree:

$ git grep -n "from 'node:path'" scripts/pm/dispatch-gates.mjs
scripts/pm/dispatch-gates.mjs:420:import * as nodePath from 'node:path';

$ git grep -n "^const relative\|const relative = " scripts/pm/dispatch-gates.mjs
scripts/pm/dispatch-gates.mjs:12679:  const relative = ["const P = new URL('../../.claude/agents/os-dev.md', import.meta.url);", "const R = '../..';"].join('\n');

The ROOT-derived spelling itself was never a workaround — it is the prefix every sibling case in that block already joins against — so only the stated reason needed restating.

Change

Comment-only, one file, no code or assertion change:

-  // `relative` from `node:path` is SHADOWED inside this function — a fixture
-  // string a few thousand lines up binds that name — so the repo-relative
-  // spelling comes from ROOT, the prefix every sibling case here already joins
-  // against. A prefix that stops holding yields an empty root, which the walk
-  // above reports rather than turning into a pass.
+  // The repo-relative spelling here comes from ROOT, the prefix every sibling
+  // case in this block already joins against — the consistent spelling, not a
+  // workaround. A prefix that stops holding yields an empty root, which the
+  // walk above reports rather than turning into a pass.
   const tierOwnAbs = fileURLToPath(import.meta.url);

5 lines → 4 lines (shorter, not longer).

Verification

Ran on b0c247c6 (rebased onto origin/main), through scripts/pm/os-verify-lock.sh, real verdict lines below (not raw exit codes):

Direct-node gates — VERDICT command-exit 0:

OK: all 143 declared cross-package glob(s) (99 unique) are covered...
check-closing-keyword-parity: OK (3 parsers agree on all 9 keywords...)
✓ check-closing-keyword-parity --self-test: 24 assertions, 5 mutations...
✓ comment-mask corpus sweep: 5895 files, 0 disagree, 0 unparseable...
✓ check-self-test-wired: every one of the 168 script(s)...
check-self-test-wired --self-test: 4 live ledger row(s) verified...
✓ check-whole-set-label-write: 0 violations...
✓ check-whole-set-label-write --self-test: all cases pass...

pnpm check:* gates — VERDICT command-exit 0:

✓ check-agent-test-spelling --self-test: all cases pass
✓ check-bash32-floor self-test: 153 cases pass.
✓ check-cli-command-ids self-test: 39 cases pass...
check:cross-package-test-inputs — ok (all fixtures resolve() off a fileURLToPath seed)
check-declared-population-live --self-test: 16 assertion(s) passed.
✓ check:declared-population-live — 201 of 252 famil(ies)...
✓ check-entry-guard self-test: 54 cases pass...
✓ check-nul-bytes --self-test: 75 assertions...
✓ check:parse-guard self-test: 46 cases pass...
✓ dispatch-gates self-test: 1382 cases pass.   ← the file's OWN self-test, same case count as main
✓ pnpm-filter-targets --self-test: 54 assertions...
✓ check-pnpm-filter-targets --self-test: 40 assertions...
OK check-ratchet-remedy-authority: 202 scripts swept...
✓ check-refd-timer-probe self-test: 11 cases pass...
✓ check-watch-hint-literal self-test: 57 cases pass...

Tooling-script rule (this file is itself a gate/tool script): no *.test.ts in scripts/pm/ tests it directly, and the only repo-wide dispatch-gates.mjs mentions outside its own self-test are prose comments in five unrelated test files (packages/cli/test/serve-node-env-production-default.e2e.test.ts, packages/create-objectstack/src/runtime-image.test.ts, packages/objectql/src/action-owner-key-single-source.test.ts, packages/runtime/src/action-owner-key-single-source.test.ts, packages/types/src/driver-error-classification.callers.test.ts) — none import or execute this file; they only cite its self-test's guarantees. The file's own self-test (pnpm check:pm-dispatch-gates, run above) is the complete test-suite obligation here.

pnpm check:nul-bytes covers the edited file; also spot-checked with grep -naP '[\x00-\x08\x0b\x0c\x0e-\x1f\x7f]' — clean.

Tooling-only change under scripts/pm/**skip-changeset applies.


Generated by Claude Code

…t comment

PR #14988 replaced the five named `node:path` imports with one namespace
binding (`import * as nodePath`), so no module-scope `relative` binding
exists for the fixture string to shadow. Restate the standing reason the
repo-relative spelling comes from ROOT: it is the prefix every sibling
case in the block already joins against, not a workaround.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019RfFHiRCSs3JXLK4cwcfox
@claude claude Bot added the skip-changeset PR has no user-facing published change; bypasses the changeset gate label Sep 4, 2026
@os-steve
os-steve marked this pull request as ready for review September 4, 2026 13:04
@os-steve
os-steve enabled auto-merge September 4, 2026 13:04
@os-steve
os-steve added this pull request to the merge queue Sep 4, 2026
Merged via the queue into main with commit b03d01e Sep 4, 2026
36 checks passed
@os-steve
os-steve deleted the claude/issue-14991-dispatch-gates-shadowed-comment branch September 4, 2026 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/xs skip-changeset PR has no user-facing published change; bypasses the changeset gate

Projects

None yet

2 participants