groovy-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paul King (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (GROOVY-6470) @Grab does not work if the same dependency is used with and without a classifier
Date Mon, 13 Nov 2017 03:27:01 GMT

     [ https://issues.apache.org/jira/browse/GROOVY-6470?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Paul King updated GROOVY-6470:
------------------------------
    Description: 
If a script uses the same artifact multiple times, once without a classifer and with classifier,
e.g. 

{code}
@Grab(group = "org.neo4j", module = "neo4j-kernel", version = "2.0.0-RC1")
@Grab(group = "org.neo4j", module = "neo4j-kernel", version = "2.0.0-RC1", classifier = "tests")
{code}

only the jar without a classifier is loaded.

The root cause for this is some weird behaviour in Ivy. Ivy expects for this case a single
DependencyDescriptor with multiple ArtifactDescriptors. Groovy generates a DependencyDescriptor
for each dependency.

I've created locally a test case demoing the wrong behaviour and a bugfix as well. If desired
I can sent a pull request for this. I assume the PR should be created vs master branch.

  was:
If a script uses the same artifact multiple times, once without a classiefer and with classifier,
e.g. 

{code}
@Grab(group = "org.neo4j", module = "neo4j-kernel", version = "2.0.0-RC1")
@Grab(group = "org.neo4j", module = "neo4j-kernel", version = "2.0.0-RC1", classifier = "tests")
{code}

only the jar without a classifier is loaded.

The root cause for this is some weird behaviour in Ivy. Ivy expects for this case a single
DependencyDescriptor with multiple ArtifactDescriptors. Groovy generates a DependencyDescriptor
for each dependency.

I've created locally a test case demoing the wrong behaviour and a bugfix as well. If desired
I can sent a pull request for this. I assume the PR should be created vs master branch.


> @Grab does not work if the same dependency is used with and without a classifier
> --------------------------------------------------------------------------------
>
>                 Key: GROOVY-6470
>                 URL: https://issues.apache.org/jira/browse/GROOVY-6470
>             Project: Groovy
>          Issue Type: Bug
>          Components: Grape
>    Affects Versions: 2.2.1
>            Reporter: Stefan Armbruster
>            Assignee: Paul King
>             Fix For: 2.2.2
>
>
> If a script uses the same artifact multiple times, once without a classifer and with
classifier, e.g. 
> {code}
> @Grab(group = "org.neo4j", module = "neo4j-kernel", version = "2.0.0-RC1")
> @Grab(group = "org.neo4j", module = "neo4j-kernel", version = "2.0.0-RC1", classifier
= "tests")
> {code}
> only the jar without a classifier is loaded.
> The root cause for this is some weird behaviour in Ivy. Ivy expects for this case a single
DependencyDescriptor with multiple ArtifactDescriptors. Groovy generates a DependencyDescriptor
for each dependency.
> I've created locally a test case demoing the wrong behaviour and a bugfix as well. If
desired I can sent a pull request for this. I assume the PR should be created vs master branch.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message