fix(control-ui): measure and decouple slow refreshes#75986
Conversation
|
Codex review: needs maintainer review before merge. Summary Reproducibility: yes. #64004 provides concrete Windows Server/npm-global steps and timing logs showing fast Next step before merge Security Review detailsBest possible solution: Proceed through maintainer review and exact-head CI for this focused #64004 slice, while leaving the broader responsiveness and polling/churn work to the existing related items. Do we have a high-confidence way to reproduce the issue? Yes. #64004 provides concrete Windows Server/npm-global steps and timing logs showing fast Is this the best way to solve the issue? Yes. The PR is a narrow maintainable fix for attribution and secondary-refresh isolation, and it avoids folding broader provider, polling, or gateway-churn changes into this patch. What I checked:
Likely related people:
Remaining risk / open question:
Codex review notes: model gpt-5.5, reasoning high; reviewed against a0c3cd68783b. |
dfcf4fb to
b64ceb3
Compare
3339fe7 to
0c09e6b
Compare
|
Response to the ClawSweeper review at #75986 (comment): I rechecked the review finding against the rebased branch and fixed it directly. What changed after the review:
Security audit:
Performance audit:
Validation on rebased SHA
|
0c09e6b to
2c49705
Compare
9f2689b to
6ca9e35
Compare
6ca9e35 to
bb42ad3
Compare
d762848 to
d986a33
Compare
4f14490 to
26f3b78
Compare
26f3b78 to
84c472c
Compare
Summary
cron.runsreturns an explicitok/error/skippedload outcome, stale Cron results are ignored after tab changes, and Overview/Cron secondary groups record duration plus aggregate status.mainso exact-headcheck:test-typesremains green after rebase.Fixes #64004.
Security / Performance Audit
id,method,ok,durationMs,slow, anderrorCode; request params and response payloads are not stored in the event log. Regression coverage uses aconfig.getrequest containing a fake token and asserts timing excludes params.cron.runsfailures are attributed from the controller's real load outcome instead of promise rejection state, so caught RPC failures recordstatus: "error"while preserving primary Cron tab feedback.Validation
Rebased head:
84c472c5abd58b66ac6ee5e27f9405a4b08b9b9d.pnpm test ui/src/ui/gateway.node.test.ts ui/src/ui/app-gateway.node.test.ts ui/src/ui/app-settings.refresh-active-tab.node.test.ts ui/src/ui/controllers/sessions.test.ts ui/src/ui/controllers/usage.node.test.ts ui/src/ui/controllers/cron.test.ts src/config/zod-schema.providers.lazy-runtime.test.ts src/cli/plugins-install-persist.test.ts src/cli/plugins-cli.install.test.ts extensions/discord/src/monitor/message-handler.preflight-channel-context.test.ts -- --reporter=dot(189 tests across 4 Vitest shards)pnpm tsgo:test:uipnpm tsgo:test:srcpnpm check:test-typespnpm exec oxfmt --check --threads=1 extensions/discord/src/monitor/message-handler.preflight-channel-context.test.ts CHANGELOG.md src/cli/plugins-install-persist.test.ts src/config/zod-schema.providers.lazy-runtime.test.ts ui/src/ui/app-gateway.ts ui/src/ui/app-settings.refresh-active-tab.node.test.ts ui/src/ui/app-settings.ts ui/src/ui/control-ui-performance.ts ui/src/ui/controllers/cron.test.ts ui/src/ui/controllers/cron.ts ui/src/ui/gateway.node.test.ts ui/src/ui/gateway.tsgit diff --check origin/main...HEADpnpm check:changelog-attributionsOPENCLAW_TESTBOX=1 pnpm check:changedontbx_01kqm03gynfzpn8248rb32nrb7Duplicate / Related Triage
sessions.listreturns quickly #64004.sessions.listreturns quickly #64004 slice: timing attribution plus slow secondary-panel isolation.channels.status, provider/reconnect churn, session-event reloads, and polling behavior outside this patch.sessions.listpolling/full-scan pressure), [Bug]: Control UI Crashes When Session Conversation History Is Too Large #45687 and [Bug]: Control UI freezes with high CPU when switching sessions via dropdown menu #51685 (large-history/session-switch frontend freezes), [Bug]: Windows local gateway has partial RPC failures/timeouts on v2026.4.9 even when gateway process is running #64476 (partial Windows local RPC timeouts), and Webhook plugin re-registers repeatedly whenever event loop saturates (dreaming, cron catchup, Control UI polling) #75298 (event-loop saturation/webhook re-registration cascade).