You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "Java Rab (JIRA)" <ji...@codehaus.org> on 2005/04/11 17:40:42 UTC

[jira] Created: (MAVEN-1590) Maven wont deploy dependencies with same artifiactId

Maven wont deploy dependencies with same artifiactId
----------------------------------------------------

         Key: MAVEN-1590
         URL: http://jira.codehaus.org/browse/MAVEN-1590
     Project: maven
        Type: Bug
  Components: core  
    Versions: 1.0, 1.0.1, 1.0.2    
 Environment: Windows XP - JDK1.4.3_06
    Reporter: Java Rab


It appears that Maven is unable to differentiate between artifacts with same artifactId but different types.

The scenario under which this bug becomes apparent is when you attempt to deploy, for example, displaytags for use in your webapp.

The project.xml would look something like:

        <dependency>
            <groupId>displaytag</groupId>
            <artifactId>displaytag</artifactId>
            <version>1.0</version>
            <type>jar</type>
            <properties>
                <war.bundle>true</war.bundle>
                <war.manifest.classpath>true</war.manifest.classpath>
            </properties>
        </dependency>
        <dependency>
            <groupId>displaytag</groupId>
            <artifactId>displaytag</artifactId>
            <type>tld</type>
            <version>12</version>
            <properties>
                <war.bundle>true</war.bundle>
            </properties>
        </dependency>

When maven attempts to run war:webapp, the displaytag-1.0.jar file is deployed to WEB-INF/lib directory but the tld dependency isn't deployed to WEB-INF/tld. If I were to reverse the order of these dependencies in the project.xml file, the first dependency is deployed, subsequent dependencies of same artifactId are not. This leads me to believe MAVEN considers dependencies with same artifactId duplicate - even although they are declared with different types.

If I now go into my MAVEN repo and change the name of the tld dependency to something like displaytag-maven-hack-12.tld and update the artifactId to be displaytag-maven-hack then it deploys both artifiacts quite happily. 

Please consider this bug request and consider implementing a fix for the release of 1.1. I would look into providing a fix if I wasn't so busy at the moment. Thanks Rab.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


[jira] Closed: (MAVEN-1590) Maven wont deploy dependencies with same artifiactId

Posted by "Brett Porter (JIRA)" <ji...@codehaus.org>.
     [ http://jira.codehaus.org/browse/MAVEN-1590?page=history ]
     
Brett Porter closed MAVEN-1590:
-------------------------------

    Resolution: Duplicate

fixed in Maven 1.1, and reported several times already.

> Maven wont deploy dependencies with same artifiactId
> ----------------------------------------------------
>
>          Key: MAVEN-1590
>          URL: http://jira.codehaus.org/browse/MAVEN-1590
>      Project: maven
>         Type: Bug
>   Components: core
>     Versions: 1.0, 1.0.1, 1.0.2
>  Environment: Windows XP - JDK1.4.3_06
>     Reporter: Java Rab

>
> Original Estimate: 1 hour
>         Remaining: 1 hour
>
> It appears that Maven is unable to differentiate between artifacts with same artifactId but different types.
> The scenario under which this bug becomes apparent is when you attempt to deploy, for example, displaytags for use in your webapp.
> The project.xml would look something like:
>         <dependency>
>             <groupId>displaytag</groupId>
>             <artifactId>displaytag</artifactId>
>             <version>1.0</version>
>             <type>jar</type>
>             <properties>
>                 <war.bundle>true</war.bundle>
>                 <war.manifest.classpath>true</war.manifest.classpath>
>             </properties>
>         </dependency>
>         <dependency>
>             <groupId>displaytag</groupId>
>             <artifactId>displaytag</artifactId>
>             <type>tld</type>
>             <version>12</version>
>             <properties>
>                 <war.bundle>true</war.bundle>
>             </properties>
>         </dependency>
> When maven attempts to run war:webapp, the displaytag-1.0.jar file is deployed to WEB-INF/lib directory but the tld dependency isn't deployed to WEB-INF/tld. If I were to reverse the order of these dependencies in the project.xml file, the first dependency is deployed, subsequent dependencies of same artifactId are not. This leads me to believe MAVEN considers dependencies with same artifactId duplicate - even although they are declared with different types.
> If I now go into my MAVEN repo and change the name of the tld dependency to something like displaytag-maven-hack-12.tld and update the artifactId to be displaytag-maven-hack then it deploys both artifiacts quite happily. 
> Please consider this bug request and consider implementing a fix for the release of 1.1. I would look into providing a fix if I wasn't so busy at the moment. Thanks Rab.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org