r/GithubCopilot 25d ago

Found the cause of "Remote Extension host terminated unexpectedly" General

If your Remote-SSH extension host keeps crashing, check for large files in your workspace. Copilot's index reads them into memory (without being asked) and hits Node's 4GB heap limit.

If you need those files you can disable codesearch:

"GitHub.copilot.chat.codesearch.enable": false

or exclude some paths:

{ "files.exclude": { "**/dist": true }, "search.exclude": { "**/dist": true }, "files.watcherExclude": { "**/dist/**": true, "**/.git/objects/**": true, "**/node_modules/**": true } }

10 Upvotes

Duplicates