Skip to content

chore(ui): restore main's core lint and startup budget - #148010

Merged
obviyus merged 3 commits into
mainfrom
bugloop/main-lint-session-ownership
Sep 14, 2026
Merged

obviyus merged 3 commits into
mainfrom
bugloop/main-lint-session-ownership

Conversation

@obviyus

@obviyus obviyus commented Sep 14, 2026 •

Copy link
Copy Markdown
Collaborator

What Problem This Solves

Main fails its own structural checks, so every open PR is red: check-lint-core-2 (the sidebar session-ownership test helper is over the 700-line rule since #147610), the chat transcript controller test (over the 1,000-line rule since #147612), and control-ui-performance (startup JS gzip 362,012 B exceeds the 361,938 B limit after #147845, #147773 and #147883).

Why This Change Was Made

These repairs belong on main, in one PR.

  • Lint: the avatar cases move from session-ownership.ts into a sibling case file in the directory's existing pattern (610 lines remain). Assertions and registration are unchanged.
  • Chat lint: the four deferred-message-reveal cases move into a sibling test file. Their assertions, names and shared setup/cleanup remain unchanged, and the canonical test list preserves their isolated runner.
  • Budget: the smallest whole-KiB cap step, 353 → 354 KiB, with the baseline refreshed to the measured 362,012 B. Deferring the new workspace labels saved only 64 B and still failed at 361,952 B, so a reduction was not available; the immediate Home and diagnostic frames stay intact. Follows fix(ui): load Home and System busyness inside their panels #147574 and chore(ui): refresh the Control UI startup budget baseline #146526.

User Impact

None. No product behavior or asset changes.

Evidence

  • Lint: the max-lines check fails on main and passes here; 426 sidebar tests pass.
  • Chat lint: pinned main fails at 1,010 counted lines; the candidate merge passes the same lint rule. All 146 affected chat tests pass, including the four moved cases in the isolated runner. The local preflight and test-root partition checks pass.
  • Budget: same-toolchain comparison, last passing source 361,718 B, main 362,016 B (+298 B), fresh main and this candidate both 362,012 B (0 B asset delta). pnpm ui:check-performance:base <main> fails before the policy refresh and passes afterward. 552 focused tests pass.

Compatibility

Cap 353 → 354 KiB; baseline 362,012 B; the 512 B growth and 64 B variance allowances are unchanged.

Consumers

The performance check and the build size report read the same policy; the sidebar test suite registers the moved cases from the new file, and both UI test runners retain isolated chat-test registration.

@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui size: M maintainer Maintainer-authored PR labels Sep 14, 2026
@obviyus obviyus changed the title test(ui): split session ownership sidebar cases under the line limit chore(ui): restore main's core lint and startup budget Sep 14, 2026
@obviyus
obviyus marked this pull request as ready for review September 14, 2026 06:50
@openclaw-barnacle openclaw-barnacle Bot added the scripts Repository scripts label Sep 14, 2026
@clawsweeper

clawsweeper Bot commented Sep 14, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@obviyus

obviyus commented Sep 14, 2026

Copy link
Copy Markdown
Collaborator Author

landpr-approve-admin-merge
pr: 148010
head: 059281e
scope: owner-review

@clawsweeper clawsweeper Bot added P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Sep 14, 2026
@clawsweeper

clawsweeper Bot commented Sep 14, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge. Reviewed September 14, 2026, 3:35 AM ET / 07:35 UTC (Revision 2).

ClawSweeper review

What this changes

The PR splits oversized sidebar and chat tests while preserving their registration, and refreshes the Control UI’s compressed JavaScript baseline and cap.

Merge readiness

⛔ Blocked before merge - 1 item remains

The focused cleanup remains useful on current main, with no actionable correctness findings. The earlier upgrade-proof blocker does not apply to build-policy metadata and test extraction. The overlapping open PR is not a viable superseding target.

Priority: P3
Reviewed head: 6d60fd4414c4de3f0f70b0e3f37c5b5475cbe2ba

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A focused maintenance patch with relevant production-check observations, preserved test coverage, and no actionable defects.
Proof confidence 🐚 platinum hermit (4/6) Sufficient (live_output): The captured production-build comparison exercises the changed performance checker: identical 362012 B assets fail the old policy and pass the refreshed policy. Reported lint and runner results support the test extraction; prior-panel screenshots are contextual only.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (live_output): The captured production-build comparison exercises the changed performance checker: identical 362012 B assets fail the old policy and pass the refreshed policy. Reported lint and runner results support the test extraction; prior-panel screenshots are contextual only.
Evidence reviewed 9 items Verified scope and clean checkout: The local introduced-file comparison matches the seven host-pinned paths. Changes comprise budget policy, test extraction, and isolated-runner registration; final git status is clean and diff whitespace checks pass.
Budget calculation and storage boundary: The checker reads repository build-policy JSON and compressed asset sizes. Its enforcement limit remains min(baseline, cap) plus 512 B growth and 64 B variance. The proposed baseline yields 362588 B, above the reported 362012 B measurement. No user-state schema, preferences, migration, or installed updater changes.
Test extraction preserves execution: The four deferred-reveal scenarios retain their assertions and shared setup/cleanup. The canonical list routes the new file into both isolated runners and excludes it from shared execution. Sidebar avatar cases remain registered inside the original ownership suite.
Findings None None.
Security None None.

How this fits together

Control UI checks measure built browser assets against repository budgets and run UI regression tests through shared or isolated runners. This change adjusts the size policy and reorganizes tests without changing application behavior.

flowchart TD
  A[Built browser assets] --> B[Performance checker]
  C[Baseline and size cap] --> B
  B --> D[Size report and CI result]
  E[Sidebar and chat regression cases] --> F[Test registration]
  F --> G[Shared or isolated runners]
  G --> D
Loading

Before merge

  • Add data-model compatibility proof - Confirm migration or upgrade compatibility proof before merge.
Agent review details

Security

None.

PR surface

Tests +35, Other 0. Total +35 across 7 files.

View PR surface stats
Area Files Added Removed Net
Source 0 0 0 0
Tests 5 267 232 +35
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 2 4 4 0
Total 7 271 236 +35

Review metrics

Metric Value Why it matters
Startup budget Cap 353 → 354 KiB; enforcement limit 361938 → 362588 B The refresh increases the effective threshold by 650 B while retaining the 512 B growth and 64 B variance allowances.

Stored data model

Persistent data-model change detected: migration/backfill/repair: config/control-ui-startup-budget-baseline.json. Confirm migration or upgrade compatibility proof before merge.

Technical review

Best possible solution:

Keep one measured startup-budget policy and preserve the existing regression coverage through the canonical test runners.

Do we have a high-confidence way to reproduce the issue?

Not applicable as a product bug: this is check maintenance. The body supplies before/after lint and production-size results; this review verified source and routing without executing tests.

Is this the best way to solve the issue?

Yes. The extraction preserves existing cases and isolation, and the documented budget refresh uses the existing checker without adding a competing policy or changing runtime loading.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 43bf86e1ef4f.

Labels

Label justifications:

  • P3: This is bounded internal check maintenance with no application behavior change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (live_output): The captured production-build comparison exercises the changed performance checker: identical 362012 B assets fail the old policy and pass the refreshed policy. Reported lint and runner results support the test extraction; prior-panel screenshots are contextual only.
  • proof: sufficient: Contributor real behavior proof is sufficient. The captured production-build comparison exercises the changed performance checker: identical 362012 B assets fail the old policy and pass the refreshed policy. Reported lint and runner results support the test extraction; prior-panel screenshots are contextual only.

Evidence

What I checked:

  • Verified scope and clean checkout: The local introduced-file comparison matches the seven host-pinned paths. Changes comprise budget policy, test extraction, and isolated-runner registration; final git status is clean and diff whitespace checks pass. (6d60fd4414c4)
  • Budget calculation and storage boundary: The checker reads repository build-policy JSON and compressed asset sizes. Its enforcement limit remains min(baseline, cap) plus 512 B growth and 64 B variance. The proposed baseline yields 362588 B, above the reported 362012 B measurement. No user-state schema, preferences, migration, or installed updater changes. (scripts/check-control-ui-performance.mts:54, 6d60fd4414c4)
  • Test extraction preserves execution: The four deferred-reveal scenarios retain their assertions and shared setup/cleanup. The canonical list routes the new file into both isolated runners and excludes it from shared execution. Sidebar avatar cases remain registered inside the original ownership suite. (test/vitest/vitest.ui-isolated-paths.mjs:36, 6d60fd4414c4)
  • Current main still needs the policy refresh: Fetched main retains the 361362 B baseline and 353 KiB cap. The comparison is behavioral context only; PR ownership comes from the pinned merge-base delta. (config/control-ui-startup-budget-baseline.json:2, 43bf86e1ef4f)
  • Latest release comparison: The v2026.9.4 baseline is 352531 B with a stated 358400 B cap; it does not contain this proposed refresh. (config/control-ui-startup-budget-baseline.json:2, 3a9d69db306c)
  • Behavior evidence and review continuity: The captured PR body reports same-toolchain production builds measuring 362012 B on both main and candidate, with the performance command failing before the policy refresh and passing afterward. It also reports passing sidebar, chat, and runner-partition checks. Source snapshot identity: cfbf0e4cfd0b50138eb2751c70b6674191f5306df040feb7538352cc46627557. No builds or tests were executed during this read-only review. The previous review had no findings; its migration request is inapplicable to the inspected boundary. (6d60fd4414c4)

Likely related people:

  • obviyus: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)
  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

