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

NullPointerException with mvn dependency:sources

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.0.7
    • 2.0.9, 3.0-alpha-1
    • Dependencies
    • None

    Description

      I got a NPE when I use mvn dependency:sources to download all the sources for my appfuse M5 project:

      $ mvn -e -U dependency:sources
      + Error stacktraces are turned on.
      [INFO] Scanning for projects...
      [INFO] Searching repository for plugin with prefix: 'dependency'.
      [INFO] org.apache.maven.plugins: checking for updates from appfuse
      [INFO] org.apache.maven.plugins: checking for updates from central
      [INFO] org.codehaus.mojo: checking for updates from appfuse
      [INFO] org.codehaus.mojo: checking for updates from central
      [INFO] artifact org.apache.maven.plugins:maven-dependency-plugin: checking for updates from appfuse
      [INFO] artifact org.apache.maven.plugins:maven-dependency-plugin: checking for updates from central
      [INFO] ----------------------------------------------------------------------------
      [INFO] Building AppFuse Struts 2 Application
      [INFO] task-segment: [dependency:sources]
      [INFO] ----------------------------------------------------------------------------
      Downloading: http://repo1.maven.org/maven2/org/codehaus/xfire/bcprov-jdk15/133/bcprov-jdk15-133.pom
      Downloading: http://static.appfuse.org/repository/org/codehaus/xfire/bcprov-jdk15/133/bcprov-jdk15-133.pom
      Downloading: http://repo1.maven.org/maven2/xml-security/xmlsec/1.3.0/xmlsec-1.3.0.pom
      Downloading: http://static.appfuse.org/repository/xml-security/xmlsec/1.3.0/xmlsec-1.3.0.pom
      Downloading: http://repo1.maven.org/maven2/wss4j/wss4j/1.5.1/wss4j-1.5.1.pom
      Downloading: http://static.appfuse.org/repository/wss4j/wss4j/1.5.1/wss4j-1.5.1.pom
      Downloading: http://repo1.maven.org/maven2/xfire/saaj-impl/1.3/saaj-impl-1.3.pom
      Downloading: http://static.appfuse.org/repository/xfire/saaj-impl/1.3/saaj-impl-1.3.pom
      [INFO] [dependency:sources]
      Downloading: http://repo1.maven.org/maven2/ant/ant/1.5/ant-1.5-sources.jar
      Downloading: http://static.appfuse.org/repository/ant/ant/1.5/ant-1.5-sources.jar
      Downloading: http://repo1.maven.org/maven2/asm/asm/1.5.3/asm-1.5.3-sources.jar
      Downloading: http://static.appfuse.org/repository/asm/asm/1.5.3/asm-1.5.3-sources.jar
      Downloading: http://repo1.maven.org/maven2/asm/asm-attrs/1.5.3/asm-attrs-1.5.3-sources.jar
      Downloading: http://static.appfuse.org/repository/asm/asm-attrs/1.5.3/asm-attrs-1.5.3-sources.jar
      Downloading: http://repo1.maven.org/maven2/aspectj/aspectjweaver/1.5.3/aspectjweaver-1.5.3-sources.jar
      Downloading: http://static.appfuse.org/repository/aspectj/aspectjweaver/1.5.3/aspectjweaver-1.5.3-sources.jar
      [INFO] ------------------------------------------------------------------------
      [ERROR] FATAL ERROR
      [INFO] ------------------------------------------------------------------------
      [INFO] null
      [INFO] ------------------------------------------------------------------------
      [INFO] Trace
      java.lang.NullPointerException
      at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:92)
      at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:73)
      at org.apache.maven.plugin.dependency.utils.resolvers.DefaultArtifactsResolver.resolve(DefaultArtifactsResolver.java:81)
      at org.apache.maven.plugin.dependency.AbstractDependencyFilterMojo.getClassifierTranslatedDependencies(AbstractDependencyFilterMojo.java:308)
      at org.apache.maven.plugin.dependency.AbstractDependencyFilterMojo.getDependencySets(AbstractDependencyFilterMojo.java:265)
      at org.apache.maven.plugin.dependency.resolvers.ResolveDependencySourcesMojo.execute(ResolveDependencySourcesMojo.java:69)
      at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:443)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:539)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:493)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:463)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:311)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:278)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:143)
      at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:334)
      at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:125)
      at org.apache.maven.cli.MavenCli.main(MavenCli.java:272)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:585)
      at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
      at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
      at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
      at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 16 seconds
      [INFO] Finished at: Tue Aug 17 11:39:04 CEST 2007
      [INFO] Final Memory: 9M/17M
      [INFO] ------------------------------------------------------------------------

      Attachments

        1. pom.xml
          29 kB
          Sam Imari

        Activity

          People

            siveton Siveton Vincent
            sam_imari Sam Imari
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: