java.lang.IllegalStateException: The “build-wrapper-dump.json” file was found but 0 C/C++/Objective-C files were analyzed
Must-share information (formatted with Markdown ):
Which versions are you using
SonarQube Developer Edition Version 8.9.10,
Scanner 4.6.2.2472
What are you trying to achieve: Scann C++ source files
What have you tried so far to achieve this split the analysis of sub modules
We are building the code on windows GitLab Runners with the sonar-wrapper around a bat script that launch several msbuild
Then we must transform the path to be conformed to the runner number
And finally, we do the several sonar analisys in parallel for the several modules some work fine and other failed systematically, but the cause is not clear
ganncamp
(G Ann Campbell)
November 14, 2022, 8:06pm
2
Hi,
Welcome to the community!
Could you provide your analysis log and the build-wrapper-dump.json
file?
Ann
ganncamp
(G Ann Campbell)
November 15, 2022, 2:00pm
4
Hi Charles,
Thanks for the files. Could you also give us your analysis log?
The analysis / scanner log is what’s output from the analysis command. Hopefully, the log you provide will include that command as well.
This guide will help you find them.
Ann
Hello,
Here are the analysis logs of the failing jobs
analysis (4).log (3.55 KB)
analysis (3).log (3.59 KB)
analysis (2).log (3.57 KB)
analysis (1).log (3.58 KB)
analysis.log (3.47 KB)
ganncamp
(G Ann Campbell)
November 16, 2022, 5:33pm
6
Hi,
None of these files is an analysis log.
Ann
Hello,
I hope that the logs are in these archives
Otherwise, can you tell me which name pattern should I look for
artifacts (1).zip (30.6 KB)
artifacts.zip (37.8 KB)
artifacts (4).zip (24.7 KB)
artifacts (3).zip (25.1 KB)
artifacts (2).zip (25.6 KB)
ganncamp
(G Ann Campbell)
November 17, 2022, 1:26pm
8
Hi,
Did you read the guide I linked to?
Ann
Hi,
Yes I have, I’ve launched the sonar-scanner
with the -X flag on my CI
Here you will find my logs from the failing CI Jobs
Sonar.log (43.3 KB)
Sonar1.log (43.3 KB)
Sonar2.log (42.4 KB)
Sonar3.log (42.2 KB)
Sonar4.log (41.9 KB)
mpaladin
(Massimo Paladin)
November 21, 2022, 8:44am
12
Hi @charles.demagneval ,
I had a look at your files and don’t understand what you are trying to do, there is no match between what you compile and what you analyze.
From the build-wrapper-dump.json I see:
$ grep '"cwd"' build-wrapper-dump.json
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-c\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-comm\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-itc\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-modules\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-module-opc-ua\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-module-S7\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\modules\\module-dai-citilog-alertes-serveur\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\modules\\module-dai-citilog-alertes-client\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-c\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-comm\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-itc\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-modules\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-module-opc-ua\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\libs\\lib-module-S7\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\modules\\module-opc-ua-serveur\\",
"cwd":"C:\\gitlab-runner\\builds\\exkx6y71\\0\\projets\\cleo\\interface\\simb\\",
and the folders where you are launching the analysis are different:
C:\gitlab-runner\builds\exkx6y71\6\projets\cleo\interface\itexe
C:\gitlab-runner\builds\exkx6y71\2\projets\cleo\interface\modules\module-opc-ua-serveur
C:\gitlab-runner\builds\exkx6y71\3\projets\cleo\interface\modules\module-opc-ua-client
C:\gitlab-runner\builds\exkx6y71\5\projets\cleo\interface\modules\module-tcp-modbus-client
C:\gitlab-runner\builds\exkx6y71\1\projets\cleo\interface\modules\module-applicom
If I understand correctly you are not trying to analyze what you are building.
There should be a match between what you build and what you analyze.