Uploaded image for project: 'Maven'
  1. Maven
  2. MNG-4858

NullPointerException if goal name is malformed

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.0
    • Fix Version/s: 3.0.1
    • Component/s: Errors
    • Labels:
      None

      Description

      Typing a goal like:

      mvn help:
      

      or

      mvn group:artifact:version:goal:onetoomany
      

      Results in:

      [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)
      

      In Maven 2.2.1, it produced an error message to adjust the goal format.

        Attachments

          Activity

            People

            • Assignee:
              brettporter Brett Porter
              Reporter:
              brettporter Brett Porter
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: