Repository navigation
fix(control-ui): keep assistant display content in the transcript chunk - #207550
Conversation
- #207505 moved src/shared/assistant-display-content.ts to chat-transcript-runtime, but an older case for the same module in the deferred-ui-support list came first, so the new case was dead code and oxlint failed with no-duplicate-case. - Remove the stale case. The module's only importers (chat-gateway.ts, chat-live-events.runtime.ts) are in chat-transcript-runtime.
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: passed. What this changesRemoves the earlier assistant-display-content chunk assignment so the module joins its Chat consumers in chat-transcript-runtime. Example: Build the Control UI with src/shared/assistant-display-content.ts.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Regression provenanceRegression provenance — suspected predecessor, not a causality claim: source commit Possible regression — suspected (reviewed change). No predecessor PR is attributed. Merge readiness✅ Ready for maintainer review Keep open: this PR minimally repairs a duplicate switch label still present on current main and restores the intended transcript chunk assignment. No actionable defects found; lint and performance checks pass, while UI CI remains in progress. Reviewed head: Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe Vite chunking configuration maps source module IDs to output bundles that the browser downloads for Control UI routes. flowchart LR
A[Source module IDs] --> B[Stable chunk assignment]
B --> C[Vite build]
C --> D[Chat transcript bundle]
C --> E[Deferred support bundle]
D --> F[Browser Chat route]
Technical reviewBest possible solution: Retain this one-line deletion so the existing chunk owner assigns the module exactly once alongside its Chat consumers. Do we have a high-confidence way to reproduce the issue? Current-main source directly establishes the duplicate labels and first-match behavior; the PR reports the corresponding lint failure, and the reviewed head passes that lint check. Is this the best way to solve the issue? Deleting the stale earlier case is the smallest complete repair: it fixes lint and activates the assignment intended by the merged startup-budget work without introducing another owner. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 2053c2111816. Provenance checked
TestingProof path: none. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource -1. Total -1 across 1 file. Added test files: 0. View PR surface stats
Preflight sourceSource unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified. LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed November 28, 2026, 9:22 AM ET / 14:22 UTC. |
…ng-duplicate-case
…chunk (#207592) ## What Problem This Solves #207505 placed `src/shared/assistant-display-content.ts` in the `chat-transcript-runtime` chunk ("Chat loads events and media together; keep both out of the route entry"). The same module also had an older case in the `deferred-ui-support` list, which made a duplicate `case` and failed lint. #207548 and #207550 each removed one of the two copies, so main now has no case for the module. It falls through to the Chat route boot chunk, `control-ui-boot-chat`, which #207505 meant to keep it out of. ## Why This Change Was Made Restore the one case in the `chat-transcript-runtime` list, as #207505 intended. The module's only importers, `ui/src/pages/chat/chat-gateway.ts` and `ui/src/pages/chat/chat-live-events.runtime.ts`, are already in that list. There is still only one case for the module, so lint stays clean. ## User Impact No visible change. Chat makes the same number of startup requests, and its boot entry is slightly smaller. ## Evidence `pnpm ui:build` and `scripts/check-control-ui-performance.mts` on main 800644b and on this head (`--base-dist` main build): 0 violations on both. | | main 800644b | this head | |---|---|---| | Module location (source maps) | `control-ui-boot-chat` | `chat-transcript-runtime` | | `control-ui-boot-chat` chunk | 971,819 B raw / 288,708 B gzip | 971,607 B raw / 288,646 B gzip | | `chat-transcript-runtime` chunk | 80,684 B raw / 28,375 B gzip | 80,862 B raw / 28,436 B gzip | | Chat boot JS (perf check) | 18 requests, 1,336,210 B gzip | 18 requests, 1,336,203 B gzip (limit 1,336,272 B) | | New Session boot JS | 16 requests, 819,989 B gzip | 16 requests, 819,989 B gzip | | CSS (startup, Chat, total) | unchanged | unchanged | `node scripts/run-oxlint.mjs ui/config/control-ui-chunking.ts`: 0 errors, one case for the module. Co-authored-by: Ayaan Zaidi <[email protected]>
…nk (openclaw#207550) ## What Problem This Solves `check-lint-core-5` fails on every PR that runs it: ``` ui/config/control-ui-chunking.ts:178:10: error: Duplicate case label (eslint(no-duplicate-case)) ``` openclaw#207505 added `case "src/shared/assistant-display-content.ts":` to the `chat-transcript-runtime` list. An older case for the same module (openclaw#183198) was already in the `deferred-ui-support` list. In a `switch` the first label wins, so the new case never ran: a build of main still puts the module in `deferred-ui-support`, not where openclaw#207505 meant it to go. ## Why This Change Was Made Remove the stale `deferred-ui-support` case and keep openclaw#207505's placement. The only importers of the module are `ui/src/pages/chat/chat-gateway.ts` and `ui/src/pages/chat/chat-live-events.runtime.ts`, and both are in the `chat-transcript-runtime` list. ## User Impact No visible change. Chat loads the same code with the same number of requests. Routes that use `deferred-ui-support` without Chat download 200 fewer raw bytes. ## Evidence - `node scripts/run-oxlint.mjs ui/config/control-ui-chunking.ts`: 1 error on main 35d95ac, 0 with this change. - `pnpm ui:build` on main and on this change. Source maps show `assistant-display-content.ts` in `deferred-ui-support` before and in `chat-transcript-runtime` after. The chunk names are the same; only those two chunks change materially (`deferred-ui-support` -200 B raw, `chat-transcript-runtime` +178 B raw). - `scripts/check-control-ui-performance.mts --base-dist <main build>`: 0 violations. Chat boot JS 18 -> 18 requests, 1,335,977 -> 1,336,203 B gzip (limit 1,336,272 B), served brotli 1,148,012 -> 1,147,881 B. New Session 16 -> 16 requests. Co-authored-by: Ayaan Zaidi <[email protected]>
…chunk (openclaw#207592) ## What Problem This Solves openclaw#207505 placed `src/shared/assistant-display-content.ts` in the `chat-transcript-runtime` chunk ("Chat loads events and media together; keep both out of the route entry"). The same module also had an older case in the `deferred-ui-support` list, which made a duplicate `case` and failed lint. openclaw#207548 and openclaw#207550 each removed one of the two copies, so main now has no case for the module. It falls through to the Chat route boot chunk, `control-ui-boot-chat`, which openclaw#207505 meant to keep it out of. ## Why This Change Was Made Restore the one case in the `chat-transcript-runtime` list, as openclaw#207505 intended. The module's only importers, `ui/src/pages/chat/chat-gateway.ts` and `ui/src/pages/chat/chat-live-events.runtime.ts`, are already in that list. There is still only one case for the module, so lint stays clean. ## User Impact No visible change. Chat makes the same number of startup requests, and its boot entry is slightly smaller. ## Evidence `pnpm ui:build` and `scripts/check-control-ui-performance.mts` on main 4d25e66 and on this head (`--base-dist` main build): 0 violations on both. | | main 4d25e66 | this head | |---|---|---| | Module location (source maps) | `control-ui-boot-chat` | `chat-transcript-runtime` | | `control-ui-boot-chat` chunk | 971,819 B raw / 288,708 B gzip | 971,607 B raw / 288,646 B gzip | | `chat-transcript-runtime` chunk | 80,684 B raw / 28,375 B gzip | 80,862 B raw / 28,436 B gzip | | Chat boot JS (perf check) | 18 requests, 1,336,210 B gzip | 18 requests, 1,336,203 B gzip (limit 1,336,272 B) | | New Session boot JS | 16 requests, 819,989 B gzip | 16 requests, 819,989 B gzip | | CSS (startup, Chat, total) | unchanged | unchanged | `node scripts/run-oxlint.mjs ui/config/control-ui-chunking.ts`: 0 errors, one case for the module. Co-authored-by: Ayaan Zaidi <[email protected]>
What Problem This Solves
check-lint-core-5fails on every PR that runs it:#207505 added
case "src/shared/assistant-display-content.ts":to thechat-transcript-runtimelist. An older case for the same module (#183198) was already in thedeferred-ui-supportlist. In aswitchthe first label wins, so the new case never ran: a build of main still puts the module indeferred-ui-support, not where #207505 meant it to go.Why This Change Was Made
Remove the stale
deferred-ui-supportcase and keep #207505's placement. The only importers of the module areui/src/pages/chat/chat-gateway.tsandui/src/pages/chat/chat-live-events.runtime.ts, and both are in thechat-transcript-runtimelist.User Impact
No visible change. Chat loads the same code with the same number of requests. Routes that use
deferred-ui-supportwithout Chat download 200 fewer raw bytes.Evidence
node scripts/run-oxlint.mjs ui/config/control-ui-chunking.ts: 1 error on main da76574, 0 with this change.pnpm ui:buildon main and on this change. Source maps showassistant-display-content.tsindeferred-ui-supportbefore and inchat-transcript-runtimeafter. The chunk names are the same; only those two chunks change materially (deferred-ui-support-200 B raw,chat-transcript-runtime+178 B raw).scripts/check-control-ui-performance.mts --base-dist <main build>: 0 violations. Chat boot JS 18 -> 18 requests, 1,335,977 -> 1,336,203 B gzip (limit 1,336,272 B), served brotli 1,148,012 -> 1,147,881 B. New Session 16 -> 16 requests.