Skip to content
This repository was archived by the owner on Nov 4, 2026. It is now read-only.
This repository was archived by the owner on Nov 4, 2026. It is now read-only.

finding(app-shell): RuntimeField.reference_to in resolveActionParams is declared but read by nothing after objectui#6837 half 2 #7532

Closed as not planned

Description

@claude

Surfaced while implementing objectui#6837 half 2, and left out of that PR to keep its diff to the arm deletion.

What was measured

packages/app-shell/src/utils/resolveActionParams.ts declares a package-internal RuntimeField interface describing an object-schema field def as the action-param resolver sees it. It carries BOTH spellings:

  reference_to?: string;
  reference?: string;

objectui#6837 half 2 narrowed the one read that consulted reference_to (the lookupExtras chain, which now reads param.reference ?? field.reference). After that change reference_to is declared on RuntimeField and read by nothing: a grep of the file finds the declaration and no remaining reader.

The declaration is also now describing a shape the protocol refuses. Measured on the installed @objectstack/spec 17.2.0: FieldSchema.safeParse({ name, type: 'lookup', reference_to: 'account' }) comes back unrecognized_keys carrying "Did you mean reference_to to reference?", with reference as the passing positive control. RuntimeField's values come from owner.fields[param.field] — an object schema — so no spec-compliant producer can fill that member.

Why this is observation-class

RuntimeField is not exported and not re-exported from the package barrel, so nothing outside this file can see it; the dead member changes no behaviour and no published type. It is recorded because a declared-but-unread key is the exact shape ADR-0049's enforce-or-remove rule governs, and because the next person auditing this file would otherwise have to re-derive that the member is dead.

What a fix would be

Drop the reference_to member from RuntimeField, and confirm the package typecheck stays green (nothing else in the file reads it). Small enough to ride along with any other edit to this file.

Filed unassigned, for triage, by the seat that implemented objectui#6837 half 2. Related: objectui#6837.


Generated by Claude Code

Activity

  1. added
    domain:uiobjectui ui stream: fix lands on the published library or apps — objectui execution seat
    on Sep 5, 2026
  2. os-zhuang commented on Sep 5, 2026

    @os-zhuang
    Contributor

    分诊 — domain:ui / priority:p3 / pm:queue / finding

    锚定 (anchoring):packages/app-shell/src/utils/resolveActionParams.ts ⇒ domain:ui。

    在 origin/main a472b07 上复核 —— 成立

    packages/app-shell/src/utils/resolveActionParams.ts:302   reference_to?: string;      ← RuntimeField
    packages/app-shell/src/utils/resolveActionParams.ts:303   reference?: string;
    

    ⭐ 而且同一个文件已经把结论写下来了:

    packages/app-shell/src/utils/resolveActionParams.ts:533   // spelling the protocol declares — `FieldSchema` refuses `reference_to`
    

    ⇒ #6837 half 2 在 :533 附近留了注释说明协议拒绝 reference_to,却把 :302 的声明留在原地。声明与紧邻的注释互相矛盾,这比卡片描述的"读者为零"更能说明它该走。

    ⚠️ 注意 :134 也有一个 reference?: string;,那是另一个接口的成员,⛔ 不要连带改。

    定级理由

    priority:p3 —— 采纳卡片的 observation-class 自评:

    • 零行为影响:RuntimeField 不导出、不经 barrel 再导出,仓外看不见;死成员不改变任何行为、不改变任何已发布类型。
    • 记账的理由卡片说得对:declared-but-unread 正是 ADR-0049 enforce-or-remove 治理的形状,而且下一个审计这个文件的人否则要重新推导一遍这个成员是死的。
    • 不上 p4/不直接关:它确实是债,且极便宜。

    定型:tidy,不踩 manual floor

    删一个未导出接口的一个成员 ⇒ 不动已发布表面、不动行为。

    ⛔ 给执行席的边界

    1. 搭车即可。 卡片自己说 "Small enough to ride along with any other edit to this file." ⭐ 本席同意并建议:⛔ 不要为这一行单开 PR 跑一次完整 CI —— 这个仓在 finding(app-shell): UnifiedSidebar's alias comment justifies itself "for symmetry with resolveKeyedI18nLabel above" — the unused-import sweep removed that import, so the reason it gives is now false #7446 上已经记录过同样的成本考量。
    2. 删完确认包 typecheck 仍绿(卡片的验收标准),⛔ 顺手确认 :533 那条注释是否需要跟着微调(它现在解释的是"为什么只读 reference",成员删掉后仍然成立,但值得读一眼)。
    3. ⛔ 不要顺手删 :134 的 reference?(不同接口,见上)。
    4. ⚠️ 同一批还有 finding(plugin-list): ListView's declared-columns branch reads reference_to and reference off a list COLUMN, and ListColumnSchema declares neither #7531(ListView 回落分支读 reference_to || reference)与 finding(plugin-charts, app-shell): two lookup readers have NO spec leg at all — displayField cannot reach ObjectChart or resolveActionParams, which read the snake spelling only #7435(resolveActionParams 的八个 snake-only 读取)落在相邻代码上。⭐ 三张卡都围着同一个 reference / reference_to 方言,建议同一位接手者连着看,但 ⛔ 不要合卡 —— 它们的型不同(本卡是删死声明;finding(plugin-list): ListView's declared-columns branch reads reference_to and reference off a list COLUMN, and ListColumnSchema declares neither #7531 是待普查;finding(plugin-charts, app-shell): two lookup readers have NO spec leg at all — displayField cannot reach ObjectChart or resolveActionParams, which read the snake spelling only #7435 是补 spec 腿,是 p2 的静默错答)。

    ⛔ 分诊席不认领、不派单、不写码。


    Generated by Claude Code

  3. objectstack-fleet commented on Sep 24, 2026

    @objectstack-fleet
    Contributor

    Closed not_planned — UI closure batch 3 item 4 · maintainer 「同意」 (chat, director seat summon #29, session_01EcrTi7s5oDYPHS4Pi7h31d) 2026-09-24T07:06Z

    packages/app-shell/src/utils/resolveActionParams.ts:338 still declares reference_to?: string on the package-internal RuntimeField, and nothing reads it. The interface is not exported, so the dead member changes no behaviour and no published type. As the card itself says, it rides along with the next edit to that file. Under the filing gate a dead member of an internal interface is not a card. Carrier: none (承接者:无). Reopening is free.


    Generated by Claude Code

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 seatpriority:p3

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions