Problem:
SonarQube Cloud successfully completes pull-request analysis and the
Quality Gate passes, but Azure DevOps remains permanently waiting for:
SonarCloud/quality gate
The problem affects all repositories in our organization.
Troubleshooting completed:
Repository binding is correct.
Pull-request analysis completes successfully.
The Quality Gate passes in SonarQube Cloud.
The Azure DevOps PAT stored in SonarQube Cloud was replaced.
The PAT has Code: Read & write scope.
The PAT owner has access to the project, repository and PR.
We manually called the Azure DevOps Pull Request Status API using
the same PAT.
The manual API call succeeded and created a PR status.
Querying the PR statuses API shows Azure Pipelines code-coverage
statuses and our manual test status, but no SonarCloud/quality gate
or SonarQube/quality gate status.
The problem occurs across all repositories.
Manual PR status creation result:
state : succeeded
description : Manual Sonar PAT validation
context : sonar-pat-test/quality-gate-test
This confirms that the PAT and Azure DevOps status permissions work.
Could you please confirm whether this is a known SonarQube Cloud
Azure DevOps PR-decoration problem, or check whether additional
organization-level configuration is required?
And then starting yesterday, we cannot even login to sonar cloud web app anymore (via Azure Devops sso login). We get an error “You don’t have access to the US server region”.
We are completely locked out of using this service that we pay good money for. Good luck trying to get support…
The issue could be related to your Azure DevOps PAT. There are actually two possibilities here. At some point in the past when project-level PAT configuration was still available in the UI you may have set a project-level Azure DevOps token: sonar.pullrequest.vsts.token.secured. That setting is no longer visible, but it’s still there in the background and takes precedence over your organization-level binding PAT. This could be one reason why the quality gate status never gets posted back to ADO.
We have an open dev ticket to address this, but the fix currently is to clear that hidden setting via the API. You’ll need admin permissions on the project to do this.
Are you able to login via Azure DevOps user, or are you completely locked out?
If you have lost admin access to your Organization, please follow the instructions in our documentation, by sending an email to contact@sonarsource and including the Organization key and the admin username/email which is unable to log in.
If you need help troubleshooting login issues with SSO, please open a separate Community Post.
We have attempted to perform the API call, but are having trouble. It seems we need to specify a project parameter or we get an error. But we are not sure the proper way to send the project value, and what value to send for that param.
We used our org token that has access to both of our projects. We tried putting the project name under “component” but that didn’t work.
We contacted support and they informed us that we needed to select the EU/Frankfurt server region. We had never been prompted for this before, and so we were selecting US server region. Much to our surprise all of our data is in the EU. Once we selected the EU server region we were able to login. We learned that we cannot be hosted in the US server region because that’s reserved for very high paying accounts. We are violating our companies data security policy and didn’t even know it. Maybe it was just my team that was ignorant, but I wonder how many other people are aware of this…
We have attempted to perform the API call, but are having trouble… We used our org token that has access to both of our projects.
Scoped Organization Tokens are currently only supported for project analysis endpoints, so you’ll need to use a user PAT for this operation.
We contacted support and they informed us that we needed to select the EU/Frankfurt server region. We had never been prompted for this before, and so we were selecting US server region.
US region of SonarQube Cloud was only recently made available, so most likely when you signed up it may not have even been an option. There was a change made recently to the overall login flow, with the ability to toggle US/EU region rather than navigating to separate domains. This is being rolled out progressively across our userbase, announced here.
We learned that we cannot be hosted in the US server region because that’s reserved for very high paying accounts.
Yes, currently access to the US region requires a SonarQube Cloud Enterprise plan and must be specifically requested from your sales representative.