SonarQube is not showing the analysis results of the C# code

Dear Team,

After spending long time in the multiple tryouts, i am not able to figure out what is going wrong in sonar integration with Azure Devops. We are integrating the developer edition with our azure DevOps.

In our project we have most of the code from C# and Javascript. What we are trying to acheive is, as soon as pull request is raised in the Azure DevOps, sonarqube should analyze all the files and show the errors to the developer.

I have integrated the SonarQube with Azure DevOps as per the steps given in the documentation and added respective task in the Build Pipeline.

Below are the version details -

SonarQube version -
SonarScanner for MSBuild - 5.8

According to task given in pipeline, it is identifying the new files using the attribute sonar.source in “Prepare analysis on SonarQube”. If i see the logs of “Build Solution” task, i can see the error/bug/code smells but there are no details shown in the pull request decoration, it is showing entirely blank. I have tried using both stand alone scanner and Integrate with MSBuild. Strange thing is it is showing the code smells of the javascript if we add .js files in the PR, but not C#.

By checking the blog of the categorization of project, i have set the test project as false in .csproj file of my project. Variable SonarQubeTestProject set to false.

Please let me know if i am missing something.

Please find below screenshot.

PrepareAnalysisOnSonarQube_Logs.txt (8.6 KB)
BuildSolution_Logs.txt (360.8 KB)


Thanks for the logs. Something seems to be missing, though. I don’t see the analysis report submission to the server.

Your screenshot shows “1.3k New Lines”. If you click through on that, what languages show up in the list of files?

And finally, there are 3 yellow, “warning” areas on your screen:

  • There’s a newer version available, at the top. You really should upgrade your evaluation to 9.7.1.
  • You’re using the embedded database, at the bottom. You’re planning to connect to another DB for production, right?
  • “Last analysis of this PR had 3 warnings”. What are those warnings?