Error observed - When setting up SonarCloud PR Decoration within Azure DevOps Services, the scans will complete and whether the quality gate passes or fails, the pull request is stuck on the ‘SonarCloud/quality gate’ check.
Correct Status Check is added to branch policies
PATs between Azure DevOps and SonarCloud have been updated multiple times with an account that has sufficient permissions. Sonar PAT added to ADO side and ADO (Code - Read/Write) token added to SonarCloud configuration.
This appears to be a common issue, but continues to occur at random times.
Sorry for not coming back to you more quickly!
As an experiment, could you remove the sonarcloud-buildbreaker task from your pipeline and see if it improves things? We have had issues in the past with it, so it would be good to rule it out first.
@denis.troller , I would need to redact the log first before I can send it over as it has a bit of personal creds and code in it. What information are you looking for specifcally?
I do not know exactly what I am looking for at this point, it’s more to understand what could be going on here. Please do redact sensitive information in it.
@denis.troller , do you need anything in regards to the actual build process itself? This log is 45k+ lines long and probably 75% of it is tied to just the build.
Are you okay with just the Sonar steps themselves?
@denis.troller , I have completed the redacting of the log, but my CISO requested that I contact you directly. Is there any way that you can provide an email address?
Hi, thanks for the logs. I have raised the issue with the proper team and will get back to you as soon as we have anything or if we require further enquiries.
From what you are saying (the issue is intermittent), I can rule out the most basic reasons why your issue appears, but still could you double check that:
Once you ensured all of the following, we can rule out all the basic reasons why it could not be working (monorepo setup, PAT not set in the project, pipeline not running for the specific pull request change).
If all the rest looks good, we will need to allocate a bit of time to dig into that with someone who has expertise on the specific part of the code that handles sending the quality gate status to Azure DevOps.
You state that the issue is intermittent, could you be more specific about how intermittent it is? Is it failing 10% of the time, 50%, 90%?
Hello @prketner , it’s been more than 2 months, I am assuming you found a resolution for your issue. If so, would you be willing to share it to help other users facing the same issue?
Cheers
Benjamin
Hello @benjamin.raymond,
we’re also facing this issue from time to time and I can confirm that all these 4 settings are correctly configured as per your suggestions in all the projects that are experiencing the problem.
It’s quite frustrating not being able to provide a clear solution to our colleagues except the awkward “workaround” to disable the quality gate check in the branch policy setting…
Do you have any updates on it ?
Is there anything else we can check on our side ?