What might cause an ASP.Net Core web application to display hundreds of build errors suddenly without explanation? I started working on an app I had not worked on for awhile and when I clicked publish I got hundreds of build errors that never existed before.
Some were quite simple. Like this block of code used for a Blazor component (file extention .razor) that never had problems before. This block displays red squiggly lined underneath both instances of the string "crumbicon" I can think of no reason why there would be a problem with this:
@using PostAlmostAnything.Models
@crumbicon<a href="@GlobalStatic.SITEURL()">Home</a>
@code {
string crumbicon = "<<";
}
The exact errors say that there is "ambiguity between filename.crumbicon and filename.crumbicon "the type [blazor file name] already contains a definition for crumbicon". This error has never been encountered before, but now exists on every .razor file that was designed this way.
The other error appear related to various assemblies or variables on pages. They typically say that something has already been defined someplace else, but if the code were the problem then it would have been an error long ago and not suddenly.
When I try to update Nuget packages they say the updates are not compatible with version 3.1 of .Net Core.