Files
vscode/cli
Nikolai Zakharov 016f6a1848 fix(cli): self-heal missing execute permission on server binary
When the VS Code server binary is extracted without execute permissions
or loses them (e.g. on network filesystems, after interrupted downloads,
or when copied without preserving permissions), spawning the server fails
with 'Permission denied'. The previous code treated this as generic
'ServerUnexpectedExit' corruption, triggering a useless re-download loop
that never fixes the actual problem.

Changes:
- Add ensure_executable() helper that checks and restores +x on Unix
  before attempting to spawn the server binary.
- Add ServerNotExecutable error variant so permission failures are
  reported clearly instead of being lumped into ServerUnexpectedExit.
- Skip the 'evict on corruption' logic for permission errors, since
  re-downloading cannot fix a filesystem permission issue.

Fixes the root cause where VS Code Remote-SSH shows generic connection
failure popups while the actual error ('Permission denied on server
binary') is hidden in remote logs.
2026-05-18 20:08:40 +08:00
..