stablyai/orca · error · Error

Remote file upload is unavailable. Reconnect the SSH target

Error message

Remote file upload is unavailable. Reconnect the SSH target and retry.

What it means

Thrown by importExternalPathsSsh() after a provider is acquired when provider.openFileUploadSession is undefined. Upload sessions are an optional capability on IFilesystemProvider: not every transport can stream file uploads. The message mirrors the download-folder case and points the user at reconnecting, since a fresh full-capability provider normally registers openFileUploadSession.

Source

Thrown at src/main/ipc/filesystem-import-ssh.ts:54

    if (state.status === 'reconnecting') {
      throw new Error('SSH connection is reconnecting — please try again in a moment')
    }
    throw new Error('SSH connection is not active — please reconnect and try again')
  }

  const provider = requireSshFilesystemProvider(connectionId)

  if (options?.ensureDir) {
    // Why: terminal-drop staging needs `${worktree}/.orca/drops` to exist
    // before the first upload. .orca/ is reserved as Orca-owned remote state;
    // see docs/terminal-drop-ssh.md.
    await ensureDropStagingDir(provider, destDir, options.assertCurrent)
  }

  const results: ImportItemResult[] = []
  const reservedNames = new Set<string>()
  if (!provider.openFileUploadSession) {
    throw new Error('Remote file upload is unavailable. Reconnect the SSH target and retry.')
  }
  options?.assertCurrent?.()
  const uploadSession = await provider.openFileUploadSession()
  // Why: filename legality follows the remote filesystem, not the client's OS.
  const remotePathFlavor: RemotePathFlavor = isWindowsAbsolutePathLike(destDir)
    ? 'windows'
    : 'posix'
  try {
    for (const sourcePath of sourcePaths) {
      const result = await importOneSourceSsh(
        provider,
        uploadSession,
        sourcePath,
        destDir,
        reservedNames,
        remotePathFlavor,
        options?.assertCurrent
      )

View on GitHub (pinned to 1136503c6a)

Solutions

  1. Click Reconnect on the SSH target to rebuild a provider that supports openFileUploadSession.
  2. If reconnect still lacks the capability, the chosen transport cannot accept uploads — use a supported transport or create the files remotely another way.
  3. Confirm the host-side Orca component version supports upload sessions before retrying.
Defensive patterns

Strategy: retry

Validate before calling

// Confirm the provider supports upload sessions before importing
import { getSshFilesystemProvider } from '../providers/ssh-filesystem-dispatch'
function providerCanUpload(connectionId: string): boolean {
  const p = getSshFilesystemProvider(connectionId)
  return !!p && typeof p.openFileUploadSession === 'function'
}

Type guard

function providerSupportsUpload(p: unknown): p is { openFileUploadSession: () => Promise<unknown> } {
  return !!p && typeof (p as any).openFileUploadSession === 'function'
}

Try / catch

try {
  await importExternalPathsSsh(sources, dest, connectionId, opts)
} catch (e) {
  if (e instanceof Error && /upload is unavailable/i.test(e.message)) {
    await reconnectSshTarget(connectionId) // rebuild a full-capability provider, then retry
  } else throw e
}

Prevention

When it happens

Trigger: requireSshFilesystemProvider returns a provider whose openFileUploadSession capability is absent — a limited/relay/system-SSH transport variant, or a provider registered during a degraded reconnect.

Common situations: Reconnect negotiated a transport that lacks upload session support; client/host capability version skew; the connection is using a fallback SSH transport (ProxyJump/FIDO2/system-SSH) that did not wire upload sessions.

Related errors


AI-assisted analysis of stablyai/orca@1136503c6a (2026-08-12). Data as JSON: /api/errors/119b2e8e8b84120b. Report an issue: GitHub.