SonarCloud - VSTS - java.lang.IllegalArgumentException

sonarcloud
web

(Peter Connor) #1

Since SonarCloud got upgraded to 7.2, one of our Ci builds is throwing a large amount of errors when on the ‘Run Code Analysis’ step. We have private repositories so cannot link to the files I am afraid.

2018-06-19T13:24:46.9591830Z WARNING: WARN: Giving up highlighting/handling duplication for file xxxxxxxxxxx.html
2018-06-19T13:24:46.9747830Z ##[error]java.lang.IllegalArgumentException: Unable to register token in file xxxxxxxxxxx.html
2018-06-19T13:24:46.9747830Z java.lang.IllegalArgumentException: Unable to register token in file xxxxxxxxxxx.html
2018-06-19T13:24:46.9747830Z ##[error]at org.sonar.api.batch.sensor.cpd.internal.DefaultCpdTokens.addToken(DefaultCpdTokens.java:79)
2018-06-19T13:24:46.9747830Z 	at org.sonar.api.batch.sensor.cpd.internal.DefaultCpdTokens.addToken(DefaultCpdTokens.java:79)
2018-06-19T13:24:46.9903830Z ##[error]at org.sonar.plugins.web.core.WebTokensVisitor.highlightAndDuplicate(WebTokensVisitor.java:67)
2018-06-19T13:24:46.9903830Z 	at org.sonar.plugins.web.core.WebTokensVisitor.highlightAndDuplicate(WebTokensVisitor.java:67)
2018-06-19T13:24:46.9903830Z ##[error]at org.sonar.plugins.web.core.WebTokensVisitor.startDocument(WebTokensVisitor.java:49)
2018-06-19T13:24:46.9903830Z 	at org.sonar.plugins.web.core.WebTokensVisitor.startDocument(WebTokensVisitor.java:49)
2018-06-19T13:24:46.9903830Z ##[error]at org.sonar.plugins.web.visitor.HtmlAstScanner.scan(HtmlAstScanner.java:75)
2018-06-19T13:24:46.9903830Z 	at org.sonar.plugins.web.visitor.HtmlAstScanner.scan(HtmlAstScanner.java:75)
2018-06-19T13:24:46.9903830Z ##[error]at org.sonar.plugins.web.visitor.HtmlAstScanner.scan(HtmlAstScanner.java:59)
2018-06-19T13:24:46.9903830Z 	at org.sonar.plugins.web.visitor.HtmlAstScanner.scan(HtmlAstScanner.java:59)
2018-06-19T13:24:46.9903830Z ##[error]at org.sonar.plugins.web.core.WebSensor.execute(WebSensor.java:98)
2018-06-19T13:24:46.9903830Z 	at org.sonar.plugins.web.core.WebSensor.execute(WebSensor.java:98)
2018-06-19T13:24:46.9903830Z ##[error]at org.sonar.scanner.sensor.SensorWrapper.analyse(SensorWrapper.java:53)
2018-06-19T13:24:46.9903830Z 	at org.sonar.scanner.sensor.SensorWrapper.analyse(SensorWrapper.java:53)
2018-06-19T13:24:46.9903830Z ##[error]at org.sonar.scanner.phases.SensorsExecutor.executeSensor(SensorsExecutor.java:88)
2018-06-19T13:24:46.9903830Z 	at org.sonar.scanner.phases.SensorsExecutor.executeSensor(SensorsExecutor.java:88)
2018-06-19T13:24:46.9903830Z ##[error]at org.sonar.scanner.phases.SensorsExecutor.execute(SensorsExecutor.java:82)
2018-06-19T13:24:46.9903830Z 	at org.sonar.scanner.phases.SensorsExecutor.execute(SensorsExecutor.java:82)
2018-06-19T13:24:46.9903830Z ##[error]at org.sonar.scanner.phases.SensorsExecutor.execute(SensorsExecutor.java:68)
2018-06-19T13:24:46.9903830Z 	at org.sonar.scanner.phases.SensorsExecutor.execute(SensorsExecutor.java:68)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.scanner.phases.AbstractPhaseExecutor.execute(AbstractPhaseExecutor.java:88)
2018-06-19T13:24:47.0059830Z 	at org.sonar.scanner.phases.AbstractPhaseExecutor.execute(AbstractPhaseExecutor.java:88)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.scanner.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:182)
2018-06-19T13:24:47.0059830Z 	at org.sonar.scanner.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:182)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0059830Z 	at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
2018-06-19T13:24:47.0059830Z 	at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.scanner.scan.ProjectScanContainer.scan(ProjectScanContainer.java:312)
2018-06-19T13:24:47.0059830Z 	at org.sonar.scanner.scan.ProjectScanContainer.scan(ProjectScanContainer.java:312)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:307)
2018-06-19T13:24:47.0059830Z 	at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:307)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:305)
2018-06-19T13:24:47.0059830Z 	at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:305)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:281)
2018-06-19T13:24:47.0059830Z 	at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:281)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0059830Z 	at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
2018-06-19T13:24:47.0059830Z 	at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.scanner.task.ScanTask.execute(ScanTask.java:48)
2018-06-19T13:24:47.0059830Z 	at org.sonar.scanner.task.ScanTask.execute(ScanTask.java:48)
2018-06-19T13:24:47.0059830Z ##[error]at org.sonar.scanner.task.TaskContainer.doAfterStart(TaskContainer.java:81)
2018-06-19T13:24:47.0059830Z 	at org.sonar.scanner.task.TaskContainer.doAfterStart(TaskContainer.java:81)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0215830Z 	at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
2018-06-19T13:24:47.0215830Z 	at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonar.scanner.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:132)
2018-06-19T13:24:47.0215830Z 	at org.sonar.scanner.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:132)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonar.batch.bootstrapper.Batch.doExecuteTask(Batch.java:116)
2018-06-19T13:24:47.0215830Z 	at org.sonar.batch.bootstrapper.Batch.doExecuteTask(Batch.java:116)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:71)
2018-06-19T13:24:47.0215830Z 	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:71)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46)
2018-06-19T13:24:47.0215830Z 	at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46)
2018-06-19T13:24:47.0215830Z ##[error]at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2018-06-19T13:24:47.0215830Z 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2018-06-19T13:24:47.0215830Z ##[error]at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
2018-06-19T13:24:47.0215830Z 	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
2018-06-19T13:24:47.0215830Z ##[error]at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
2018-06-19T13:24:47.0215830Z 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
2018-06-19T13:24:47.0215830Z ##[error]at java.lang.reflect.Method.invoke(Unknown Source)
2018-06-19T13:24:47.0215830Z 	at java.lang.reflect.Method.invoke(Unknown Source)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60)
2018-06-19T13:24:47.0215830Z 	at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60)
2018-06-19T13:24:47.0215830Z ##[error]at com.sun.proxy.$Proxy0.execute(Unknown Source)
2018-06-19T13:24:47.0215830Z 	at com.sun.proxy.$Proxy0.execute(Unknown Source)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:171)
2018-06-19T13:24:47.0215830Z 	at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:171)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:128)
2018-06-19T13:24:47.0215830Z 	at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:128)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonarsource.scanner.cli.Main.execute(Main.java:111)
2018-06-19T13:24:47.0215830Z 	at org.sonarsource.scanner.cli.Main.execute(Main.java:111)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonarsource.scanner.cli.Main.execute(Main.java:75)
2018-06-19T13:24:47.0215830Z 	at org.sonarsource.scanner.cli.Main.execute(Main.java:75)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonarsource.scanner.cli.Main.main(Main.java:61)
2018-06-19T13:24:47.0215830Z 	at org.sonarsource.scanner.cli.Main.main(Main.java:61)
2018-06-19T13:24:47.0215830Z ##[error]Caused by: java.lang.IllegalArgumentException: 121 is not a valid line offset for pointer. File xxxxxxxxxxx.html has 120 character(s) at line 1
2018-06-19T13:24:47.0215830Z Caused by: java.lang.IllegalArgumentException: 121 is not a valid line offset for pointer. File xxxxxxxxxxx.html has 120 character(s) at line 1
2018-06-19T13:24:47.0215830Z ##[error]at org.sonar.api.internal.google.common.base.Preconditions.checkArgument(Preconditions.java:145)
2018-06-19T13:24:47.0215830Z 	at org.sonar.api.internal.google.common.base.Preconditions.checkArgument(Preconditions.java:145)
2018-06-19T13:24:47.0215830Z ##[error]at org.sonar.api.batch.fs.internal.DefaultInputFile.checkValid(DefaultInputFile.java:312)
2018-06-19T13:24:47.0215830Z 	at org.sonar.api.batch.fs.internal.DefaultInputFile.checkValid(DefaultInputFile.java:312)
2018-06-19T13:24:47.0371830Z ##[error]at org.sonar.api.batch.fs.internal.DefaultInputFile.newPointer(DefaultInputFile.java:246)
2018-06-19T13:24:47.0371830Z 	at org.sonar.api.batch.fs.internal.DefaultInputFile.newPointer(DefaultInputFile.java:246)
2018-06-19T13:24:47.0371830Z ##[error]at org.sonar.api.batch.fs.internal.DefaultInputFile.newRange(DefaultInputFile.java:262)
2018-06-19T13:24:47.0371830Z 	at org.sonar.api.batch.fs.internal.DefaultInputFile.newRange(DefaultInputFile.java:262)
2018-06-19T13:24:47.0371830Z ##[error]at org.sonar.api.batch.sensor.cpd.internal.DefaultCpdTokens.addToken(DefaultCpdTokens.java:77)
2018-06-19T13:24:47.0371830Z 	at org.sonar.api.batch.sensor.cpd.internal.DefaultCpdTokens.addToken(DefaultCpdTokens.java:77)
2018-06-19T13:24:47.0371830Z ##[error]... 38 common frames omitted
2018-06-19T13:24:47.0371830Z 	... 38 common frames omitted
2018-06-19T13:24:47.0371830Z WARNING: WARN: Giving up highlighting/handling duplication for file xxxxxxxxxxx.html
2018-06-19T13:24:47.0371830Z ##[error]java.lang.IllegalArgumentException: Unable to register token in file xxxxxxxxxxx.html
2018-06-19T13:24:47.0371830Z java.lang.IllegalArgumentException: Unable to register token in file xxxxxxxxxxx.html
2018-06-19T13:24:47.0371830Z ##[error]at org.sonar.api.batch.sensor.cpd.internal.DefaultCpdTokens.addToken(DefaultCpdTokens.java:79)
2018-06-19T13:24:47.0371830Z 	at org.sonar.api.batch.sensor.cpd.internal.DefaultCpdTokens.addToken(DefaultCpdTokens.java:79)
2018-06-19T13:24:47.0371830Z ##[error]at org.sonar.plugins.web.core.WebTokensVisitor.highlightAndDuplicate(WebTokensVisitor.java:67)
	at org.sonar.plugins.web.core.WebTokensVisitor.startDocument(WebTokensVisitor.java:49)
