SonarQube Scanners run the analyzers on code. Use this tag for questions related to any of the scanners: SonarQube Scanner for CLI, Maven, Gradle, Jenkins, etc.
Questions tagged [sonarqube-scan]
1464 questions
6
votes
1 answer
What is the correct way to configure an Android project with submodules for use with the sonarqube gradle plugin?
What is the correct way to configure an Android project with submodules for use with the sonarqube gradle plugin? Google has not been my friend, but I may have missed something basic. (I search for sonarqube issues related to the android build…

Brendan A R Sechter
- 61
- 1
- 3
6
votes
1 answer
How to scan hidden folder such as ".nameFolder" in SonarQube?
I'm trying to run SonarQube 4.5.4 on a project. Files and metrics are found for each folder except for the hidden ones (the ones like .m2, .something). Sadly those folders are the one that I am more interested in.
Is someone else experiencing the…

Ale
- 946
- 4
- 17
- 28
6
votes
5 answers
Exporting Sonarqube reports into Excel - based on major, minor and critical categories
Is there a way to export Sonarqube reports into Excel - based on major, minor and critical categories?

user3845894
- 353
- 1
- 5
- 17
6
votes
1 answer
How to exclude single files when using MSBuild Scanner
We are using the SonarQube Scanner for MSBuild (1.1.0.0) and have a solution containing multiple projects.
There is a SonarQube.Analysis.xml in the solution root folder which we supply to the scanners cli.

philipooo
- 1,039
- 9
- 17
6
votes
1 answer
Incompatibility:org.codehaus.plexus. .exception.ComponentLookupException
When I tried to run mvn sonar:sonar command on my project often I'm getting below error:
[ERROR] Failed to execute goal org.sonarsource.scanner.maven:sonar-maven-plugin:3.2:sonar (default-c
li) on project ProjectName: Execution default-cli of goal…

Praveen Kumar Mekala
- 628
- 1
- 10
- 26
6
votes
3 answers
SonarQube: Coverage on New Code never calculated
I have set up SonarQube, Maven and Cobertura to upload unit test coverage at every build run. I want to use the differential views to get coverage for the delta (new code only).
The coverage itself is successfully uploaded, and I can see the delta…

MisterStrickland
- 947
- 1
- 15
- 35
6
votes
0 answers
Why does SonarQube reopen issues marked as Won't Fix?
In our organization, we are using SonarQube 5.6 with C# plugin 5.3.1 and every issue we mark as Won't Fix gets reopened next time analysis runs. Sometimes, when the analysis runs again the issues get marked as Won't Fix (as manually marked before).…

Alexis
- 61
- 2
6
votes
2 answers
sonar runner authorization error
I'm trying to send a job to sonarqube from jenkins. However I'm getting an error saying te following when I run the job
ERROR: Error during Sonar runner execution
org.sonar.runner.impl.RunnerException: Unable to execute Sonar
at…

NoSixties
- 2,443
- 2
- 28
- 65
5
votes
0 answers
SonarScanner running inside the docker container cannot access source code
I'm trying to scan the source code of some project with SonarQube and SonarScanner running locally on Docker, OS: Windows.
By providing the next command in the terminal I'm trying to run container with SonarScanner which should scan the code in my…

hellneck
- 59
- 3
5
votes
4 answers
SonarQube - A "NullPointerException" could be thrown;
SonarQube reports this bug to me: A "NullPointerException" could be thrown; "getBody()" can return null.
This is the code:
if (holdingResponseEntity == null || holdingResponseEntity.getBody() == null || holdingResponseEntity.getBody().getError() ||…

Gino Sarnieri
- 51
- 1
- 1
- 3
5
votes
0 answers
SonarQube - Override quality profile with sonar-project.properties
I'm struggling to override rules on my Sonar project. I've got a custom profile set on my project, but it seems I can't override its rules in the sonar-project.properties.
Here is my config file:
# --- Sonar basic configuration…

SylvainAr
- 154
- 5
5
votes
7 answers
SonarQube does not return status of waitForQualityGate() to jenkins?
I have used sonarQube in jenkins pipeline. I have installed all plugin related to sonarqube in jenkins. In the jenkins configure system, I configured the sonarqube server properly and jenkins global tool configuration I configured SonarQube Scanner…

Prakash
- 591
- 3
- 9
- 28
5
votes
1 answer
How to configure SonarQube for Typescript based AngularJS project?
I have set up SonarQube and SonarScanner and managed to scan my project. I can see the metrics on my screen except for code coverage, which is always 0%. What am I missing?
#----- Default SonarQube…

oatcrunch
- 443
- 9
- 18
5
votes
1 answer
SonarQube - "The class '...' could not be matched to its original source file."
Within my SonarQube Analysis I can find the following error:
WARN: The class 'com.mycompany.bla.BlaTest' could not be matched to its original source file. It might be a dynamically generated class.
WARN: Failed to load the class file…

Christoph Forster
- 1,728
- 4
- 27
- 39
5
votes
3 answers
Sonar complaining "The diamond operator ("<>") should be used"
So I have below line of code in my file
List nameList = new ArrayList();
Now each time I run sonar scans it shows an error in above line saying I should use diamond operator instead. Now I understand that from Java7 compiler will…

Amit
- 13,134
- 17
- 77
- 148