ParseErrors and java.lang.UnsupportedOperationException Errors

Must-share information (formatted with Markdown):

  • which versions are you using (SonarQube, Scanner, Plugin, and any relevant extension)
  • We are using SQ version 8.9 and Using plugins CodeScan and CodeScan Lang
  • what are you trying to achieve
  • We have integrated with out github repo’s and running it in the pipelines for the PR’s to run static analysis
  • what have you tried so far to achieve this
  • We have tried downgrading the CodeScan and CodeLang versions but still getting the errors

Issues Faced

  • We are getting parse errors in the pipeline and we need help to figure out the cause of those - errors are below:
# Error 1
INFO: Sensor CodeScan parser [codescan]

954ERROR: error while parsing file 'sfdx/node_modules/@salesforce/templates/lib/templates/apexclass/DefaultApexClass.cls'

955com.villagechief.pmd.lang.apex.ast.ParseException: Encountered " "<" "< "" at line 1, column 27.

956Was expecting:

957 <IDENTIFIER> ...


959 at com.villagechief.pmd.lang.apex.ast.ApexParser.generateParseException(

960 at com.villagechief.pmd.lang.apex.ast.ApexParser.jj_consume_token(
# Error 2

ERROR: Parse error at line 7 column 3:


1284 1: // @flow

1285 2:

1286 3: declare module.exports: (

1287 4: dateLeft: Date | string | number,

1288 5: dateRight: Date | string | number

1289 6: ) => number

1290 --> EOF
# Error 3
ERROR: Error during SonarScanner execution
The only way to get an accurate analysis of C/C++/Objective-C files is by using the SonarSource build-wrapper
and setting the property "", but it was not specified.
If you don't want to analyze C/C++/Objective-C files, then prevent them from being analyzed by setting the following properties:
	at com.sonar.cpp.plugin.CFamilySensor.process(
	at com.sonar.cpp.plugin.CFamilySensor.execute(
	at org.sonar.scanner.sensor.AbstractSensorWrapper.analyse(
	at org.sonar.scanner.sensor.ModuleSensorsExecutor.execute(
	at org.sonar.scanner.sensor.ModuleSensorsExecutor.execute(
	at org.sonar.scanner.scan.ModuleScanContainer.doAfterStart(
	at org.sonar.core.platform.ComponentContainer.startComponents(
	at org.sonar.core.platform.ComponentContainer.execute(
	at org.sonar.scanner.scan.ProjectScanContainer.scan(
	at org.sonar.scanner.scan.ProjectScanContainer.scanRecursively(
	at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(
	at org.sonar.core.platform.ComponentContainer.startComponents(
	at org.sonar.core.platform.ComponentContainer.execute(
	at org.sonar.scanner.bootstrap.GlobalContainer.doAfterStart(
	at org.sonar.core.platform.ComponentContainer.startComponents(
	at org.sonar.core.platform.ComponentContainer.execute(
	at org.sonar.batch.bootstrapper.Batch.doExecute(
	at org.sonar.batch.bootstrapper.Batch.execute(
	at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(
	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(
	at com.sun.proxy.$Proxy0.execute(Unknown Source)
	at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(
	at org.sonarsource.scanner.api.EmbeddedScanner.execute(
	at org.sonarsource.scanner.cli.Main.execute(
	at org.sonarsource.scanner.cli.Main.execute(
	at org.sonarsource.scanner.cli.Main.main(
ERROR: Re-run SonarScanner using the -X switch to enable full debug logging.

Need Urgent Help on this please


Welcome to the community!

We try to keep it to one question per thread. Otherwise things get messy.

It seems that your first error is caused by your CodeScan plugin. You’ll need to reach out to them for that.

For the second error, I can’t tell but I’m guessing it’s the same.

For the third error, it seems that your project includes C, C++ or Objective-C files but you haven’t followed the correct procedures to analyze those files.


Hi Ann,

Thank you for the response.

How can I reach out to codescan for the issue - is there any way or link to check with them ?



This is a 3rd-party commercial product. Perhaps their sales rep can point you in the right direction.