@heng19970427 Could you share which version of Windows you’re running? Also, are you using VS Code Insiders or Stable?
We haven’t seen this error before, so I’d love to make sure we have the right repro. Thanks!
FWIW I'm also seeing this and I'm on Windows 7.
@diminutivesloop Thanks for confirming! And you’re also using VS Code? Do you get this error the moment you try to share a new terminal?
If possible, could you run the “Live Share: Export Logs” command in VS Code and attach the resulting zip to this thread?
@heng19970427, @diminutivesloop also, what version of VSCode and Windows are you using? Logs from "Live Share: Export Logs" can help investigate the issue.
I'm using VSCode 1.23.0
live-share-logs.zip
@diminutivesloop The logs show that you most likely have this user setting:
"terminal.integrated.shell.windows": "Cmd.exe"
Live Share doesn't use %PATH% to search for the terminal shell and cannot find Cmd.exe.
To fix the issue, you need to specify the full path, e.g.
"terminal.integrated.shell.windows": "C:\\Windows\\system32\\cmd.exe"
Or you can remove terminal.integrated.shell.windows setting from the user settings, VSCode by default uses the full path.
On an unrelated note, please note that ANSI ESC sequences are not yet supported on Windows prior to Windows 10.
@IlyaBiryukov I see the same problem when using the WSL prompt even with a full path. "terminal.integrated.shell.windows": "C:\WINDOWS\System32\bash.exe"
@LongJohnCoder Please double check you have C:\WINDOWS\System32\bash.exe file. It's not there in default Windows 7 install (build 7601, SP1).
Does it work if you change it to "C:\\Windows\\system32\\cmd.exe" ?
Please also note double \\ are used to escape '\' chars in VSCode settings json.
OS: 10.0.17133
VS code: 1.23.1 Stable
logs.zip
I set "terminal.integrated.shell.windows": "C:\Windows\system32\cmd.exe",
it worked for me
@heng19970427 please use double \\ in the VSCode settings file, and ensure the path is correct and cmd.exe exists at that path.
"terminal.integrated.shell.windows": "C:\\Windows\\system32\\cmd.exe"
@IlyaBiryukov I am running Windows 10 and bash.exe exists (windows subsystem for linux is installed), but for some reason doesn't appear within Live Share's shared terminal..
Bash.exe does appear in a regular windows cmd.exe prompt as well as via View->Integrated Terminal with cmd.exe:
C:\>ver
Microsoft Windows [Version 10.0.17134.48]
C:\>dir C:\WINDOWS\System32\bash.exe
Volume in drive C is Win10NVME
Volume Serial Number is B86F-AF3E
Directory of C:\WINDOWS\System32
04/12/2018 03:32 AM 115,712 bash.exe
1 File(s) 115,712 bytes
0 Dir(s) 13,910,663,168 bytes free
However, when using cmd.exe from within Live Share Terminal, the file system does NOT have bash.exe... Is the shared terminal running inside a container or virtual file system? :
C:\>ver
Microsoft Windows [Version 10.0.17134.48]
C:\>dir c:\windows\System32\bash.exe
Volume in drive C is Win10NVME
Volume Serial Number is B86F-AF3E
Directory of c:\windows\System32
File Not Found
"terminal.integrated.shell.windows": "C:\\WINDOWS\\System32\\bash.exe" correctly launches via View->Integrated Terminal, but not Live Share's "Share Terminal". As an additional data point: "terminal.integrated.shell.windows": "C:\\WINDOWS\\System32\\cmd.exe" works correctly with Live Share's "Share Terminal".
Using the full path worked for me. However it would be nice if the default configuration for either Live Share or VSCode "just worked".
@diminutivesloop Agreed! It's a bug that we don't "just work", so we'll use this issue to track that improvement.
@LongJohnCoder I could reproduce the issue with bash.exe, we'll use #381 to track it.
This issue has been resolved with the 0.3.198 release that went out this afternoon. If folks could update to that, and let us know if they're still experiencing issues, that would be great. Thanks again for reporting this issue!