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

CulpritsRecipientProvider is not working as expected

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • email-ext-plugin
    • Jenkins 2.32
      email-ext:2.53

      Basically, the issue is well described at JENKINS-39925 which is close as a duplicate of JENKINS-40653

      The thing is that JENKINS-40653 assumes that currentBuild.result variable is set to SUCCESS. If your pipeline ends succesfully but you didn't set the currentBuild.result value then the email won't be sent to the users who committed since the last non-broken.

      The problem seems to be in this else if. Switching the else if to an else seems to fix the problem.

      Probably this is failing because the plugin was designed originally to work with Freestyle jobs and the email was sent as a post-build action, in that case the build result s always != null. That's not works at Pipeline.

      I will try to send a PR shorly for your review.

          [JENKINS-42761] CulpritsRecipientProvider is not working as expected

          Code changed in jenkins
          User: Darío Villadiego
          Path:
          src/main/java/hudson/plugins/emailext/plugins/recipients/CulpritsRecipientProvider.java
          http://jenkins-ci.org/commit/email-ext-plugin/3208a515f52913c996b752fdfa453508ebaa7403
          Log:
          fixing JENKINS-42761 (#152)

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Darío Villadiego Path: src/main/java/hudson/plugins/emailext/plugins/recipients/CulpritsRecipientProvider.java http://jenkins-ci.org/commit/email-ext-plugin/3208a515f52913c996b752fdfa453508ebaa7403 Log: fixing JENKINS-42761 (#152)

          merged

          David van Laatum added a comment - merged

            davidvanlaatum David van Laatum
            dariver Darío Villadiego
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: