Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add folder to workspace on ssh host crashes the windows client #224565

Closed
filimonm opened this issue Aug 2, 2024 · 10 comments
Closed

add folder to workspace on ssh host crashes the windows client #224565

filimonm opened this issue Aug 2, 2024 · 10 comments
Assignees
Labels
*duplicate Issue identified as a duplicate of another issue(s)

Comments

@filimonm
Copy link

filimonm commented Aug 2, 2024

Does this issue occur when all extensions are disabled?: Yes

  • VS Code Version: 1.92.0 (system setup)
    Commit: b1c0a14
  • OS Version: Windows_NT x64 10.0.19045

Steps to Reproduce:

  1. Connect to an SSH host running Linux
  2. Open a folder
  3. Try to add another folder
  4. The VSCode window freezes and cannot even be closed
video_2024-08-02_13-13-36_01.mp4
@roblourens
Copy link
Member

Could you do

  • F1 > Set Log Level > Trace
  • Try this again, but check the Window log for errors in that time after you add the folder and are waiting

@roblourens roblourens added the info-needed Issue requires more information from poster label Aug 2, 2024
@roblourens
Copy link
Member

I do see something a bit odd on mac when trying this, there is a long pause after I try to add the folder, but then the window reloads properly. It seems like we've already shut down the local EH process at this point, but then I bet something is trying to resolve the remote authority (which it can't do without the extension in the local EH process)

I'd bet that if you create the .code-workspace file manually on your remote, you'd be able to open it though.

@vijaydhanraj
Copy link

Observe same issue when trying to connect to SSH host running Linux.

Once the frozen VS code window is killed and restarted, can see the workspace folder added but when trying to save the workspace, VS code freezes again. Needs another restart (kill frozen window and start VS code) to finally save the workspace. Ater this can open the saved workspace as usual.

@filimonm
Copy link
Author

filimonm commented Aug 6, 2024

I see this in the window exthost.log right after choosing the folder to add to the workspace:

2024-08-06 12:20:38.649 [info] Extension host terminating: renderer closed the MessagePort
2024-08-06 12:20:38.651 [trace] ExtHostCommands#executeCommand setContext
2024-08-06 12:20:38.651 [trace] ExtHostCommands#executeCommand _setContext
2024-08-06 12:20:38.658 [error] Canceled: Canceled
at new C (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:144:35204)
at E.U (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:151:6017)
at B..j.charCodeAt.R.CharCode.DollarSign.B. (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:151:3107)
at d.g (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:154:205942)
at d.executeCommand (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:154:205380)
at A.registerCommand.description (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:154:204704)
at d.h (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:154:206481)
at d.g (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:154:205473)
at d.executeCommand (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:154:205380)
at Object.executeCommand (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:164:23060)
at t.shutdown (c:\Users\Filimonm.vscode\extensions\ms-vscode-remote.remote-ssh-0.113.2024072315\out\extension.js:2:585555)
at e.deactivate (c:\Users\Filimonm.vscode\extensions\ms-vscode-remote.remote-ssh-0.113.2024072315\out\extension.js:2:854204)
at m.eb (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:160:9856)
at c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:160:7927
at Array.map ()
at m.$ (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:160:7914)
at m.terminate (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:160:8187)
at $.terminate (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:164:1513)
at o (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:177:10633)
at MessagePortMain. (c:\Program Files\Microsoft VS Code\resources\app\out\vs\workbench\api\node\extensionHostProcess.js:177:6825)
at MessagePortMain.emit (node:events:519:28)
at MessagePortMain._internalPort.emit (node:electron/js2c/utility_init:2:2285) setContext undefined
2024-08-06 12:20:38.658 [info] Extension host with pid 10224 exiting with code 0

exthost.log

@br-maurinn
Copy link

And here are the window logs when adding a folder to workspace

2024-08-05 12:04:31.340 [info] [remote-connection][Management ][1c14f…][reconnect] received socket timeout event (unacknowledgedMsgCount: 2, timeSinceOldestUnacknowledgedMsg: 20003, timeSinceLastReceivedSomeData: 20003).
2024-08-05 12:04:31.341 [info] [remote-connection][Management ][1c14f…][reconnect] starting reconnecting loop. You can get more information with the trace log level.
2024-08-05 12:04:31.342 [info] [remote-connection][Management ][1c14f…][reconnect] resolving connection...
2024-08-05 12:04:31.343 [info] Invoking resolveAuthority(ssh-remote)...
2024-08-05 12:04:31.348 [error] resolveAuthority(ssh-remote) returned an error after 1 ms Cannot resolve authority
2024-08-05 12:04:31.348 [error] [remote-connection][Management ][1c14f…][reconnect] An unknown error occurred while trying to reconnect, since this is an unknown case, it will be treated as a permanent error! Will give up now! Error:
2024-08-05 12:04:31.349 [error] Error: Cannot resolve authority
at Q.qb (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:3233:26944)
at Q.Pb (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:3235:2756)
at Q.pb (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:3233:26571)
at Q.ob (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:3233:26284)
at u.value (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:3235:4448)
at o.B (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:93:732)
at o.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:93:949)
at Object.getAddress (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:2324:25676)
at T (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:694:11442)
at W.z (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:694:16439)
at W.y (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:694:15537)
at u.value (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:694:15329)
at o.B (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:93:732)
at o.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:93:949)
at s.fire (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:123:15085)
at b.C (vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:123:19255)
at vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:123:19486
2024-08-05 12:04:31.349 [trace] DialogService#confirm Cannot reconnect. Please reload the window.

@jkwashbourne-oss
Copy link

Hi, any idea what is going on here? This has been happening to me for months. Previously the "Developer: reload window" would solve the problem but lately I need to kill vscode from task manager and restart. Any suggestions greatly appreciated, and thanks for your time!

@aeghnnsw
Copy link

I do see something a bit odd on mac when trying this, there is a long pause after I try to add the folder, but then the window reloads properly. It seems like we've already shut down the local EH process at this point, but then I bet something is trying to resolve the remote authority (which it can't do without the extension in the local EH process)

I'd bet that if you create the .code-workspace file manually on your remote, you'd be able to open it though.

I encountered similar issue and tried this, the window can't reload but when opened in a new window, it works.
I try to save the workspace in .code-workspace, it will fail to reload and crash, but the file is saved, once opened in a new window, and open the workspace from file, I can add folder to the workspace.

@johan-boule
Copy link

johan-boule commented Sep 28, 2024

You're lucky vscode even allows you to add a remote folder to a remote workspace.
In my case, it just says "path does not exist". I suspect vscode has totally lost the context and tries to look up the path locally.
So the only way workspaces can be properly managed is by editing the workspace file with vi.

@joshspicer joshspicer removed the info-needed Issue requires more information from poster label Oct 4, 2024
@joshspicer
Copy link
Member

joshspicer commented Dec 11, 2024

/duplicate microsoft/vscode-remote-release#10168

@vs-code-engineering vs-code-engineering bot added the *duplicate Issue identified as a duplicate of another issue(s) label Dec 11, 2024
Copy link

Thanks for creating this issue! We figured it's covering the same as another one we already have. Thus, we closed this one as a duplicate. You can search for similar existing issues. See also our issue reporting guidelines.

Happy Coding!

@vs-code-engineering vs-code-engineering bot closed this as not planned Won't fix, can't repro, duplicate, stale Dec 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
*duplicate Issue identified as a duplicate of another issue(s)
Projects
None yet
Development

No branches or pull requests

9 participants