SonarQube for IDE in Intellij ignores exclusions

Please provide

  • Operating system: Mac
  • SonarQube for IntelliJ plugin version: latest
  • IntelliJ version: latest
  • Programming language you’re coding in: Java
  • Is connected mode used: no

And a thorough description of the problem / question:

But when doing a full analysis, it still analyzes files from that location.

Hi,

Can you give us a verbose log from IDE startup through to when that happens?

 
Thx,
Ann

verbose.log (21.1 MB)

Hi,

Thanks for the log. I’ve flagged this for the experts.

 
Ann

Hi,

This is a known existing behavior. It’s been there for a while.

We have a ticket here with the intention to change it to make it more aligned with the expectations: Jira

IMO this is crucial. I work on mixed projects with Java and JavaScript, and I don’t want to have one or the other analyzed.
Otherwise, what are the exclusions used for?

1 Like

Exclusions are currently applied only to automatic analysis. We made a deliberate decision early on to still allow users to analyze excluded files by manually triggering an analysis.

For example, if a file is excluded, modifying it will not trigger an automatic analysis. However, if you manually trigger an analysis on that file, it will be included.

While this behavior makes sense in isolation, it can be confusing when running a full project analysis. We agree that this is an area for improvement, and based on recent feedback, we will try improving this behavior in our next release.

1 Like