Repository navigation
fix(ui): unblock sidebar navigation line-cap checks - #158778
Conversation
Compute the route session key inside its existing session-route guard, removing the duplicate predicate and temporary local without changing navigation behavior. The reviewed saved-pane head was within the cap; mainline import refactoring added two lines when the patches composed. Related: #158639.
|
🦞👀 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. Reviewed September 26, 2026, 5:23 AM ET / 09:23 UTC. ClawSweeper reviewWhat this changesThe branch moves the Control UI sidebar’s session-key lookup inside its existing session-route guard, removing one counted source line. Merge readiness✅ Ready for maintainer review Current main still exceeds the sidebar file’s local lint cap by one counted line. The proposed change brings it within the cap while retaining the session-route guard and existing call order, so the PR remains useful. Priority: P3 Review scores
Verification
How this fits togetherThe Control UI sidebar receives the active route and session key from application state. For session routes, it loads session lineage before scheduling child-session reads that feed the sidebar. flowchart LR
A[Active route] --> B{Session route?}
B -->|Yes| C[Read session key]
C --> D[Load session lineage]
B -->|All routes| E[Schedule child reads]
D --> F[Sidebar sessions]
E --> F
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource -1. Total -1 across 1 file. View PR surface stats
Review metrics
Technical reviewBest possible solution: Preserve the 700-line rule and the sidebar’s session-only lineage loading behavior when landing this correction. Do we have a high-confidence way to reproduce the issue? Yes, current-main source counts 701 nonblank, noncomment lines against the 700-line rule, while the PR head counts 700. This review did not execute Oxlint. Is this the best way to solve the issue? Yes. The route predicate is unchanged, and inlining the key read removes the excess line without changing the lint rule or the order of lineage and child-session work. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 5f3781df412c. LabelsLabel changes:
Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
|
|
Merged via squash.
|
Compute the route session key inside its existing session-route guard, removing the duplicate predicate and temporary local without changing navigation behavior. The reviewed saved-pane head was within the cap; mainline import refactoring added two lines when the patches composed. Related: openclaw#158639.
Compute the route session key inside its existing session-route guard, removing the duplicate predicate and temporary local without changing navigation behavior. The reviewed saved-pane head was within the cap; mainline import refactoring added two lines when the patches composed. Related: #158639.
What Problem This Solves
Core lint rejects the sidebar navigation file at 701 lines against its 700-line cap after #158639 composed with the mainline import refactor in #158198.
User Impact
No user-visible behavior changes. This unblocks the existing lint gate without changing its cap or exemptions.
Why This Change Was Made
Obtain the session key inside the existing session-route guard, removing the redundant route check and temporary variable. The getter still runs exactly once for session routes and never for other routes; lineage loading and child scheduling retain their order.
Evidence
9c5598ce9c5b3c3c9d68b9847e70764f91ad6d1d.The earlier saved-pane reviewed head passed before merge composition added two import lines. This correction preserves that historical distinction; it does not claim the earlier checks covered the composed main tree.