maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paul Vonnahme (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (MENFORCER-230) Document support for transitive dependencies in enforcer plugins
Date Thu, 14 Feb 2019 23:27:00 GMT

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

Paul Vonnahme edited comment on MENFORCER-230 at 2/14/19 11:26 PM:
-------------------------------------------------------------------

Feel free to close this old issue (I don't appear to have access).  It looks like 
{noformat}
requiresDependencyCollection = ResolutionScope.TEST{noformat}
was added way back in 1.4.1 and still exists in 3.0.0-M2


was (Author: pmv):
Closing old issue.  It looks like 
{noformat}
requiresDependencyCollection = ResolutionScope.TEST{noformat}
was added way back in 1.4.1 and still exists in 3.0.0-M2

> Document support for transitive dependencies in enforcer plugins
> ----------------------------------------------------------------
>
>                 Key: MENFORCER-230
>                 URL: https://issues.apache.org/jira/browse/MENFORCER-230
>             Project: Maven Enforcer Plugin
>          Issue Type: Bug
>          Components: Documentation, Rule API
>    Affects Versions: 1.3.1, 1.4, 1.4.1
>            Reporter: Paul Vonnahme
>            Priority: Critical
>              Labels: regression
>
> In the past, enforcer plugins were able to get transitive dependencies with the following
code (or similar):
> {code:java}
> project = (MavenProject) helper.evaluate("${project}");
> Set<Artifact> artifacts = project.getArtifacts();
> {code}
> However, as part of the fix for MENFORCER-156, 
> {code:java}
> requiresDependencyCollection = ResolutionScope.TEST
> {code}
> was removed from the @Mojo annotation, and I believe it broke the above functionality:
> https://svn.apache.org/viewvc/maven/enforcer/trunk/maven-enforcer-plugin/src/main/java/org/apache/maven/plugins/enforcer/EnforceMojo.java?r1=1493565&r2=1499852&pathrev=1499852&diff_format=h
> Is this a regression in 1.3.1+, or is 'DependecyGraphBuilder' now the only way to get
transitive dependencies?
> I believe this has caused MENFORCER-194, as well as broken the BanDuplicateClasses rule
from extra-enforcer-rules, so I consider it a regression.
> Right now the only workaround I know of is to continue using the 1.2 version of the enforcer
plugin.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message