Skip to content

[Bug]: Diff routing follows global default runtime instead of selected worktree owner #8484

Closed

Description

@ruigomeseu

Operating system

  • Client: macOS 26.5.2, Apple Silicon (arm64)
  • Paired Orca server: Ubuntu 26.04, x86_64

Orca version

1.4.137 on the macOS client

Details

Short summary

When the same Git project has both a local host setup and a paired-runtime host setup, the built-in diff viewer routes file and diff requests according to the global Settings → Remote Orca Servers → Advanced → Default runtime value instead of the selected worktree's owning host.

This makes local and remote diffs mutually exclusive: whichever host is selected as the global default works, while the worktree on the other host fails.

Reproduction

  1. Connect the macOS Orca client to an Orca server running on Linux.

  2. Make one Git project available on both Local desktop and the paired runtime.

  3. Have one worktree with a tracked change on each host.

  4. Set Default runtime to Local desktop.

  5. Open the local worktree's diff: it loads successfully.

  6. Open the paired-runtime worktree's diff: it fails with:

    Error invoking remote method 'fs:readFile': Error: Access denied: path resolves outside allowed directories. If this blocks a legitimate workflow, please file a GitHub issue.
    
  7. Change only Default runtime to the paired runtime, close the failed tabs, and reopen both diffs.

  8. The paired-runtime diff now loads successfully, while the local diff fails with:

    Error loading diff: RuntimeRpcCallError: selector_not_found
    
  9. Restarting Orca does not change the behavior. Changing the global default reliably flips which host works.

Expected behavior

Diff routing should use the selected worktree's explicit owner:

  • A local worktree should use local file/git IPC (runtimeEnvironmentId: null).
  • A paired-runtime worktree should use that runtime's RPC connection.
  • The global default runtime should only be a fallback when a worktree genuinely has no known owner.

Both local and paired-runtime diffs should therefore work in the same Orca session without changing settings.

Additional diagnostics

  • The paired-runtime checkout is a normal registered Git worktree located beneath the server's configured workspace directory.
  • The requested file's canonical path remains inside that worktree, and its permissions are normal.
  • The paired runtime can operate on the worktree through its terminal and Git normally.
  • The two failures are consistent with the same missing/incorrect owner in opposite directions:
    • With Local desktop as the default, Orca appears to send the Linux path to the macOS filesystem handler, which rejects it as outside local allowed roots.
    • With the paired runtime as the default, Orca appears to send the local worktree selector to the Linux runtime, where that selector does not exist.

This looks like a regression or an uncovered path related to #6440 / #6562 and #6942: the diff/editor record is not consistently retaining the selected worktree's runtime owner and instead falls back to activeRuntimeEnvironmentId.

Activity

  1. brennanb2025 commented on Jul 13, 2026

    @brennanb2025
    Contributor

    Taking a look!

  2. added 2 commits that reference this issue on Jul 14, 2026
  3. added
    orca-remote-server
    on Jul 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

orca-remote-server

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions