Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MNG-8041] A quick draft about problem #1398

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

cstamas
Copy link
Member

@cstamas cstamas commented Feb 5, 2024

This is just a attempt to fix reproducer, and to see what ITs have to say.

https://github.com/cstamas/MNG-8041 is a reproducer: when asked mvn provisio:provision the lib will lack guava, while it should be part of runtime dependency (and actually IS, when the project is used as dependency!).


https://issues.apache.org/jira/browse/MNG-8041

Collection<String> resolveScopesToExclude = negate(scopesToResolve);

DependencyFilter collectionFilter = new ScopeDependencyFilter(null, collectScopesToExclude);
DependencyFilter resolutionFilter = new ScopeDependencyFilter(null, resolveScopesToExclude);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we just use the scopes to collect / resolve instead of the ones to exclude and give them as a negative test in the filter ?
i.e.:

DependencyFilter collectionFilter = new ScopeDependencyFilter(scopesToCollect);
DependencyFilter resolutionFilter = new ScopeDependencyFilter(scopesToResolve);

# Conflicts:
#	maven-core/src/main/java/org/apache/maven/project/DefaultProjectDependenciesResolver.java
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants