Skip to content

[P3] Generalise the lint rule surfaces axis to an open N-surface dimension (#4463 P1 introduced a closed two-value one) #7443

Description

@os-zhuang

Split out of #4717 at dispatch, per the maintainer's 2026-08-07 migration ruling. Filed by the domain:metadata seat that landed the backend half; unassigned, and deliberately carrying no domain:* label — routing is the triage seat's call (this lands in packages/lint, not in packages/metadata*).

What exists today

#4463 P1 introduced, as needed rather than as a design, a closed axis on lint rules:

  • surfaces: ('cli' | 'runtime-publish')[]
  • plus runtimeTypes and surfaceReason

That was not optional at the time and should not be read as speculative: it is the structural precondition for the ratchet guard — a guard cannot guard a surface that was never declared. So the axis earned its place; the question this card raises is only whether two values is the right arity.

What this card asks

Generalise it to an open N-surface dimension, so a new enforcement surface is a declaration rather than an enum edit plus the guard changes that follow it.

⚠️ Grade this against the appetite bar before sizing it

Per the escalation guidance, an ability that no measured consumer is asking for is exactly what should not get built on speculation. So the first question for whoever takes this is not "how" but:

Is there a third surface actually arriving? If the honest answer is "not yet", the correct outcome may be to hold this rather than build an open dimension for a set that has had two members since it was created.

Filing it because #4717's scope named it and dropping it silently would be worse than recording it — not because it is obviously due.

The adjacent card that could supply the pull

#7220 (domain:spec-tooling, currently pm:blocked) is the concrete instance of the same question from the other end: the four views[] visibility-predicate rules are CLI-only, so a Studio/REST/MCP view write bypasses all of them — and its own title records the constraint "if they move to runtime-publish, they must move together". If those rules move, the axis gets exercised for real, and this card gains an evidence-backed reason to exist. Whoever grades this should read #7220 first; the two are likely one decision, not two.

Related

#4463 (P1), PR #4715, #4717 (parent, now closed — its metadata half landed as 89d7b35a7), #7220 (the CLI-only visibility predicates).

Blocked-by: #7220


Generated by Claude Code

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