stablyai/orca · error · Error
Remote connection dropped. Click Reconnect on the SSH target
Error message
Remote connection dropped. Click Reconnect on the SSH target before retrying.
What it means
Thrown by the 'git:status' handler (src/main/ipc/filesystem.ts:1182) when args.connectionId is set but getSshGitProvider(connectionId) returns undefined. The SSH git provider map (ssh-git-dispatch.ts) is keyed by connectionId and a provider is removed via unregisterSshGitProvider when the SSH connection drops. The accompanying generation counter increments on each register/unregister so callers can detect a stale connection.
Source
Thrown at src/main/ipc/filesystem.ts:1182
}
): Promise<GitStatusResult> => {
const controller = gitStatusCancellations.begin(event, args.requestToken)
const options = {
includeIgnored: args.includeIgnored ?? false,
...(args.reuseLineStats === true ? { reuseLineStats: true } : {}),
...(args.branchLineTotalMergeBase === undefined
? {}
: { branchLineTotalMergeBase: args.branchLineTotalMergeBase }),
...(args.bypassEffectiveUpstreamNegativeCache === true
? { bypassEffectiveUpstreamNegativeCache: true }
: {}),
...(controller ? { signal: controller.signal } : {})
}
try {
if (args.connectionId) {
const provider = getSshGitProvider(args.connectionId)
if (!provider) {
throw new Error(SSH_GIT_PROVIDER_UNAVAILABLE_MESSAGE)
}
// Why: await keeps the cancellation token registered until the remote request settles (an early finally would free it).
return await provider.getStatus(args.worktreePath, options)
}
const worktreePath = await resolveRegisteredWorktreePath(args.worktreePath, store)
// Why: one registered-worktree lookup feeds both — status polls this
// handler, and the scan walks every repo's worktree meta.
const repo = getLocalRepoForRegisteredWorktree(store, args.worktreePath, worktreePath)
const gitOptions = getLocalGitOptionsForRepo(store, repo)
const sharedLinkPaths = repo ? getWorktreeSharedLinkPaths(repo) : []
return await getStatus(worktreePath, {
...options,
...gitOptions,
...(sharedLinkPaths.length > 0 ? { sharedLinkPaths } : {})
})
} finally {
gitStatusCancellations.finish(event, args.requestToken, controller)
}View on GitHub (pinned to 1136503c6a)
Solutions
- Trigger the app's 'Reconnect' on the SSH target to re-register an SSH git provider.
- After reconnect, refresh the connectionId in the renderer (reconnect yields a new id/generation).
- Retry the git:status call once the reconnect is confirmed.
- If it persists, the SSH target is unreachable: verify network, credentials, and that the relay process is up.
Example fix
// before: invoke status with a stale connectionId
await invoke('git:status', { worktreePath, connectionId })
// after: reconnect first, then retry with the fresh id
if (!await ensureSshConnected(connectionId)) {
connectionId = await reconnectSshTarget(targetId)
}
await invoke('git:status', { worktreePath, connectionId }) Defensive patterns
Strategy: retry
Validate before calling
// Treat a missing provider as a reconnect signal; check connection health first.
async function ensureProvider(connectionId: string): Promise<string> {
if (await isSshConnected(connectionId)) return connectionId
return reconnectSshTarget(connectionId)
} Try / catch
const UNAVAILABLE = /Remote connection dropped|No git provider for connection/
try {
return await invoke('git:status', { worktreePath, connectionId })
} catch (e) {
if (e instanceof Error && UNAVAILABLE.test(e.message)) {
connectionId = await reconnectSshTarget(targetId)
return invoke('git:status', { worktreePath, connectionId }) // one retry
}
throw e
} Prevention
- Drive git calls from the live connectionId held by the SSH session store, not a cached copy.
- On reconnect, invalidate cached connectionIds and refresh them.
- Back off status polling when the SSH target is known to be down.
When it happens
Trigger: Invoking ipcRenderer.invoke('git:status', { worktreePath, connectionId }) while the SSH connection for that connectionId has disconnected, been torn down, or was never registered. Also after a reconnect that produced a new provider/connectionId while the renderer still holds the stale id.
Common situations: SSH TCP session dropped by network sleep/resume; remote relay restarted; rapid branch/target switching racing with teardown; renderer holding a connectionId from before a reconnect.
Related errors
- No git provider for connection "${args.connectionId}"
- Remote connection dropped. Click Reconnect on the SSH target
- Clone failed: ${message}
- Translation request failed with status ${response.status}
- Unable to load source control
AI-assisted analysis of stablyai/orca@1136503c6a (2026-08-12).
Data as JSON: /api/errors/43b860a91d4a3c8c.
Report an issue: GitHub.