Repository navigation
fix: close worktree dialog before slow script checks - #25472
Merged
Merged
Conversation
8 tasks done
7 of 9 tasks
8 of 9 tasks
This was referenced Oct 5, 2026
8 of 9 tasks
This was referenced Oct 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ELI5
Clicking Create worktree no longer leaves the dialog open while Orca inspects setup scripts. The existing workspace preparation screen takes over, so you can keep using the app.
What Changed
Move setup-script inspection, issue-command confirmation, and VM recipe confirmation into the background creation flow. Capture the selected execution host for script checks, creation dispatch, retry, and the returned worktree, show the existing Preparing workspace state, and preserve cancellation, trust refusal, and retry behavior. Required setup choices remain in the composer.
Why
Script inspection can take seconds, particularly on remote hosts. Reusing the existing preparation screen removes that wait from the dialog without adding another loading UI or bypassing script trust checks.
Linked Issue
Reported directly by the maintainer; no linked issue.
Visual Proof
Before: the reported dialog stays open after Create.
After: the creation tab and sidebar show Preparing workspace while the rest of Orca remains accessible.
In a hidden macOS Electron app, with hook inspection deliberately delayed by five seconds, the dialog closed in 76–77 ms. Creation completed after preparation; cancelling during preparation prevented creation.
Testing
72 focused tests passed across creation flow, script preparation, duplicate handling, failure recovery, and request construction. New tests cover delayed trust checks, cancellation, refused setup/VM scripts, issue-command host routing, and preparation retry.
pnpm tc:web, changed-code quality checks, targeted test lint, andgit diff --checkpassed. Electron validation usedORCA_BACKGROUND_LAUNCH=1and Playwright CDP on macOS. Actual SSH, Linux, and Windows were not exercised; host routing is covered by unit tests. Full lint/typecheck/test/build remain for CI.Review
Adversarial review found and fixed a host-selection race: switching runtimes during preparation could send creation to the newly focused runtime. Regression tests reproduced it before the fix and now verify local, SSH, and paired-runtime dispatch plus ownership after switching focus during creation. Also reviewed request handoff, cancellation, trust refusal, retry, duplicate handling, setup-policy defaults, and folder-workspace behavior; no other blocking findings remain.
Agent skill upstream boundary
docs/reference/agent-skill-sharing-upstream-boundary.mdand copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.Notes
Renderer-only change; no wire protocol, path handling, keyboard shortcut, or agent status changes. Folder-workspace creation retains its existing flow. Metadata resolution, explicit setup choices, and pending preference saves can still precede the background handoff.
Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred)