Backelite / sonar-objective-c

Sonar Plugin for Objective-C
197 stars 75 forks source link

Measure with line 0 for file '.......*.h' must be > 0 #32

Open fjtrujy opened 7 years ago

fjtrujy commented 7 years ago

Sonar: Sonar 6.3.0.19869 Objective C (Backelite) 0.6.1

Build Slave: Xcode 8.3.2

Slather 2.4.2

I have seen in the sonar-Swift this issue that is exactly the same: sonar-swift-issue-77

Where their solution is update the Slather version. I have already the lastest one 2.4.2

ERROR: Error during SonarQube Scanner execution
java.lang.IllegalStateException: Measure with line 0 for file '............................h' must be > 0
    at org.sonar.scanner.sensor.DefaultSensorStorage.validatePositiveLine(DefaultSensorStorage.java:347)
    at org.sonar.scanner.sensor.DefaultSensorStorage.validateCoverageMeasure(DefaultSensorStorage.java:330)
    at org.sonar.scanner.sensor.DefaultSensorStorage.saveCoverageMetricInternal(DefaultSensorStorage.java:271)
    at org.sonar.scanner.sensor.DefaultSensorStorage.saveMeasure(DefaultSensorStorage.java:260)
    at org.sonar.scanner.index.DefaultIndex.addMeasure(DefaultIndex.java:155)
    at org.sonar.scanner.deprecated.DeprecatedSensorContext.saveMeasure(DeprecatedSensorContext.java:126)
    at org.sonar.plugins.objectivec.coverage.CoberturaReportParser.collectPackageMeasures(CoberturaReportParser.java:100)
    at org.sonar.plugins.objectivec.coverage.CoberturaReportParser.access$000(CoberturaReportParser.java:46)
    at org.sonar.plugins.objectivec.coverage.CoberturaReportParser$1.stream(CoberturaReportParser.java:74)
    at org.sonar.api.utils.StaxParser.parse(StaxParser.java:115)
    at org.sonar.api.utils.StaxParser.parse(StaxParser.java:95)
    at org.sonar.api.utils.StaxParser.parse(StaxParser.java:85)
    at org.sonar.plugins.objectivec.coverage.CoberturaReportParser.parse(CoberturaReportParser.java:77)
    at org.sonar.plugins.objectivec.coverage.CoberturaReportParser.parseReport(CoberturaReportParser.java:64)
    at org.sonar.plugins.objectivec.coverage.CoberturaSensor.analyse(CoberturaSensor.java:76)
    at org.sonar.scanner.phases.SensorsExecutor.executeSensor(SensorsExecutor.java:57)
    at org.sonar.scanner.phases.SensorsExecutor.execute(SensorsExecutor.java:49)
    at org.sonar.scanner.phases.AbstractPhaseExecutor.execute(AbstractPhaseExecutor.java:74)
    at org.sonar.scanner.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:175)
    at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:143)
    at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:128)
    at org.sonar.scanner.scan.ProjectScanContainer.scan(ProjectScanContainer.java:262)
    at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:257)
    at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:247)
    at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:143)
    at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:128)
    at org.sonar.scanner.task.ScanTask.execute(ScanTask.java:47)
    at org.sonar.scanner.task.TaskContainer.doAfterStart(TaskContainer.java:86)
    at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:143)
    at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:128)
    at org.sonar.scanner.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:118)
    at org.sonar.batch.bootstrapper.Batch.executeTask(Batch.java:117)
    at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:63)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    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:233)
    at org.sonarsource.scanner.api.EmbeddedScanner.runAnalysis(EmbeddedScanner.java:151)
    at org.sonarsource.scanner.cli.Main.runAnalysis(Main.java:123)
    at org.sonarsource.scanner.cli.Main.execute(Main.java:77)
    at org.sonarsource.scanner.cli.Main.main(Main.java:61)
ERROR: 
ERROR: Re-run SonarQube Scanner using the -X switch to enable full debug logging.
ERROR - Command 'sonar-scanner ' failed with error code: 1

Do you have any clue? Thanks