Repository navigation
fix(control-ui): unblock core lint by dropping a duplicate chunk label - #207548
fuller-stack-dev merged 3 commits into
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 changesThis PR removes an unreachable duplicate case label from the Control UI chunk selector. Example: Core lint checks ui/config/control-ui-chunking.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 — probable (reviewed change; failure trace). No predecessor PR is attributed. Merge readiness✅ Ready for maintainer review This PR fixes a confirmed lint failure that remains on current main, preserves chunk assignments, and introduces no actionable defects. Reviewed head: Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe Control UI build maps normalized source module IDs to stable chunk names that Vite uses to produce browser assets. flowchart LR
A[Source module IDs] --> B[Manifest key normalization]
B --> C[Stable chunk selector]
C --> D[Vite code splitting]
D --> E[Browser assets]
Technical reviewBest possible solution: Remove the unreachable later label and retain the existing chunk selector and lint rule. Do we have a high-confidence way to reproduce the issue? Current main contains both labels in one switch, and the PR supplies the corresponding failing lint diagnostic; no target code was executed during review. Is this the best way to solve the issue? Deleting the later unreachable label is the smallest complete repair because the earlier match already determines the module's chunk. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 4f8d4f5a36d7. Provenance checked
TestingProof path: in-process harness. 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:19 AM ET / 14:19 UTC. |
…ng-duplicate-case
|
Merged via squash.
|
…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]>
…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
The
check-lint-core-5CI job fails onmainand on every PR based on it.ui/config/control-ui-chunking.tslistscase "src/shared/assistant-display-content.ts":twice in the sameswitch, and oxlint'sno-duplicate-caserule reports it as an error. The second copy came in with #207505; the first has been there since #183198. Example failing job: https://github.com/openclaw/openclaw/actions/runs/46149712291/job/140994731390User Impact
No user-visible change. Contributors get a passing core lint lane again. The built Control UI keeps the same chunk layout it has on
maintoday.Why This Change Was Made
In a
switch, the first matching label wins. Onmain,src/shared/assistant-display-content.tsmatches the earlier label (line 178) and lands in thedeferred-ui-supportchunk. The later label (line 345, in the group that returnschat-transcript-runtime) can never match.#207505 added that later label, apparently meaning to move the module into
chat-transcript-runtime. But the label was unreachable from the moment it landed, so #207505's own budget numbers were measured with the module indeferred-ui-support. The Control UI performance check passes onmainwith the module there. Nothing onmainneeds the move, so this PR removes the unreachable later label.Chunk assignment for this module:
deferred-ui-supportbefore and after. No other label or chunk changes.Evidence
Tested commit:
5ab8644997c(fixc2108b39d0amerged withmainat7b5470e3358). Current headab77301c3f2mergesmainatafc98065f22to pick up #207547, which fixes the worktrees e2e failure inherited frommain. The diff againstmainis still the same one-line deletion. Red runs used unmodifiedmainatb46646b9470. The commits between those two bases touch onlysrc/agents/.Red, unmodified
main:pnpm lint:coreon the same commit reports the sameno-duplicate-caseerror. That is the only non-max-lineserror locally; CI's changed-scope run downgradesmax-lineson untouched files to warnings. CI reported "Found 278 warnings and 1 error" in stripe 5.Green, this branch:
Chunk assignment unchanged:
controlUiStableChunkName("src/shared/assistant-display-content.ts")returns"deferred-ui-support"on bothmainand this branch.pnpm ui:buildon both and mapped every source in every emitted.js.mapto its chunk name, with the content hash stripped. Both builds have the same 5,013 module-to-chunk entries, anddifffinds no differences. The module appears only indeferred-ui-support.pnpm ui:check-performancepasses on both, exit 0. Chat boot JS is 18 requests and 1,335,977 B normalized gzip in both builds, against limits of 20 requests and 1,336,272 B. The largest CSS file is 58,143 B gzip in both, against a ceiling of 58,315 B.Other checks on this branch:
node scripts/run-vitest.mjs run ui/src/app/vite-config.node.test.ts ui/src/app/vite-build.node.test.ts: 2 files, 67 tests passed.git diff --check: clean.node scripts/check-changed.mjs: every lane passed except the dead export scan, which flags five unused exports in files this PR does not touch (cli-root-options.mjs,extensions/codex/src/app-server/dynamic-tool-profile.ts,src/agents/harness/types.ts,src/agents/tool-search-catalog-visibility.ts,src/config/sessions/session-pending-input-history.types.ts). They exist onmainwithout this change.No test was added: the change deletes a label that could never match, and the lint rule itself is the check.
Not proven: I did not run the packaged browser scenarios from #207505. The module-to-chunk layout of both builds is identical, so they have nothing new to exercise.
CI history on
5ab8644997c(run 46152917381):checks-ui-e2e (8/10)failed inlinked-session-navigation.e2e.test.ts(both "preserves selected worktree identity ... colliding prefixes" cases). The same failure appears on scheduledmainfrom run 46144916564 (8b99132b530) onward, and I reproduced it locally on the CI merge'smainparentc9e795f1bcb. Onmainatafc98065f22(with test(ui): open worktree row details before following the owner link #207547) both cases pass locally.checks-ui-e2e (6/10)failed once insidebar-choice-pages.e2e.test.ts:104("bounds catalog owner navigation ... at 820"), a 30 sscrollIntoViewIfNeededtimeout on a visible menu item: attempt 1 https://github.com/openclaw/openclaw/actions/runs/46152917381/job/141003636747 failed; a single diagnostic rerun, attempt 2 https://github.com/openclaw/openclaw/actions/runs/46152917381/job/141011048831, passed. The file also passes locally on bothmainand this branch (5 of 5 tests). I treat it as a flake.Review: no separate autoreview. The diff is a one-line deletion of an unreachable
caselabel.