2018-06-19T13:24:47.0371830Z 	at org.sonar.plugins.web.core.WebTokensVisitor.highlightAndDuplicate(WebTokensVisitor.java:67)
2018-06-19T13:24:47.0527830Z 	at org.sonar.plugins.web.core.WebTokensVisitor.startDocument(WebTokensVisitor.java:49)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.plugins.web.visitor.HtmlAstScanner.scan(HtmlAstScanner.java:75)
2018-06-19T13:24:47.0527830Z 	at org.sonar.plugins.web.visitor.HtmlAstScanner.scan(HtmlAstScanner.java:75)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.plugins.web.visitor.HtmlAstScanner.scan(HtmlAstScanner.java:59)
2018-06-19T13:24:47.0527830Z 	at org.sonar.plugins.web.visitor.HtmlAstScanner.scan(HtmlAstScanner.java:59)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.plugins.web.core.WebSensor.execute(WebSensor.java:98)
2018-06-19T13:24:47.0527830Z 	at org.sonar.plugins.web.core.WebSensor.execute(WebSensor.java:98)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.scanner.sensor.SensorWrapper.analyse(SensorWrapper.java:53)
2018-06-19T13:24:47.0527830Z 	at org.sonar.scanner.sensor.SensorWrapper.analyse(SensorWrapper.java:53)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.scanner.phases.SensorsExecutor.executeSensor(SensorsExecutor.java:88)
2018-06-19T13:24:47.0527830Z 	at org.sonar.scanner.phases.SensorsExecutor.executeSensor(SensorsExecutor.java:88)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.scanner.phases.SensorsExecutor.execute(SensorsExecutor.java:82)
2018-06-19T13:24:47.0527830Z 	at org.sonar.scanner.phases.SensorsExecutor.execute(SensorsExecutor.java:82)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.scanner.phases.SensorsExecutor.execute(SensorsExecutor.java:68)
	at org.sonar.scanner.phases.AbstractPhaseExecutor.execute(AbstractPhaseExecutor.java:88)
