maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrei Tomashpolskiy (JIRA)" <>
Subject [jira] [Created] (MDEP-558) Dependency version from test scope leaks into compile scope
Date Mon, 13 Mar 2017 12:03:41 GMT
Andrei Tomashpolskiy created MDEP-558:

             Summary: Dependency version from test scope leaks into compile scope
                 Key: MDEP-558
             Project: Maven Dependency Plugin
          Issue Type: Bug
          Components: analyze
    Affects Versions: 3.0.0, 2.10, 2.8
            Reporter: Andrei Tomashpolskiy

Despite test scope being non-transitive [1] it's still used to resolve versions of compile
dependencies. This might be causing issues in IDEs that rely on the Dependency plugin to assemble
the application's classpath.

E.g. for the following project configuration *javax.servlet-api* version is resolved to *3.0.1*
(using nearest-first strategy to resolve conflicts):
|-- project2:compile
|..|-- jetty-server:compile
|....|-- javax.servlet-api:3.1.0:compile
|-- jersey-test-framework-core:test
|..|-- javax.servlet-api:3.0.1:compile

My understanding is that it should rather be resolved to 3.1.0, because version 3.0.1 stems
from the test scope and should be ignored (AFAIK Maven Shade plugin works in that way).

Please see a runnable code example in

Thank you!


This message was sent by Atlassian JIRA

View raw message