Bypassing sonar quality gate on merge queue CI checks

Template for a good new topic, formatted with Markdown:

  • ALM used
  • CI system used
  • Scanner command used when applicable (private details masked)
  • Languages of the repository
  • Only if the SonarCloud project is public, the URL
    • And if you need help with pull request decoration, then the URL to the PR too
  • Error observed (wrap logs/code around with triple quotes ``` for proper formatting)
  • Steps to reproduce
    Merge into merge queue and navigate to CI checks running on merge queue
  • Potential workaround

Do not share screenshots of logs – share the text itself (bonus points for being well-formatted)!

I’ve enabled merge queues as a requirement for my company’s master branch. The problem is, we run sonar analysis as a branch level check to ensure that our sonar quality gate has passed before merging into the branch. Since this acts as a blocker to even merge into the merge queue, we do not want to run the Sonar checks again when the change is actually in the merge queue since it is a superfluous check. I am looking for guidance on how I can forego my branch level merge requirement for the CI checks run from within the merge queue but keep the sonar checks at the PR level.


I’m not sure I follow your flow, but presumably this is a matter of editing your pipeline(s) to limit which steps run on which branches / under which conditions?