Hi,
I have a C++ project on which I ran the build-wrapper and then I ran SonarScanner. The scanner ran for a very long time but ended with a java.lang.IllegalStateException during the scan of one source file in particular.
Here is the call stack
17:25:05.633 ERROR: Error during SonarScanner execution
java.lang.IllegalStateException:
An error occurred while analyzing the following compilation unit:
D:\cae\dev\Odyssey\Source\CaeImmersiveMassLaser\Private\MassLaser_SystemDesignatingProcessor.cpp
A file named “sonar-cfamily-reproducer.zip” has been generated to help the problem investigation.
Please contact SonarSource support providing the following file to help improving the analyzer:
D:\cae\dev\Odyssey\ThirdParty\Validation\sonar-scanner-cli-4.7.0.2747-windows\bin\sonar-cfamily-reproducer.zip
> at com.sonar.cpp.plugin.CFamilySensor.process(CFamilySensor.java:442)
at com.sonar.cpp.plugin.CFamilySensor.execute(CFamilySensor.java:215) at org.sonar.scanner.sensor.AbstractSensorWrapper.analyse(AbstractSensorWrapper.java:62) at org.sonar.scanner.sensor.ModuleSensorsExecutor.execute(ModuleSensorsExecutor.java:75) at org.sonar.scanner.sensor.ModuleSensorsExecutor.execute(ModuleSensorsExecutor.java:51) at org.sonar.scanner.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:64) at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:123) at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:109) at org.sonar.scanner.scan.ProjectScanContainer.scan(ProjectScanContainer.java:468) at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:464) at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:420) at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:123) at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:109) at org.sonar.scanner.bootstrap.GlobalContainer.doAfterStart(GlobalContainer.java:130) at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:123) at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:109) at org.sonar.batch.bootstrapper.Batch.doExecute(Batch.java:58) at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:52) at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.base/java.lang.reflect.Method.invoke(Unknown Source) at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60) at com.sun.proxy.$Proxy0.execute(Unknown Source) at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:189) at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:138) at org.sonarsource.scanner.cli.Main.execute(Main.java:112) at org.sonarsource.scanner.cli.Main.execute(Main.java:75) at org.sonarsource.scanner.cli.Main.main(Main.java:61)
I have access to a sonar-cfamily-reproducer.zip file that contains info to help improve the analyzer. I would like a description of how I debug and fix this issue. Thanks