Reputation: 211
When I select "Debug > Start Debugging" I'm prompted for the environment and I select ".NET Core" but then nothing happens.
If I type"dotnet run" in the terminal window the program runs just fine.
"Help > About" displays the following;
Version: 1.33.1 (user setup)
Commit: 51b0b28134d51361cf996d2f0a1c698247aeabd8
Date: 2019-04-11T08:27:14.102Z
Electron: 3.1.6
Chrome: 66.0.3359.181
Node.js: 10.2.0
V8: 6.6.346.32
OS: Windows_NT x64 10.0.17134
EDIT:
I've tried the 32 and 64 bit versions of .NET Core and the corresponding System and User versions of vscode. In each instance I've tried running as Administrator and normally. I just don't think it's going to work on this machine.
I've done a similar install on Ubuntu and it worked the first time.
EDIT 2:
I finally managed to see this error, but I haven't been able to resolve it.
Cannot create .NET debug configurations. The OmniSharp server is still
initializing or has exited unexpectedly.
Upvotes: 8
Views: 14869
Reputation: 11
I had a similar issue when I hit f5 on a VSCode .net project. It asked me to select the debugger (.net core 5+ or .net framework). However nothing happened no matter what I tried. Clicking on the Debug icon on the left revealed a link to create a launch.json file. Clicking that link created the file and then I was able to debug. enter image description here
Upvotes: 1
Reputation: 4765
The debug freature is provided by the C# (ms-vscode.csharp) extension that uses omnisharp as back-end. So debug not working is probably because omnisharp is not working properly, which is maybe your omnisharp is still downloading (The download source is sometimes unstable) or there are some problems in your project files (csproj and sln files), or the SDK environment is not correctly configured.
If omnisharp is running, you can see the Omnisharp Log
item in the output window, otherwise check the C#
item, which may includes the downloading status of omnisharp. Check them and you may get how it is not working, or just paste the exact output logs for help.
Upvotes: 3