Maven Archetype
  1. Maven Archetype
  2. ARCHETYPE-355

NPE in DefaultArchetypeArtifactManager.closeZipFile when running integration-test goal

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0
    • Fix Version/s: 2.1
    • Component/s: Plugin
    • Labels:
      None
    • Environment:

      Description

      After successfully creating an archetype from a project (using archetype:create-from-project), a NullPointerException is encountered when executing the "integration-test" goal of the archetype plugin. The steps to reproduce are:

      cd /tmp
      svn co https://squirrel-sql.svn.sourceforge.net/svnroot/squirrel-sql/trunk/sql12/plugins/example example
      cd example
      mvn -X clean install > build.log
      mvn -X archetype:create-from-project > archetype-create.log
      cd /tmp/example/target/generated-sources/archetype
      mvn -X -e archetype:integration-test > archetype-test.log

      The NullPointerException is listed at the bottom of /tmp/example/target/generated-sources/archetype/archetype-test.log and appears as follows:

      Caused by: java.lang.NullPointerException
              at org.apache.maven.archetype.common.DefaultArchetypeArtifactManager.closeZipFile(DefaultArchetypeArtifactManager.java:588)
              at org.apache.maven.archetype.common.DefaultArchetypeArtifactManager.isFileSetArchetype(DefaultArchetypeArtifactManager.java:200)
              at org.apache.maven.archetype.generator.DefaultArchetypeGenerator.generateArchetype(DefaultArchetypeGenerator.java:104)
              at org.apache.maven.archetype.generator.DefaultArchetypeGenerator.generateArchetype(DefaultArchetypeGenerator.java:149)
              at org.apache.maven.archetype.mojos.IntegrationTestMojo.processIntegrationTest(IntegrationTestMojo.java:237)
              at org.apache.maven.archetype.mojos.IntegrationTestMojo.execute(IntegrationTestMojo.java:108)
              at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:107)

      The attached zip file contains all of the logs that were generated. The source is available on the web with the svn checkout listed above for convenience.

      1. logs.zip
        27 kB
        Rob Manning

        Activity

        Rob Manning created issue -
        Hervé Boutemy made changes -
        Field Original Value New Value
        Description After successfully creating an archetype from a project (using archetype:create-from-project), a NullPointerException is encountered when executing the "integration-test" goal of the archetype plugin. The steps to reproduce are:

        cd /tmp
        svn co https://squirrel-sql.svn.sourceforge.net/svnroot/squirrel-sql/trunk/sql12/plugins/example example
        cd example
        mvn -X clean install > build.log
        mvn -X archetype:create-from-project > archetype-create.log
        cd /tmp/example/target/generated-sources/archetype
        mvn -X -e archetype:integration-test > archetype-test.log

        The NullPointerException is listed at the bottom of /tmp/example/target/generated-sources/archetype/archetype-test.log and appears as follows:


        Caused by: java.lang.NullPointerException
                at org.apache.maven.archetype.common.DefaultArchetypeArtifactManager.closeZipFile(DefaultArchetypeArtifactManager.java:588)
                at org.apache.maven.archetype.common.DefaultArchetypeArtifactManager.isFileSetArchetype(DefaultArchetypeArtifactManager.java:200)
                at org.apache.maven.archetype.generator.DefaultArchetypeGenerator.generateArchetype(DefaultArchetypeGenerator.java:104)
                at org.apache.maven.archetype.generator.DefaultArchetypeGenerator.generateArchetype(DefaultArchetypeGenerator.java:149)
                at org.apache.maven.archetype.mojos.IntegrationTestMojo.processIntegrationTest(IntegrationTestMojo.java:237)
                at org.apache.maven.archetype.mojos.IntegrationTestMojo.execute(IntegrationTestMojo.java:108)
                at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:107)


        The attached zip file contains all of the logs that were generated. The source is available on the web with the svn checkout listed above for convenience.
        After successfully creating an archetype from a project (using archetype:create-from-project), a NullPointerException is encountered when executing the "integration-test" goal of the archetype plugin. The steps to reproduce are:

        {noformat}cd /tmp
        svn co https://squirrel-sql.svn.sourceforge.net/svnroot/squirrel-sql/trunk/sql12/plugins/example example
        cd example
        mvn -X clean install > build.log
        mvn -X archetype:create-from-project > archetype-create.log
        cd /tmp/example/target/generated-sources/archetype
        mvn -X -e archetype:integration-test > archetype-test.log{noformat}

        The NullPointerException is listed at the bottom of /tmp/example/target/generated-sources/archetype/archetype-test.log and appears as follows:


        {noformat}Caused by: java.lang.NullPointerException
                at org.apache.maven.archetype.common.DefaultArchetypeArtifactManager.closeZipFile(DefaultArchetypeArtifactManager.java:588)
                at org.apache.maven.archetype.common.DefaultArchetypeArtifactManager.isFileSetArchetype(DefaultArchetypeArtifactManager.java:200)
                at org.apache.maven.archetype.generator.DefaultArchetypeGenerator.generateArchetype(DefaultArchetypeGenerator.java:104)
                at org.apache.maven.archetype.generator.DefaultArchetypeGenerator.generateArchetype(DefaultArchetypeGenerator.java:149)
                at org.apache.maven.archetype.mojos.IntegrationTestMojo.processIntegrationTest(IntegrationTestMojo.java:237)
                at org.apache.maven.archetype.mojos.IntegrationTestMojo.execute(IntegrationTestMojo.java:108)
                at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:107){noformat}


        The attached zip file contains all of the logs that were generated. The source is available on the web with the svn checkout listed above for convenience.
        Hervé Boutemy made changes -
        Assignee Herve Boutemy [ hboutemy ]
        Status Open [ 1 ] Closed [ 6 ]
        Resolution Fixed [ 1 ]
        Fix Version/s 2.1 [ 16795 ]
        Mark Thomas made changes -
        Project Import Sun Apr 05 09:05:55 UTC 2015 [ 1428224755734 ]
        Mark Thomas made changes -
        Workflow jira [ 12716793 ] Default workflow, editable Closed status [ 12748103 ]
        Mark Thomas made changes -
        Project Import Sun Apr 05 22:17:37 UTC 2015 [ 1428272257260 ]
        Mark Thomas made changes -
        Workflow jira [ 12953944 ] Default workflow, editable Closed status [ 12991080 ]

          People

          • Assignee:
            Hervé Boutemy
            Reporter:
            Rob Manning
          • Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development