'dotnet new console' fails with '2.0.0-preview3-006607' .NET Command Line Tools
See original GitHub issueSteps to reproduce
dotnet new console
Expected behavior
No error and successfully restored
Actual behavior
PS:52> dotnet new console
The template "Console Application" was created successfully.
Processing post-creation actions...
Running 'dotnet restore' on C:\Arena\Apps\dotnet2\bb\bb.csproj...
Restoring packages for C:\Arena\Apps\dotnet2\bb\bb.csproj...
C:\Users\usr\AppData\Local\Microsoft\dotnet\sdk\2.0.0-preview3-006607\NuGet.targets(102,5): error :
Failed to retrieve information about 'Microsoft.NETCore.App' from remote source 'C:\Users\usr\.dotnet\NuGetFallbackFolder'. [C:\Arena\Apps\dotnet2\bb\bb.csproj]
Restore failed.
Post action failed.
Description: Restore NuGet packages required by this project.
Manual instructions: Run 'dotnet restore'
PS:53> dotnet restore
Restoring packages for C:\Arena\Apps\dotnet2\bb\bb.csproj...
C:\Users\usr\AppData\Local\Microsoft\dotnet\sdk\2.0.0-preview3-006607\NuGet.targets(102,5): error :
Failed to retrieve information about 'Microsoft.NETCore.App' from remote source 'C:\Users\usr\.dotnet\NuGetFallbackFolder'. [C:\Arena\Apps\dotnet2\bb\bb.csproj]
Environment data
dotnet --info
output:
.NET Command Line Tools (2.0.0-preview3-006607)
Product Information:
Version: 2.0.0-preview3-006607
Commit SHA-1 hash: 81dd304f72
Runtime Environment:
OS Name: Windows
OS Version: 10.0.15063
OS Platform: Windows
RID: win10-x64
Base Path: C:\Users\usr\AppData\Local\Microsoft\dotnet\sdk\2.0.0-preview3-006607\
Microsoft .NET Core Shared Framework Host
Version : 2.0.0-preview3-25426-01
Build : 122309e7e7fb9bb233fe4910f822c28ec73f0957
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:8 (3 by maintainers)
Top Results From Across the Web
Troubleshoot .NET tool usage issues
A common reason for failure is that the tool name isn't correct. This can happen because of mistyping, or because the tool has...
Read more >'dotnet new console' fails to restore nuget packa #8325
Run 'dotnet new console -n console1' from an admin cmd prompt. Expected behavior. Nuget packages are restored during the creation process ...
Read more >dotnet new console fails to create when being built within a ...
All I want to do right now is create a new hello world console project and run it with a mapped directory. This...
Read more >Dotnet new console error in vs code. : r/csharp
I get this error: It was not possible to find any installed .NET Core SDKs. Did you mean to run .NET Core SDK...
Read more >Getting started: .NET Core with command line > xUnit.net
Create the unit test project. From the command line, create a folder for your test project, change into it, and then create the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@JonathanLoscalzo, look under %appdata%/NuGet/NuGet.Config and remove any references to CLIFallbackFolder from it. This is an entry that we no longer need in preview3. If you do that, you will get the real error, which is that we can’t find the M.NC.App package. The reason for that is that the runtime between the CLI and asp.net are out of sync and when that happens, you need the feed above.
Still, I am moving this issue to NuGet, I don’t think NuGet should say that it failed to find the package on that feed if the folder is empty, it should just say that it failed to find the package.
@livarcocc Could you please comment? Moving the NuGet.config file to the same folder doesn’t work for me, and I see the same problem with
2.0.0-preview3-006609
. This is on a win10 clean machine without%appdata%/NuGet
folder.