Skip to content

fix(ui): show menus for child sessions in the sidebar - #125033

Merged
clawsweeper merged 3 commits into
mainfrom
fix/sidebar-child-session-menu
Aug 17, 2026
Merged

clawsweeper merged 3 commits into
mainfrom
fix/sidebar-child-session-menu

Conversation

@clawsweeper

@clawsweeper clawsweeper commented Aug 17, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes an issue where users managing spawned/child sessions from the Control UI sidebar had no row menu or context-menu access. Operators had to open the child chat first and then use its header menu to rename, archive, delete, or otherwise manage the session.

Reported by @vyctorbrzezowski.

Why This Change Was Made

Child rows now use the existing session-menu owner and access checks for mouse, keyboard context-menu, and right-click entry points. The menu also respects the child-session contract: Pin and Move to group are omitted because root sidebar placement is controlled by lineage for child sessions, while session-level actions remain available.

User Impact

Operators can manage subagent and other child sessions directly where they appear in the sidebar. The coherent child menu offers Mark as unread, Rename, Set icon, Fork, Archive, and Delete, plus applicable worktree or cloud-worker actions. It does not offer root-only Pin or grouping controls.

Evidence

Before

Expanded child rows had status/runtime information but no menu affordance.

Before: child session rows without a sidebar menu

After

The completed Verify tests child exposes the child-specific session menu directly from the sidebar. Pin and Move to group are absent because lineage owns child placement.

After: coherent child session sidebar menu

Validation

  • session-management.sidebar.e2e.test.ts: 11/11 passed with a fresh dark-theme screenshot capture.
  • session-menu.test.ts: 39/39 passed, including an exact child action-set regression.
  • app-sidebar.test.ts + session-menu.test.ts: 302/302 passed at the final head.
  • Dead-export scans and core test typecheck passed on the prepared host after 4 GB remote gate workers were resource-terminated without source diagnostics.
  • Exact-head GitHub CI run 32062453469 passed.
  • Final whole-branch autoreview: clean; no accepted/actionable findings.

Production LOC: +62/-48 (net +14) | Tests and test support: +48/-4.

@clawsweeper

clawsweeper Bot commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

@openclaw-barnacle openclaw-barnacle Bot added app: web-ui App: web-ui size: S maintainer Maintainer-authored PR labels Aug 17, 2026
@clawsweeper
clawsweeper marked this pull request as ready for review August 17, 2026 04:19
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. 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 17, 2026
@clawsweeper

clawsweeper Bot commented Aug 17, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge. Reviewed August 17, 2026, 3:55 PM ET / 19:55 UTC.

ClawSweeper review

What this changes

This PR lets Control UI operators open the existing session menu from child-session sidebar rows while hiding Pin and Move to group actions that only apply to root placement.

Merge readiness

⚠️ Ready for maintainer review - 3 items remain

Keep open for protected maintainer handling. No blocking patch defect found: current main still suppresses child-row menu entry points, while this branch routes them through the shared owner and omits lineage-incompatible placement actions; exact-head CI is still incomplete. Likely related people: Peter Steinberger (high confidence, recent sidebar/menu source owner).

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

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) The focused shared-owner repair and coverage are solid; remaining merge readiness depends on exact-head CI and protected maintainer approval.
Proof confidence 🌊 off-meta tidepool Not applicable: This maintainer-associated PR is outside the external-contributor proof gate; its body also supplies before-and-after UI screenshots and browser E2E 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-associated PR is outside the external-contributor proof gate; its body also supplies before-and-after UI screenshots and browser E2E evidence.
Evidence reviewed 5 items Current-main behavior: Current main explicitly removes the context-menu handler and action aside for child rows, so child sessions have no sidebar menu entry point.
Shared owner-boundary repair: The branch enables the existing row menu trigger for every session, passes child status into the shared menu, and masks only root-placement actions there.
Action contract and caller: The renderer supplies isChild to the shared menu, whose root-placement predicate omits Pin and Move to group while retaining session-level actions.
Findings None None.
Security None None.

How this fits together

The Control UI sidebar renders agent session trees and sends row interactions to a shared session-menu controller. The menu then maps permitted actions to session-management operations such as rename, archive, delete, and fork.

flowchart LR
  A[Session tree data] --> B[Sidebar child row]
  B --> C[Shared session menu controller]
  C --> D{Child or root session}
  D --> E[Allowed menu actions]
  E --> F[Session management operations]
Loading

Decision needed

Question Recommendation
After exact-head CI is green, should the Control UI owner approve exposing the shared menu on child rows while continuing to omit Pin and Move to group? Approve after CI: Accept the focused shared-menu implementation once every required check for the current head succeeds.

Why: The PR carries the protected maintainer label and changes a visible Control UI management flow, so final acceptance requires an explicit owner decision.

Before merge

  • Resolve merge risk (P1) - Required checks for the exact head d03b9bd are still in progress, so it is not ready to merge yet.
  • Complete next step (P2) - The protected maintainer label and incomplete exact-head checks require human approval after CI, not an automated repair.
Agent review details

Security

None.

PR surface

Source +17, Tests +41. Total +58 across 7 files.

View PR surface stats
Area Files Added Removed Net
Source 5 67 50 +17
Tests 2 43 2 +41
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 7 110 52 +58

Review metrics

Metric Value Why it matters
Production versus test LOC production +62/-48 (net +14); tests +43/-2; test support +5/-2 The small production increase is concentrated in the child-row action slot and shared-menu policy; behavior coverage includes unit and browser E2E paths.

Stored data model

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

Merge-risk options

Maintainer options:

  1. Decide the mitigation before merge
    Keep one shared session-menu path, with child placement constraints expressed as the isChild action predicate, then land after exact-head CI and protected maintainer review succeed.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Technical review

Best possible solution:

Keep one shared session-menu path, with child placement constraints expressed as the isChild action predicate, then land after exact-head CI and protected maintainer review succeed.

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

Yes, from source: current main excludes child rows from both sidebar menu triggers and menu controls, while the branch’s focused browser test exercises the restored row-to-menu path.

Is this the best way to solve the issue?

Yes. Reusing the existing menu controller and action-access checks avoids a second child-only action implementation; the child predicate cleanly preserves lineage-owned placement rules.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 29fc91fe99d8.

Labels

Label changes:

  • remove proof: sufficient: Current real behavior proof status is not_applicable, not sufficient.
  • remove proof: 📸 screenshot: Current real behavior proof evidence kind is not_applicable.

Label justifications:

  • P2: This is a bounded Control UI repair that restores direct session management for child rows without affecting runtime availability or stored state.
  • 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-associated PR is outside the external-contributor proof gate; its body also supplies before-and-after UI screenshots and browser E2E evidence.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Current-main blame attributes the child-row suppression and surrounding session-menu wiring to this recent source revision. (role: recent sidebar and session-menu contributor; confidence: high; commits: 5e964265fde9; files: ui/src/components/app-sidebar-session-row-render.ts, ui/src/components/session-menu.ts)

Rank-up moves

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

  • Wait for all required checks on d03b9bd to complete successfully.

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 (3 earlier review cycles)
  • reviewed 2026-08-17T04:28:22.177Z sha a217a79 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-17T05:33:23.628Z sha bfdd8b7 :: needs maintainer review before merge. :: none
  • reviewed 2026-08-17T19:44:16.291Z sha bfdd8b7 :: needs maintainer review before merge. :: none

@clawsweeper

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Aug 17, 2026 •

Copy link
Copy Markdown
Contributor

🦞🧹
ClawSweeper re-review requested.

I asked ClawSweeper to review this item again.
Action: item re-review queued (workflow sweep.yml, event exact_review_queue).
Result: when the review finishes, ClawSweeper will create the durable review comment if needed or update the existing comment in place.

Re-review progress:

@clawsweeper clawsweeper Bot added rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. and removed rating: 🦐 gold shrimp Decent PR readiness signal, but merge confidence is limited. labels Aug 17, 2026
@clawsweeper clawsweeper Bot added proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. proof: sufficient ClawSweeper judged the real behavior proof convincing. and removed proof: sufficient ClawSweeper judged the real behavior proof convincing. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. labels Aug 17, 2026
@clawsweeper

Copy link
Copy Markdown
Contributor Author

Maintainer review is complete for d03b9bd79a9a98541c71f4e970c581bdb138bd80.

The root cause was the child-row renderer suppressing both menu events and the action container. The fix restores the canonical menu path, then omits only lineage-incompatible placement actions (Pin and grouping) inside the shared menu owner. Provenance traces the exclusion to #108838; this repair was reported by @vyctorbrzezowski.

Validation:

  • node scripts/run-vitest.mjs ui/src/components/app-sidebar.test.ts ui/src/components/session-menu.test.ts — 302 passed
  • session-management.sidebar.e2e.test.ts — 11 passed with inspected before/after UI proof
  • pnpm deadcode:exports — all three Knip scans passed with zero findings
  • node scripts/run-tsgo-core-test-shards.mjs — passed
  • .agents/skills/autoreview/scripts/autoreview --mode branch --base origin/main — clean, no accepted/actionable findings
  • Exact-head CI run 32062453469 — green
  • OPENCLAW_TESTBOX=1 scripts/pr prepare-run 125033 — hosted exact/recent-parent gates passed

The 4 GB remote changed-check workers were resource-terminated in Knip and core test typecheck without source diagnostics; both exact lanes passed on the prepared host, and exact-head CI plus the native prepare gate are green. No proof gap remains.

Visual proof: before · after

Ready for the guarded merge.

@clawsweeper
clawsweeper merged commit 248966d into main Aug 17, 2026
153 checks passed
@clawsweeper

clawsweeper commented Aug 17, 2026 •

Copy link
Copy Markdown
Contributor Author

Merged via squash.

@clawsweeper
clawsweeper deleted the fix/sidebar-child-session-menu branch August 17, 2026 19:59
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Aug 18, 2026
* fix(ui): add child session sidebar menus

* fix(ui): tailor child session menus

* test(ui): align child session menu expectations

---------

Co-authored-by: ClawSweeper <[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 P2 Normal backlog priority with limited blast radius. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: S 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.

2 participants