Skip to content

fix: explain Xcode-blocked Git once in the sidebar and rescan on return - #22552

Merged
Jinwoo-H merged 3 commits into
mainfrom
fix/xcode-license-sidebar-banner
Sep 23, 2026
Merged

Jinwoo-H merged 3 commits into
mainfrom
fix/xcode-license-sidebar-banner

Conversation

@Jinwoo-H

@Jinwoo-H Jinwoo-H commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor
Files Added Deleted Net
Test 1 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​152 0 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​152
Prod 5 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​257 $\color{#cf222e}{\Huge{\mathbf{−}}}$​59 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​198

ELI5

After a macOS update, Git refuses to run until you accept Apple's Xcode license. Orca used to show a small red icon next to every project and hide the explanation in a hover. Now it shows one clear box at the top of the project list that says what to run, and it checks again automatically when you switch back to Orca.

What Changed

Before: every local project got its own red warning icon. The fix command was only visible on hover. The hover text said "Click to retry" without saying what to click: only the icon itself worked, and buttons inside the hover did not. After running the command, nothing told you whether it had worked.

After (macOS, local projects only):

  • One box at the top of Projects: "Accept the Xcode license to use Git". It shows the command (sudo xcodebuild -license accept), a Copy command button, a Retry now button, and how many projects are affected.
  • When the Orca window becomes active again (for example after you run the command in Terminal), Orca rescans the blocked projects by itself. When the scan succeeds, the box goes away and a short "Git is working again" message appears.
  • The same box covers missing Apple developer tools (xcode-select --install).
  • The per-project icon no longer appears for these two causes, and its now-unreachable copy-command path is removed, so the command is defined once. It stays for failures that really are per-project: SSH/remote hosts, CPU-architecture mismatch, and unknown errors. Its hover text now says "Click the warning icon to retry".

Mechanism: sidebar/repo-scan-failure.ts now holds one classifier shared by the per-project icon and the new LocalGitToolchainScanBanner. isLocalToolchainFailure decides whether a failure belongs to the banner, and findLocalToolchainBlock groups the affected repos. The banner listens for window focus only while something is blocked. Its rescan reads the store when it runs and calls the existing fetchWorktrees, which already merges overlapping local scans and returns whether the scan succeeded. That return value drives the confirmation, with no extra state. This is renderer-only; nothing changes in main or on the wire.

Why

This failure is machine-wide: one unaccepted license breaks Git for every local repo at once. Showing it once per project made it look like N separate problems, and it put the only instructions behind a hover. People fix this in another app (Terminal), so switching back to Orca is the natural time to check again. That removes the "how do I rescan?" step completely.

The command changed to sudo xcodebuild -license accept, which accepts in one step instead of opening the license text and asking you to type "agree".

Alternatives considered: rewording only the tooltip, which leaves N icons and a hover-only fix; and polling on a timer, which costs a Git spawn per repo on an interval for something that changes only when the user acts.

Linked Issue

Follow-up to #21291 (UX feedback after updating to macOS 27).

Visual Proof

Before: a red ⚠ next to every project. The command and "Click to retry" appeared only on hover.

After:

oxcl-after.png

Testing

  • Dev Orca on macOS 27 with 3 local repos and a simulated Xcode-license scan failure. One box appears and no per-project icons. Removing the failure and then focusing the window rescans all three, the box disappears, and "Git is working again" shows.

  • LocalGitToolchainScanBanner.test.tsx: one box and no per-repo marker on macOS; a window focus rescans every blocked repo and confirms recovery; a still-blocked rescan shows no toast; SSH and remote-runtime repos keep the per-repo marker; off macOS there's no box and the per-repo markers stay.

  • Existing RepoScanUnavailableIndicator.test.tsx still passes.

  • pnpm tc:web and pnpm run check:code-quality:changed pass.

  • I manually tested these changes locally

  • Automated tests added/updated, or explained why not below

AI Disclosure

Review

Agent skill upstream boundary

  • Not applicable, or this change follows docs/reference/agent-skill-sharing-upstream-boundary.md and copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

Notes

  • SSH/remote: the box covers only local repos on a macOS client; remote failures keep the per-repo icon and diagnostics from fix: make worktree scan failures actionable #21291.
  • Linux/Windows: no change. The box never shows because the failure kinds are macOS-only.
  • Performance: the focus listener exists only while something is blocked, and overlapping rescans join the in-flight local scan instead of starting a new Git process.

Checklist

  • This PR is small and focused
  • I explained what changed and why (ELI5, the user-facing before/after, the mechanism, and why over the alternatives)
  • Before/after screenshots or videos attached for UI changes, or N/A with reason
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote, and path/shortcut impact considered (or N/A)
  • pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass (or CI will cover; local preferred)

@pullfrog

pullfrog Bot commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

This run was cancelled 🛑

The workflow was cancelled before completion. Please check the link below for details.

Pullfrog  | View workflow run | via Pullfrog | 𝕏

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