Ignore Issues on Multiple Criteria is not working for external_roslyn:CA2254

Hi,

I’m trying to use Ignore Issues on Multiple Criteria in one project. The project language is C#, and current configuration like this

After this configuration I’m still getting coment for external_roslyn:CA2254 in my PR. Here is an example comment

I couldn’t find what is the issue here. Thanks in advance

Hey there.

It’s not possible to suppress external issues in this manner. I would recommend turning this rule off in Visual Studio itself if you want to suppress it for all files.

Hi Colin,

Thanks for the answer.

I can do this with .editorconfig. Does that count?

dotnet_diagnostic.CA2254.severity = none

As long as it stops the issues from being raised during your build :+1:

1 Like

It didn’t work with the .editorconfig, but I did this by updating the project file. When we add the NoWarn config, it’ll be ok.

<PropertyGroup>
    <TargetFramework>net6.0</TargetFramework>
    <UserSecretsId>.....</UserSecretsId>
    <DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
    <NoWarn>$(NoWarn),CA2254</NoWarn>
  </PropertyGroup>
1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.