Skip to content

finding(types): text-value-retired-6951.test.ts names two cases by line address (layout.ts:66) — accurate today, checked by nothing #8045

Description

@claude

Found by the packages/** sweep objectui#7913 asked its seat to run. Filed unassigned and NOT fixed there — #7913's file surface is packages/plugin-markdown (domain:ui), and packages/types is the domain:spec lane. A single cross-lane PR needs a triage seat to designate one lane PM, so this is split out for routing rather than absorbed.

What

packages/types/src/__tests__/text-value-retired-6951.test.ts names two cases by line address:

176:  it('control: `TextSpanSchema.value` — the sibling member at `layout.ts:66` — is still ACCEPTED and survives', ...
342:  it('control: `TextSpanSchema.value` (`layout.ts:66`) still type-checks — retired by symbol, not by grep', ...

Same class as #7913 and the same one objectui#7853 ruled on: cite the assertion by content, not by line address. Prior recurrences: #6998, #7289, and #6548.

⭐ Are they stale today? NO — measured, not assumed

Triage explicitly did not check this. On origin/main at 06761b351:

$ sed -n '66p' packages/types/src/layout.ts
  value?: string;

packages/types/src/layout.ts:66 is TextSpanSchema.value — both citations are accurate right now. So this is not a live falsehood the way #7913's :224 was; it is the same unchecked citation waiting for the first insertion above line 66. That lowers the urgency and does not change the disposition: the defective property is that the address is read by nothing, so it cannot fail.

⚠️ The rot is close. layout.ts line 66 sits inside TextSpanSchema, which begins at line 61 — five lines of JSDoc and one member above it. Any comment added to type: 'span' or to the value doc block moves it.

The sweep, and its control

Run in a clean worktree of origin/main at 06761b351:

grep -rnE "^[[:space:]]*(it|test|describe)[.a-zA-Z]*\(.*\.(md|mdx|ts|tsx|js|jsx|mjs|cjs|json|ya?ml|css|html|txt|snap|sh):[0-9]+" \
  packages --include='*.test.ts' --include='*.test.tsx' --include='*.test.mts' \
           --include='*.spec.ts' --include='*.spec.tsx'

Control that fires (a zero from an unvalidated regex proves nothing): run against a fixture carrying five known-positive shapes (single quotes, double quotes, backticks, it.each, it.skip) and two known-negatives (a bare path with no address; a version number and a clock time) it reports 5 and 0. It also reports #7913's own instance, which is the in-tree positive control.

Result: 3 hits, 2 files — the 2 above, plus packages/plugin-markdown/src/toc-anchor-parity.test.tsx:136, which is fixed in the PR for #7913. Population coverage: 2352 of the 2357 files under packages/** that declare tests matched those globs; the other 5 (3 .md, create-plugin/src/templates.ts, core/src/__benchmarks__/core.bench.ts) were swept separately and are clean.

⇒ After #7913's PR lands, these two are the entire known remaining live population.

A note for whoever picks this up

The it( -line regex above has a blind spot the #7913 seat hit in practice: a test name built from data does not carry the address on the it( line. toc-anchor-parity.test.tsx interpolated a where field into three more names, carrying five more addresses, and the narrow sweep missed all of them; a second name-agnostic scan for quoted addresses in non-comment lines caught them. If this card is used to close the class, run the second scan too.

Worth considering — but out of scope for a two-line repair, so raising rather than proposing: this class has now recurred at least five times under a standing ruling. A scripts/check-*.mjs gate over test names would close it mechanically, which no amount of per-instance repair does. That is a domain:devx decision, not something to bolt onto this card.


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

    Labels

    domain:specobjectui spec stream: fix lands on packages/types, schema corpus or spec pin coupling — spec lanepriority:p3tests

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions