Skip to content

Disambiguate sidebar project setup groups - #6430

Merged
Jinwoo-H merged 1 commit into
mainfrom
Jinwoo-H/remote-server-left-sidebar
Jun 26, 2026
Merged

Jinwoo-H merged 1 commit into
mainfrom
Jinwoo-H/remote-server-left-sidebar

Conversation

@Jinwoo-H

@Jinwoo-H Jinwoo-H commented Jun 26, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • preserve per-setup sidebar groups when a project has duplicate checkouts on the same execution surface
  • extend that ambiguous case to all setups for the project, so a single remote copy is not implicitly attached to one of several duplicate checkouts
  • keep one-project sidebar grouping when a project has only one setup per execution surface

Behavior

  • Local + SSH/runtime, one setup per surface: one project header
  • Two local checkouts on the same surface: separate setup headers
  • Two local checkouts plus one remote checkout: all setups render as setup headers, because Orca cannot know which duplicate checkout the remote copy belongs to without explicit linking
  • Windows-host and WSL paths on the same runtime host count as different surfaces, so C:\...\orca plus \\wsl.localhost\Ubuntu\...\orca still group as one project

Test

  • pnpm test src/renderer/src/components/sidebar/worktree-list-groups.test.ts

Note: test passed with the existing Node engine warning in this shell (repo wants Node 24, shell has Node v26.0.0).

@coderabbitai

coderabbitai Bot commented Jun 26, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 6aa82678-9819-41e6-9cb2-5f017d9a6de8

📥 Commits

Reviewing files that changed from the base of the PR and between 58caa464625de6d149e65759e9af2aa784c58484 and 985aaa3.

📒 Files selected for processing (2)
  • src/renderer/src/components/sidebar/worktree-list-groups.test.ts
  • src/renderer/src/components/sidebar/worktree-list-groups.ts
🚧 Files skipped from review as they are similar to previous changes (2)
  • src/renderer/src/components/sidebar/worktree-list-groups.ts
  • src/renderer/src/components/sidebar/worktree-list-groups.test.ts

📝 Walkthrough

Walkthrough

The sidebar worktree grouping logic now derives setup grouping from execution surfaces built from project, host, and WSL or Windows path classification. Repo grouping uses the resulting project-level flag to choose setup-scoped header keys when duplicate setups exist on the same surface. The tests now assert three separate setup headers for duplicate local and remote checkouts and keep the Windows/WSL grouping case afterward.

🚥 Pre-merge checks | ✅ 3 | ❌ 2

❌ Failed checks (2 warnings)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description covers summary and testing, but it omits required Screenshots, AI Review Report, Security Audit, and Notes sections. Add the missing template sections, especially screenshots or 'No visual change', a cross-platform AI review, security audit, and notes.
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and accurately summarizes the main sidebar grouping change.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/renderer/src/components/sidebar/worktree-list-groups.ts (1)

190-192: 📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Add a short rationale for collapsing to the project key.

This return encodes the PR’s non-obvious behavior change: setup-scoped headers are intentionally skipped when project lookup succeeds. A one-line comment would help prevent reintroducing the old split.

Proposed comment
+  // Keep same-project checkouts under one sidebar header, matching the create-worktree host picker.
   return {
     key: `project:${project.id}`,
     label: project.displayName,

As per coding guidelines, “When writing or modifying code driven by a design doc or non-obvious constraint, add a comment explaining why the code behaves the way it does.”

Source: Coding guidelines


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 6e1f70ee-5f78-4dd2-a43a-56850d3d72b8

📥 Commits

Reviewing files that changed from the base of the PR and between 14a742e and 0c8a6e7c8a3d372b089f0f448dd58e8c7b65e34c.

📒 Files selected for processing (2)
  • src/renderer/src/components/sidebar/worktree-list-groups.test.ts
  • src/renderer/src/components/sidebar/worktree-list-groups.ts

@Jinwoo-H
Jinwoo-H force-pushed the Jinwoo-H/remote-server-left-sidebar branch from 0c8a6e7 to 58caa46 Compare June 26, 2026 18:37
@Jinwoo-H Jinwoo-H changed the title Group sidebar repos by project identity Disambiguate sidebar project setup groups Jun 26, 2026
@Jinwoo-H
Jinwoo-H force-pushed the Jinwoo-H/remote-server-left-sidebar branch from 58caa46 to 985aaa3 Compare June 26, 2026 18:52
@Jinwoo-H
Jinwoo-H merged commit a3ce269 into main Jun 26, 2026
1 check passed
@Jinwoo-H
Jinwoo-H deleted the Jinwoo-H/remote-server-left-sidebar branch June 26, 2026 19:24
enrick-dev pushed a commit to enrick-dev/orca that referenced this pull request Oct 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant