Skip to content

test(ui): the Automations Problems double serves the draft door's node path (#28192) - #28227

Merged
objectstack-fleet[bot] merged 1 commit into
mainfrom
claude/project-thread-gbt6yx
Oct 30, 2026
Merged

objectstack-fleet[bot] merged 1 commit into
mainfrom
claude/project-thread-gbt6yx

Conversation

@objectstack-fleet

Copy link
Copy Markdown
Contributor

Requested by Tesla · project thread

Clause-②: no
Metadata-protocol: none

Fixes #28219

维护者速读

  • 改了什么:只改了一个测试文件。Studio「自动化」页「问题」列表与节点单元格一致性的测试里,模拟草稿读取的替身现在像真实服务端一样,把节点配置值发现的路径改写成草稿诊断的写法(nodes.1.config.fields.id)。
  • 为什么改:fix(lint): a flow node config-value finding carries the slot's key path, so Studio's Problems row selects the node #28192 让这类发现带上了键路径 flows[0].nodes[1].config.fields.id;真实草稿接口会把它改写成条目相对路径,但测试替身直接透传原始路径,导致 main 上 Test UI (13/16) 一直红、合并队列不断踢出 PR。
  • 风险与回滚:不动任何产品代码,不发包;回滚即 revert 本 PR。
  • 先看:测试文件里新增的 itemRelative(对照 packages/metadata-protocol/src/metadata-diagnostics.ts 的 itemRelativeIssuePath),以及重新钉住的两行断言。
  • 两分钟验证:pnpm --dir ui exec vitest run packages/app-shell/src/views/studio-design/AutomationsPillar.problemsAgree-27799.test.tsx,预期 3 条全过。
  • 业务含义:问题行现在直接定位到节点本身(显示节点名「Write」,悬停为节点 id),与节点单元格说的是同一句「需要表达式」,这正是 fix(lint): a flow node config-value finding carries the slot's key path, so Studio's Problems row selects the node #28192 想要的行为;Studio 没有回归。

What changed

draftVerdict in the test's server double built _diagnostics from validateStackExpressions with path: i.path ?? i.where. Since #28192 (3efccfd5) a node config-value finding carries path: 'flows[0].nodes[1].config.fields.id'. The real draft door re-spells a gate path found on the written item to the dotted item-relative form in itemRelativeIssuePath (packages/metadata-protocol/src/metadata-diagnostics.ts L388–400, called from withPublishVerdict L422; pinned by the [#27828] case in protocol.draft-publish-verdict.test.ts L466, nodes.1.config.fields.name). That helper is not exported and @object-ui/app-shell does not depend on metadata-protocol, so the double mirrors it (for type: 'flow', prefix flows[0]) and cites the line.

With the door's spelling the Problems row is located at the node itself: targetLabel (ProblemsPanel.tsx L54–57) renders the node's display name Write with the node id as title. Before #28192 the row fell back to the where prose (node 'write' … config.fields.id), which is what L211–212 pinned. They are re-pinned to the node-located shape. The case's subject is unchanged: the row still reads the cell's own refusal, NEEDED() (the assertion before the target pins, which stayed green throughout).

Verification

  • Red on origin/main @ 7811c3f6 (≥ 3efccfd5): AssertionError: expected 'flows[0].nodes[1].config.fields.id' to contain 'node \'write\'' — 1 failed | 2 passed.
  • Green on 3efccfd5^: by reasoning from L62, not a second build — before fix(lint): a flow node config-value finding carries the slot's key path, so Studio's Problems row selects the node #28192 lint gave a node config finding no path, so i.path ?? i.where served the where prose that L211–212 pinned.
  • Door spelling only (before the re-pin): expected 'Write' to contain 'node \'write\'' — the row names the node by its label; cell and row agree.
  • With the fix: 3 passed (3).
  • Ablation: path: i.path ?? i.where restored verbatim ⇒ reds again with Received: "flows[0].nodes[1].config.fields.id"; fix restored, git diff HEAD empty.
  • Gates: dispatch-gates.mjs --commands derived 24 commands for this one file; ran record below.

Ran record (in progress; completed record follows in the os-dev-report): 14 of 24 exit 0 so far; pnpm --dir ui exec vitest run scripts/ exit 1 (7 tests in 2 files, under triage against main — this diff touches no script).

