-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error parsing JSON eslint-angular #12
Comments
Could you please post or (private message) the json report file ? The console output of the reporter task (from jenkins or the PC who launched the gulp task) |
The json file is more than 350000 lines, the structure is like this:
|
And how does it end ?, it might be a bit too big to be process in RAM end not have the closing part |
"nbFiles" : 1971, |
Ok the end is valid, so not a size problem |
if you can, mail me the whole file : [email protected] |
With http://jsonviewer.stack.hu/ -- > Invalid JSON variable |
Just a question, you wanna really scan 2K files and 690 000 lines of code (it's huge) or did you scan vendors folder too ? |
is you sonar-web-frontend-reporters at version 2.1.2 ? |
Sonar-web-frontend-reporters is 2.2.1, now I have scanned a subfolder of the project but the error is the same |
sorry, 2.1.1 |
upgrade to 2.1.2 (it will be compatible with the 2.1 plugin and it probably will fix your error) |
Ok, I will try. |
Ok, now I have a global idea of the situation: the plugin 2.1.1 works fine, the problem is in a js file that has a bad encoding. This file (or more than one) is located in one of 200 folders, i have to find it. |
I have found the file js that corrupts JSON. This is the eslint-angular.json
|
Wow it is self contained is some sort of recursive parse. Can you see what in the files cause that problem ? |
I have noticed if i remove the literal expression 'use strict' , the plugin works fine. |
Thanks, so it is a problem with this particular eslint issue, we will investigate it. |
Hi,
I have installed:
When I configure gulp to start scan on a single js file, it generates a valid JSON report, but when I select all project, I have this error:
15:45:05.818 INFO - Sensor JsHintQualitySensor done: 38140 ms 15:45:05.834 INFO - Sensor EslintAngularQualitySensor... 15:45:06.115 ERROR - failed to parse json file. Cause: Unexpected end-of-input: expected close marker for ARRAY (from [Source: java.io.InputStreamReader@7444d60 d; line: 5, column: 19]) at [Source: java.io.InputStreamReader@7444d60d; line: 345187, column: 327] (thr ough reference chain: fr.sii.sonar.report.core.quality.domain.report.QualityRepo rt["files"]) 15:45:06.115 DEBUG - Release semaphore on project : org.sonar.api.resources.Proj ect@119655f1[id=6804,key=cdfe,qualifier=TRK], with key batch-cdfe INFO: ------------------------------------------------------------------------ INFO: EXECUTION FAILURE INFO: ------------------------------------------------------------------------ Total time: 2:27.374s Final Memory: 23M/191M INFO: ------------------------------------------------------------------------ ERROR: Error during Sonar runner execution org.sonar.runner.impl.RunnerException: Unable to execute Sonar at org.sonar.runner.impl.BatchLauncher$1.delegateExecution(BatchLauncher .java:91) at org.sonar.runner.impl.BatchLauncher$1.run(BatchLauncher.java:75) at java.security.AccessController.doPrivileged(Native Method) at org.sonar.runner.impl.BatchLauncher.doExecute(BatchLauncher.java:69) at org.sonar.runner.impl.BatchLauncher.execute(BatchLauncher.java:50) at org.sonar.runner.api.EmbeddedRunner.doExecute(EmbeddedRunner.java:102 ) at org.sonar.runner.api.Runner.execute(Runner.java:100) at org.sonar.runner.Main.executeTask(Main.java:70) at org.sonar.runner.Main.execute(Main.java:59) at org.sonar.runner.Main.main(Main.java:53) Caused by: java.lang.IllegalArgumentException: Cannot parse report E:\cdil0\cdfe 0_SRC\.\reports\sonar\eslint-angular.json at fr.sii.sonar.report.core.common.ReportSensor.analyse(ReportSensor.jav a:109) at org.sonar.batch.phases.SensorsExecutor.executeSensor(SensorsExecutor. java:79) at org.sonar.batch.phases.SensorsExecutor.execute(SensorsExecutor.java:7 0) at org.sonar.batch.phases.PhaseExecutor.execute(PhaseExecutor.java:119) at org.sonar.batch.scan.ModuleScanContainer.doAfterStart(ModuleScanConta iner.java:194) at org.sonar.api.platform.ComponentContainer.startComponents(ComponentCo ntainer.java:93) at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer. java:78) at org.sonar.batch.scan.ProjectScanContainer.scan(ProjectScanContainer.j ava:233) at org.sonar.batch.scan.ProjectScanContainer.scanRecursively(ProjectScan Container.java:228) at org.sonar.batch.scan.ProjectScanContainer.doAfterStart(ProjectScanCon tainer.java:221) at org.sonar.api.platform.ComponentContainer.startComponents(ComponentCo ntainer.java:93) at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer. java:78) at org.sonar.batch.scan.ScanTask.scan(ScanTask.java:64) at org.sonar.batch.scan.ScanTask.execute(ScanTask.java:51) at org.sonar.batch.bootstrap.TaskContainer.doAfterStart(TaskContainer.ja va:125) at org.sonar.api.platform.ComponentContainer.startComponents(ComponentCo ntainer.java:93) at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer. java:78) at org.sonar.batch.bootstrap.BootstrapContainer.executeTask(BootstrapCon tainer.java:173) at org.sonar.batch.bootstrapper.Batch.executeTask(Batch.java:95) at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:67) at org.sonar.runner.batch.IsolatedLauncher.execute(IsolatedLauncher.java :48) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.sonar.runner.impl.BatchLauncher$1.delegateExecution(BatchLauncher .java:87) ... 9 more
My project has js files in multiple directories, please help me.
The text was updated successfully, but these errors were encountered: