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

Quality gate "Reset" button not showing for jobs under GitHub Organization Folder

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Minor Minor
    • warnings-ng-plugin

      When using the Warnings NG plugin with jobs inside a GitHub Organization Folder, the "Reset Quality Gate" button does not appear in the build UI, even when a quality gate is triggered. This issue does not occur with standalone jobs or multibranch pipeline jobs outside of Organization Folders.

      Steps to Reproduce:

      1. Create a GitHub Organization Folder.
      2. Allow it to scan and create repository jobs.
      3. Configure a job to use the Warnings NG plugin and trigger a quality gate.
      4. Navigate to a build where the gate fails or triggers.
      5. Observe that the "Reset Quality Gate" button is missing from the UI.

      Expected Behavior:
      The "Reset Quality Gate" button should be visible in the build UI if a quality gate has been triggered, regardless of the job being in an Organization Folder.

      Actual Behavior:
      The button does not show for builds under jobs created via Organization Folders, making it impossible to manually reset the gate from the UI.

      Additional Info:
      Jenkins version: 2.492.3
      Warnings NG plugin version: 12.5.0
      Job type: WorkflowJob under a GitHub Organization Folder
      User has full permissions.

      Here are screenshots of 3 jobs used to reproduce the error:

      Org Folder Job (This is the issue)

      Standalone multibranch pipeline

      Standalone pipeline

      They are all checking out the same repo with this pipeline:

      pipeline {
        agent {
          label 'ubuntu-small'
        }
        stages {
          stage( "Create Warning file" ) {
            steps {
              sh '''
                echo "warnings.txt(1): warning W1: New warning exists" >> warnings.txt
                echo "warnings.txt(2): warning W1: New warning exists" >> warnings.txt
                echo "warnings.txt(3): warning W1: New warning exists" >> warnings.txt
              '''
            }
          }
          stage( "Warnings" ) {
            steps {
              discoverReferenceBuild referenceJob: env.JOB_NAME
              recordIssues(tools: [msBuild([pattern:'warnings.txt', id:'real-target-msbuild-cds', name:"${env.STAGE_NAME} Construction Design Scope MSBuild"])],
               qualityGates:[[threshold:2,type:'NEW',unstable:true]])
            }
          }
        }
      } 

      Any help is much appreciated.

        1. org-folder-job.png
          104 kB
          Eduardo
        2. standalone-multibranch-pipeline.png
          99 kB
          Eduardo
        3. standalone-pipeline.png
          85 kB
          Eduardo

            Unassigned Unassigned
            benitezlalom Eduardo
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: