One of our projects has a lot of issues that cause over thousand warnings right now. This leads to the problem that new warnings go unrecognized during development. Since we cannot solve all warnings through the whole code base right now, we decided to temporarily disable several types of warnings.
We added a
.editorconfig file and tried to disable some warnings using
[*.cs] dotnet_diagnostic.CS0219.severity = none dotnet_diagnostic.CS1998.severity = none dotnet_diagnostic.CS4014.severity = none dotnet_diagnostic.MVC1000.severity = none
This works exactly as intended for the first three rules, however the warnings with the code
MVC1000 still appear in the error list of Visual Studio 2019 (16.11.15). This is really strange, cause Visual Studio seems to read and understand the line in the
.editorconfig file, as it can be seen in the following screenshot:
Using the Visual Studio UI to change the severity also reflects in the
Does anyone have an idea why Visual Studio ignores this line, but not the other three lines? Is the reason for this somehow linked to the difference between rules defined by Visual Studio and rules defined by an analyzer? Is there any solution to this problem?