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

DownStreamProjectActionFactory throws a nullpointer exception

      Please see the Jenkins run output in the attached file jenkins.log

      It seems some of the downstream projects are null (possibly because these projects are disabled?) This causes the exception on line 61.

      Snippet from DownstreamProjectActionFactory:
      --------------------------------------------
      52 public Collection<? extends Action> createFor(@SuppressWarnings("unchecked") AbstractProject target) {
      53 LOG.fine(this + " adds DownStreamProjectAction for " + target);
      54 final ArrayList<Action> actions = new ArrayList<Action>();
      55
      56
      57 // add the DownstreamBuildViewAction to all run builds, DownstreamBuildViewRunListener will append this to the others.
      58 final List<?> builds = (List<?>) target.getBuilds();
      59 for (Object object : builds) {
      60 final AbstractBuild<?, ?> build = (AbstractBuild<?, ?>) object;
      61 final List<DownstreamBuildViewAction> dBuildViewAction = build.getActions(DownstreamBuildViewAction.class);

          [JENKINS-15625] DownStreamProjectActionFactory throws a nullpointer exception

          Tjaart van der Walt created issue -
          Tjaart van der Walt made changes -
          Description Original: Please see our Jenkins run output in the attached file jenkins.log

          It seems some of our downstream projects are null (possibly because the project is disabled?) This causes the exception on line 61.

          Snippet from DownstreamProjectActionFactory:
          --------------------------------------------
          52 public Collection<? extends Action> createFor(@SuppressWarnings("unchecked") AbstractProject target) {
          53 LOG.fine(this + " adds DownStreamProjectAction for " + target);
          54 final ArrayList<Action> actions = new ArrayList<Action>();
          55
          56
          57 // add the DownstreamBuildViewAction to all run builds, DownstreamBuildViewRunListener will append this to the others.
          58 final List<?> builds = (List<?>) target.getBuilds();
          59 for (Object object : builds) {
          60 final AbstractBuild<?, ?> build = (AbstractBuild<?, ?>) object;
          61 final List<DownstreamBuildViewAction> dBuildViewAction = build.getActions(DownstreamBuildViewAction.class);

          New: Please see the Jenkins run output in the attached file jenkins.log

          It seems some of the downstream projects are null (possibly because the project is disabled?) This causes the exception on line 61.

          Snippet from DownstreamProjectActionFactory:
          --------------------------------------------
          52 public Collection<? extends Action> createFor(@SuppressWarnings("unchecked") AbstractProject target) {
          53 LOG.fine(this + " adds DownStreamProjectAction for " + target);
          54 final ArrayList<Action> actions = new ArrayList<Action>();
          55
          56
          57 // add the DownstreamBuildViewAction to all run builds, DownstreamBuildViewRunListener will append this to the others.
          58 final List<?> builds = (List<?>) target.getBuilds();
          59 for (Object object : builds) {
          60 final AbstractBuild<?, ?> build = (AbstractBuild<?, ?>) object;
          61 final List<DownstreamBuildViewAction> dBuildViewAction = build.getActions(DownstreamBuildViewAction.class);

          Tjaart van der Walt made changes -
          Description Original: Please see the Jenkins run output in the attached file jenkins.log

          It seems some of the downstream projects are null (possibly because the project is disabled?) This causes the exception on line 61.

          Snippet from DownstreamProjectActionFactory:
          --------------------------------------------
          52 public Collection<? extends Action> createFor(@SuppressWarnings("unchecked") AbstractProject target) {
          53 LOG.fine(this + " adds DownStreamProjectAction for " + target);
          54 final ArrayList<Action> actions = new ArrayList<Action>();
          55
          56
          57 // add the DownstreamBuildViewAction to all run builds, DownstreamBuildViewRunListener will append this to the others.
          58 final List<?> builds = (List<?>) target.getBuilds();
          59 for (Object object : builds) {
          60 final AbstractBuild<?, ?> build = (AbstractBuild<?, ?>) object;
          61 final List<DownstreamBuildViewAction> dBuildViewAction = build.getActions(DownstreamBuildViewAction.class);

          New: Please see the Jenkins run output in the attached file jenkins.log

          It seems some of the downstream projects are null (possibly because these projects are disabled?) This causes the exception on line 61.

          Snippet from DownstreamProjectActionFactory:
          --------------------------------------------
          52 public Collection<? extends Action> createFor(@SuppressWarnings("unchecked") AbstractProject target) {
          53 LOG.fine(this + " adds DownStreamProjectAction for " + target);
          54 final ArrayList<Action> actions = new ArrayList<Action>();
          55
          56
          57 // add the DownstreamBuildViewAction to all run builds, DownstreamBuildViewRunListener will append this to the others.
          58 final List<?> builds = (List<?>) target.getBuilds();
          59 for (Object object : builds) {
          60 final AbstractBuild<?, ?> build = (AbstractBuild<?, ?>) object;
          61 final List<DownstreamBuildViewAction> dBuildViewAction = build.getActions(DownstreamBuildViewAction.class);

          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 146381 ] New: JNJira + In-Review [ 176603 ]

            shinodkm shinodkm
            tjaart Tjaart van der Walt
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: