Repository navigation
refactor(providers): delete the SSH git and filesystem providers and relay-only wiring - #27644
Merged
Merged
Conversation
added 2 commits
October 11, 2026 17:22
OrcaWin
force-pushed
the
OrcaWin/p399-B7
branch
from
October 12, 2026 00:27
b67f69f to
7d31820
Compare
OrcaWin
marked this pull request as ready for review
October 12, 2026 00:48
8 of 9 tasks
5 of 7 tasks
3 of 5 tasks
9 tasks done
7 of 9 tasks
This was referenced Oct 18, 2026
This was referenced Oct 22, 2026
Merged
8 of 9 tasks
8 of 9 tasks
11 tasks done
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
The old SSH relay is gone, but the code that used it to read files and run git on an SSH host was still here. Nothing ever switched that code on any more, so every call either did nothing or failed with "Remote connection dropped". This PR deletes that code and points each caller straight at the answer it was already getting.
What Changed
Before: about 50 places checked "is there an SSH git or file provider for this connection?" No production code registers one any more, so the answer was always no. Behind those checks sat the SSH git provider (about 1,200 lines), its stream readers, a direct-SSH "authority" check that always said no, a placeholder multiplexer lookup that always threw, and the code each of them fed: remote transcript readers, a remote disk-usage scan, SSH upload and download helpers, and the remote clipboard copy.
After: each caller does what it already did when the provider was missing:
SshHostNotServedError, with the same message as before ("Remote connection dropped…", or the "SSH Git provider is not available…" text for the PR and MR head fetches). Paths that used to quietly answer nothing still do: remote URL probes return null, template reads return an empty string, hook reads report an error, the workspace scan lists the stored rows, a media preview returns 404, and folder path status isunavailable.ipc/ssh.tsstops re-exporting the registry.ssh-target-registry.tslosesgetActiveMultiplexerand the direct-authority resolver, and the migration fence, the delta move and the conversion lose their direct-session guard. The guard was always false.ssh-git-*providers and dispatch,ssh-git-response-stream-reader,ssh-filesystem-stream-reader,ssh-file-stream-read-cap,ssh-plain-ssh-mode,shared/git-exec-mutation,workspace-space-remote-scan,worker-transcript-remote-{read,range-read},ssh-file-explorer-chunk-read,filesystem-import-ssh*,filesystem-download-folder(the channel stays registered and throws the typed error, likefs:downloadFile), andlocal-downloaded-folder-promotion. The tests and harness mocks that only covered these went with them.Kept on purpose:
providers/ssh-filesystem-dispatch.ts, cut to the four functions that the remote file-watcher code still calls (both the per-worktree watcher and the base-directory watcher). That watcher code is a bigger piece of its own (about 1k lines), tied into worktree removal, so it gets its own follow-up PR, and the table is deleted with it. Native chat's SSH transcript path parser also stays. Its two read functions now throw the typed error.Small changes on paths that already failed, all accepted for this phase:
fs:importExternalPaths,fs:resolveDroppedPathsForAgent) now throw the typed error right away. Before, they first checked the connection state, and they returned an empty result when no paths were given.Net: production −3,895 lines (+330/−4,225), tests −9,830 lines (+528/−10,358); 303 files.
Why
Per Phase 3.99 PR B7. Every arm deleted here was already dead: nothing calls
registerSsh{Git,Filesystem}ProviderorsetDirectSshAuthorityResolver, andgetActiveMultiplexeralways threw. Keeping the dead arms meant every new git or file caller copied a branch that could never run. We could have kept the provider modules as empty stubs, but then the dead branches would stay in place and look as if they could run. Deleting them means the compiler finds every remaining reader.Proof the code is dead:
rgacrosssrc,config,mobileandpackages, including all@ts-nocheckfiles, finds no reference to any deleted module or symbol.pnpm tc,build:electron-vite,build:cliandbuild:orcadall succeed.getActiveMultiplexercallers listed in the design's addendum were already removed by B4/B6. This PR deletes the function itself.Linked Issue
Phase 3.99 (owner-approved cleanup plan), PR B7.
Visual Proof
N/A. No UI change. Every touched path already failed or returned nothing for SSH hosts.
Testing
pnpm tc,pnpm lint(all ratchets OK),pnpm run check:code-quality:changed(0 new findings),build:electron-vite,build:cliandbuild:orcadall pass. All changed test files pass, plusorca-runtime.test.ts,src/main/window/,src/main/gitlab/and the filesystem IPC suites (264 files, 4,205 tests). Tests that only exercised a registered SSH provider are deleted. Where a test protected routing (no local fallback, the typed error, the host-scoped stored rows), it now asserts the not-served outcome or lists the stored rows.Review
Agent skill upstream boundary
Notes
fs:downloadFolderstays registered.unavailable, as it already did in production.runtime:) and cloud/mobile relay paths are untouched.Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred)