-1

VS 2019 .NetCore 3.1

I regularly keep the NuGet packages upto date. But for some reason, this time (all V5.0.0) fail to install.

It's saying they are not compatible. I've not experienced this before. Why is it listing the updates if they are not for .NET Core 3.1? Are others experiencing this? Also, it does seem a bit of a jump from 3.1.9 -> 5.0.0 when I am upgrading them about once a week.

enter image description here enter image description here

Rob L
  • 2,124
  • 3
  • 22
  • 50
  • It is a double question. Check these posts - https://stackoverflow.com/questions/64792261/can-i-update-to-net-5-nuget-packages-even-if-im-using-net-core-3-1/64794340?noredirect=1#comment114561787_64794340 – Serge Nov 12 '20 at 15:56
  • 1
    As lan Kemp told you, [dotnet core 5](https://dotnet.microsoft.com/download/dotnet/5.0) is released 2 days ago and these nuget packages are compatible with new version of dotnet core (v5). So, if you like, you can immigrate to v5 as [this article](https://learn.microsoft.com/en-us/aspnet/core/migration/31-to-50?view=aspnetcore-5.0&tabs=visual-studio) explained how to. – Jab Nov 12 '20 at 15:04
  • Check these posts too - https://stackoverflow.com/questions/64792261/can-i-update-to-net-5-nuget-packages-even-if-im-using-net-core-3-1/64794340?noredirect=1#comment114561787_64794340 – Serge Nov 12 '20 at 15:57
  • Jab, Thank you. I'll look at the article. – Rob L Nov 12 '20 at 22:50
  • Sergey, I think those two were posted at the same time. – Rob L Nov 13 '20 at 00:38

1 Answers1

0

Upgrading to .NET 5.0 (followed by updating the NuGet packages) fixed the issue. In my case, it was simply a matter of replacing all:

<TargetFramework>netcoreapp3.1</TargetFramework>

with:

<TargetFramework>net5.0</TargetFramework>

throughout the whole of the solution. Thanks for the heads up.

Rob L
  • 2,124
  • 3
  • 22
  • 50