Skip to content

fix(ui): restore custom page and session ordering - #123530

Merged
steipete merged 4 commits into
mainfrom
steipete/pinned-entries-ordering-regression-373dd0
Aug 14, 2026
Merged

steipete merged 4 commits into
mainfrom
steipete/pinned-entries-ordering-regression-373dd0

Conversation

@steipete

@steipete steipete commented Aug 14, 2026 •

Copy link
Copy Markdown
Contributor

Related: #121712

What Problem This Solves

Fixes an issue where operators who customized the Control UI sidebar to interleave pages with pinned sessions would have that order discarded at render time. A persisted order such as Usage → Quarterly dashboard → Plugins instead rendered all pages first and moved every pinned session into a separate Pinned group.

This regressed the mixed, drag-ordered sidebar zone introduced in #110682.

Why This Change Was Made

The reconciled sidebar list is already the canonical heterogeneous order for routes, Workboard entries, and pinned sessions. This change renders that list directly again and removes the second presentation-only partition that grouped entries by type.

The shared drag/drop owner and persisted preference shape are unchanged. Pinning, unpinning, page hiding, and ordering continue to write through the existing canonical list.

Exact-head CI also exposed four deterministic Node shard failures that were already red on current main. During the conflict-required rebase, #123549 landed the shared synchronous-subscription and exact-run authority repairs. This branch retains the missing owner-boundary rule that routes requests with new tool bindings through normal dispatch instead of an existing run with a different tool surface, and consolidates stale reply-operation test doubles into one typed fixture.

User Impact

Operators can once again arrange pages and pinned sessions in any order. Existing customized layouts render as saved instead of silently moving sessions below every page.

The CI repair preserves active-run steering while keeping per-turn tool bindings fail-closed and prevents immediate terminal events from being lost during queued steering setup.