2018-06-19T13:24:47.0527830Z 	at org.sonar.scanner.phases.SensorsExecutor.execute(SensorsExecutor.java:68)
2018-06-19T13:24:47.0527830Z 	at org.sonar.scanner.phases.AbstractPhaseExecutor.execute(AbstractPhaseExecutor.java:88)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.scanner.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:182)
2018-06-19T13:24:47.0527830Z 	at org.sonar.scanner.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:182)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0527830Z 	at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
	at org.sonar.scanner.scan.ProjectScanContainer.scan(ProjectScanContainer.java:312)
2018-06-19T13:24:47.0527830Z 	at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
2018-06-19T13:24:47.0527830Z 	at org.sonar.scanner.scan.ProjectScanContainer.scan(ProjectScanContainer.java:312)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:307)
2018-06-19T13:24:47.0527830Z 	at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:307)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:305)
2018-06-19T13:24:47.0527830Z 	at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:305)
2018-06-19T13:24:47.0527830Z ##[error]at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:281)
	at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
	at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
	at org.sonar.scanner.task.ScanTask.execute(ScanTask.java:48)
	at org.sonar.scanner.task.TaskContainer.doAfterStart(TaskContainer.java:81)
2018-06-19T13:24:47.0683830Z 	at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:281)
2018-06-19T13:24:47.0683830Z 	at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0683830Z 	at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
2018-06-19T13:24:47.0683830Z 	at org.sonar.scanner.task.ScanTask.execute(ScanTask.java:48)
2018-06-19T13:24:47.0683830Z 	at org.sonar.scanner.task.TaskContainer.doAfterStart(TaskContainer.java:81)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0683830Z 	at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:136)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
2018-06-19T13:24:47.0683830Z 	at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:122)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonar.scanner.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:132)
	at org.sonar.batch.bootstrapper.Batch.doExecuteTask(Batch.java:116)
	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:71)
	at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46)
2018-06-19T13:24:47.0683830Z 	at org.sonar.scanner.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:132)
2018-06-19T13:24:47.0683830Z 	at org.sonar.batch.bootstrapper.Batch.doExecuteTask(Batch.java:116)
2018-06-19T13:24:47.0683830Z 	at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:71)
2018-06-19T13:24:47.0683830Z 	at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46)
2018-06-19T13:24:47.0683830Z ##[error]at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2018-06-19T13:24:47.0683830Z 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
2018-06-19T13:24:47.0683830Z ##[error]at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
	at 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)
2018-06-19T13:24:47.0683830Z 	at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
2018-06-19T13:24:47.0683830Z 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
2018-06-19T13:24:47.0683830Z 	at java.lang.reflect.Method.invoke(Unknown Source)
2018-06-19T13:24:47.0683830Z 	at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60)
2018-06-19T13:24:47.0683830Z 	at com.sun.proxy.$Proxy0.execute(Unknown Source)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:171)
2018-06-19T13:24:47.0683830Z 	at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:171)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:128)
2018-06-19T13:24:47.0683830Z 	at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:128)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonarsource.scanner.cli.Main.execute(Main.java:111)
2018-06-19T13:24:47.0683830Z 	at org.sonarsource.scanner.cli.Main.execute(Main.java:111)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonarsource.scanner.cli.Main.execute(Main.java:75)
2018-06-19T13:24:47.0683830Z 	at org.sonarsource.scanner.cli.Main.execute(Main.java:75)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonarsource.scanner.cli.Main.main(Main.java:61)
2018-06-19T13:24:47.0683830Z 	at org.sonarsource.scanner.cli.Main.main(Main.java:61)
2018-06-19T13:24:47.0683830Z ##[error]Caused by: java.lang.IllegalArgumentException: 12 is not a valid line offset for pointer. File xxxxxxxxxxx.html has 11 character(s) at line 1
2018-06-19T13:24:47.0683830Z Caused by: java.lang.IllegalArgumentException: 12 is not a valid line offset for pointer. File xxxxxxxxxxx.html has 11 character(s) at line 1
2018-06-19T13:24:47.0683830Z ##[error]at org.sonar.api.internal.google.common.base.Preconditions.checkArgument(Preconditions.java:145)
2018-06-19T13:24:47.0683830Z 	at org.sonar.api.internal.google.common.base.Preconditions.checkArgument(Preconditions.java:145)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonar.api.batch.fs.internal.DefaultInputFile.checkValid(DefaultInputFile.java:312)
2018-06-19T13:24:47.0683830Z 	at org.sonar.api.batch.fs.internal.DefaultInputFile.checkValid(DefaultInputFile.java:312)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonar.api.batch.fs.internal.DefaultInputFile.newPointer(DefaultInputFile.java:246)
2018-06-19T13:24:47.0683830Z 	at org.sonar.api.batch.fs.internal.DefaultInputFile.newPointer(DefaultInputFile.java:246)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonar.api.batch.fs.internal.DefaultInputFile.newRange(DefaultInputFile.java:262)
2018-06-19T13:24:47.0683830Z 	at org.sonar.api.batch.fs.internal.DefaultInputFile.newRange(DefaultInputFile.java:262)
2018-06-19T13:24:47.0683830Z ##[error]at org.sonar.api.batch.sensor.cpd.internal.DefaultCpdTokens.addToken(DefaultCpdTokens.java:77)
2018-06-19T13:24:47.0683830Z 	at org.sonar.api.batch.sensor.cpd.internal.DefaultCpdTokens.addToken(DefaultCpdTokens.java:77)
2018-06-19T13:24:47.0683830Z ##[error]... 38 common frames omitted

