Repository navigation
perf(control-ui): restore dashboard name links before hello - #168663
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: needs maintainer review before merge. What this changesThis PR resolves unique cached dashboard names before Gateway hello and gives their transcript startup foreground priority. Example: Reload /dashboard/main/mission-control with a cached Mission control session and transcript.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep open: this PR fixes a dashboard reload delay still present on current main, and no actionable introduced defect was found; required CI remains failed and incomplete. Priority: P2 Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe Control UI router consumes session URLs and account-scoped boot snapshots, presents cached session content, then uses the connected Gateway for authoritative resolution and board documents. flowchart LR
A[Dashboard URL] --> B[Session route loader]
C[Scoped boot snapshot] --> B
B --> D[Dashboard and cached transcript]
E[Foreground scheduler] --> D
F[Connected Gateway] --> B
F --> G[Fresh board ticket]
G --> H[Board document]
Technical reviewBest possible solution: Land the shared cached-name resolution when normal CI or the repository’s verified inherited-failure landing path permits it. Do we have a high-confidence way to reproduce the issue? Current-main source shows name-only routes missing cached resolution, and supplied before/after browser evidence demonstrates the symptom; no target code was executed during this review. Is this the best way to solve the issue? The change fixes the existing route owner and scheduler, preserves exact-key precedence and authoritative fallback, and avoids new storage or configuration. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against f893093e2b49. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource +5, Tests +59, Docs +2. Total +66 across 7 files. Added test files: 0. View PR surface stats
Review metrics
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 (11 earlier review cycles; latest 8 shown)
Reviewed October 11, 2026, 6:54 AM ET / 10:54 UTC (Revision 12). |
ee1bf79 to
28c600e
Compare
28c600e to
4af452f
Compare
4af452f to
b8018f9
Compare
|
Not merged yet: this head now conflicts with main after #168206 landed, so it needs a rebase first. Failure classification for head Every failing CI test on this head is inherited from main. Shards 1–4 failed only in |
b8018f9 to
49ca813
Compare
f9c80db to
24a7c12
Compare
|
Landed as d401bae with an admin squash merge pinned to the reviewed head On this head, after re-running only the failed/cancelled jobs of run 38129269546, every job passed except |
Bun UI test runtime now triggers JSC collection after 256 MiB allocated per cycle via BUN_JSC_gcMaxHeapSize; this is not a heap cap. The historical 11 GiB checks-ui peak came from the missing-context async-question fixture fixed in 7158f2b. Full shards measured 7.0–7.6 GiB peak with at least 8.1 GiB available on 4 vCPU/16 GiB; the broken-fixture failure path fell from 7.98 to 5.57 GiB. Related: #168663.
…#168663) Dashboard and other non-chat session routes now get the same pre-hello treatment as /chat deep links: the foreground bootstrap priority and initial-route handling apply to every session route, and display-name links resolve from the cached scoped rows owned by the boot snapshot, so a reload restores the dashboard title, saved layout, and cached transcript before the Gateway hello. Board documents keep fresh-ticket authorization.
…9324) Bun UI test runtime now triggers JSC collection after 256 MiB allocated per cycle via BUN_JSC_gcMaxHeapSize; this is not a heap cap. The historical 11 GiB checks-ui peak came from the missing-context async-question fixture fixed in 1c543c7. Full shards measured 7.0–7.6 GiB peak with at least 8.1 GiB available on 4 vCPU/16 GiB; the broken-fixture failure path fell from 7.98 to 5.57 GiB. Related: openclaw#168663.
What Problem This Solves
A signed-in reload of a dashboard deep link with a display-name-only reference waits for Gateway hello to resolve its session, despite having a scoped cached roster and transcript. The campaign measurement showed the header/right panel at about 2.5 s and the board document request at 3.29 s.
User Impact
A unique cached name now presents the title, saved split layout, cached right-panel transcript, and one board skeleton before hello. Full-ID links retain their existing behavior. Missing or ambiguous names still use authoritative resolution.
Why This Change Was Made
Both namespaces use the existing cached reference resolver and foreground transcript scheduling. After L6 (#168206), the session capability obtains its routing defaults, cached rows, and settled signal from the single account-scoped boot snapshot. The dashboard regression waits for that owner’s
sidebarSnapshotswrite; no legacy roster-cache path remains. No new cache or server state is introduced. Production delta is +5 lines (16 added, 11 removed): the added contract is scoped cached-name resolution, and the chat-only scheduling distinction is removed.Board documents still require
board.getto issue a fresh ticket after live authority checks. HTTP consumption checks authority again. Pre-hello board bytes need a separately reviewed authenticated issuance transport; tickets and grants are not persisted by this change.Evidence
--maxWorkers=1, including dashboard and sidebar cold-load browser proof.ui/src/pages/chat/route-warm-boot.test.tsui/src/app/bootstrap.test.tsui/src/lib/sessions/session-roster-warm-boot.test.tsui/src/components/sidebar-snapshot-controller.test.tsui/src/components/sidebar-snapshot-model.test.tsui/src/pages/chat/sidebar-snapshot-store.test.tsui/src/components/sidebar-online-order.test.tsui/src/components/session-data-controller.warm-boot.test.tsui/src/app/bootstrap.warm-boot.test.tsui/src/pages/chat/session-snapshot-prewarm.test.tsui/src/e2e/dashboard-cold-load.e2e.test.tsui/src/e2e/sidebar-cold-load.e2e.test.tsThe browser commands use
run --config test/vitest/vitest.ui-e2e.config.ts; the other files use the normalnode scripts/run-vitest.mjs/pnpm testowner. The dashboard name-only case still paints title, main board skeleton, and cached side transcript before hello.Rebase and CI evidence
Current head: 24a7c12, rebased onto f442662; the requested comparison baseline is e7e3b94. The L6 boot-snapshot owner, scoped cached-name resolution, foreground transcript scheduling, and fresh board-ticket authority are retained. Production delta remains +5 lines (16 added, 11 removed). Fresh detached autoreview reported no actionable P0–P2 findings. No speculative production fix was added for the CI hang.
The original CI run 38119602601 stopped twice in UI unit shard 2/3 after the same 555 completed files. This remains an unresolved hang, not a demonstrated infrastructure flake. The last completed CSS test did not identify the active test. A successful same-day peer run selected only a small changed-file subset, so it is not equivalent full-shard proof.
Reproduction used CI's Bun UI runtime and complete
ui/vitest.config.tsproject selection,--shard=2/3 --maxWorkers=2 --reporter=verbose --reporter=./scripts/lib/vitest-resource-reporter.mts --reporter=hanging-process. Each local invocation began with host load below 30. The existing progress reporter recorded active files; no test timeouts, sleeps, retries, or assertions were changed.f9c80db74d2f3f495777d43f24a7c128ade4e7e3b949ae13Both files missing from the original CI completions finished locally:
sessions-page.scope-race.test.tsand the finalmarkdown.progress.node.test.tstiming group. This does not prove the cause of the CI stall. The localchat-outbox-loading.test.tsmissing-chat.historyassertion reproduces on both main revisions. The rebased head and exact base also sharechat-view.async-questions.test.tsassertion failures,chat-responsive.browser.test.tsmissing-application-context failure, and 264 renderer errors. The rebased head additionally failedsolid-bridge.test.tsx's disconnected-root collection assertion; the isolated 10-run comparison below classifies that observation without changing the assertion.The earlier full UI E2E campaign on
b8018f9e1fc7completed with 725 files passed, 11 failed, 1 skipped (3341 tests passed, 21 failed, 1 skipped). Seventeen failing tests reproduced on its pinned main base. Lead review classified the remaining results: provider login passes in isolation; agent-file-lifecycle and QA media-transcript fail identically on main561d92da3a28; task-suggestions, catalog-bootstrap, group-defaults and plugins-lifecycle CI failures are inherited. The post-L6 12-file pass above is retained as prior-head evidence.Current-head CI is terminal: run 38129269546, head
24a7c128ade4.checks-ui (2/3)recorded a failure inchat-responsive.browser.test.ts(the same missing-application-context error reproduced on the requested main baseline), then received a runner shutdown signal. It was still emitting async-question test output 13 seconds before shutdown; this attempt does not establish the earlier silent hang's cause. Its log has 556 passed file completions and one failed completion, with no final Vitest summary. The fail-fast controller subsequently reportedfailure-cancelledand cancelled remaining jobs. No job was rerun.check-test-types-core-2was cancelled with remaining workIsolated disconnected-root comparison
The requested one-file loops used the same Bun runtime, complete
solid-bridge.test.tsxfile, and--maxWorkers=1. Each iteration began below load 30; each invocation used a fresh process. No assertion, timeout, sleep, or production code was changed.24a7c128ade4e7e3b949ae13Only PR iteration 2 failed: the disconnected-root WeakRef retained
{ id: "owned" }after the control object had been collected. All other tests in that invocation passed. One failure versus zero in ten samples does not establish a material increase or prove that the baseline flakes. The classification is an intermittent GC-sensitive assertion, with no demonstrated branch-specific leak. The bridge owner, test, GC helper, and its runtime setup are unchanged; this isolated test does not enter the three modified routing/bootstrap modules or create their cached-roster promise/foreground route lifecycle. No obvious owner defect was established, so the assertion and production code remain unchanged.The earlier silent Linux CI stall/shutdown cause remains unresolved; these loop results are not proof that it is infrastructure or that it has been fixed. With no code change, no new commit/push or CI rerun was made. No merge was performed.
Controlled Linux memory comparison
Ran the full UI unit shard through the exact CI entry point on two fresh AWS Crabbox
m6a.xlargeVMs (4 vCPU, 16 GiB nominal RAM), comparable to the failed CI job's measured 4 vCPU / 16 GiB. Each remote cloned this PR directly from GitHub with--fresh-pr; the base arm then fetched and checked out the requested full base SHA. No local tree or patch was uploaded. Both used Node 24.21.0, the repository's checksum-pinned Linux x64 Bun runtime, three workers, allui/vitest.config.tsprojects, and--shard=2/3.24a7c128ade4e7e3b949ae13RSS was sampled every 10 seconds for the complete command process tree, alongside
/proc/meminfofree/available memory, largest processes, and the existing reporter's active files. Command-completion observations have up to 10 seconds of polling granularity. Tree RSS sums process RSS and can count shared pages more than once. The VMs used the same promoted Ubuntu image (kernel7.0.0-1014-aws); this matches CI's resources and runtime, not its exact OS image.Both runs completed normally with the same
chat-responsive.browser.test.tsmissing-application-context failure and 264 unhandled renderer errors. Neither shut down, hung, or exhausted available memory. Both peaks occurred whilechat-view.async-questions.test.tswas active; the largest Bun worker was about 5.6 GiB. RSS dropped afterward rather than continuing to grow. Available memory started at 13.732 / 13.828 GiB and ended at 14.005 / 13.583 GiB (head / base).This controlled comparison found no branch-specific memory or process growth: head's peak RSS was slightly lower, process counts were comparable, and elapsed time differed by 1.41 seconds. It is evidence against attributing the historical runner deaths to these routing changes; the exact external shutdown trigger was not reproduced or identified. No production fix, test change, commit, push, or CI rerun was made for this comparison.
cbx_402a60c46628— released.cbx_79d73a1c2094— released.CI entry point used by both arms:
No private campaign capture or content is included.