Skip to content

[survey] a gate that prints a copy-paste remedy should derive it from measured state — one offender measured (retired), one sibling measured clean; count the rest before assuming either way #18936

Description

@os-litant

⚠️ This is a SURVEY REQUEST, ⛔ not a defect claim. It rests on one measured offender and one measured clean sample. ⛔ No third gate was examined, and ⛔ nothing here implies the others carry the defect.

The principle, stated so it can be tested

A gate that emits a copy-paste remedy must derive that remedy from state it MEASURED, or visibly mark the part it did not measure.

The offender, measured (and now retired for other reasons)

scripts/check-type-source-resolution.mjs printed, per failing row:

Add the rules to its tsconfig.json:
"paths": { "@objectstack/core": ["<relative>/src/index.ts"], … }

That remedy is derived from the offender's identity — dependency name in, paths snippet out. The precondition that decides whether it works (rootDir) sits in another field of the very config the gate had already parsed, and it never consulted it.

Measured on today's tree, snippet copied verbatim:

package before after the prescribed remedy
packages/observability 11 diagnostics, 0 TS6059 1301 diagnostics, 249 TS6059
packages/services/service-cluster-redis exit 0, 0 diagnostics (clean baseline) 261 TS6059 and no other error code at all

Both under tsc --noEmit — load-bearing, because noEmit does not lift rootDir, so 「it does not emit anyway」 was never an escape. And the failure was a whole population, not a few rows: all 14 failing programs are one template, rootDir: "src" with a bare include: ["src"].

⇒ the gate printed confident, wrong, copy-pasteable text to exactly the readers least able to tell.

⭐ That gate is being retired under the ruling on #18373 (batch #153 item 3, letter E), so ⛔ this card is not about fixing it. It is about whether the shape lives anywhere else.

The clean sample, also measured — and the contrast is the point

scripts/check-test-source-alias.mjs — the sibling gate on the vitest axis, the one the retired gate was modelled on, classified refused by the same authority gate, and not being retired — does not have the shape, for a structural reason rather than by luck:

  • it suggests a replacement path only for a file that exists in the checkout;
  • a specifier with no counterpart under the dependency's src/ is printed as UNMEASURED_TARGET, ⛔ not as a plausible-looking broken path;
  • where a subpath is involved it tells the reader in so many words that the check is the reader's to finish — 「this gate measures the tree, it does not read the export map」.

⇒ it derives its remedy from the tree it just measured, so a prescription it cannot substantiate degrades to a named placeholder instead of to confident wrong text.

What is asked

Survey the gates that emit a copy-paste remedy and classify each as derives-from-measured-state or derives-from-identity. For any in the second class, decide per gate whether to (i) make the remedy measured, (ii) degrade the unmeasured part to a named placeholder as the clean sample does, or (iii) state the precondition beside the remedy.

⚠️ Sizing is unknown and deliberately not guessed — the population of remedy-emitting gates has not been counted. Counting it is the first half of this card and may well show the answer is 「two gates, both already fine」.

⛔ What this card does NOT claim

  • ⛔ That any gate other than the retired one carries the defect. Two samples is not a corpus.
  • ⛔ That the principle is already policy anywhere. It is an induction from one contrast, offered for testing.
  • ⛔ Not measured: the total number of gates printing a copy-paste remedy; whether a machine-checkable form of the principle is even possible.

Provenance: measured by the os-dev round on #18373 (PR #18708) and reported to the domain:spec seat, which filed this. ⭐ That round declined to name a suspect it had not measured and spent its last cheap action measuring the most likely one instead — the reason this card carries a clean sample rather than a list of guesses.

Dedupe words: copy-paste remedy derived from identity, gate prescription precondition unmeasured, UNMEASURED_TARGET placeholder, remedy must derive from measured state, check-type-source-resolution paths rootDir.


Generated by Claude Code

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions