Closed acastaner closed 7 years ago
@acastaner Just to be clear. This happens only and as soon as you open a C# file? Like you are happily working in a TypeScript file (with IntelliSense et al) and then when you open a C# file it crashes?
Yes you are correct. I have tried with the reStructuredText and PowerShell extensions and they don't crash the window. Only the C# extension does.
@DustinCampbell anything special you guys do on activate which might cause trouble on win7?
On activation, the C# extension tries to acquire OmniSharp
Is there anything I can do to help troubleshoot this (log file, debug mode, ...) ?
Just found another extension that crashes: Go (https://marketplace.visualstudio.com/items?itemName=lukehoban.Go)
As soon as I open a Go file I get the same error as with C#. Still no problem with reStructuredText or PowerShell extensions.
All on windows 7? They all start external processes to do the real work, maybe something on your machine isn't happy with that. Can you open the Omnisharp Log (View > Output > Omnisharp) and also the console from dev tools? (F1 > Developer Tool)
Yes, all on the Windows 7 Pro PC.
The Output > Extensions output window shows nothing (it's just empty). The console shows the same errors as the window:
Extension host terminated unexpectedly. Please reload the window to recover. Extension host terminated unexpectedly. Code: 3221225477 Signal: null Error from the extension host: channel closed
Nothing in Output > Omnisharp Log
?
Unfortunately no. The Output window only lists "Extensions", "Git" and "Tasks" : http://imgur.com/WyczdxC
I definitively have C# installed though: http://imgur.com/YDglUif
That is very interesting... It seems to crash already when loading the extension. Do you see C#
in the little language indicator at the bottom (that makes sure the static part of the extension gets loaded)? Also can you check if there a the Restart OmniSharp
command in the F1 palette, iff so restart without having a file open and just run the command.
Yes, I do have the Restart OmniSharp command. When I executed it I got these messages:
Error from the extension host: channel closed
Extension host terminated unexpectedly. Please reload the window to recover.
Error from the extension host: write EPIPE
I don't see C#
in the language indicator at the bottom, but I do notice that the status bar says Downloading and configuring .NET Core Debugger
and that seems to be what gets stuck.
@DustinCampbell Is there a way to start omnisharp without it downloading the debugger etc?
Not that I know of. However, note that the Go extension is reported as crashing as well. Perhaps that will be easier to investigate?
yeah, there must be something wrong when spawning processes, tho not on all. @joaomoreno you mentioned something today during the standup
That issue ended up being Code's shared process failure to launch with a broken VSCODE_NLS_CONFIG
value: #6375. Doesn't seem related.
@acastaner could you try launching the processes that the extensions launch, but manually from a command line?
What process would that be? Because dotnet
is already installed works just fine from the command line so I'm not sure what VSCode actually calls and with which parameters.
@DustinCampbell can help you out with that.
The extension attempts to download and untar OmniSharp to ~/.vscode/extensions/ms-vscode.csharp.0.3.7/.omnisharp and launches the OmniSharp process from there.
For the debugger, the extension generates a project.json file in ~/.vscode/extensions/ms-vscode.csharp.0.3.7/coreclr-debug. It then launches "dotnet restore" with the generated project.json to acquire the debugger bits.
However, the extension creates two OutputChannels during this installation process: one for the debugger ("coreclr-debug") and one for OmniSharp ("OmniSharp Log"). I find it strange that neither of these appear as @acastaner reported above. This happens very early in the extension activation. I also find it strange that the Go extension fails as well.
@jrieken, @joaomoreno, any ideas?
Just noticed something from a comment above:
Extension host terminated unexpectedly. Code: 3221225477 Signal: null
electron/electron#3570 says that 3221225477
is a really ugly crash, as in segfault or access violation.
I was thinking about this yesterday and remembered that I have two context menu icons for VSCode. One is from one of the early build that I guess didn't uninstall/unregister correctly (same with Atom, as you can see) :
Could it be that OmniSharp (and Go) is somehow trying to use that one, but since it doesn't exist anymore it fails? Probably not that but just a thought.
Just upgraded to version 1.3.1 and still have the issue. I see that it's flagged with "needs more info." Any suggestion on what information is needed to help find the root cause?
E: I just noticed that the error message is slightly different in 1.3.1. Now I get this:
Error from the extension host: write EPIPE
Closing this because we never understood this issue and because time has passed and we believe things are better now
Throwing in my two cents here. I recently relabeled my drive that I work in from G: to E: which then made Code throw this "Extension host terminated unexpectedly" at me while editing some JS. It seems like Code (or some extension I have) is dependant on the labeling of drives.
Whenever I open a C# file in VS Code, I get two error messages:
"Extension host terminated unexpectedly. Please reload the window to recover. [Reload Window]" Followed by "Error from the extension host: channel closed."
I'm using the CSharp extension (ms-vscode.csharp-0.3.7). Here's a screenshot:
https://imgur.com/8dGJuWK
Steps to Reproduce:
Now the problem is, this issue happens only on one of my PCs (the one actually owned by my employer). The main differences with the other PCs I own are:
There are other differences of course, but these are the three biggest I can think of.