I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

      It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

      enabledForFailure is set, and the quality gate is configured as

      qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]
      

      However, it consistently uses the last successful build as a reference build.

      I used reset on the quality gate, expecting it to update the new state as the baseline.

      The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.

      [MSBuild] Repository miner is not configured, skipping repository mining
      [MSBuild] Reference build recorder is not configured
      [MSBuild] Obtaining reference build from same job (main)
      [MSBuild] Resetting reference build, ignoring quality gate result for one build
      [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
      [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
      [MSBuild] Evaluating quality gates
      [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1
      
      [MSBuild] -> Some quality gates have been missed: overall result is FAILED
      [MSBuild] Health report is disabled - skipping
      [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
      [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.
      
                  stage('MSBuild Gate') {
                    steps {
                      recordIssues(
                        sourceCodeEncoding: 'UTF-8',
                        enabledForFailure: true,
                        tools: [
                          msBuild(),
                        ],
                        qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]
                      )
                    }
                  }
      

      In the past I’ve used reset quality gate in another job a while ago just fine.

          [JENKINS-68832] Reset quality gate does not work

          Jan Klass created issue -
          Jan Klass made changes -
          Description Original: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code:java}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1{color:#FFFFFF}[MSBuild] -> Some quality gates have been missed: overall result is FAILED{color}[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          New: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code:java}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code:java}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1[MSBuild] -> Some quality gates have been missed: overall result is FAILED[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          Jan Klass made changes -
          Description Original: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code:java}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code:java}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1[MSBuild] -> Some quality gates have been missed: overall result is FAILED[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          New: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code:plain}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code:plain}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1[MSBuild] -> Some quality gates have been missed: overall result is FAILED[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          Jan Klass made changes -
          Description Original: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code:plain}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code:plain}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1[MSBuild] -> Some quality gates have been missed: overall result is FAILED[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          New: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1[MSBuild] -> Some quality gates have been missed: overall result is FAILED[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          Jan Klass made changes -
          Description Original: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1[MSBuild] -> Some quality gates have been missed: overall result is FAILED[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          New: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code:text}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1[MSBuild] -> Some quality gates have been missed: overall result is FAILED[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          Jan Klass made changes -
          Description Original: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code:text}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1[MSBuild] -> Some quality gates have been missed: overall result is FAILED[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          New: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1[MSBuild] -> Some quality gates have been missed: overall result is FAILED[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          Jan Klass made changes -
          Description Original: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1[MSBuild] -> Some quality gates have been missed: overall result is FAILED[MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          New: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1

          [MSBuild] -> Some quality gates have been missed: overall result is FAILED
          [MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          Jan Klass made changes -
          Description Original: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]{code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.
          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1

          [MSBuild] -> Some quality gates have been missed: overall result is FAILED
          [MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.{code}
          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          New: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]
          {code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.

          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1

          [MSBuild] -> Some quality gates have been missed: overall result is FAILED
          [MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.
          {code}

          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          Jan Klass made changes -
          Description Original: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]
          {code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.

          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1

          [MSBuild] -> Some quality gates have been missed: overall result is FAILED
          [MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.
          {code}

          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          New: I use recordIssues in a step following steps with dotnet build, dotnet test, dotnet publish.

          It identifies 3 issues, 3 times, and correctly identifies them as duplicates that it collapses.

          enabledForFailure is set, and the quality gate is configured as
          {code}
          qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]
          {code}
          However, it consistently uses the last successful build as a reference build.

          I used _reset_ on the quality gate, expecting it to update the new state as the baseline.

          The log shows that the reset is recognized and used, but it then uses the reference build anyway and fails the build.

          {code}
          [MSBuild] Repository miner is not configured, skipping repository mining
          [MSBuild] Reference build recorder is not configured
          [MSBuild] Obtaining reference build from same job (main)
          [MSBuild] Resetting reference build, ignoring quality gate result for one build
          [MSBuild] Using reference build '[redacted]/main #10' to compute new, fixed, and outstanding issues
          [MSBuild] Issues delta (vs. reference build): outstanding: 0, new: 3, fixed: 0
          [MSBuild] Evaluating quality gates
          [MSBuild] -> FAILED - New (any severity): 3 - Quality Gate: 1

          [MSBuild] -> Some quality gates have been missed: overall result is FAILED
          [MSBuild] Health report is disabled - skipping
          [MSBuild] Created analysis result for 3 issues (found 3 new issues, fixed 0 issues)
          [MSBuild] Attaching ResultAction with ID 'msbuild' to build '[redacted]/main #20'.
          {code}

          {code}
                      stage('MSBuild Gate') {
                        steps {
                          recordIssues(
                            sourceCodeEncoding: 'UTF-8',
                            enabledForFailure: true,
                            tools: [
                              msBuild(),
                            ],
                            qualityGates: [[threshold: 1, type: 'NEW', unstable: false]]
                          )
                        }
                      }
          {code}

          In the past I’ve used _reset quality gate_ in another job a while ago just fine.
          Ulli Hafner made changes -
          Assignee Original: Ulli Hafner [ drulli ]
          Ulli Hafner made changes -
          Labels New: help-wanted

            Unassigned Unassigned
            jk Jan Klass
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: