You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "Carlos Sanchez (JIRA)" <ji...@codehaus.org> on 2005/11/04 07:49:07 UTC
[jira] Created: (MNG-1417) Relocated artifacts hide other versions that should be picked
Relocated artifacts hide other versions that should be picked
-------------------------------------------------------------
Key: MNG-1417
URL: http://jira.codehaus.org/browse/MNG-1417
Project: Maven 2
Type: Bug
Versions: 2.0
Reporter: Carlos Sanchez
Priority: Critical
Fix For: 2.0.1
The output of mvn -X shows nothing about the servlet-api 2.4
<project>
<modelVersion>4.0.0</modelVersion>
<groupId>test</groupId>
<version>1</version>
<artifactId>test</artifactId>
<dependencies>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
<version>2.4</version>
</dependency>
<dependency>
<groupId>servletapi</groupId>
<artifactId>servletapi</artifactId>
<version>2.3</version>
</dependency>
</dependencies>
</project>
This is other test that fails
<project>
<modelVersion>4.0.0</modelVersion>
<groupId>test</groupId>
<version>1</version>
<artifactId>test</artifactId>
<dependencies>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
<version>2.4</version>
</dependency>
<dependency>
<groupId>commons-chain</groupId>
<artifactId>commons-chain</artifactId>
<version>1.0</version>
</dependency>
</dependencies>
</project>
--
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
-
For more information on JIRA, 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] Commented: (MNG-1417) Relocated artifacts hide other versions that should be picked
Posted by "Carlos Sanchez (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-1417?page=comments#action_51719 ]
Carlos Sanchez commented on MNG-1417:
-------------------------------------
but shouldn't the output of -X say 2.4 overriden by 2.3, as it does for other use cases?
> Relocated artifacts hide other versions that should be picked
> -------------------------------------------------------------
>
> Key: MNG-1417
> URL: http://jira.codehaus.org/browse/MNG-1417
> Project: Maven 2
> Type: Bug
> Components: maven-artifact
> Versions: 2.0
> Reporter: Carlos Sanchez
> Assignee: John Casey
> Priority: Critical
> Fix For: 2.0.1
>
> Original Estimate: 2 hours
> Time Spent: 1 hour
> Remaining: 0 minutes
>
> The output of mvn -X shows nothing about the servlet-api 2.4
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>servletapi</groupId>
> <artifactId>servletapi</artifactId>
> <version>2.3</version>
> </dependency>
> </dependencies>
> </project>
> This is other test that fails
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>commons-chain</groupId>
> <artifactId>commons-chain</artifactId>
> <version>1.0</version>
> </dependency>
> </dependencies>
> </project>
--
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
-
For more information on JIRA, 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: (MNG-1417) Relocated artifacts hide other versions that should be picked
Posted by "John Casey (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-1417?page=all ]
John Casey closed MNG-1417:
---------------------------
Resolution: Won't Fix
In the first test case, the servlet dependency is essentially respecified at the same transitive depth with a different version. Since the project's dependency collection is resolved using set semantics, it's undefined which servlet-api dependency will take precedence over the other, but the first encountered will win.
In the second test, the servlet-api for commons-chain is optional and at a greater depth than the servlet-api dependency specified directly in the pom. In this case, the direct specification wins.
Both tests have been verified to be working correctly.
> Relocated artifacts hide other versions that should be picked
> -------------------------------------------------------------
>
> Key: MNG-1417
> URL: http://jira.codehaus.org/browse/MNG-1417
> Project: Maven 2
> Type: Bug
> Components: maven-artifact
> Versions: 2.0
> Reporter: Carlos Sanchez
> Assignee: John Casey
> Priority: Critical
> Fix For: 2.0.1
>
> Original Estimate: 2 hours
> Time Spent: 1 hour
> Remaining: 0 minutes
>
> The output of mvn -X shows nothing about the servlet-api 2.4
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>servletapi</groupId>
> <artifactId>servletapi</artifactId>
> <version>2.3</version>
> </dependency>
> </dependencies>
> </project>
> This is other test that fails
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>commons-chain</groupId>
> <artifactId>commons-chain</artifactId>
> <version>1.0</version>
> </dependency>
> </dependencies>
> </project>
--
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
-
For more information on JIRA, 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] Updated: (MNG-1417) Relocated artifacts hide other versions that should be picked
Posted by "John Casey (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-1417?page=all ]
John Casey updated MNG-1417:
----------------------------
Component: maven-artifact
Complexity: Expert (was: Intermediate)
Remaining Estimate: 2 hours
Original Estimate: 2 hours
something in the recurse() method of the DefaultArtifactCollector is failing to compare the dependencies by depth when one has been relocated. I'll hook up the debugger and see what I can see.
> Relocated artifacts hide other versions that should be picked
> -------------------------------------------------------------
>
> Key: MNG-1417
> URL: http://jira.codehaus.org/browse/MNG-1417
> Project: Maven 2
> Type: Bug
> Components: maven-artifact
> Versions: 2.0
> Reporter: Carlos Sanchez
> Assignee: John Casey
> Priority: Critical
> Fix For: 2.0.1
>
> Original Estimate: 2 hours
> Remaining: 2 hours
>
> The output of mvn -X shows nothing about the servlet-api 2.4
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>servletapi</groupId>
> <artifactId>servletapi</artifactId>
> <version>2.3</version>
> </dependency>
> </dependencies>
> </project>
> This is other test that fails
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>commons-chain</groupId>
> <artifactId>commons-chain</artifactId>
> <version>1.0</version>
> </dependency>
> </dependencies>
> </project>
--
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
-
For more information on JIRA, 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] Reopened: (MNG-1417) Relocated artifacts hide other versions that should be picked
Posted by "Carlos Sanchez (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-1417?page=all ]
Carlos Sanchez reopened MNG-1417:
---------------------------------
We should get the output saying that one version is removed as we get for other artifacts
eg.
commons-collections:commons-collections:jar:2.1 (removed - nearer found: 3.1)
> Relocated artifacts hide other versions that should be picked
> -------------------------------------------------------------
>
> Key: MNG-1417
> URL: http://jira.codehaus.org/browse/MNG-1417
> Project: Maven 2
> Type: Bug
> Components: maven-artifact
> Versions: 2.0
> Reporter: Carlos Sanchez
> Assignee: John Casey
> Priority: Critical
> Fix For: 2.0.1
>
> Original Estimate: 2 hours
> Time Spent: 1 hour
> Remaining: 0 minutes
>
> The output of mvn -X shows nothing about the servlet-api 2.4
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>servletapi</groupId>
> <artifactId>servletapi</artifactId>
> <version>2.3</version>
> </dependency>
> </dependencies>
> </project>
> This is other test that fails
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>commons-chain</groupId>
> <artifactId>commons-chain</artifactId>
> <version>1.0</version>
> </dependency>
> </dependencies>
> </project>
--
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
-
For more information on JIRA, 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: (MNG-1417) Relocated artifacts hide other versions that should be picked
Posted by "John Casey (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-1417?page=all ]
John Casey closed MNG-1417:
---------------------------
Resolution: Fixed
cleaned up the debug output a bit, to make sure it doesn't say it's selecting both versions...my output now has:
[DEBUG] test:test:jar:1 (selected for null)
[WARNING] While downloading servletapi:servletapi:2.3
This artifact has been relocated to javax.servlet:servlet-api:2.3.
[DEBUG] javax.servlet:servlet-api:jar:2.3 (selected for compile)
[DEBUG] javax.servlet:servlet-api:jar:2.4 (removed - nearer found: 2.3)
> Relocated artifacts hide other versions that should be picked
> -------------------------------------------------------------
>
> Key: MNG-1417
> URL: http://jira.codehaus.org/browse/MNG-1417
> Project: Maven 2
> Type: Bug
> Components: Artifacts and Repositories
> Versions: 2.0
> Reporter: Carlos Sanchez
> Assignee: John Casey
> Priority: Critical
> Fix For: 2.0.1
>
> Original Estimate: 2 hours
> Time Spent: 1 hour
> Remaining: 0 minutes
>
> The output of mvn -X shows nothing about the servlet-api 2.4
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>servletapi</groupId>
> <artifactId>servletapi</artifactId>
> <version>2.3</version>
> </dependency>
> </dependencies>
> </project>
> This is other test that fails
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>commons-chain</groupId>
> <artifactId>commons-chain</artifactId>
> <version>1.0</version>
> </dependency>
> </dependencies>
> </project>
--
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
-
For more information on JIRA, 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] Commented: (MNG-1417) Relocated artifacts hide other versions that should be picked
Posted by "Carlos Sanchez (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-1417?page=comments#action_50005 ]
Carlos Sanchez commented on MNG-1417:
-------------------------------------
A workaround is exclude the relocated artifacts where used
<dependency>
<groupId>struts</groupId>
<artifactId>struts</artifactId>
<version>1.2.7</version>
<optional/>
<exclusions>
<exclusion>
<groupId>servletapi</groupId>
<artifactId>servletapi</artifactId>
</exclusion>
</exclusions>
</dependency>
> Relocated artifacts hide other versions that should be picked
> -------------------------------------------------------------
>
> Key: MNG-1417
> URL: http://jira.codehaus.org/browse/MNG-1417
> Project: Maven 2
> Type: Bug
> Versions: 2.0
> Reporter: Carlos Sanchez
> Priority: Critical
> Fix For: 2.0.1
>
>
> The output of mvn -X shows nothing about the servlet-api 2.4
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>servletapi</groupId>
> <artifactId>servletapi</artifactId>
> <version>2.3</version>
> </dependency>
> </dependencies>
> </project>
> This is other test that fails
> <project>
> <modelVersion>4.0.0</modelVersion>
> <groupId>test</groupId>
> <version>1</version>
> <artifactId>test</artifactId>
> <dependencies>
> <dependency>
> <groupId>javax.servlet</groupId>
> <artifactId>servlet-api</artifactId>
> <version>2.4</version>
> </dependency>
> <dependency>
> <groupId>commons-chain</groupId>
> <artifactId>commons-chain</artifactId>
> <version>1.0</version>
> </dependency>
> </dependencies>
> </project>
--
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
-
For more information on JIRA, 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