PR Decoration and Comments Not Showing in Azure DevOps Despite Correct Setup

Hi SonarCloud Community,

I am experiencing an issue where pull request (PR) decoration and comments are not appearing in Azure DevOps, even though the setup appears to be correct. Here are the details:

  • The Azure DevOps repository is linked to the SonarCloud project.
  • The project has PR decoration enabled with Azure DevOps as the provider.
  • A Personal Access Token (PAT) with the required scopes (Code and Pull Requests) is configured and used in the pipeline.
  • PR triggers are correctly defined in our YAML pipeline (pr.branches.include).
  • The sonar.projectKey, sonar.organization, and sonar.login are properly set via sonar-project.propertiesor extraProperties.
  • The PR analysis runs successfully, and results show up in SonarCloud — but the decoration is not posted back to the Azure DevOps PR.

Can you please help investigate why PR decoration is not working?

Any update ? @ganncamp

Hi,

Welcome to the community!

I invite you to familiarize yourself with the FAQ, and in particular this section:

I created a topic, when can I expect a response?

This is an open community with people volunteering their free time to provide assistance. We’re eager to contribute to the community, but you are not guaranteed a fast response.

Be patient

  • Wait a few days before bumping a topic that hasn’t received a response.

As well as this section:

What is @name mentioning? Should I do it?

@name mentioning is when you type someone’s username with an @ preceding it. Doing this sends a notification to the user. Depending on their settings, it may also send them an email message.

In general, it is considered bad form to @name mention someone not already engaged in the conversation. Please don’t do it.

Regarding your question, are you missing PR decoration across your organization or only for one or two projects?

 
Thx,
Ann

Apologies for name mentioned

The issue is with PR decoration across my organization

Hi,

And has PR decoration ever worked? If so, then it’s likely that your PAT expired.

 
HTH,
Ann

Checked PAT no issues with PAT

I used cURL to hit ADO and its working fine

I tried full access & Code READ/Write token both are good & working

I am using full access one

Hi,

Has decoration ever worked? Or has it been this way since you set up your organization?

 
Thx,
Ann

No its not worked ever..

I dont see any RED/Green Icon in PR list ADO also comments are not getting added after analysis completed to PR back as well

Hi,

Thanks for confirming that. I’ve flagged this for more expert eyes.

 
Ann

I can provide PR ID from SonarCloud if required to check on your side

1 Like

Hi,

Organization, project and PR IDs would all be very helpful.

 
Thx,
Ann

How can I share it privately?