[
http://jira.codehaus.org/browse/MNG-4858?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Brett Porter closed MNG-4858.
-----------------------------
Resolution: Fixed
Fix Version/s: 3.0.1
Fixed in r1005860. After discussing with Benjamin, decided not to go for an
IllegalArgumentException as it would not represent a clear error link to the
user receiving it. Instead, the empty goal or overspecified goal (goal:toomany)
are sent to the MojoNotFoundException so the user ends up getting back valid
choices of goals from the plugin in question.
> NullPointerException if goal name is malformed
> ----------------------------------------------
>
> Key: MNG-4858
> URL: http://jira.codehaus.org/browse/MNG-4858
> Project: Maven 2 & 3
> Issue Type: Bug
> Components: Errors
> Affects Versions: 3.0
> Reporter: Brett Porter
> Assignee: Brett Porter
> Fix For: 3.0.1
>
>
> Typing a goal like:
> {code}
> mvn help:
> {code}
> or
> {code}
> mvn group:artifact:version:goal:onetoomany
> {code}
> Results in:
> {code}
> [ERROR] NullPointerException
> java.lang.NullPointerException
> at
> org.apache.maven.lifecycle.internal.MojoDescriptorCreator.findPlugin(MojoDescriptorCreator.java:288)
> at
> org.apache.maven.lifecycle.internal.MojoDescriptorCreator.injectPluginDeclarationFromProject(MojoDescriptorCreator.java:268)
> at
> org.apache.maven.lifecycle.internal.MojoDescriptorCreator.getMojoDescriptor(MojoDescriptorCreator.java:211)
> at
> org.apache.maven.lifecycle.internal.DefaultLifecycleTaskSegmentCalculator.calculateTaskSegments(DefaultLifecycleTaskSegmentCalculator.java:106)
> at
> org.apache.maven.lifecycle.internal.DefaultLifecycleTaskSegmentCalculator.calculateTaskSegments(DefaultLifecycleTaskSegmentCalculator.java:86)
> at
> org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:98)
> {code}
> In Maven 2.2.1, it produced an error message to adjust the goal format.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira