Skip to main content

273 posts tagged with "Fixes"

Fixes for Common Issues and Errors

View All Tags

Fixed: "NU1903: Warning As Error: Package 'Newtonsoft.Json' 12.0.3 has a known high severity vulnerability"

· 7 min read
Jagdish Kumawat
Founder @ Dewiride

error NU1903: Warning As Error: Package 'Newtonsoft.Json' 12.0.3 has a known high severity vulnerability, https://github.com/advisories/GHSA-5crp-9r3c-p9vr NuGet's built-in audit found a published security advisory for a package version the project uses, and because warnings were errors, restore stopped. The fix is one version change. Getting there took me two failed attempts first, and both are worth knowing.

Fixed: "System.IO.IOException: Failed to bind to address http://127.0.0.1:5190: address already in use." in ASP.NET Core

· 7 min read
Jagdish Kumawat
Founder @ Dewiride

System.IO.IOException: Failed to bind to address http://127.0.0.1:5190: address already in use. The app is fine; the port isn't free. Something else, very often another copy of the same app, is already listening on it. Here's how I found what held the port, stopped it cleanly, and when to pick another port instead.

Fixed: "error NU1109: Detected package downgrade: Microsoft.EntityFrameworkCore.Relational from 10.0.12 to centrally defined 10.0.11"

· 5 min read
Jagdish Kumawat
Founder @ Dewiride

error NU1109: Detected package downgrade: Microsoft.EntityFrameworkCore.Relational from 10.0.12 to centrally defined 10.0.11. Update the centrally managed package version to a higher version. In a solution with Central Package Management and transitive pinning, the central file asked for an older version of a package than one of the dependencies needs. The two lines under the message show exactly who wants what.

Fixed: "NU1202: Package Microsoft.EntityFrameworkCore 11.0.0-rc.3 is not compatible with net10.0"

· 6 min read
Jagdish Kumawat
Founder @ Dewiride

error: NU1202: Package Microsoft.EntityFrameworkCore 11.0.0-rc.3.26522.148 is not compatible with net10.0 (.NETCoreApp,Version=v10.0). Package Microsoft.EntityFrameworkCore 11.0.0-rc.3.26522.148 supports: net11.0 (.NETCoreApp,Version=v11.0) The package was fine, and so was the project; they were made for different .NET versions. The message names both, and dotnet package add refused before it changed anything.

Fixed: "error CS0246: The type or namespace name 'Dewiride' could not be found (are you missing a using directive or an assembly reference?)"

· 7 min read
Jagdish Kumawat
Founder @ Dewiride

error CS0246: The type or namespace name 'Dewiride' could not be found (are you missing a using directive or an assembly reference?) The compiler ends the message with a question, and it's a good one: those are the two usual causes. The name in quotes and the line number tell you which one you have. Here are both, from the same .NET 10 project, and the fix for each.

Fixed: "MSB1011: Specify which project or solution file to use because this folder contains more than one project or solution file."

· 7 min read
Jagdish Kumawat
Founder @ Dewiride

MSBUILD : error MSB1011: Specify which project or solution file to use because this folder contains more than one project or solution file. I got it from a plain dotnet build, seconds after converting a solution to the new .slnx format. The conversion had worked; it had also left two solution files in one folder, and MSBuild won't guess which one you mean.

Fixed: EF Core UseCollation() Doesn't Change the MySQL Column Collation with Oracle's MySql.EntityFrameworkCore

· 10 min read
Jagdish Kumawat
Founder @ Dewiride

I gave a column a case-sensitive collation with EF Core's UseCollation("utf8mb4_0900_as_cs"), created the migration, applied it, and dotnet ef printed Done. The column was still utf8mb4_0900_ai_ci, and MySQL still refused desks as a duplicate of Desks. Oracle's MySQL provider for EF Core leaves UseCollation out of the SQL it generates. Here's how I found that, what Oracle documents instead, and the migration that does change the column.

Fixed: "Failure processing application bundle. DOTNET_BUNDLE_EXTRACT_BASE_DIR is not set, and a read-write cache directory couldn't be created."

· 8 min read
Jagdish Kumawat
Founder @ Dewiride

I built an EF Core migrations bundle, ran it, and got three lines instead of migrations: Failure processing application bundle. Failed to determine location for extracting embedded files. DOTNET_BUNDLE_EXTRACT_BASE_DIR is not set, and a read-write cache directory couldn't be created. The bundle was fine. The folder it extracts into, ~/.net, had belonged to root since 2023.

Fixed: "The migration '…_MakeDescriptionRequired' has already been applied to the database. Revert it and try again." in EF Core

· 7 min read
Jagdish Kumawat
Founder @ Dewiride

The migration '20261103044430_MakeDescriptionRequired' has already been applied to the database. Revert it and try again. If the migration has been applied to other databases, consider reverting its changes using a new migration instead. dotnet ef migrations remove checks the database before it deletes anything, and this migration was in it. The message holds both fixes: one for your own development database, one for every other database.