Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): Reveal in File Explorer and browser launches work on Windows again #19656

Mergedt3dotgg(GitHub profile, opens in a new tab)merged 10 commits intomain fromrefs/pull/19656/headmerged by t3dotgg(GitHub profile, opens in a new tab) View on GitHub

Problem

On native Windows, Reveal in File Explorer does nothing, and npx t3 / t3 start don't auto-open the pairing URL. The server starts powershell.exe with detached: true. Windows PowerShell started that way exits 0 without running its command, so nothing opens and the server reports success.

Fixes #11780.

Fix

Native Windows PowerShell launches (reveal and browser) now start attached. Stdio is still ignored and the child is still unref()'d, so nothing waits on it. WSL, macOS, Linux, and editor launches keep detached: true.

The detach choice is made where each launch is built, not by matching the command name at spawn time.

Credit

This takes over #10387 by @doubletwisted, with their commits kept. Their PR has the root cause, live Windows tests, and before/after recordings from the desktop app. @ChristianStrunk1984 independently confirmed the root cause on a clean Windows 11 VM. Takeover changes: rebased on main, moved the detach decision to the launch builders, and made the live test cleanup tolerate a short Windows file lock.

Proof

Windows runner (windows-tests.yml), externalLauncher.test.ts:

  • Old launcher + new tests (run): both live PowerShell launches never run their command and time out.
  • This branch (run): all 27 Windows tests pass, including both live launches. The reveal stub receives /select,"C:\workspace with spaces\media\author's clip.mp4".

Linux: the same file passes (54 passed, 2 Windows-only skips). Targeted lint and server typecheck pass.

Not checked by me: a real Explorer window or browser opening. @doubletwisted's recordings in #10387 cover that.

Co-authored-by: doubletwisted <118005273+doubletwisted@users.noreply.github.com>

Made with Claude Opus 5.5 in Claude Code.

🤖 Generated with Claude Code

    1. github-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:trusted

    2. juliusmarminge added labelsmacroscope-review

    3. Approvability

      Verdict: Not approved

      Macroscope's review found this PR not approvable — This targeted fix changes the default process-launch mode for native Windows browser and File Explorer actions, while adding coverage for the affected Windows and preserved WSL paths. Because that default behavior changes for users, the change warrants explicit review.

      You can add or adjust custom eligibility rules. [Learn more](https://docs.macroscope.com/approvability#example-custom-eligibility-rules).
    4. Review in Change Stack →

      No actionable comments were generated in the recent review. 🎉

      ℹ️ Recent review info
      ⚙️ Run configuration
      • Configuration used: Path: .coderabbit.config.ts
      • Review profile: CHILL
      • Plan: Team
      • Run ID: 3c089d33-0207-4505-b813-791accace1f4
      📥 Commits

      Reviewing files that changed from the base of the PR and between 5a4e9980533705774dc3f45b35cacf76c3d78dbc and 216bab1fc773418cf92e0ec279195287cdca4911.

      📒 Files selected for processing: 2
      • apps/server/src/process/externalLauncher.test.ts
      • apps/server/src/process/externalLauncher.ts

      Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 9 remain after this review.

      📝 Walkthrough

      External launch handling now supports an optional detached setting. Native Windows PowerShell browser and file-manager launches are not detached, while WSL browser launches remain detached. Tests cover mocked launch options and live Windows PowerShell browser and reveal launches.

      Changes: Platform-specific external launch behavior

      Layer / File(s)Summary
      Platform-specific detached launch behavior
      apps/server/src/process/externalLauncher.ts, apps/server/src/process/externalLauncher.test.ts
      The launcher accepts a detached override and defaults editor launches to detached. Native Windows browser and file-manager launches are not detached; WSL browser launches remain detached. Tests check launch options and use real PowerShell for browser and reveal smoke tests.

      Priority: ➖ Normal

      Estimated code review effort: 3 (Moderate) | ~20 minutes

      Change: Bug fix · Severity of issue fixed: Medium

      Suggested reviewers: juliusmarminge

      Merge Risk: ⚪ Minimal · up to 216ba

      The launch changes are ready to merge after normal checks; no actionable issue was established.

      Pre-merge checks: Passed 3 · Inconclusive 1
      Failed Failed checks: 1 inconclusive
      Check nameStatusExplanationResolution
      Linked Issues checkInconclusiveIssue #11780 requires Windows Explorer to open the containing folder and select the linked file. The PR sets native Windows PowerShell launches to attached and preserves the /select,"<path>" argumen…Provide reviewable Windows evidence or automated coverage for real Explorer selection and for the required actionable error when the reveal operation fails.
      Passed Passed checks: 3 passed
      Check nameStatusExplanation
      Title checkPassedThe title clearly and concisely describes the primary Windows fix for File Explorer and browser launches.
      Description checkPassedThe description explains the problem, fix, scope, linked issue, test results, limitations, and agent usage. It uses "Fix" and "Proof" instead of the template headings "Change" and "Verification," and …
      Out of Scope Changes checkPassedThe browser-launch changes address the same native Windows PowerShell detached: true failure described in the PR. The changes keep WSL, macOS, Linux, and editor launch behavior scoped to their exist…
      Full details: Linked Issues check

      Explanation

      Issue #11780 requires Windows Explorer to open the containing folder and select the linked file. The PR sets native Windows PowerShell launches to attached and preserves the /select,"&lt;path&gt;" argument. The live Windows test verifies the PowerShell-to-stub argument chain, but it replaces Explorer and does not verify a real Explorer result or an actionable failure path. The available evidence cannot establish full compliance.

      ✨ Finishing Touches
      📝 Generate docstrings
      • Commit to this branch
      • Create a new PR
      🧪 Generate unit tests (beta)
      • Commit to this branch
      • Create a new PR
      • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
      Comment `@coderabbitai help` to get the list of available commands.
    5. Thread transfer impact

      ✅ Thread transfer remains within every enforced ceiling.

      ProviderMetricMain baselineThis PRImpactPR ceiling
      CodexTotal thread wire5.0 KiB5.0 KiB0 B (0.0%)6.8 KiB✅
      CodexThread snapshot wire3.8 KiB3.8 KiB0 B (0.0%)4.9 KiB✅
      CodexLive turn WebSocket wire1.2 KiB1.2 KiB0 B (0.0%)2.0 KiB✅
      CodexLive turn WebSocket decoded20.9 KiB20.9 KiB0 B (0.0%)29.3 KiB✅
      CodexLive turn messages220 (0.0%)8✅
      ClaudeTotal thread wire5.0 KiB5.0 KiB0 B (0.0%)6.8 KiB✅
      ClaudeThread snapshot wire3.8 KiB3.8 KiB0 B (0.0%)4.9 KiB✅
      ClaudeLive turn WebSocket wire1.2 KiB1.2 KiB0 B (0.0%)2.0 KiB✅
      ClaudeLive turn WebSocket decoded21.2 KiB21.2 KiB0 B (0.0%)29.3 KiB✅
      ClaudeLive turn messages220 (0.0%)8✅

      Baseline: 5a4e998 · PR result: 216bab1 · Source CI: success

      Scenario and decoded snapshot size

      10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.

      • Codex decoded thread snapshot: 108.5 KiB
      • Claude decoded thread snapshot: 108.8 KiB

      Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.

Sign in to join this conversation.