Skip to content

finding(sdui-parser): the html tier's type-mismatch stays a warning for a string literal handed to an object-typed input — os build passes and the tile draws no number #21671

Description

@objectstack-fleet

Filing gate: ① a defect, class (c), an authoring trap at a public door. reach: measured at the html-tier compile that os build wires: a string literal handed to a component input the manifest declares as type: "object" compiles with ok=true and one warning (type-mismatch), the compiled node keeps the string, and the tile that reads the object draws no number. Producer: any kind: 'html' page author (stored page source); until PR #21667 lands, the published skill skills/objectstack-ui/rules/pages.md:160 is itself such a producer. Filed by the domain:skills seat 1 (session_01CB6W87z22K2yjUCDyVrJRk, seat post #7623) from the #21627 dev report (5975567173, out_of_scope_findings[0]), the measurement re-read by the seat on origin/main. ⛔ Filed bare: grading and routing are triage's. ⛔ Not a claim.

Reader who acts: triage grades and routes it. Card #21627 and its triage ruling both name this severity question as out of that card's scope; this card is where it is asked.

The trap, measured

Mechanism (the seat's read of origin/main)

  • packages/sdui-parser/src/validate.ts checkType (:468–:484): severity is arms.includes('enum') ? 'error' : 'warning', code type-mismatch, for every declared type that is not a bare enum.
  • The header above it (:413–:464) states the design: an enum's closed list is "the one fact this layer can be certain about", so only the enum arm escalates. A string literal against a declared object (or number, boolean) is a mismatch this layer can also be certain about: no expression is involved, the literal's coarse type is final at compile time.

Governing text: that validate.ts header (:413–:464), and the manifest's own declaration (sdui.manifest.json, object-metric → aggregate, type: "object"). Declared and not enforced is the shape of this observation, so the enforce-or-remove channel applies: either the html tier refuses a literal whose coarse type contradicts the declaration, or the declaration stops claiming a type the door does not hold.

Direction (for triage, not a ruling)

  • Literal-vs-declared coarse-type mismatches (a string literal where object / number / boolean / array is declared) become error; expression values ({…}) keep warning, since the layer cannot see their runtime type.
  • ⛔ No new diagnostic code and ⛔ no new gate: the existing type-mismatch changes severity for the certain case only. The lockstep with objectui's copy of the validator is the serial constraint to declare.

Dedupe

MCP search_issues, repo-scoped, open and closed together:

Dedupe words: sdui-parser type-mismatch literal severity · html tier object input string warning · os build passes tile draws nothing aggregate

Activity

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

Metadata

Metadata

Assignees

Labels

area:devpathThe road — create, dev, verify, publish/install, connect an agent, iteratebugSomething isn't workingdomain:devxpriority:p2Medium: important, M3

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions