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

Workflow sidebar has duplicated Git Build Data links

      In a Workflow build, if you use certain resources in >1 node, you get duplication of the links in the left navigation pane when you look at the info page for a build that has already run. To reproduce, install the Workflow plugin, create a new Workflow job, and give it a configuration like:

      node {
        git branch: "master", credentialsId: '', url: 'git@mygitrepo/project.git'
      }
      node {
        git branch: "master", credentialsId: '', url: 'git@mygitrepo/project.git'
      }
      node {
        git branch: "master", credentialsId: '', url: 'git@mygitrepo/project.git'
      }
      

      Each time you use the git resource within a new node, it causes duplication of the nav items as shown in the attached screenshot. This issue is not confined to the workflow+git combination. I have also seen it with the 'Show Build Parameters' plugin, where there is duplication of the Parameters link in the nav pane, but I can't seem to reproduce that issue consistently. I suspect that other plugins which add something to the nav field on a per-job basis could have similar issues.

      I'm attaching a support bundle from my MacOS test Jenkins server, and also a build.xml that shows the issue.

        1. build.xml
          10 kB
        2. jenkins.log
          11 kB
        3. Screen Shot 2015-07-09 at 12.01.47 PM.png
          Screen Shot 2015-07-09 at 12.01.47 PM.png
          129 kB
        4. Screen Shot 2017-10-26 at 9.53.46 am.png
          Screen Shot 2017-10-26 at 9.53.46 am.png
          17 kB
        5. support.zip
          31 kB

          [JENKINS-29326] Workflow sidebar has duplicated Git Build Data links

          Andrew Bayer added a comment -

          And I should mention that it legitimately should have 2 BuildData, but no more than that.

          Andrew Bayer added a comment - And I should mention that it legitimately should have 2 BuildData , but no more than that.

          Andrew Bayer added a comment -

          Ah-ha! With the embeddable build status plugin, this duplicates, without, it doesn't. Seems to be JENKINS-28642 (in this case, but could be another plugin) causing it.transientActions in WorkflowRun/sidePanel.jelly to barf leading to duplicate actions being put in the sidebar. deepchip, I know you're seeing this still - do you see any stacktraces in jenkins.log when you load an offending build page? And jglick, any ideas for a workaround?

          Andrew Bayer added a comment - Ah-ha! With the embeddable build status plugin, this duplicates, without, it doesn't. Seems to be JENKINS-28642 (in this case, but could be another plugin) causing it.transientActions in WorkflowRun/sidePanel.jelly to barf leading to duplicate actions being put in the sidebar. deepchip , I know you're seeing this still - do you see any stacktraces in jenkins.log when you load an offending build page? And jglick , any ideas for a workaround?

          Andrew Bayer added a comment -

          Confirmed that with embeddable build status 1.9-SNAPSHOT (after the fix for JENKINS-28642 went in), I don't see duplicate actions any more.

          Andrew Bayer added a comment - Confirmed that with embeddable build status 1.9-SNAPSHOT (after the fix for JENKINS-28642 went in), I don't see duplicate actions any more.

          Martin d'Anjou added a comment - - edited

          Yes indeed I see a stacktrace when I visit a page with a duplicate build data in the left side menu, and it has it.transientActions in it. See the jenkins.log file attached. I am running Jenkins 1.625.2, Pipeline 1.13, Git Plugin 2.4.1, Embeddable build status 1.8.

          Martin d'Anjou added a comment - - edited Yes indeed I see a stacktrace when I visit a page with a duplicate build data in the left side menu, and it has it.transientActions in it. See the jenkins.log file attached. I am running Jenkins 1.625.2, Pipeline 1.13, Git Plugin 2.4.1, Embeddable build status 1.8.

          Jesse Glick added a comment -

          The fix got broken again in 2.4.2.

          Jesse Glick added a comment - The fix got broken again in 2.4.2.

          Code changed in jenkins
          User: Jesse Glick
          Path:
          src/main/java/hudson/plugins/git/util/BuildData.java
          http://jenkins-ci.org/commit/git-plugin/7e501ab38c60ad203cd5f1cdce8a9683c4fb89d8
          Log:
          [FIXED JENKINS-29326] Restore lost BuildData.equals override.

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: src/main/java/hudson/plugins/git/util/BuildData.java http://jenkins-ci.org/commit/git-plugin/7e501ab38c60ad203cd5f1cdce8a9683c4fb89d8 Log: [FIXED JENKINS-29326] Restore lost BuildData.equals override.

          Code changed in jenkins
          User: Andrew Bayer
          Path:
          job/src/main/java/org/jenkinsci/plugins/workflow/job/WorkflowJob.java
          http://jenkins-ci.org/commit/workflow-job-plugin/ec2575b1f03ea1bb4cce4d53c2b78aec626e5c28
          Log:
          Merge pull request #271 from abayer/jenkins-29326

          JENKINS-29326 Don't add duplicate BuildData (downstream)
          Originally-Committed-As: 3840d8ca847ed0ea8097c2f62e7b21504190afad

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Andrew Bayer Path: job/src/main/java/org/jenkinsci/plugins/workflow/job/WorkflowJob.java http://jenkins-ci.org/commit/workflow-job-plugin/ec2575b1f03ea1bb4cce4d53c2b78aec626e5c28 Log: Merge pull request #271 from abayer/jenkins-29326 JENKINS-29326 Don't add duplicate BuildData (downstream) Originally-Committed-As: 3840d8ca847ed0ea8097c2f62e7b21504190afad

          trejkaz added a comment -

          Did someone revert the fix? It's showing five for me.

          trejkaz added a comment - Did someone revert the fix? It's showing five for me.

          Nick Jones added a comment -

          This is happening to me today on Jenkins 2.89.2 LTS with Pipeline Job 2.16. I've got 3 "Git Build Data" links in the left-hand menu (URLs ending in "git", "git-2", and "git-3"), and moreover, the main panel lists three Git revision SHAs that aren't actually part of my repository. This is a Multibranch Pipeline job building a pull request using the default "Merging the pull request with the current target branch revision" behavior. It also shows two Changes sections in the main panel listing the same Git commit message twice, in case that's relevant or related.

          Nick Jones added a comment - This is happening to me today on Jenkins 2.89.2 LTS with Pipeline Job 2.16. I've got 3 "Git Build Data" links in the left-hand menu (URLs ending in "git", "git-2", and "git-3"), and moreover, the main panel lists three Git revision SHAs that aren't actually part of my repository. This is a Multibranch Pipeline job building a pull request using the default "Merging the pull request with the current target branch revision" behavior. It also shows two Changes sections in the main panel listing the same Git commit message twice, in case that's relevant or related.

          Max M added a comment - - edited

          May I ask why is this Priority: Minor?
          Can this be escalated?

          There are like dozens of duplicates of this issue (see e.g. JENKINS-38204 – the SVN lineage of dupes), and it looks like it's getting "fixed", then broken, then fixed again, then broken again... Is this an architectural problem in Jenkins?

          Can anybody fix this once-and-for-all?

          Max M added a comment - - edited May I ask why is this Priority: Minor ? Can this be escalated? There are like dozens of duplicates of this issue (see e.g. JENKINS-38204 – the SVN lineage of dupes), and it looks like it's getting "fixed", then broken, then fixed again, then broken again... Is this an architectural problem in Jenkins? Can anybody fix this once-and-for-all?

            Unassigned Unassigned
            owenmehegan Owen Mehegan
            Votes:
            28 Vote for this issue
            Watchers:
            37 Start watching this issue

              Created:
              Updated: