Scaffolding error the same as issue 25898 with latest version of VS2019
- Dominant language
- C#
- Stars
- 818
- Forks
- 260
- Avg merge
- 1d 8h
- Merged PRs (30d)
- 10
Description
### Describe the bug
When i use the Visual Studio 2019 Professional UI to add a scaffolding item, it reverts my Nuget packages to older versions and then fails. I'm attempting to add an Identity scaffolded item with .Net Core 5.0.2. When I right click on the project, and selected to add a new scaffolded item, then it tries to update dependencies. It then reverts my codegeneration.design to version 5.0.0-rc.1.20453.2. It also reverts EntityFrameworkCore.SqlServer and .Tools to the same version. I then get the same popup from issue 25898
### To Reproduce
Create a project.
Use as.net core web application template with authentication.
target .netcore 5.
try to add scaffolded item.
If you looked at the nuget packages before and after, you'll notice it downgrades some of them.
### Exceptions (if any)

before:

after:

### Further technical details
- ASP.NET Core version - 5.0.2
.NET SDK (reflecting any global.json):
Version: 5.0.102
Commit: 71365b4d42
Runtime Environment:
OS Name: Windows
OS Version: 10.0.18363
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\5.0.102\
Host (useful for support):
Version: 5.0.2
Commit: cb5f173b96
.NET SDKs installed:
5.0.102 [C:\Program Files\dotnet\sdk]
.NET runtimes installed:
Microsoft.AspNetCore.All 2.1.24 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.1.24 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.1.11 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 5.0.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 2.1.24 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.1.11 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 5.0.2 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 3.1.11 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 5.0.2 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
- The IDE (VS / VS Code/ VS4Mac) you're running on, and its version
-
Windows 10 Enterprise 1909
visual studio 2019 professional 16.8.4
Contributor guide
Assessment
This issue has not been assessed yet.