Before (#121712 separated pinned sessions from the custom page order) After (the persisted page/session/page order renders directly)
Separate Pinned group Interleaved sidebar order restored

Evidence

  • Regression proof before the UI fix: the existing sidebar fixture expected Usage → Alpha → Plugins but received Usage → Plugins → Alpha.
  • node scripts/run-vitest.mjs ui/src/components/app-sidebar.test.ts ui/src/lib/sidebar-zone.test.ts — 259 passed.
  • node scripts/run-vitest.mjs run --config test/vitest/vitest.ui-e2e.config.ts --configLoader runner ui/src/e2e/session-management.sidebar.e2e.test.ts -t "pins a session dropped below an existing row in the interleaved sidebar zone" — 1 passed; the mocked Gateway observed the real sessions.patch pin and the resulting order.
  • A source-independent mocked-browser scenario loaded ui.prefs.sidebarEntries = [route:usage, session:agent:main:dashboard, route:plugins] through config.get, observed exactly Usage → Quarterly dashboard → Plugins, confirmed no Pinned heading, and produced the after screenshot above.
  • Initial exact-head CI run 31777423764 exposed four Node shard failures that reproduced on current-main run 31777530552; the Control UI timeout was unrelated and did not reproduce locally.
  • Exact-head CI run 31781493193 exposed a branch-caused CLI commentary fixture collision: the real JSONL subprocess test failed on the PR head but passed on clean current origin/main. Keeping the shared authority fixture on the canonical main agent while isolating that subprocess case restored both the commentary test (3/3) and its CLI-session sibling (12/12).
  • Final-head focused proof: CLI commentary 3/3, CLI sessions 12/12, media/final 14/14, Gateway directive/injection 193/193, sidebar unit 259/259, and mocked-browser drag 1/1.
  • node scripts/check-changed.mjs --timed — all selected core, core-test, and UI lanes passed locally. Blacksmith Testbox was unavailable; a Daytona raw-sync attempt also stopped before project checks because .git was absent, so exact-head hosted CI remains the remote merge gate.
  • Fresh Codex autoreview of the combined diff and repair-specific patch — clean, no accepted/actionable findings.
  • Production LOC: +22/-70 (net -48). Tests: +106/-62. Test support: +76/-67.

AI-assisted with Codex; the maintainer independently inspected the owners, callers, drag/drop path, queue lifecycle, authority revalidation, upstream Codex turn-steering contract, tests, history, rendered behavior, and final diff.

@clawsweeper

clawsweeper Bot commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

@steipete
steipete marked this pull request as ready for review August 14, 2026 06:45
@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui size: S maintainer Maintainer-authored PR labels Aug 14, 2026
@steipete steipete self-assigned this Aug 14, 2026
@clawsweeper clawsweeper Bot added merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. P2 Normal backlog priority with limited blast radius. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. labels Aug 14, 2026
@clawsweeper

clawsweeper Bot commented Aug 14, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 14, 2026, 4:51 AM ET / 08:51 UTC.

ClawSweeper review

What this changes

The PR renders the Control UI’s reconciled page/session list in saved order again and dispatches tool-bound Gateway turns instead of injecting them into an active run.

Regression provenance

Possible regression — probable (reviewed change; failure trace). No predecessor PR is attributed.

Merge readiness

⚠️ Ready for maintainer review - 3 items remain

Keep open for maintainer review: the UI fix directly restores the canonical persisted sidebar order, but it intentionally reverses the recently shipped separate-Pinned-group presentation decision.

Priority: P2
Reviewed head: 0714a0d7c08fe898034a30bf764a2864e0d6b27a
Owner decision: Required. See Decision needed.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The patch follows the canonical sidebar and dispatch owners with targeted boundary coverage; remaining work is product confirmation and exact-head CI, not a demonstrated code defect.
Proof confidence 🌊 off-meta tidepool Not applicable: This maintainer-authored PR is outside the external-contributor proof gate; its body still supplies focused browser/harness and regression-test evidence.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Not applicable Not applicable: This maintainer-authored PR is outside the external-contributor proof gate; its body still supplies focused browser/harness and regression-test evidence.
Evidence reviewed 8 items Current-main UI defect: Current main preserves the heterogeneous persisted list in reconciliation, but the renderer partitions it into navigation and session arrays, so a saved route/session/route sequence cannot render in that order.
Canonical order owner: The reconciler explicitly defines entries as the render list and preserves valid serialized entries in encounter order, including pinned session entries.
Branch repair: The branch removes the type partition and renders sidebarZone.entries directly inside the sole drop zone, preserving the reconciler’s order.
Findings None None.
Security None None.

How this fits together

The Control UI reconciles gateway-synced sidebar preferences with available routes and pinned sessions, then renders that list as navigation. Gateway chat requests either inject into an eligible active run or proceed through normal dispatch, preserving the incoming turn’s tool bindings.

flowchart LR
  A[Saved sidebar preferences] --> B[Sidebar reconciliation]
  C[Available routes and pinned sessions] --> B
  B --> D[Control UI sidebar]
  E[Gateway chat request] --> F{Has tool bindings?}
  F -->|Yes| G[Normal turn dispatch]
  F -->|No| H[Active-run injection when eligible]
Loading

Decision needed

Question Recommendation
Should saved mixed page/session order remain a rendering contract, or should pinned sessions continue to be forcibly shown in a separate Pinned group? Restore canonical interleaving: Adopt this PR’s direct rendering of the persisted heterogeneous order and remove the presentation-only partition.

Why: Both behaviors were deliberately shipped recently; source alone cannot choose the intended operator experience.

Before merge

  • Resolve merge risk (P1) - Merging intentionally changes the presentation semantics introduced by improve(ui): give pinned sessions their own sidebar group #121712: existing saved mixed layouts render interleaved again instead of as a dedicated Pinned group.
  • Complete next step (P2) - A maintainer must resolve the intentional sidebar-presentation conflict before this otherwise focused repair can land.
Agent review details

Security

None.

PR surface

Source -39, Tests +44. Total +5 across 12 files.

View PR surface stats
Area Files Added Removed Net
Source 7 98 137 -39
Tests 5 106 62 +44
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 12 204 199 +5

Review metrics

Metric Value Why it matters
Production vs test LOC production +22/-70; tests +108/-73; test support +74/-56 The behavior repair is net -48 production lines; the remaining churn consolidates typed test fixtures and updates regression coverage.

Stored data model

Persistent data-model change detected: serialized state: ui/src/e2e/session-management.sidebar.e2e.test.ts. Confirm migration or upgrade compatibility proof before merge.

Merge-risk options

Maintainer options:

  1. Confirm canonical ordering before merge (recommended)
    Accept restored interleaving as the saved-layout contract, then merge after exact-head CI is green.
  2. Retain the separate Pinned group
    Pause or close the PR if the product decision remains that pinned sessions must always render after page routes.

Technical review

Best possible solution:

Confirm that persisted sidebar order is the product contract, then land this direct-render repair once the exact head’s required checks are green.

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

Yes—on current main, persist route:usage, session:agent:main:alpha, route:plugins; reconciliation preserves it, while the renderer filters routes before sessions. The branch’s focused UI case encodes the resulting expected order.

Is this the best way to solve the issue?

Yes for the source-proven ordering defect: rendering the reconciled list directly is the narrow owner-boundary fix. Whether that restored behavior is the intended product policy needs maintainer confirmation.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 0bd50cc0a5ba.

Labels

Label justifications:

  • P2: This repairs a localized but user-visible saved-sidebar ordering regression.
  • merge-risk: 🚨 compatibility: The PR deliberately restores mixed rendering for existing persisted layouts after a recently shipped separate-group presentation change.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🌊 off-meta tidepool and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Not applicable: This maintainer-authored PR is outside the external-contributor proof gate; its body still supplies focused browser/harness and regression-test evidence.

Evidence

What I checked:

Likely related people:

  • steipete: Authored the original interleaved-zone work and the current branch; current-main blame also attributes the surrounding renderer to Peter Steinberger. (role: original interleaved-zone contributor and recent area contributor; confidence: high; commits: 88e5af7097de, c636cf559ae1, 0714a0d7c08f; files: ui/src/components/app-sidebar.ts, src/gateway/server-methods/chat-send-message-injection.ts)
  • vyctorbrzezowski: The merged separate-Pinned-group change is the directly conflicting presentation decision that this PR proposes to reverse. (role: separate-group design contributor; confidence: high; commits: d7ea18e60088; files: ui/src/components/app-sidebar.ts, ui/src/components/app-sidebar-render.ts, ui/src/styles/layout.css)

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Confirm the intended sidebar presentation policy.
  • Wait for exact-head required checks to finish green.

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 (2 earlier review cycles)
  • reviewed 2026-08-14T06:50:00.239Z sha 48c0dc819ce39a770e3d53febc4f71600ba1cd4d :: needs maintainer review before merge. :: none
  • reviewed 2026-08-14T08:20:26.702Z sha 3523d564330deb8f9ef5db145ace73ccb73bbac5 :: needs maintainer review before merge. :: none

@steipete
steipete force-pushed the steipete/pinned-entries-ordering-regression-373dd0 branch from 48c0dc8 to 99a5c8b Compare August 14, 2026 07:50
@openclaw-barnacle openclaw-barnacle Bot added gateway Gateway runtime agents Agent runtime and tooling size: M and removed size: S labels Aug 14, 2026
@steipete
steipete force-pushed the steipete/pinned-entries-ordering-regression-373dd0 branch from e692288 to 3523d56 Compare August 14, 2026 08:12
Render pinned sessions at their persisted slots among page entries again instead of projecting them into a separate group. This restores custom page/session interleaving regressed by #121712 while preserving drag-to-pin behavior.
@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. and removed proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. labels Aug 14, 2026
@steipete
steipete force-pushed the steipete/pinned-entries-ordering-regression-373dd0 branch from 3523d56 to 0714a0d Compare August 14, 2026 08:44
@steipete

Copy link
Copy Markdown
Contributor Author

Rank-up moves addressed:

No ClawSweeper finding remains; the review's product decision and CI conditions are resolved.

@steipete
steipete merged commit 1011b41 into main Aug 14, 2026
278 of 282 checks passed
@steipete
steipete deleted the steipete/pinned-entries-ordering-regression-373dd0 branch August 14, 2026 09:00
@steipete

Copy link
Copy Markdown
Contributor Author

Merged via squash.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 15, 2026
* fix(ui): restore interleaved sidebar ordering

Render pinned sessions at their persisted slots among page entries again instead of projecting them into a separate group. This restores custom page/session interleaving regressed by openclaw#121712 while preserving drag-to-pin behavior.

* test: consolidate steering authority fixtures

* test: isolate CLI commentary fixture

* fix: dispatch tool-bound turns normally
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agents Agent runtime and tooling app: web-ui App: web-ui gateway Gateway runtime maintainer Maintainer-authored PR merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: M 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