Workflow

  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

History

Review history (1 earlier review cycle)
  • reviewed 2026-09-14T07:00:19.203Z sha 059281e :: blocked before merge. :: none

Main fails its startup check: 362,012 B exceeds 361,938 B. Use the approved
1 KiB cap increase for scoped catalog invalidation (#147845), remote
workspaces (#147773), and update-status feedback (#147883). Deferring the new
workspace labels saved only 64 B and still failed at 361,952 B. Baseline
362,012 B; the 512 B growth and 64 B variance allowances are unchanged.
@obviyus
obviyus force-pushed the bugloop/main-lint-session-ownership branch from 8591761 to 549b81b Compare September 14, 2026 07:22
@obviyus

obviyus commented Sep 14, 2026

Copy link
Copy Markdown
Collaborator Author

landpr-approve-admin-merge
pr: 148010
head: 6d60fd4
scope: owner-review

@obviyus
obviyus merged commit 81380b7 into main Sep 14, 2026
241 of 243 checks passed
@obviyus
obviyus deleted the bugloop/main-lint-session-ownership branch September 14, 2026 08:39
@obviyus

obviyus commented Sep 14, 2026

Copy link
Copy Markdown
Collaborator Author

Proof: CI passed core lint and startup-size checks.

  • Bug: Main's overlong test files and startup-size budget caused pull requests to fail checks.
  • Fix: Split the existing cases, preserve their test registration, and refresh the measured startup budget.
Before After
Test files exceeded line limits; startup-size validation failed. Both checks pass, with test assertions and runtime behavior unchanged.

vincentkoc added a commit that referenced this pull request Sep 14, 2026
* commit 'a08cdc50bc049074ed7ad2db9e18e0ed3f5415ec': (81 commits)
  perf: reuse stateless plugin scope defaults (#148080)
  fix(gateway): flush slow-consumer 1008 close frame before terminating socket (#147707)
  fix: keep model catalogs loading during other session updates (#147878)
  fix: show queued external chat messages and their source (#147848)
  refactor(chat): share math label configuration (#148073)
  perf(ui): trim eager debug overlay icon payload (#147954)
  improve(logbook): sample batch frame metadata in SQLite (#147999)
  fix(ui): dismiss suggested task cards without waiting (#148021)
  fix(maturity): cover governance, interoperability, fleet, and state (#143528)
  chore(ui): restore core lint and startup budget checks (#148010)
  fix: chat startup loads unnecessary session setup text (#147973)
  perf: speed up fresh cloud worker activation (#147945)
  fix: recover PR preparation after committed merge conflicts (#148063)
  test(plugins): isolate ClawHub Docker fixture identity (#148074)
  fix(release): acknowledge ClawHub risk on moving installs (#148041)
  fix: restore context reads for installed official Discord and Slack plugins (#143341)
  fix: identify source capsule filesystem failures (#147778)
  fix(linux): keep Quick Chat widgets bound to their Gateway (#146049)
  refactor(infra): consolidate update campaign reset ownership (#146555)
  refactor: simplify Gateway health response parsing (#147834)
  ...
vincentkoc added a commit to nvtoroy/openclaw that referenced this pull request Sep 15, 2026
* commit '7d485aa2e89af7fdbd09e8ed0489b06d250b07e3':
  test(scripts): check the configurable ClawHub sweep spec
  fix: show queued external chat messages and their source (openclaw#147848)
  refactor(chat): share math label configuration (openclaw#148073)
  perf(ui): trim eager debug overlay icon payload (openclaw#147954)
  improve(logbook): sample batch frame metadata in SQLite (openclaw#147999)
  fix(ui): dismiss suggested task cards without waiting (openclaw#148021)
  fix(maturity): cover governance, interoperability, fleet, and state (openclaw#143528)
  chore(ui): restore core lint and startup budget checks (openclaw#148010)
  fix: chat startup loads unnecessary session setup text (openclaw#147973)
  perf: speed up fresh cloud worker activation (openclaw#147945)
  fix: recover PR preparation after committed merge conflicts (openclaw#148063)
  test(plugins): isolate ClawHub Docker fixture identity (openclaw#148074)
  fix(release): acknowledge ClawHub risk on moving installs (openclaw#148041)
  fix: restore context reads for installed official Discord and Slack plugins (openclaw#143341)
  fix: identify source capsule filesystem failures (openclaw#147778)
  fix(linux): keep Quick Chat widgets bound to their Gateway (openclaw#146049)
  refactor(infra): consolidate update campaign reset ownership (openclaw#146555)
  refactor: simplify Gateway health response parsing (openclaw#147834)
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Sep 15, 2026
AI-assisted.

## What Problem This Solves
Main fails its own structural checks, so every open PR is red: `check-lint-core-2` (the sidebar session-ownership test helper is over the 700-line rule since openclaw#147610), the chat transcript controller test (over the 1,000-line rule since openclaw#147612), and `control-ui-performance` (startup JS gzip 362,012 B exceeds the 361,938 B limit after openclaw#147845, openclaw#147773 and openclaw#147883).

## Why This Change Was Made
These repairs belong on main, in one PR.

- Lint: the avatar cases move from `session-ownership.ts` into a sibling case file in the directory's existing pattern (610 lines remain). Assertions and registration are unchanged.
- Chat lint: the four deferred-message-reveal cases move into a sibling test file. Their assertions, names and shared setup/cleanup remain unchanged, and the canonical test list preserves their isolated runner.
- Budget: the smallest whole-KiB cap step, 353 → 354 KiB, with the baseline refreshed to the measured 362,012 B. Deferring the new workspace labels saved only 64 B and still failed at 361,952 B, so a reduction was not available; the immediate Home and diagnostic frames stay intact. Follows openclaw#147574 and openclaw#146526.

## User Impact
None. No product behavior or asset changes.

## Evidence
- Lint: the max-lines check fails on main and passes here; 426 sidebar tests pass.
- Chat lint: pinned main fails at 1,010 counted lines; the candidate merge passes the same lint rule. All 146 affected chat tests pass, including the four moved cases in the isolated runner. The local preflight and test-root partition checks pass.
- Budget: same-toolchain comparison, last passing source 361,718 B, main 362,016 B (+298 B), fresh main and this candidate both 362,012 B (0 B asset delta). `pnpm ui:check-performance:base <main>` fails before the policy refresh and passes afterward. 552 focused tests pass.

## Compatibility
Cap 353 → 354 KiB; baseline 362,012 B; the 512 B growth and 64 B variance allowances are unchanged.

## Consumers
The performance check and the build size report read the same policy; the sidebar test suite registers the moved cases from the new file, and both UI test runners retain isolated chat-test registration.

Co-authored-by: Ayaan Zaidi <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: web-ui App: web-ui maintainer Maintainer-authored PR P3 Low-priority cleanup, docs, polish, ergonomics, or speculative work. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. scripts Repository scripts size: L status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant