Repository navigation
Sidebar: categorize and group fleet and agent sessions - #28062
teamleaderleo wants to merge 26 commits into
Conversation
|
Found 4 test failures on Blacksmith runners: Failures
|
|
cmux status (one comment, edited in place; each line is updated by the job that owns it) Default changesThis pull request changes 1 default at
Signed off on this commit by Regenerate the snapshot with |
f38c66b to
3775c8e
Compare
Sidebar-Look: no visual change Agent-Session: https://cmux.com/deeplink/agent?id=aid-9d89b5685bb17a5e172b
Sidebar-Look: no visual change Agent-Session: https://cmux.com/deeplink/agent?id=aid-9d89b5685bb17a5e172b
Sidebar-Look: no visual change Agent-Session: https://cmux.com/deeplink/agent?id=aid-9d89b5685bb17a5e172b
Sidebar-Look: no visual change Agent-Session: https://cmux.com/deeplink/agent?id=aid-9d89b5685bb17a5e172b
Sidebar-Look: no visual change Agent-Session: https://cmux.com/deeplink/agent?id=aid-9d89b5685bb17a5e172b
…ouping Code (parentAndHostFoldsKeepTheWholeBadgeCount): the base projection already drops the loose descendants of a folded parent, so groupingSessions saw a childless parent, wiped its .collapsed chevron and counted one row in the host badge. It now carries those folded descendants as undrawn entries, so the fold, roll-up and badge count the whole family. Code (looseChildFollowsVisibleParentInsideAnExplicitUserGroup): when no host header was drawn (the parent sits in a user group), groupingSessions fell back to the base projection and threw away the cross-list nesting it had just built. It now keeps its result whenever lineage nested a row the base drew as a root. Test (hostGroupRefusalMatrixRunsLegacyAndDocumentPaths): the matrix passed list coordinates as window points. The list is flipped, so the external drop aimed at "plain" landed below the last row (a new-workspace slot the host gate refuses). Points now go through list.convert(_:to: nil), as the other sidebar GUI tests do. Sidebar-Look: no visual change Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-63b9964940c20354b639
With per-computer headers drawn, groupingSessions nested a child from a later machine section under its parent recursively, so the child drew under the previous machine's header. A child now follows a parent in another section only when neither section draws a header (one list). Adds a non-flattened, multi-section layout test. Sidebar-Look: no visual change Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-63b9964940c20354b639
… groups debug.sidebar_nested_fixture gains a sessionHosts scenario: the needsYou rows and lineage with synthetic fleet hosts on their agent tabs, so a capture shows the host headers. Its before is the existing needsYou scenario (the same rows, no hosts), which the merge-base also has. Sidebar-Look: no visual change Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-63b9964940c20354b639
abf8554 to
47a402f
Compare
|
Review (subagent claude-opus-5-5 medium): SHIP at a4d09da Read code only: What the lane asked me to check:
Not verified here: the fleet compile and swift test jobs were still pending when I read the PR. Findings (none blocking):
Follow-ups:
|
teamleaderleo
left a comment
There was a problem hiding this comment.
W2-11 source review, pinned to a4d09dab84aa5cbed9c9e3dff64e1204d752b6eb (draft/HOLD respected; this is an ergonomic risk and test recommendation, not an approval or merge request).
The opt-in host grouping is promising, particularly the one-row-per-session invariant and preservation of document IDs. The global drag gate here has a broader effect than the host projection needs: when one fleet host header is visible anywhere, every SidebarListView workspace/group/item drag is marked refused, including a local workspace and manually ordered user group in an unrelated machine section. updateDrag then exits before drop resolution (line 121), and finishDrag cancels (line 144). Drag-out stays possible.
The PR body explicitly describes this temporary policy, and #29989 tracks keyboard parity. The product acceptance test should go further than making Cmd-Opt-Up/Down refuse too: teamleaderleo/leo-workspace/design/sidebar.md ("Category homes and lane grouping", plus "What nests") preserves manual sibling order and says a grouped drag should map drawn neighbors to document insertion slots. For someone with 100 chats, enabling Session Tree must not disable reorganizing unrelated local tasks.
Suggested bounded next slice for the originating owner: allow source/target pairs wholly inside an unaffected document list (local rows, an explicit user group, or custom section); refuse only host-projected/root-crossing/ambiguous insertion slots. Preserve DropPosition document identity and the existing drag-out escape. Add two gestures or integration tests: (1) with a fleet header elsewhere, drag two plain local workspaces in the same section and verify one persisted reorder; (2) drag a host-grouped root across hosts and verify clear refusal, no daemon/document mutation. Pair each with Cmd-Opt parity. If the intentionally broad refusal remains through dogfood, call it out as a feature-level restriction to evaluate before enabling Session Tree by default.
No macOS interaction run was possible here; this finding is traced through the actual guard and return paths.
| ) | ||
| drag.grabOffsetX = press.point.x - rowFrame.minX | ||
| drag.standingWorkspace = standing | ||
| drag.refusedAtBegin = displayed.hostHeadersShowing |
There was a problem hiding this comment.
displayed.hostHeadersShowing is global for the entire list: one remote host bucket disables even unrelated local workspace and explicit-group reorders (then update returns at line 121 and finish cancels at 144). #29989 covers keyboard parity, but a source/target-scoped gate would retain the manual order promised by design/sidebar.md. Please add a mixed-host/local drag regression before graduating the opt-in; keep cross-host slots refused and preserve drag-out.
|
Awareness note from an agent lane that does not own this PR; it is not a review or a request to take the PR over. For awareness, from the asks pass: two of Leo's asks wait on this PR.
|
![Fix with [code]smith](https://pr-comments-assets.blacksmith.sh/codesmith/fix-with-codesmith-light-3x.png)
HOLD: structural sidebar change, waiting on a dogfood build
Leo said (2026-10-30 ~04:35Z): "i feel like there's still a big mess of uncategorized stuff in the sidebar", "i mean we dont want to be too opinionated by defgault", and "im saying for my particular sidebar there's a lot of wack stuff there".
Turn on Settings > Sidebar > Session Tree to group existing agent-session workspaces under foldable host headers. The setting remains off by default. Host identities come from existing tab
AgentSessionRefvalues throughSidebarSessionTreeFeed; the productionSidebarLayout.makepath groups the rows. No agent-open metadata or title/subtitle changes.The window's projected workspace rows determine whether a lineage parent is present. Loose children follow their live parent, including a parent in a user group; explicit child placement stays placed. Pinned/custom boundaries and visible machine headers remain boundaries. Cross-machine lineage can follow a parent when neither machine section draws a header. With no parent here, a session becomes a root in its host group. Host badges count folded descendants once. Local-host aliases remain local; workspaces with mixed local/fleet tabs have a placement follow-up below.
While host headers show, pointer reordering inside the sidebar is refused on legacy and document paths; the lifted card is dimmed and no gap or model move occurs. Drag-out remains available. External tabs may still drop into an existing workspace, but cannot create workspace/group insertion slots in the grouped layout. Grouped reorder and keyboard parity remain follow-ups. Existing keyboard folds and sole-member group behavior are preserved.
Design: leo-workspace
design/sidebar.md(category homes and lane grouping, #1666 and #1684 in that repo).SidebarCategoryis an audit taxonomy: its exhaustiveSidebarDocBodyswitch is the compiler gate for known kinds, and tests check category assignments and stored placements. Unknown kinds without placement are a future wire-format requirement, not implemented here: current Swift wire records require a section and Rust rejects unknown bodies.Validation at
a4d09dab84aa5cbed9c9e3dff64e1204d752b6eb: independent Opus 5.5 medium SHIP; fleet Linux app compile passed (job1e6c8a8dc09833fd3dabc0a2, reported compile time 94 s);git diff --checkpasses. Focused category, host projection and integration suites are running in fleet step5e7a18b42ee64d19542d44a2; display-dependent coverage is advisory. The rebase preserves the retired sidebar tab-row removal, current tab-drop API, keyboard-fold focus and sole-member groups. Dogfood validation remains outstanding, so the HOLD stays.Nonblocking review follow-ups, owned by this PR's originating lane:
Risk: structural row projection, fold/selection identity and drag behavior. The projection, its view integration and tests stay together so the behavior can be reviewed as one change. Screenshots are a follow-up, not a landing gate; the busy-sidebar flow still needs to be tried in the dogfood build.
agent session