Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What's changed?
Handle the default value of plugin
groupId
as per https://maven.apache.org/xsd/maven-4.0.0.xsdSee also is groupId required for plugins in Maven pom.xml? on Stack Overflow.
What's your motivation?
Someone declared a plugin without groupId…
Have you considered any alternatives or workarounds?
It would be possible to fix just
RemoveRedundantDependencyVersions
, but since this default value is defined in the xsd, I thought it would be better to fix the parsing/resolution.Any additional context
It was causing an invisible NPE in
RemoveRedundantDependencyVersions
for thepluginManagement
case. I’m not sure how such exceptions should be handled.Theoretically the
artifactId
is optional as well, but I don’t see why anyone wouldn’t provide it. Moreover there isn’t a default for it.Checklist