Repository navigation
fix(control-ui): keep assistant display content out of the Chat boot chunk - #207592
Conversation
|
🦞👀 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 changesAssigns assistant display-content code to the existing Chat transcript runtime chunk. Example: Build the Control UI with src/shared/assistant-display-content.ts.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Regression provenancePossible regression — suspected (reviewed change). No predecessor PR is attributed. Merge readiness✅ Ready for maintainer review This PR restores the intended Chat chunk assignment with a minimal change that current main still needs; no actionable defects were found. Reviewed head: Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe Control UI build maps source module IDs to JavaScript chunks that browsers download for each route. flowchart LR
A[Source module IDs] --> B[Stable chunk assignment]
B --> C[Vite build]
C --> D[Chat boot chunk]
C --> E[Chat transcript runtime]
D --> F[Browser Chat route]
E --> F
Technical reviewBest possible solution: Retain the single explicit assignment in the existing chunking owner alongside the module's Chat consumers. Do we have a high-confidence way to reproduce the issue? Current-main source establishes the missing explicit assignment and Chat boot fallback; the PR reports matching before-and-after source-map results, but no build was executed during this read-only review. Is this the best way to solve the issue? The one-line assignment is the smallest complete repair, reusing the established chunk owner and preserving the existing import graph and budgets. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 3e55ac17fe46. Provenance checked
TestingProof path: none. SecurityNone. EvidenceWhat I checked:
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, 11:03 AM ET / 16:03 UTC. |
…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
#207505 placed
src/shared/assistant-display-content.tsin thechat-transcript-runtimechunk ("Chat loads events and media together; keep both out of the route entry"). The same module also had an older case in thedeferred-ui-supportlist, which made a duplicatecaseand 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-runtimelist, as #207505 intended. The module's only importers,ui/src/pages/chat/chat-gateway.tsandui/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:buildandscripts/check-control-ui-performance.mtson main 800644b and on this head (--base-distmain build): 0 violations on both.control-ui-boot-chatchat-transcript-runtimecontrol-ui-boot-chatchunkchat-transcript-runtimechunknode scripts/run-oxlint.mjs ui/config/control-ui-chunking.ts: 0 errors, one case for the module.