microsoft / vscode-remote-release

Visual Studio Code Remote Development: Open any folder in WSL, in a Docker container, or on a remote machine using SSH and take advantage of VS Code's full feature set.
https://aka.ms/vscode-remote
Other
3.68k stars 296 forks source link

"stream is closed" error prevents anything related to Dev Containers #10374

Closed siblount closed 3 weeks ago

siblount commented 1 month ago

Type: Bug

I was working inside of a dev container, closed VS Code, came back and it just no longer works.

I tried restarting VS Code, restarting Docker engine, clearing anything docker related. No dice!

I've confirmed it's not my dev container config, since it works on my other laptop and on Codespaces.

I believe it uses Docker in WSL 2 for windows ofc.

Log for previous attempt:

[2024-10-09T13:55:58.920Z] Dev Containers 0.388.0 in VS Code 1.94.1 (e10f2369d0d9614a452462f2e01cdc4aa9486296).
[2024-10-09T13:55:58.920Z] Start: Run: wsl -l -v
[2024-10-09T13:55:59.046Z] Stop (126 ms): Run: wsl -l -v
[2024-10-09T13:55:59.047Z] Start: Run: wsl -d docker-desktop -e wslpath -u d:\Github Clones\reimagined-couscous
[2024-10-09T13:55:59.460Z] Stop (413 ms): Run: wsl -d docker-desktop -e wslpath -u d:\Github Clones\reimagined-couscous
[2024-10-09T13:55:59.492Z] Start: Run: wsl -d docker-desktop -e /bin/sh -c cd '/tmp/docker-desktop-root/run/desktop/mnt/host/d/Github Clones/reimagined-couscous' && /bin/sh
[2024-10-09T13:55:59.512Z] Start: Run in host: id -un
[2024-10-09T13:55:59.567Z] root
[2024-10-09T13:55:59.567Z] 
[2024-10-09T13:55:59.567Z] Stop (55 ms): Run in host: id -un
[2024-10-09T13:55:59.568Z] Start: Run in host:  (command -v getent >/dev/null 2>&1 && getent passwd 'root' || grep -E '^root|^[^:]*:[^:]*:root:' /etc/passwd || true)
[2024-10-09T13:55:59.569Z] Stop (1 ms): Run in host:  (command -v getent >/dev/null 2>&1 && getent passwd 'root' || grep -E '^root|^[^:]*:[^:]*:root:' /etc/passwd || true)
[2024-10-09T13:55:59.569Z] Start: Run in host: echo ~
[2024-10-09T13:55:59.570Z] /root
[2024-10-09T13:55:59.570Z] 
[2024-10-09T13:55:59.570Z] Stop (1 ms): Run in host: echo ~
[2024-10-09T13:55:59.570Z] Start: Run in host: test -f '/root/.vscode-server/cli/servers/Stable-e10f2369d0d9614a452462f2e01cdc4aa9486296/server/node'
[2024-10-09T13:55:59.571Z] 
[2024-10-09T13:55:59.571Z] 
[2024-10-09T13:55:59.571Z] Exit code 1
[2024-10-09T13:55:59.571Z] Stop (1 ms): Run in host: test -f '/root/.vscode-server/cli/servers/Stable-e10f2369d0d9614a452462f2e01cdc4aa9486296/server/node'
[2024-10-09T13:55:59.571Z] Start: Run in host: test -f '/root/.vscode/cli/servers/Stable-e10f2369d0d9614a452462f2e01cdc4aa9486296/server/node'
[2024-10-09T13:55:59.573Z] 
[2024-10-09T13:55:59.574Z] 
[2024-10-09T13:55:59.574Z] Exit code 1
[2024-10-09T13:55:59.574Z] Stop (3 ms): Run in host: test -f '/root/.vscode/cli/servers/Stable-e10f2369d0d9614a452462f2e01cdc4aa9486296/server/node'
[2024-10-09T13:55:59.574Z] Start: Run in host: test -f '/root/.vscode-server/bin/e10f2369d0d9614a452462f2e01cdc4aa9486296/node'
[2024-10-09T13:55:59.574Z] 
[2024-10-09T13:55:59.574Z] 
[2024-10-09T13:55:59.575Z] Exit code 1
[2024-10-09T13:55:59.575Z] Stop (1 ms): Run in host: test -f '/root/.vscode-server/bin/e10f2369d0d9614a452462f2e01cdc4aa9486296/node'
[2024-10-09T13:55:59.575Z] Start: Run in host: test -f '/root/.vscode-remote-containers/bin/e10f2369d0d9614a452462f2e01cdc4aa9486296/node'
[2024-10-09T13:55:59.575Z] 
[2024-10-09T13:55:59.576Z] 
[2024-10-09T13:55:59.576Z] Stop (1 ms): Run in host: test -f '/root/.vscode-remote-containers/bin/e10f2369d0d9614a452462f2e01cdc4aa9486296/node'
[2024-10-09T13:55:59.576Z] Start: Run in host: test -f '/root/.vscode-remote-containers/bin/e10f2369d0d9614a452462f2e01cdc4aa9486296/node_modules/node-pty/package.json'
[2024-10-09T13:55:59.576Z] 
[2024-10-09T13:55:59.577Z] 
[2024-10-09T13:55:59.577Z] Stop (1 ms): Run in host: test -f '/root/.vscode-remote-containers/bin/e10f2369d0d9614a452462f2e01cdc4aa9486296/node_modules/node-pty/package.json'
[2024-10-09T13:55:59.577Z] Start: Run in host: test -f '/root/.vscode-remote-containers/dist/vscode-remote-containers-server-0.388.0.js'
[2024-10-09T13:55:59.577Z] 
[2024-10-09T13:55:59.578Z] 
[2024-10-09T13:55:59.578Z] Stop (1 ms): Run in host: test -f '/root/.vscode-remote-containers/dist/vscode-remote-containers-server-0.388.0.js'
[2024-10-09T13:55:59.579Z] Host server: /bin/sh: /root/.vscode-remote-containers/bin/e10f2369d0d9614a452462f2e01cdc4aa9486296/node: not found
[2024-10-09T13:55:59.580Z] userEnvProbe: loginInteractiveShell (default)
[2024-10-09T13:55:59.580Z] userEnvProbe: not found in cache
[2024-10-09T13:55:59.580Z] userEnvProbe shell: /bin/sh
[2024-10-09T13:55:59.614Z] Error reading shell environment.
[2024-10-09T13:55:59.614Z] Error: stream ended with:0 but wanted:9
    at l (c:\Users\Solomon\.vscode\extensions\ms-vscode-remote.remote-containers-0.388.0\dist\extension\extension.js:27:22149)
    at c:\Users\Solomon\.vscode\extensions\ms-vscode-remote.remote-containers-0.388.0\dist\extension\extension.js:27:22330
    at s (c:\Users\Solomon\.vscode\extensions\ms-vscode-remote.remote-containers-0.388.0\dist\extension\extension.js:30:5371)
    at Socket.<anonymous> (c:\Users\Solomon\.vscode\extensions\ms-vscode-remote.remote-containers-0.388.0\dist\extension\extension.js:30:5541)
    at Socket.emit (node:events:531:35)
    at Socket.emit (node:domain:488:12)
    at endReadableNT (node:internal/streams/readable:1696:12)
    at processTicksAndRejections (node:internal/process/task_queues:82:21)
[2024-10-09T13:55:59.615Z] Stop (123 ms): Run: wsl -d docker-desktop -e /bin/sh -c cd '/tmp/docker-desktop-root/run/desktop/mnt/host/d/Github Clones/reimagined-couscous' && /bin/sh
[2024-10-09T13:55:59.615Z] Host server terminated (code: 127, signal: null).

Log inside dev container: devcontainerlog.log

Extension version: 0.388.0 VS Code version: Code 1.94.1 (e10f2369d0d9614a452462f2e01cdc4aa9486296, 2024-10-05T05:44:32.189Z) OS version: Windows_NT x64 10.0.22631 Modes:

System Info |Item|Value| |---|---| |CPUs|AMD Ryzen 9 5900X 12-Core Processor (24 x 3700)| |GPU Status|2d_canvas: enabled
canvas_oop_rasterization: enabled_on
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_graphite: disabled_off
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled
webnn: disabled_off| |Load (avg)|undefined| |Memory (System)|127.91GB (106.61GB free)| |Process Argv|--folder-uri file:///d%3A/Github%20Clones/reimagined-couscous --crash-reporter-id 59979b9a-4685-4cb7-b62d-eaaf880c2f57| |Screen Reader|no| |VM|0%|
A/B Experiments ``` vsliv368cf:30146710 vspor879:30202332 vspor708:30202333 vspor363:30204092 vscod805cf:30301675 binariesv615:30325510 vsaa593cf:30376535 py29gd2263:31024239 c4g48928:30535728 azure-dev_surveyone:30548225 2i9eh265:30646982 962ge761:30959799 pythongtdpath:30769146 pythonnoceb:30805159 asynctok:30898717 pythonmypyd1:30879173 h48ei257:31000450 pythontbext0:30879054 accentitlementsc:30995553 dsvsc016:30899300 dsvsc017:30899301 dsvsc018:30899302 cppperfnew:31000557 dsvsc020:30976470 pythonait:31006305 dsvsc021:30996838 9c06g630:31013171 a69g1124:31058053 dvdeprecation:31068756 dwnewjupyter:31046869 2f103344:31071589 impr_priority:31102340 nativerepl2:31139839 refactort:31108082 pythonrstrctxt:31112756 flighttreat:31134774 wkspc-onlycs-t:31132770 wkspc-ranged-t:31151552 cf971741:31144450 autoexpandse:31146404 notype1cf:31151524 cc771715:31146322 ```
joshspicer commented 1 month ago

Do you happen to be using the same nvidea device shared in https://github.com/microsoft/vscode-remote-release/issues/10284 (seeing similar error messages)

siblount commented 1 month ago

No, I have a NVIDIA RTX 3090 Desktop GPU (no iGPU) with driver version 551.23

siblount commented 1 month ago

Any idea on what might be causing this?

chrmarti commented 1 month ago

This also (like #10284) starts with:

Host server: /bin/sh: /root/.vscode-remote-containers/bin/e10f2369d0d9614a452462f2e01cdc4aa9486296/node: not found

One difference is that this tries to run node in WSL ("Host server"), #10284 shows the same error for the container.

chrmarti commented 1 month ago

@siblount Could you check you are on the latest Docker Desktop for Windows? (I currently get 4.34.3.)

siblount commented 1 month ago

I am currently on the latest version of Docker Desktop (v4.35.0) and I still get 'stream is closed' errors.

Here is what the container log looks like:

10-24-2024-devcontainer-containerlog.txt

chrmarti commented 1 month ago

It is using the docker CLI in the docker-desktop WSL distro for a folder on drive D: which is a bit unexpected.

Could you check what the default distro is with wsl -l -v? The default will have an asterisk *. Make sure this is not docker-desktop, but a regular distribution like Ubuntu / Debian.

vs-code-engineering[bot] commented 3 weeks ago

This issue has been closed automatically because it needs more information and has not had recent activity. See also our issue reporting guidelines.

Happy Coding!