You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Stefan Filip (Jira)" <ji...@apache.org> on 2021/07/19 19:44:00 UTC

[jira] [Commented] (MSHADE-399) Infinite cycle with same test dependency at different versions

    [ https://issues.apache.org/jira/browse/MSHADE-399?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17383544#comment-17383544 ] 

Stefan Filip commented on MSHADE-399:
-------------------------------------

I encountered this issue working on Apache Spark related things. In the master branch of Spark, creating dependency reduced jars was disabled in the patch for SPARK-33212. I haven't synced with the author of that patch to understand more about the issue that they were seeing.

> Infinite cycle with same test dependency at different versions
> --------------------------------------------------------------
>
>                 Key: MSHADE-399
>                 URL: https://issues.apache.org/jira/browse/MSHADE-399
>             Project: Maven Shade Plugin
>          Issue Type: Bug
>    Affects Versions: 3.2.4
>         Environment: maven 3.8.1
> maven-shade-plugin 3.3.1-SNAPSHOT (I tested various version, 2.4.1, 3.1.1, 3.2.1, 3.2.4)
>            Reporter: Stefan Filip
>            Priority: Major
>         Attachments: mvn-cycle.zip
>
>
> Hello,
> The Maven Shade plugin goes into an infinite loop when we specify a test dependency with the following properties: 
>  # the artifactId of the dependency is specified using properties
>  # we have a parent that specified a different version of the dependency
>  # the test dependency has dependencies of its own
> I attached the smallest repro that I could get in mvn-cycle.zip. `mvn clean install` will reproduce the issue.
> I debugged a bit but I don't understand exactly what the code is trying to do or the maven APIs that are called. The issue here looks to be that the project that is constructed at the reduced-pom phase. The project ends up having the with the dependency list containing both versions of test dependency and that invalidates the assumptions of the reduction loop.
> Let me know if you have questions.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)