Repository navigation
fix: restore Control UI startup headroom and enforce budget limits - #179227
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 SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
# Conflicts: # ui/config/control-ui-boot-modules.json
|
Codex review: needs changes before merge. What this changesThis PR defers session English copy, enforces Control UI asset budgets, and preserves refresh retry state across unrelated shell updates. Example: Control UI refresh recovery is pending when the connection status changes.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Needs changes before merge - 1 item remains This PR remains useful and has no actionable code findings; GitHub reports a merge conflict that must be resolved before landing. Priority: P2 Before merge
FindingsNone. Agent review detailsHow this fits togetherControl UI build tooling groups browser assets and checks their compressed sizes; runtime catalog registration supplies lazy English copy, while the sidebar presents update recovery. flowchart TD
A[English catalogs] --> B[Consumer registration]
B --> C[Control UI routes]
A --> D[Vite chunk grouping]
D --> E[Built browser assets]
E --> F[Performance budget checker]
G[Recovery scope] --> H[Sidebar retry state]
Technical reviewBest possible solution: Retain the existing catalog, chunking, budget, and recovery owners while deferring session copy and enforcing the documented limits. Do we have a high-confidence way to reproduce the issue? Current-main source shows advisory Actions exits and the refresh memo's unstable object identity; the PR records failing CLI and recovery scenarios before repair, without a new run during this read-only review. Is this the best way to solve the issue? The patch uses the existing owners, preserves shared English labels and namespace identity, compares locale sizes independently, and repairs recovery equality without adding lifecycle machinery. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 7050f5b04d42. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfacePR surface statistics unavailable: the file list is incomplete. LabelsLabel changes: No label 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 HistoryReview history (1 earlier review cycle)
Reviewed October 21, 2026, 7:51 AM ET / 11:51 UTC (Revision 2). |
|
@clawsweeper re-review Head |
|
🦞👀 Re-review progress:
|
|
@clawsweeper re-review The reported conflicts are resolved on Full CI 39600190268 is green: 50 successful jobs, 22 intentionally skipped, both real-Gateway shards and the CI gate pass. Performance CI measures 323,551 B startup with zero budget-violation warnings. The exact former Telegram automation failure passes in 30,753 ms after incorporating #179385. The PR body records the current proof; native landing preparation is in progress. |
|
🦞👀 Re-review progress:
|
|
Merged via squash.
|
Picks up openclaw#179227 so the Control UI startup budget passes.
Move Session English into its canonical lazy catalog and register it at all translating consumers without changing copy or primary behavior. Keep pending widget presentation lazy and use the canonical shared plugin-actions grouping; regenerate the branch-specific boot manifest. Adapt the source repair by Peter Steinberger from #179227 and #179367, retaining the existing Details geometry and dashboard menu lifecycle. Preserve startup and route budgets without changing their policies. Co-authored-by: Peter Steinberger <[email protected]> Co-authored-by: RomneyDa <[email protected]>
…penclaw#179227) * fix(ui): restore startup headroom and enforce asset budgets * fix(ui): register deferred English at translating consumers * fix: keep lazy English within Control UI route budgets * fix(ui): retain refresh recovery across shell updates
What Problem This Solves
Fixes Control UI performance CI accepting absolute budget violations and allowing further growth whenever the comparison base already exceeds a cap.
Related: #178054, #179084. Builds on the Composer extraction in #179169.
User Impact
Startup JavaScript drops from 331,062 B to 323,557 B gzip on the same machine, restoring 1,443 B of margin below the requested 325,000 B hotfix ceiling. The integrated main changes leave it 557 B above the preferred 323,000 B target; no budget or baseline was raised. English text, routes, markup, styles, and selectors are unchanged. No configuration or migration is required. The shared English chunk costs New Session 1,458 B against this base while staying within its existing cap; it saves startup bytes and keeps feature code lazy.
Why This Change Was Made
Session English now follows its lazy translating consumers through the existing catalog owner. Each independently imported leaf or helper registers the catalog it reads; retained shared labels and namespace objects remain eager. This adopts main's Composer extraction and groups Composer and Session English in one lazy, data-only chunk so either route can load shared copy without pulling in the other route’s code. The canonical boot manifest was regenerated; the final config produces byte-identical manifest output. Source maps confirm the shared English chunk contains exactly the two dictionaries and no renderer. The internal Chat partition size preserves a shared compression dictionary after extraction; every enforced gzip/request cap and the startup baseline remain unchanged.
An already-over-budget base may hold or shrink each byte surface, with at most 64 B of build variance. More growth fails with a clear diagnostic. Request counts allow no growth. This applies to startup, route, and locale caps; locales compare by identity so one shrinking language cannot mask another growing. Absolute violations now exit 1 in GitHub Actions as well as locally.
--report-onlyremains advisory.Full CI also exposed the refresh-recovery card losing its pending/error state on an unrelated shell update. Its recovery-scope memo now compares
refreshRequiredby value, retaining retry state until recovery actually ends and re-enters. The existing regression fails before the repair whenconnectedchanges during a pending refresh; all 22 sidebar-card tests pass afterward. No new lifecycle or state owner was added.Evidence
Paired canonical builds use the same machine, Node 26.12.0, Vite 8.3.4, and Solid rc.16. Both use release mode (hidden source maps) and the fixed measurement timestamp
2026-09-01T00:00:00.000Z. Base:4700321df3dcb14910c90852545f7453013c58ad; head:4776432d9065834e6a6a8232c5ac3ee10cf0bd7d. All 58,691 tracked files in the baseline snapshot were verified, then all 1,256 changed paths were copied and verified against this merge parent. Both sides use the fixed comparison build ID and the same explicit branch metadata; Git discovery is disabled for the measurement. Git identities differ; source, build mode, and toolchain are bound to each measured side.ci:full)The real CLI reproduces both enforcement holes on the original base: +65 B over an already-over-budget startup and an absolute startup violation in Actions both exit 0. Both exit 1 with this fix. Regression coverage exercises shrink/hold/+64/+65 for startup, both routes, and locale pairs, independent locale identity, request counts, and strict absolute checks.
Canonical
pnpm ui:boot-manifest:gencaptured synthetic cold and credential-authorized warm/newand/chatpaths, followed bypnpm ui:buildand strict checks. This is a loading-boundary change: no rendered content/style change, so no before/after visual delta. Full UI CI is requested withci:full.The checker, catalog, and sidebar regression results are reused across this merge because those source/test inputs are unchanged. The typecheck, scoped lint, full English comparison, 101-consumer AST comparison, boot manifest, production Knip, and paired builds were refreshed for this integrated source.
Growth attribution and change size
A same-toolchain rebuild of #178054 (
2e602936e5f24ffc39554ba7a15e2e4bc70f939c) measured 324,405 B, versus its published 324,590 B. The original task base5f86587ce75c245ebea7839c5901d49da9bbbcd4measured 331,657 B: +7,252 B across startup chunk families.Core contributors include eager English growth in #176378, #176490, #176398, #176349, and #177941; locale wiring in #178110; web-push access in #178164; session descriptions in #178064; viewport work in #176356; and icon data in #176321. The runtime graph adds Solid action/lanes and session-key parsing. #179084's own paired proof records +2,628 B from first action/optimism use. Snapshot growth maps to #178642; gateway changes include #178658 and #178106. These identify source contributors; individual PR byte allocations are not additive because bundling and compression are shared.
The final comparison above is against the newer merge parent, which already includes #179169. This PR claims only its incremental savings. It offsets startup growth through lazy copy while retaining those features. Simplification reuses the existing catalog/registration owners and adds no manager, cache, lifecycle, or state machinery. Touched physical LOC: 44,374 → 44,976 (+602), comprising production 39,917 → 40,370 (+453), tests +140, docs +5, and generated manifest +4. Diff: +1,493/−891 across 112 files. Most file changes register Session copy at 101 independently loadable translating consumers; all 101 renderer/helper bodies remain AST-equivalent after removing imports and registration calls. The Solid census is unchanged: 2 effects, 6 untrack calls, 2 flush calls, and zero controllers, render effects, native listeners, DOM queries, or owner APIs in the touched consumers.
Current CI: this head integrates
origin/mainto resolve five import conflicts and include #179385's Telegram ownership repair. The previously failing testconfigured owners and admin chat manage a Telegram-created job while a non-owner cannotpasses in 27,893 ms on newer scheduled main 39592709539 / job 119197769096. The older inherited-failure evidence was not submitted for landing. Current-head full CI 39600190268 is green: 50 successful jobs and 22 intentionally skipped jobs, including successful real-Gateway shards andopenclaw/ci-gate. The exact automation case passes on this PR head in 30,753 ms. No inherited-failure exception is needed.The five conflict resolutions preserve main's renderer changes and retain this PR's catalog registration. All 101 renderer/helper bodies remain AST-equivalent to the new merge parent after imports and catalog registration are excluded. Independent review of the integrated candidate reports no actionable P0–P2 findings.
Local setup note: the retained sidebar regression proof uses the default pinned Bun fork with
BUN_RUNTIME_TRANSPILER_CACHE_PATH=0after an observed external-SSD cache rename stall. No test timeout or assertion was weakened. External-disk builds and checks useNODE_DISABLE_COMPILE_CACHE=1.