Skip to content

ActionParam is declared twice in app-shell and the two copies disagree on five members — ActionDefaultInspector.tsx:266 vs ActionPreview.tsx:47 #6329

Description

@os-support-ai

Filed unassigned, as an observation for PM triage, from the excluded half of #6287 (that card's dispatch named this pair explicitly as out of its scope: different files, different pair). Not fixed there.

Verified on origin/main @ 090927f4f, not taken from the parent card's text.

The two declarations

packages/app-shell/src/views/metadata-admin/inspectors/ActionDefaultInspector.tsx:266

interfaceActionParam{name?: string;field?: string;label?: unknown;type?: string;required?: boolean;placeholder?: string;defaultFromRow?: boolean;[k: string]: unknown;}

packages/app-shell/src/views/metadata-admin/previews/ActionPreview.tsx:47

interfaceActionParam{name?: string;field?: string;label?: string|{en?: string};type?: string;required?: boolean;options?: Array<{label: string|{en?: string};value: string}>;placeholder?: string;helpText?: string;defaultValue?: unknown;defaultFromRow?: boolean;}

They disagree on five things:

ActionDefaultInspector.tsx:266ActionPreview.tsx:47
labelunknownstring | { en?: string }
optionsabsentdeclared
helpTextabsentdeclared
defaultValueabsentdeclared
index signature[k: string]: unknownnone

The index-signature row is what makes the other four hard to see: the inspector's copy admits options / helpText / defaultValue through [k: string]: unknown at type unknown, so the two copies are not loudly incompatible — they just describe different authoring surfaces for the same key, and the compiler cannot compare them.

Why nothing caught it

Both are module-local interfaces, and both scanners in scripts/check-spec-symbol-derivation.mjs skip non-exported declarations — the hole #5899 is about. These sit in its measured population (PR #6284 is the census).

Suggested shape (for triage, not a ruling)

Same treatment #6287 applied to the FlowNode / FlowEdge copies: stop restating the shape, converge both files onto one declaration, and check the surviving one against ActionParamSchema by probe rather than by eye — in particular whether label?: unknown is a real layer difference or just the looser of two guesses.

⚠️ Worth probing before assuming the narrow copy is right: on #6287 the analogous "narrow the local type onto the contract" instinct was half wrong. Dropping a key the strict schema refuses was a genuine defect with a live UI producing it; making an optional member required was a measured no-op that would have made a state which genuinely occurs unrepresentable. Which half applies here needs the same two separate measurements.

Related: #6287 (the pair this was excluded from), #5899 (the instrument hole), PR #6284 (the census).

Generated by Claude Code

Metadata

Metadata

Assignees

Labels

domain:uiobjectui ui stream: fix lands on the published library or apps — objectui execution seatpm:dispatched

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions