- ALM used: Azure DevOps
- CI system used: Azure DevOps
- Languages of the repository: C/C++
Hi,
I am building and testing my project inside Docker container where I am also trying to execute sonar-scanner, based on build wrapper executed at the begining. At the end I was able to find build-wrapper-domp.json but for some reason I’ve got the error like this:
...
2023-10-06T19:08:35.3356790Z 19:08:35.294 INFO: 0/2283 files marked as unchanged
2023-10-06T19:08:35.3356924Z 19:08:35.295 INFO: Cache: 0/0 hits, 125 bytes
2023-10-06T19:08:35.3357059Z 19:08:35.295 INFO: 0 compilation units analyzed
2023-10-06T19:08:35.3357192Z 19:08:35.304 DEBUG: the bridge server will shutdown
2023-10-06T19:08:40.3062200Z 19:08:40.305 DEBUG: the bridge server closed
2023-10-06T19:08:40.3062410Z 19:08:40.305 INFO: Time spent writing ucfgs 227ms
2023-10-06T19:08:40.7969001Z 19:08:40.796 INFO: ------------------------------------------------------------------------
2023-10-06T19:08:40.7969225Z 19:08:40.796 INFO: EXECUTION FAILURE
2023-10-06T19:08:40.7969458Z 19:08:40.796 INFO: ------------------------------------------------------------------------
2023-10-06T19:08:40.7969623Z 19:08:40.796 INFO: Total time: 15:31.980s
2023-10-06T19:08:40.8847742Z 19:08:40.884 ERROR: Error during SonarScanner execution
2023-10-06T19:08:40.8848035Z 19:08:40.884 INFO: Final Memory: 114M/4096M
2023-10-06T19:08:40.8848625Z 19:08:40.884 INFO: ------------------------------------------------------------------------
2023-10-06T19:08:40.8851924Z java.lang.IllegalStateException: The "build-wrapper-dump.json" file was found but 0 C/C++/Objective-C files were analyzed. Please make sure that:
2023-10-06T19:08:40.8852188Z * you are using the latest version of the build-wrapper and the CFamily analyzer
2023-10-06T19:08:40.8852404Z * you are correctly invoking the scanner with correct configuration
2023-10-06T19:08:40.8852532Z * your compiler is supported
2023-10-06T19:08:40.8852653Z * you are wrapping your build correctly
2023-10-06T19:08:40.8852769Z * you are wrapping a full/clean build
2023-10-06T19:08:40.8852980Z * you are providing the path to the correct build-wrapper output directory
2023-10-06T19:08:40.8853159Z * you are building and analyzing the same source checkout, absolute paths must be identical in build and analysis steps
2023-10-06T19:08:40.8853357Z at com.sonar.cpp.plugin.CFamilySensor.process(CFamilySensor.java:611)
2023-10-06T19:08:40.8853536Z at com.sonar.cpp.plugin.CFamilySensor.execute(CFamilySensor.java:241)
2023-10-06T19:08:40.8853741Z at org.sonar.scanner.sensor.AbstractSensorWrapper.analyse(AbstractSensorWrapper.java:62)
2023-10-06T19:08:40.8853950Z at org.sonar.scanner.sensor.ModuleSensorsExecutor.execute(ModuleSensorsExecutor.java:75)
2023-10-06T19:08:40.8854167Z at org.sonar.scanner.sensor.ModuleSensorsExecutor.execute(ModuleSensorsExecutor.java:51)
2023-10-06T19:08:40.8854374Z at org.sonar.scanner.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:64)
2023-10-06T19:08:40.8854590Z at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:123)
2023-10-06T19:08:40.8854796Z at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:109)
2023-10-06T19:08:40.8855076Z at org.sonar.scanner.scan.ProjectScanContainer.scan(ProjectScanContainer.java:163)
2023-10-06T19:08:40.8855285Z at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:159)
2023-10-06T19:08:40.8855503Z at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:130)
2023-10-06T19:08:40.8855715Z at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:123)
2023-10-06T19:08:40.8855925Z at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:109)
2023-10-06T19:08:40.8856126Z at org.sonar.scanner.bootstrap.ScannerContainer.doAfterStart(ScannerContainer.java:396)
2023-10-06T19:08:40.8856340Z at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:123)
2023-10-06T19:08:40.8856544Z at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:109)
2023-10-06T19:08:40.8856752Z at org.sonar.scanner.bootstrap.GlobalContainer.doAfterStart(GlobalContainer.java:128)
2023-10-06T19:08:40.8856962Z at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:123)
2023-10-06T19:08:40.8857173Z at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:109)
2023-10-06T19:08:40.8857361Z at org.sonar.batch.bootstrapper.Batch.doExecute(Batch.java:57)
2023-10-06T19:08:40.8857530Z at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:51)
2023-10-06T19:08:40.8857740Z at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46)
2023-10-06T19:08:40.8857940Z at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2023-10-06T19:08:40.8858231Z at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
2023-10-06T19:08:40.8858399Z at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
2023-10-06T19:08:40.8858562Z at java.base/java.lang.reflect.Method.invoke(Unknown Source)
2023-10-06T19:08:40.8858748Z at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60)
2023-10-06T19:08:40.8858933Z at com.sun.proxy.$Proxy0.execute(Unknown Source)
2023-10-06T19:08:40.8859100Z at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:189)
2023-10-06T19:08:40.8859377Z at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:138)
2023-10-06T19:08:40.8859557Z at org.sonarsource.scanner.cli.Main.execute(Main.java:112)
2023-10-06T19:08:40.8859727Z at org.sonarsource.scanner.cli.Main.execute(Main.java:75)
2023-10-06T19:08:40.8859888Z at org.sonarsource.scanner.cli.Main.main(Main.java:61)
Do you have any idea, how to fix this issue?
If you would like to get full build log etc then just let me know, the log file is to big to attach it here