Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-594

NullPointerException in MavenModuleSetBuild.getResult

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • maven-plugin
    • None
    • Platform: All, OS: Linux

      Got this looking at the console output in Hudson 109.

      started
      Updating svn+ssh://...
      At revision 7582
      no change for svn+ssh://... since the previous build
      Parsing POMs
      Triggering org.gria:base
      FATAL: null
      java.lang.NullPointerException
      at hudson.maven.MavenModuleSetBuild.getResult(MavenModuleSetBuild.java:68)
      at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:131)
      at hudson.model.Run.run(Run.java:559)
      at hudson.maven.MavenModuleSetBuild.run(MavenModuleSetBuild.java:132)
      at hudson.model.Executor.run(Executor.java:59)

          [JENKINS-594] NullPointerException in MavenModuleSetBuild.getResult

          tal added a comment -

          The code is (from MavenModuleSetBuild.java):

          public Result getResult() {
          Result r = super.getResult();

          for (List<MavenBuild> list : getModuleBuilds().values())
          for (MavenBuild build : list)

          { Result br = build.getResult(); if(br!=null) r = r.combine(br); }

          return r;
          }

          But it seems that super.getResult() can (and does) return null (from Run.java):

          /**

          • Returns the build result.
            *
          • <p>
          • When a build is {@link #isBuilding() in progress}

            , this method

          • may return null or a temporary intermediate result.
            */
            @Exported
            public Result getResult() { return result; }

          tal added a comment - The code is (from MavenModuleSetBuild.java): public Result getResult() { Result r = super.getResult(); for (List<MavenBuild> list : getModuleBuilds().values()) for (MavenBuild build : list) { Result br = build.getResult(); if(br!=null) r = r.combine(br); } return r; } But it seems that super.getResult() can (and does) return null (from Run.java): /** Returns the build result. * <p> When a build is {@link #isBuilding() in progress} , this method may return null or a temporary intermediate result. */ @Exported public Result getResult() { return result; }

          Fixed in 1.112.

          Kohsuke Kawaguchi added a comment - Fixed in 1.112.

            Unassigned Unassigned
            tal tal
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: