templating icon indicating copy to clipboard operation
templating copied to clipboard

The reference to System.Commandline for Microsoft.TemplateEngine.Authoring.TemplateVerifier is invalid

Open ghost opened this issue 3 years ago • 9 comments

Product

dotnet CLI & Visual Studio

Describe The Bug

When I try to add the following package Microsoft.TemplateEngine.Authoring.TemplateVerifier I get the following error

Error	NU1102	Unable to find package System.CommandLine with version (>= 2.0.0-beta4.22613.1)
  - Found 29 version(s) in nuget.org [ Nearest version: 2.0.0-beta4.22272.1 ]

Actually, the latest version of System.CommandLine is 2.0.0-beta4.22272.1 and I believe the version you use in the config is wrong.

To Reproduce

Steps:

  1. Make a MS Test project with .net 7
  2. Try to add Microsoft.TemplateEngine.Authoring.TemplateVerifier as nugget package to the project
  3. You get an error

dotnet Info

output

Visual Studio Version

17.5.1

Additional context

No response

ghost avatar Mar 08 '23 22:03 ghost

Hi @vashdigital ,

Thank you for reporting this issue. We are taking a look.

YuliiaKovalova avatar Mar 09 '23 10:03 YuliiaKovalova

The issue was fixed in release/7.0.2xx .

Feel free to comment on the ticket if you have other questions.

YuliiaKovalova avatar Mar 10 '23 09:03 YuliiaKovalova

@YuliiaKovalova I still get the error installing the 7.0.201 version.

NuGet\Install-Package Microsoft.TemplateEngine.Authoring.TemplateVerifier -Version 7.0.201 Restoring packages for C:\dev\TemplateTests\TemplateTests.csproj... GET https://api.nuget.org/v3-flatcontainer/system.commandline/index.json OK https://api.nuget.org/v3-flatcontainer/system.commandline/index.json 136ms NuGet\Install-Package : NU1102: Unable to find package System.CommandLine with version (>= 2.0.0-beta4.22613.1)

  • Found 29 version(s) in nuget [ Nearest version: 2.0.0-beta4.22272.1 ] At line:1 char:1
  • NuGet\Install-Package Microsoft.TemplateEngine.Authoring.TemplateVeri ...
  •   + CategoryInfo          : NotSpecified: (:) [Install-Package], Exception
      + FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
    

togglecode avatar Mar 15 '23 09:03 togglecode

@togglecode , the fix will be available in release/7.0.203

YuliiaKovalova avatar Mar 15 '23 09:03 YuliiaKovalova

@YuliiaKovalova any idea, when it will be released?

togglecode avatar Mar 15 '23 10:03 togglecode

It is planned to make it available next month

YuliiaKovalova avatar Mar 15 '23 11:03 YuliiaKovalova

@YuliiaKovalova so is there no way meanwhile to use it? Any workarounds or alternatives?

togglecode avatar Mar 15 '23 12:03 togglecode

+1 to @togglecode , how we can workaround this issue?

siyavash1984 avatar Mar 15 '23 20:03 siyavash1984

As a workaround, you can get the latest daily build of Microsoft.TemplateEngine.Authoring.TemplateVerifier from https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet7/nuget/v3/index.json (public feed) or connect to to https://dev.azure.com/dnceng/public/_artifacts/feed/dotnet-libraries to restore missing System.CommandLine package.

vlada-shubina avatar Mar 16 '23 10:03 vlada-shubina