Sonarqube treating 'suggestion' setting as issue

Azure Devops ALM and CI
SonarQubePrepare@7
SonarQubeAnalyze@7
SonarQubePublish@7
Languages: C#, TypeScript

Error Observed:
IDE0007 is configured in our .editorconfig as ‘suggestion’ only. SonarQube reports IDE0007 as an error/issue.

To reproduce:
Set IDE0007 = suggestion in your .editorconfig. Run sonarqube prepare, analyze, publish. Sonarqube server reports a ‘Maintainability’ issue.

Workaround:
changing IDE0007 to ‘none’ gets around the issue however this is not ideal.

Log text:

use ‘var’ instead of explicit type

Use implicit type(external_roslyn:IDE0007)roslyn

Related issue and bug:
Sonar cloud - Ignoring rules with editorconfig is not working - SonarQube Cloud - Sonar Community
[SCAN4NET-190] Severity level set in .editorconfig are not properly taken into account during analysis - Jira

Hi,

What version of SonarQube are you using?

And I’m not sure we read the .editorconfig. However, you can turn off import of those issues altogether if you like.

 
Ann

We are on version 2025.1.0.102418.
SQ does import those settings since it adjusts based on changing the setting from ‘suggestion’ to ‘none’. It’s also discussed in depth in the associated link that I shared.

Does turning off importing these just remove other analyzer rules (like the builtin IDE rules and Roslyn rules) from Sonarqube? Or would these rules still be included in SQ and just not use any of our settings?
The former would be ok since the analyzers run as part of our build anyways. The second seems like it would still cause the same issue.

Hi,

It would remove all 3rd-party issues.

Sorry I overlooked your links. In fact the second one is a still-Open ticket to fix the very thing you’re complaining about…?

 
Ann

That sounds like it’s worth trying. Is that a per-project setting? How do I turn off importing those settings?

That’s correct - one of those links is a bug for the issue we are experiencing. I was hoping for some way to ‘upvote’ a fix for it.

Hi,

Did you check the link I sent?

 
:joy:
Ann

:joy: I did not even see there. Thank you!