Omnisharp-vscode: The .NET CLI tools cannot be located. .NET Core debugging will not be enabled.

Created on 28 Jun 2017  路  5Comments  路  Source: OmniSharp/omnisharp-vscode

Environment data

dotnet --info output:
'dotnet' is not recognized as an internal or external command, operable program or batch file.

VS Code version:
1.13.1

C# Extension version:
1.11.0

Steps to reproduce

Open C# file in Visual Code and install extension

Here's my user experience:
I opened a C# file for the first time in VS Code. It suggests I use the C# extension. Install the extension. The output window says:

Updating C# dependencies...
Platform: win32, x86_64

Downloading package 'OmniSharp (.NET 4.6 / x64)' (15622 KB) .................... Done!
Downloading package '.NET Core Debugger (Windows / x64)' (43510 KB) .................... Done!

Installing package 'OmniSharp (.NET 4.6 / x64)'
Installing package '.NET Core Debugger (Windows / x64)'

Finished
Failed to spawn 'dotnet --info'

Then I get a message:
The .NET CLI tools cannot be located. .NET Core debugging will not be enabled. Make su...
Disable this message in user settings
Get .NET CLI tools
Close

Should this work out of the box? Or is there some dependency that is missing that I need? The extension says it has no dependencies.

Debugger Question

Most helpful comment

Ok thank you that answers it I guess. Just found it to be an odd user experience for it to be an error upon install, but admittedly I didn't read the extension description which does have as it's first bullet point: "Lightweight development tools for .NET Core."

All 5 comments

@realuser Are you trying to do .NET Core debugging?

I don't know what that is so I'm going to say no. In what scenario would I want that?

There are three different versions of .NET which run on Windows computers --

  • Desktop (Full) Framework - this is the traditional version of .NET that has been around for a long time now. It offers stability and the widest possible API surface (example: it includes support for UI technologies of WinForms and WPF).
  • .NET Core - this is a newer version of .NET which is designed to be smaller (so it can work better in things like MicroServices), server/console-only, cross-platform and more command line friendly
  • Windows Store (a.k.a. UWP) .NET - if you are trying to make a Windows Store App, this is what you would use

VS Code support is mostly tailored to .NET Core. If this is what you want you need to install the .NET Core SDK.

If you want one of the other versions of .NET, you can certainly use this extension to provide editing, but I would recommend Visual Studio 2017 if you want a full IDE.

@realuser do you have any other questions, or can I close this?

Ok thank you that answers it I guess. Just found it to be an odd user experience for it to be an error upon install, but admittedly I didn't read the extension description which does have as it's first bullet point: "Lightweight development tools for .NET Core."

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mattwoberts picture mattwoberts  路  3Comments

tstivers1990 picture tstivers1990  路  3Comments

hamhub7 picture hamhub7  路  3Comments

olfek picture olfek  路  3Comments

visten picture visten  路  4Comments