1

I am reffering to following pom entry for dependencies of htmlunit-driver.

<dependency>
    <groupId>org.seleniumhq.selenium</groupId>
    <artifactId>htmlunit-driver</artifactId>
    <version>2.27</version>
</dependency>

But while packaging it with a JNLP file, I am getting following error:

Failed to execute goal org.codehaus.mojo:webstart-maven-plugin:1.0-beta-6:jnlp-inline (package) on project : Error while updating manifest of unprocessed_htmlunit-driver__V2.27.jar: duplicate entry: META-INF/maven/org.seleniumhq.selenium/htmlunit-driver/pom.xml -> [Help 1]

Investigating further I found that the htmlunit-driver-2.27.jar file contains two pom.properties and pom.xml.

enter image description here

Please help me to solve the issue:

  1. Should I rectify the JAR and use my own version .
  2. Is there any maven plugin available which can automatically resolve such corrupted JAR files.
  3. Any other available option.
Amit
  • 182
  • 3
  • 3
  • 12
  • How exactly are you packaging it? – Steve C Jun 13 '17 at 13:31
  • I am using webstart-maven-plugin for packaging .Although , everything was working fine till 2.21 version of this jar, but it broke when I upgraded to 2.27 version of the jar . The jar file available in maven central is incorrect , you may download and check the same. – Amit Jun 13 '17 at 14:20
  • You're right, those jars are busted. Are using a repository manager? I would repair the jar that you want (un-jar, remove duplicates and re-jar) and deploy it your repository manager with a different version - say 2.27.FIX or something like that – Steve C Jun 14 '17 at 00:39
  • Yes Steve , thanks for the suggestion , as of now I am doing the same . – Amit Jun 14 '17 at 06:08

1 Answers1

0

This happens because of Eclipse/maven conflict as hinted in this question.

Since 2.27 was released, it can't be changed, but 2.28-snapshot was just deployed, if you can use it.

Otherwise, you can manually make your own version.

Regarding the next releases, mven clean should always precede deploy.

Ahmed Ashour
  • 5,179
  • 10
  • 35
  • 56
  • Thanks for the answer Ahmed. I am manually fixing them and keeping my own version . – Amit Jun 14 '17 at 06:10