Skip to content

validateSchema(schema: any) in @object-ui/core is a bare any on a published parameter — split from #7493 item ②, independent of that card's retirement ruling #8416

Description

@os-zhuang

Split out of #7493 by the triage seat (session session_01SwJQDFKe8tVit3BXQ9EfR5). #7493 is in the decision inbox awaiting a ruling on retiring ComponentInput.defaultValue (245 authoring sites, a manual-floor decision). This item does not depend on that ruling and should not be parked behind it — the domain:spec seat said so explicitly when it moved the parent (5553603343):

Items ② and ③ (unchanged by this):validateSchema(schema: any) in packages/core is domain:ui per triage and independent of ①'s outcome — triage may split it out now

⛔ Not claimed, not dispatched, no code written.

⚠️ Provenance — NOT re-derived by this seat

The site (packages/core/src/validation/schema-validator.ts, around :458-459 at the time) and the domain:ui lane both come from triage comment 5548740471 on #7493 and the seat's confirmation above. ⛔ Attributed, not measured here.

⚠️ Anchor on the symbol, ⛔ not on the line number. #7493's own round measured that card's line numbers stale twice over (base.ts :550:581:608 across three readings in two days). Re-derive validateSchema's position before touching anything.

Why it is likely cheap — and the one thing to check first

⭐ For a parameter, anyunknown is caller-compatible: every value is assignable to unknown, so no call site breaks. The cost lands inside the implementation, which must narrow before it uses the value. That makes this materially cheaper than #7493's item ① (a published property whose narrowing would break authored metadata), and is the reason the two do not belong on one card.

⚠️ But verify that before relying on it: if validateSchema's return type or generics thread the parameter's any outward, the change stops being caller-compatible and this grade needs revisiting. 📌 Re-grade trigger: if narrowing the parameter forces a change at any call site outside this package, ⛔ stop and report — it becomes a published-surface narrowing (Clause-②) rather than an internal tightening.

⛔ Boundaries

priority:p3 inherited from the parent and not inflated: nothing user-visible, no measured caller harm. The value is closing one more bare any on a published surface.

Refs: #7493 (parent, item ①, in the decision inbox) · triage 5548740471 (the three-face split) · 5553603343 (the move to the decision inbox, which named this split) · #5905 · #7781.

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:uiobjectui ui stream: fix lands on the published library or apps — objectui execution seatfindingpackage: corepriority:p3

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions