Skip to content
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

Exception "Unexpected token: to" after upgrading to 4.3.0 #72

Closed
marek-parfianowicz opened this issue Dec 17, 2019 · 1 comment
Closed

Exception "Unexpected token: to" after upgrading to 4.3.0 #72

marek-parfianowicz opened this issue Dec 17, 2019 · 1 comment
Labels
Milestone

Comments

@marek-parfianowicz
Copy link
Member

@marek-parfianowicz marek-parfianowicz commented Dec 17, 2019

Hi,

I tried to switch to OpenClover version 4.3.0 from previous version, but am getting an exception during the instrumentation build with maven. This does not happen with OpenClover 4.2.1.

{code} [INFO] OpenClover Version 4.3.0, built on August 03 2018 (build-1010) [INFO] Updating existing database at '/Users/myUser/Projects/client_folder/client_project/testing_dependencies/target/clover/clover.db'. [INFO] Processing files at 1.8 source level. [INFO] /Users/myUser/Projects/client_folder/client_project/brightcove_connector/brightcove-services/src/main/java/org/jsonBC/JSONTokener.java:385:29:unexpected token: to [INFO] Instrumentation error com.atlassian.clover.api.CloverException: /Users/myUser/Projects/client_folder/client_project/brightcove_connector/brightcove-services/src/main/java/org/jsonBC/JSONTokener.java:385:29:unexpected token: to at com.atlassian.clover.instr.java.Instrumenter.instrument(Instrumenter.java:159) at com.atlassian.clover.CloverInstr.execute(CloverInstr.java:76) at com.atlassian.clover.CloverInstr.mainImpl(CloverInstr.java:54) at com.atlassian.maven.plugin.clover.internal.instrumentation.AbstractInstrumenter.instrumentSources(AbstractInstrumenter.java:197) at com.atlassian.maven.plugin.clover.internal.instrumentation.AbstractInstrumenter.instrument(AbstractInstrumenter.java:72) at com.atlassian.maven.plugin.clover.CloverInstrumentInternalMojo.execute(CloverInstrumentInternalMojo.java:289) at com.atlassian.maven.plugin.clover.CloverSetupMojo.execute(CloverSetupMojo.java:31) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80) at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51) at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288) at org.apache.maven.cli.MavenCli.main(MavenCli.java:199) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289) at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229) at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415) at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356) Caused by: line 385:29: unexpected token: to at com.atlassian.clover.instr.java.JavaRecognizer.parameterDeclaration(JavaRecognizer.java:3813) at com.atlassian.clover.instr.java.JavaRecognizer.parameterDeclarationList(JavaRecognizer.java:2975) at com.atlassian.clover.instr.java.JavaRecognizer.field(JavaRecognizer.java:2639) at com.atlassian.clover.instr.java.JavaRecognizer.classBlock(JavaRecognizer.java:2126) at com.atlassian.clover.instr.java.JavaRecognizer.classDefinition(JavaRecognizer.java:1134) at com.atlassian.clover.instr.java.JavaRecognizer.typeDefinition2(JavaRecognizer.java:1064) at com.atlassian.clover.instr.java.JavaRecognizer.typeDefinition(JavaRecognizer.java:968) at com.atlassian.clover.instr.java.JavaRecognizer.compilationUnit(JavaRecognizer.java:880) at com.atlassian.clover.instr.java.Instrumenter.instrument(Instrumenter.java:211) at com.atlassian.clover.instr.java.Instrumenter.instrument(Instrumenter.java:124) ... 28 more {code}

I am running {code} $ mvn -version Apache Maven 3.3.9 (bb52d8502b132ec0a5a3f4c09453c07478323dc5; 2015-11-10T17:41:47+01:00) Maven home: /usr/local/Cellar/maven/3.3.9/libexec Java version: 1.8.0_45, vendor: Oracle Corporation Java home: /Library/Java/JavaVirtualMachines/jdk1.8.0_45.jdk/Contents/Home/jre Default locale: en_US, platform encoding: UTF-8 OS name: "mac os x", version: "10.13.6", arch: "x86_64", family: "mac" {code}

Find the java class attached for which this exception is raised.

@marek-parfianowicz

This comment has been minimized.

Copy link
Member Author

@marek-parfianowicz marek-parfianowicz commented Dec 17, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
1 participant
You can’t perform that action at this time.