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

${CHANGES_SINCE_LAST_SUCCESS} no longer displays "No changes" when there are no new SCM changes

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Minor
    • Resolution: Fixed
    • Component/s: token-macro-plugin
    • Labels:
      None
    • Environment:
      Jenkins 2.23
      Email Extension Plugin 2.51
      Token Macro Plugin 2.0
      Git plugin 3.0.0
    • Similar Issues:

      Description

      I recently updated my plugins and I think one of them caused the emails to no longer display "No changes" then there are no new SCM changes in the build.

      In my case I am using Git.

      Here is our usual output config:
      ${CHANGES_SINCE_LAST_BUILD, showDependencies=true, format="\n[%r]\n\t%m\t\t%a - %d\n%p"}

      I tired using no attributes and it still did the same thing.

      I also tried using/changing the default attribute and it still did not show anything.

      It still properly displays the SCM changes when there are some to show.

        Attachments

        1. build.log
          18 kB
        2. build.log
          2 kB
        3. token-macro.hpi
          436 kB

          Activity

          Hide
          davidvanlaatum David van Laatum added a comment -

          Handled by token macro plugin

          Show
          davidvanlaatum David van Laatum added a comment - Handled by token macro plugin
          Hide
          slide_o_mix Alex Earl added a comment -

          What output do you get?

          Show
          slide_o_mix Alex Earl added a comment - What output do you get?
          Hide
          tspencer3 Thomas Spencer added a comment -

          The output when there are no SCM changes is empty/blank.

          Show
          tspencer3 Thomas Spencer added a comment - The output when there are no SCM changes is empty/blank.
          Hide
          slide_o_mix Alex Earl added a comment -

          Did the git plugin also get updated?

          Show
          slide_o_mix Alex Earl added a comment - Did the git plugin also get updated?
          Hide
          tspencer3 Thomas Spencer added a comment -

          Yes, I also updated to the latest Git plugin (3.0.0) at the same time.

          Show
          tspencer3 Thomas Spencer added a comment - Yes, I also updated to the latest Git plugin (3.0.0) at the same time.
          Hide
          slide_o_mix Alex Earl added a comment -

          Can you post the build log?

          Show
          slide_o_mix Alex Earl added a comment - Can you post the build log?
          Hide
          tspencer3 Thomas Spencer added a comment -

          Attached is a stripped down build log.

          Show
          tspencer3 Thomas Spencer added a comment - Attached is a stripped down build log.
          Hide
          slide_o_mix Alex Earl added a comment -

          Are you still seeing this issue?

          Show
          slide_o_mix Alex Earl added a comment - Are you still seeing this issue?
          Hide
          tspencer3 Thomas Spencer added a comment -

          I am still seeing this issue.

          Here are my current versions:

          Plugin Version
          Jenkins 2.41
          Email Extension Plugin 2.53
          Token Macro Plugin 2.0
          Git client plugin 2.2.1
          Git plugin 3.0.1
          SCM API Plugin 1.3
          Show
          tspencer3 Thomas Spencer added a comment - I am still seeing this issue. Here are my current versions: Plugin Version Jenkins 2.41 Email Extension Plugin 2.53 Token Macro Plugin 2.0 Git client plugin 2.2.1 Git plugin 3.0.1 SCM API Plugin 1.3
          Hide
          slide_o_mix Alex Earl added a comment -

          Are you willing to try a debug version of the token-macro to help narrow down the issue?

          Show
          slide_o_mix Alex Earl added a comment - Are you willing to try a debug version of the token-macro to help narrow down the issue?
          Hide
          tspencer3 Thomas Spencer added a comment -

          Willing and able. Just let me know how to get it.

          Show
          tspencer3 Thomas Spencer added a comment - Willing and able. Just let me know how to get it.
          Hide
          slide_o_mix Alex Earl added a comment -

          I'll create a snapshot release and point you to the .hpi file to install.

          Show
          slide_o_mix Alex Earl added a comment - I'll create a snapshot release and point you to the .hpi file to install.
          Hide
          slide_o_mix Alex Earl added a comment -

          I attached a snapshot hpi to this issue. Please upload the build log after running with this version.

          Show
          slide_o_mix Alex Earl added a comment - I attached a snapshot hpi to this issue. Please upload the build log after running with this version.
          Hide
          tspencer3 Thomas Spencer added a comment -

          Log attached. I was not sure what I was looking for in it, but I didn't see anything that looked different than before. The build still did not say No changes.

          Show
          tspencer3 Thomas Spencer added a comment - Log attached. I was not sure what I was looking for in it, but I didn't see anything that looked different than before. The build still did not say No changes.
          Hide
          slide_o_mix Alex Earl added a comment -

          The last two lines are stuff I added as logs. Let me look at the flow now.

          Show
          slide_o_mix Alex Earl added a comment - The last two lines are stuff I added as logs. Let me look at the flow now.
          Hide
          tspencer3 Thomas Spencer added a comment -

          I see it now that you pointed it out.

          Show
          tspencer3 Thomas Spencer added a comment - I see it now that you pointed it out.
          Hide
          slide_o_mix Alex Earl added a comment -

          Ok, I believe I know what the issue is. I am coding up a test to make sure and then I'll build a version with a fix and let you try it out.

          Show
          slide_o_mix Alex Earl added a comment - Ok, I believe I know what the issue is. I am coding up a test to make sure and then I'll build a version with a fix and let you try it out.
          Hide
          slide_o_mix Alex Earl added a comment -

          The internet went down at my house (where my build system is), so it will take me longer than I anticipated to get the version to try.

          Show
          slide_o_mix Alex Earl added a comment - The internet went down at my house (where my build system is), so it will take me longer than I anticipated to get the version to try.
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: Alex Earl
          Path:
          src/test/java/org/jenkinsci/plugins/tokenmacro/impl/ChangesSinceLastSuccessfulBuildMacroTest.java
          http://jenkins-ci.org/commit/token-macro-plugin/f7b7652e63c7c7a0dbfdde71dd5f75a8d3aeefc0
          Log:
          Fix JENKINS-38668

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Alex Earl Path: src/test/java/org/jenkinsci/plugins/tokenmacro/impl/ChangesSinceLastSuccessfulBuildMacroTest.java http://jenkins-ci.org/commit/token-macro-plugin/f7b7652e63c7c7a0dbfdde71dd5f75a8d3aeefc0 Log: Fix JENKINS-38668
          Show
          slide_o_mix Alex Earl added a comment - Please try this HPI https://ci.jenkins.io/job/Plugins/job/token-macro-plugin/job/master/lastSuccessfulBuild/artifact/target/token-macro.hpi
          Hide
          tspencer3 Thomas Spencer added a comment -

          No changes!

          In a good way.

          The message is now appearing in the output like it used to.

          Thanks for looking into this.

          Show
          tspencer3 Thomas Spencer added a comment - No changes! In a good way. The message is now appearing in the output like it used to. Thanks for looking into this.
          Hide
          slide_o_mix Alex Earl added a comment -

          I'll put out a new release soon so you can have an official plugin. Thanks for filing the issue.

          Show
          slide_o_mix Alex Earl added a comment - I'll put out a new release soon so you can have an official plugin. Thanks for filing the issue.
          Hide
          slide_o_mix Alex Earl added a comment -

          Fixed in 2.1

          Show
          slide_o_mix Alex Earl added a comment - Fixed in 2.1

            People

            • Assignee:
              slide_o_mix Alex Earl
              Reporter:
              tspencer3 Thomas Spencer
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: