自上周以来,我就因为这个特殊错误而伤透了脑筋。我无法从世界任何地方找到此错误的解决方案。
我正在为我的项目新设置 Sonar 。
在执行 sonar-runner 时,我收到以下错误。有人可以帮我看看错误是什么吗?
11:53:31.185 WARN - Class 'ui/component/JXCollapsiblePane' is not accessible through the ClassLoader.
11:53:31.187 INFO - Java bytecode scan done: 10026 ms
11:53:31.374 INFO - Package design analysis...
11:53:36.044 INFO - Package design analysis done: 4670 ms
11:53:45.673 INFO - Sensor JavaSquidSensor done: 63118 ms
11:53:45.673 INFO - Sensor SurefireSensor...
11:53:45.675 INFO - parsing /home/jenkins/.jenkins/workspace/CSF_Build/CRM/.sonar/build/surefire-reports
11:53:45.676 INFO - Sensor SurefireSensor done: 3 ms
11:53:45.676 INFO - Sensor CpdSensor...
11:53:45.676 INFO - SonarEngine is used
11:53:45.847 INFO - Cross-project analysis disabled
INFO: ------------------------------------------------------------------------
INFO: EXECUTION FAILURE
INFO: ------------------------------------------------------------------------
INFO: Total time: 2:03.486s
INFO: Final Memory: 12M/452M
INFO: ------------------------------------------------------------------------
ERROR: Error during Sonar runner execution
ERROR: Unable to execute Sonar
ERROR: Caused by: Unable to build statement from token : ''[301,2]
ERROR: Caused by: None of the statement channel has been able to consume token: ''[301,2]
ERROR:
ERROR: To see the full stack trace of the errors, re-run Sonar Runner with the -e switch.
ERROR: Re-run Sonar Runner using the -X switch to enable full debug logging.
最佳答案
我已经发现了这个问题。
其中一个 java 文件已使用错误的字符集 checkin 代码存储库。扫描此 java 文件时,代码扫描被弹出
关于java - org.sonar.duplications.DuplicationsException : Unable to build statement from token,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23335943/