Any other information I can provide to help please let me know.

Thanks,
Pete


(Julien Henry) #2

Hi Pete,

Looking at the stacktrace, for me this is an issue in the SonarWeb analyzer. Would be great if you could share the offending file (privately is fine), or provide a reproducer.

Thanks,


(Peter Connor) #3

Hi Julien,

The entirety of the HTML file is as follows:

<preview-modal content-tempate="pcnModal" modal-id="pcnModal" carousel-id="pcnCarousel" show="{{show}}"></preview-modal>

Thanks,
Pete


(Bert) #4

Hi all,

I observed also an exception from HighlightingLineReader with SQ 7.2 and all HTML files which start with the following lines create exceptions.

<!doctype html>
<html>
...

Best regards
Bert

2018.06.22 00:44:08 WARN  ce[AWQkgXzQt4SAz9th4Hei][o.s.s.c.t.p.s.l.HighlightingLineReader] Inconsistency detected in Highlighting data. Highlighting will be ignored for file xxxxx:Help.html'
org.sonar.server.computation.task.projectanalysis.source.linereader.RangeOffsetConverter$RangeOffsetConverterException: End offset 16 is defined outside the length (15) of the line 1
        at org.sonar.server.computation.task.projectanalysis.source.linereader.RangeOffsetConverter.checkExpression(RangeOffsetConverter.java:65)
        at org.sonar.server.computation.task.projectanalysis.source.linereader.RangeOffsetConverter.validateEndOffsetNotGreaterThanLineLength(RangeOffsetConverter.java:59)
        at org.sonar.server.computation.task.projectanalysis.source.linereader.RangeOffsetConverter.offsetToString(RangeOffsetConverter.java:34)
        at org.sonar.server.computation.task.projectanalysis.source.linereader.HighlightingLineReader.processHighlighting(HighlightingLineReader.java:104)
        at org.sonar.server.computation.task.projectanalysis.source.linereader.HighlightingLineReader.processHighlightings(HighlightingLineReader.java:91)
        at org.sonar.server.computation.task.projectanalysis.source.linereader.HighlightingLineReader.read(HighlightingLineReader.java:78)
        at org.sonar.server.computation.task.projectanalysis.source.ComputeFileSourceData.read(ComputeFileSourceData.java:67)
        at org.sonar.server.computation.task.projectanalysis.source.ComputeFileSourceData.compute(ComputeFileSourceData.java:51)
        at org.sonar.server.computation.task.projectanalysis.step.PersistFileSourcesStep$FileSourceVisitor.visitFile(PersistFileSourcesStep.java:125)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visitNode(DepthTraversalTypeAwareCrawler.java:79)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visitImpl(DepthTraversalTypeAwareCrawler.java:51)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visit(DepthTraversalTypeAwareCrawler.java:39)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visitChildren(DepthTraversalTypeAwareCrawler.java:98)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visitImpl(DepthTraversalTypeAwareCrawler.java:54)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visit(DepthTraversalTypeAwareCrawler.java:39)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visitChildren(DepthTraversalTypeAwareCrawler.java:98)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visitImpl(DepthTraversalTypeAwareCrawler.java:54)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visit(DepthTraversalTypeAwareCrawler.java:39)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visitChildren(DepthTraversalTypeAwareCrawler.java:98)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visitImpl(DepthTraversalTypeAwareCrawler.java:54)
        at org.sonar.server.computation.task.projectanalysis.component.DepthTraversalTypeAwareCrawler.visit(DepthTraversalTypeAwareCrawler.java:39)
        at org.sonar.server.computation.task.projectanalysis.step.PersistFileSourcesStep.execute(PersistFileSourcesStep.java:93)
        at org.sonar.server.computation.task.step.ComputationStepExecutor.executeSteps(ComputationStepExecutor.java:64)
        at org.sonar.server.computation.task.step.ComputationStepExecutor.execute(ComputationStepExecutor.java:52)
        at org.sonar.server.computation.task.projectanalysis.taskprocessor.ReportTaskProcessor.process(ReportTaskProcessor.java:73)
        at org.sonar.ce.taskprocessor.CeWorkerImpl.executeTask(CeWorkerImpl.java:134)
        at org.sonar.ce.taskprocessor.CeWorkerImpl.findAndProcessTask(CeWorkerImpl.java:97)
        at org.sonar.ce.taskprocessor.CeWorkerImpl.withCustomizedThreadName(CeWorkerImpl.java:81)
        at org.sonar.ce.taskprocessor.CeWorkerImpl.call(CeWorkerImpl.java:73)
        at org.sonar.ce.taskprocessor.CeWorkerImpl.call(CeWorkerImpl.java:43)
        at java.util.concurrent.FutureTask.run(Unknown Source)
        at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
        at java.util.concurrent.FutureTask.run(Unknown Source)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(Unknown Source)
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
        at java.lang.Thread.run(Unknown Source)

(Elena Vilchik) #5

Hi all,

Most probably you are having this problem due to BOM in your source files. I’ve created a ticket https://jira.sonarsource.com/browse/SONARWEB-79 which should be fixed in next version of plugin.

Still, it’s not clear why it started to fail with upgrade of SonarCloud, probably just coincidence.

Regards,
Elena


(Bert) #6

Hallo Elena,

yes, the source file is a UTF-8 with BOM.
Thank you for creating the ticket.

Best regards
Bert


(Peter Connor) #7

Yes our files are UTF-8 with BOM, but why would that then affect one file only then and not all of them?

Thanks,
Pete