org.apache.maven.lifecycle.LifecycleExecutionException

Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:2.4.2:shade (default) on project selenese-runner-java: Error creating shaded jar: duplicate entry: Main.class

Samebug tips0

There are no available Samebug tips for this exception. If you know how to solve this issue, help other users by writing a short tip.

Don't give up yet. Paste your full stack trace to get a solution.

Solutions on the web4964

  • via GitHub by sentry0
    , 10 months ago
    Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:2.4.2:shade (default) on project selenese-runner-java: Error creating shaded jar: duplicate entry: Main.class
  • Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:2.4.3:shade (default) on project shade: Error creating shaded jar: null
  • Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:1.2:shade (default) on project cxf-bundle: Error creating shaded jar.
  • Stack trace

    • org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:2.4.2:shade (default) on project selenese-runner-java: Error creating shaded jar: duplicate entry: Main.class at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217) 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:84) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59) at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183) at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196) at org.apache.maven.cli.MavenCli.main(MavenCli.java:141) 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:498) 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: org.apache.maven.plugin.MojoExecutionException: Error creating shaded jar: duplicate entry: Main.class at org.apache.maven.plugins.shade.mojo.ShadeMojo.execute(ShadeMojo.java:539) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209) ... 19 more Caused by: java.util.zip.ZipException: duplicate entry: Main.class at java.util.zip.ZipOutputStream.putNextEntry(ZipOutputStream.java:232) at java.util.jar.JarOutputStream.putNextEntry(JarOutputStream.java:109) at org.apache.maven.plugins.shade.resource.IncludeResourceTransformer.modifyOutputStream(IncludeResourceTransformer.java:63) at org.apache.maven.plugins.shade.DefaultShader.shade(DefaultShader.java:203) at org.apache.maven.plugins.shade.mojo.ShadeMojo.execute(ShadeMojo.java:454) ... 21 more

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    Unknown user
    2 times, 1 year ago