Acceptance notes

🤖 Generated with Claude Code

https://claude.ai/code/session_01L9qibvQ7smY6Y87y1pRDaY

…e path

Since the lint pass gave a flow node's config-value finding its slot key
path (flows[0].nodes[1].config.fields.id), the test's draft-read double
passed that stack spelling straight into `_diagnostics`, so the Problems
row showed the raw path. The real door re-spells it item-relative
(nodes.1.config.fields.id) in itemRelativeIssuePath; the double now does
the same, and the row is located at the node itself, so the target pin
reads the node's name and id.

Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L9qibvQ7smY6Y87y1pRDaY
@objectstack-fleet objectstack-fleet Bot added the skip-changeset PR has no user-facing published change; bypasses the changeset gate label Oct 30, 2026
@objectstack-fleet

Copy link
Copy Markdown
Contributor Author

domain:ui#3 · os-tesla · session_01L9qibz8HEj53Wx2uphTo2o

维护者速读

席位意见:根因已核实,替身逐行对照服务端改写函数,测试主旨「节点格与问题行用同样的话」不变,p0 修复前进,可直接落地。

席位核对

ACCEPT · seat domain:ui#3 · head 04064bcf · 2026-10-30T18:12Z

  1. Shape: Fixes #28219, draft, base main; 1 file, +17/−5: new itemRelative() in the draft-read double (strips the flows[0] prefix, [n] → .n, keeps any other path as written), used in draftVerdict; header comment updated; L211–212 re-pinned to textContent === 'Write' and title === 'write'. The NEEDED() message assertion and the problems count are unchanged. Seat read of the diff against packages/metadata-protocol/src/metadata-diagnostics.ts itemRelativeIssuePath L388–400: same prefix rule and re-spelling for the flows stack key.
  2. Premise measured: red on origin/main 7811c3f6 (expected 'flows[0].nodes[1].config.fields.id' to contain node 'write', the queue signature of 41095303977), green with the fix 3/3; ablation (restore i.path ?? i.where unwrapped) reds with the same Received, restored blob = HEAD. Problems row measured as located at the node, so no Studio regression and no revert of 3efccfd5 (card step 4).
  3. Gates / check-runs: on head 04064bcf every latest check-run is success or skipped (41 / 14, 0 failure), Test UI (13/16) success, mergeable_state clean. Dev: 24/24 derived commands exit 0, --ran 0 NOT-MEASURED (os-dev-report 6530102393); writes relay 2, MCP 0.
  4. Accepted deviations: the first ui scripts/ run had 7 load timeouts; the same head re-ran exit 0 (4901 passed), and check-i18n-call-site-keys passed 137/137 alone. type-check-debt hit the dev's 580 s cap and was exit 0 uncapped. Both declared in the report.
  5. Out of scope: the CI gap that let fix(lint): a flow node config-value finding carries the slot's key path, so Studio's Problems row selects the node #28192 land without the Test UI shards is ci: a diff confined to a package ui tests import (packages/lint, spec, client, core, formula, sdui-parser, types) skips the Test UI shards on the PR and in the queue #28220 (domain:devx). Skills-docs: none — Metadata-protocol: none.
  6. Landing: check-governed-merges --pr 28227 NOT governed, 22 changed lines ≤ 3000; no contract review owed (Clause-②: no, no packages/spec path); skip-changeset (test-only, private package). Main-red fix-forward (landing-operations main-red ①). The seat readies it and arms auto-merge under the maintainer's 「按 pm-dispatch 审过的pr你可以自主落地」; fix(ui): Setup metadata lists take their title from the sidebar and lead with the label #28197 is requeued after it lands.

@objectstack-fleet
objectstack-fleet Bot marked this pull request as ready for review October 30, 2026 18:15
@objectstack-fleet
objectstack-fleet Bot added this pull request to the merge queue Oct 30, 2026
Merged via the queue into main with commit 16e2122 Oct 30, 2026
61 checks passed
@objectstack-fleet
objectstack-fleet Bot deleted the claude/project-thread-gbt6yx branch October 30, 2026 19:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/s skip-changeset PR has no user-facing published change; bypasses the changeset gate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Test UI red on main: AutomationsPillar.problemsAgree-27799 still expects the node config finding's where prose, and #28192 now gives it a key path

1 participant