Sonar Report .DuplicationsException

we are getting below error
while trying to generate sonar report on our working repository
here is the version we are using

sonarqube-8.4.2.36762

can you let us know how to identify what file has issue so that we can fix

org.sonar.duplications.DuplicationsException: Unable to build statement from token : '*'[266,3]
        at org.sonar.duplications.statement.StatementChunker.chunk(StatementChunker.java:50)
        at org.sonar.scanner.cpd.JavaCpdBlockIndexerSensor.createIndex(JavaCpdBlockIndexerSensor.java:99)
        at org.sonar.scanner.cpd.JavaCpdBlockIndexerSensor.execute(JavaCpdBlockIndexerSensor.java:83)
        at org.sonar.scanner.sensor.AbstractSensorWrapper.analyse(AbstractSensorWrapper.java:48)
        at org.sonar.scanner.sensor.ProjectSensorsExecutor.execute(ProjectSensorsExecutor.java:49)
        at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:356)
        at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:137)
        at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:123)
        at org.sonar.scanner.bootstrap.GlobalContainer.doAfterStart(GlobalContainer.java:144)
        at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:137)
        at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:123)
        at org.sonar.batch.bootstrapper.Batch.doExecute(Batch.java:72)
        at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:66)
        at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:566)
        at org.sonarsource.scanner.api.internal.IsolatedLauncherProxy.invoke(IsolatedLauncherProxy.java:60)
        at com.sun.proxy.$Proxy3.execute(Unknown Source)
        at org.sonarsource.scanner.api.EmbeddedScanner.doExecute(EmbeddedScanner.java:185)
        at org.sonarsource.scanner.api.EmbeddedScanner.execute(EmbeddedScanner.java:137)
        at org.sonarsource.scanner.ant.SonarQubeTask.launchAnalysis(SonarQubeTask.java:107)
        at org.sonarsource.scanner.ant.SonarQubeTask.execute(SonarQubeTask.java:88)
        at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
        at jdk.internal.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:566)
        at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:99)
        at org.apache.tools.ant.Task.perform(Task.java:350)
        at java.base/java.util.Vector.forEach(Vector.java:1387)
        at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:67)
        at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
        at jdk.internal.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:566)
        at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:99)
        at org.apache.tools.ant.Task.perform(Task.java:350)
        at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.java:391)
        at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
        at jdk.internal.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:566)
        at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:99)
        at org.apache.tools.ant.Task.perform(Task.java:350)
        at org.apache.tools.ant.Target.execute(Target.java:449)
        at org.apache.tools.ant.Target.performTasks(Target.java:470)
        at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1388)
        at org.apache.tools.ant.Project.executeTarget(Project.java:1361)
        at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
        at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
        at org.apache.tools.ant.Main.runBuild(Main.java:834)
        at org.apache.tools.ant.Main.startAnt(Main.java:223)
        at org.apache.tools.ant.launch.Launcher.run(Launcher.java:284)
        at org.apache.tools.ant.launch.Launcher.main(Launcher.java:101)
Caused by: java.lang.IllegalStateException: None of the statement channel has been able to consume token: '*'[266,3]
        at org.sonar.duplications.statement.StatementChannelDisptacher.consume(StatementChannelDisptacher.java:46)
        at org.sonar.duplications.statement.StatementChunker.chunk(StatementChunker.java:47)
        ... 54 more

Hi,

Welcome to the community!

Thanks for this report. Are you able to provide a concise reproducer file?

 
Ann

hi
plz check this
SonarLogs.txt (110.2 KB)

hi
plz check this

SonarLogs.txt (110.2 KB)

if you are available we can connect in call also to discuss further.

Hi,

Thanks for the analysis log. What I was actually asking for is a small file or file set that can cause the problem.

 
Ann

hi for that we need to share entire our source code that might not be possible

if you have any other suggestions let me know