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

HockeyAppRecorder.getProjectActions throws NullPointerException

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • hockeyapp-plugin
    • None

      When getProjectActions is called before current build has a result, it throws a NullPointerException. The following code fails when the current build has no result yet, getResult() returns null:

      Collection<AbstractBuild<?, ?>> predicated = CollectionUtils.select(builds, new Predicate() {
      public boolean evaluate(Object o)

      { return ((AbstractBuild<?, ?>) o).getResult().isBetterOrEqualTo( Result.SUCCESS); }

      });

      Steps to reproduce:
      1. Configure EnvInject plugin to prepare the environment (use the EnvInjectListener)
      2. Add HockeyApp plugin

      EnvInject listener will call getProjectActions before the current build has a result.

            lacostej lacostej
            nebula Guido van Loon
            Votes:
            1 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: