[GRADLE-2371] Scope mappings from POM dependency management do not consider type attribute Created: 05/Jul/12 Updated: 10/Nov/13 Resolved: 10/Nov/13 |
|
Status: | Resolved |
Project: | Gradle |
Affects Version/s: | None |
Fix Version/s: | 1.10-rc-1 |
Type: | Bug | ||
Reporter: | Gradle Forums | Assignee: | Unassigned |
Resolution: | Fixed | Votes: | 0 |
Description |
This gist has 4 files: [1]https://gist.github.com/3052189
Why are the outputs not equal? The gradle dependencies are missing a lot of transitive dependencies, like activemq-core, which is a transitive compile scoped dependency. In fact, it seems like Gradle only "follows" the two first top-level dependencies for their transitive dependencies (slf4j-api and camel-jms). What about the rest? Environment: Gradle 1.0 Apache Maven 3.0.3 (r1075438; 2011-02-28 18:31:09+0100) |
Comments |
Comment by Gradle Forums [ 05/Jul/12 ] |
You have indeed exposed a bug in our handling of Maven pom files: Ivy 2.0 has reverse engineered the pom parsing logic and we are currently using a slightly modified version this code. We have plans to try to switch to using Maven code directly for pom parsing, but it's not trivial to integrate. The crux of the issue is the dependency management block in the [1]activemq-parent pom, which contains: <dependency> Unfortunately, we don't differentiate based on the `type` attribute, and the second entry overwrites the first, causing `activemq-core` to be mapped to the `test` scope. This explains why `activemq-core` and it's transitive dependencies are not part of the compile configuration. For now, the workaround for this issue is to use a [2]Client Module dependency declaration, such as: dependencies { ---------------------------------------------------------------------------------------- |