[GRADLE-3514] Ivy Publish plugin does not reflect transitive = false for a dependency in generated metadata Created: 27/Jul/16  Updated: 27/Jul/16  Resolved: 27/Jul/16

Status: Resolved
Project: Gradle
Affects Version/s: None
Fix Version/s: 3.1-rc-1

Type: Bug
Reporter: Benjamin Muschko Assignee: Benjamin Muschko
Resolution: Fixed Votes: 0

Known Issue Of:


The Ivy Publishing plugin does not take into account the transitive attribute declared for a dependency when generating the publishing metadata. The problem can be exposed with the following sample project:

apply plugin: 'java'
apply plugin: 'ivy-publish'

group = 'org.gradle'
version = '1.0'

dependencies {
    compile "commons-dbcp:commons-dbcp:1.4", {
        transitive = false

publishing {
   publications {
       ivy(IvyPublication) {
           from components.java
   repositories {
       ivy { 
           url "file://${buildDir}/repo" 

The result is a ivy.xml file containing the following dependency declaration for commons-dbcp:commons-dbcp:1.4:

    <dependency org="commons-dbcp" name="commons-dbcp" rev="1.4" conf="runtime-&gt;default"/>

The expected metadata should declare the attribute transitive="false" according to Ivy's behavior.

Generated at Wed Jun 30 12:50:46 CDT 2021 using Jira 8.4.2#804003-sha1:d21414fc212e3af190e92c2d2ac41299b89402cf.