Run Code Analysis (sonar-scanner-vsts) stopped working after auto-upgrading from version 4.27.0 to 4.28.0 or 5.4 on Azure DevOps SaaS - WARN: No protobuf reports found

Since February we have been facing an issue related to not collecting metrics in Run Code Analysis plugin in Azure DevOps Service pipelines. It was working fine on version 4.27.0 but stopped working after auto-upgrading to 4.28.0 or 5.4, the plugin stopped collecting metrics and start showing the following alert:

WARN: No protobuf reports found. The C# files will not have highlighting and metrics. You can get help on the community forum: https://community.sonarsource.com

This issue occurs for all versions of NetCore, example 3.1, 5.0 and 6.0

Works fine!
Run Code Analysis 4.27.0
SonarScanner for MSBuild 5.5

Not working!
Run Code Analysis 4.28.0
SonarScanner for MSBuild 5.5.3

and

Run Code Analysis 5.4.0
SonarScanner for MSBuild 5.5.3

The execution logs for each plugin version are attached.
sonar-4.27.0.txt (14.4 KB)
sonar-4.28.0.txt (13.5 KB)
sonar-5.4.0.txt (13.5 KB)

Hello @DhiegoM

Could you provide us verbose logs of the build step (if possible in the binary format -bl)?

Hi @Caba_Sagi, sorry for the delay in responding. I have attached the log in binary format as you request. If you need more information just ask
msbuild.zip (430.6 KB)

Hello @DhiegoM

We are working on the investigation of the problem you are facing and we need a bit more information.

First of all are you using a self hosted agent or not?

Also could you please give us the verbose level logs of the begin step? To ahieve that you can do the following thing:

  • Add /d:"sonar.verbose=true" to the…
    • SonarScanner.MSBuild.exe or dotnet sonarscanner begin command to get more detailed logs
      • For example: SonarScanner.MSBuild.exe begin /k:"MyProject" /d:"sonar.verbose=true"
    • “SonarQubePrepare” or “SonarCloudPrepare” task’s extraProperties argument if you are using Azure DevOps
      • For example:
# Applies to SonarQubePrepare as well
- task: SonarCloudPrepare@1
    inputs:
      SonarCloud: 'sonarcloud'
      organization: 'zucchinibreadco'
      scannerMode: 'MSBuild'
      projectKey: 'zuchhinibreadco_sonar-scanning-someconsoleapp'
      projectName: 'sonar-scanning-someconsoleapp'
      extraProperties: |
        sonar.verbose=true

And it would be great if you could share the SonarQubeAnalysis.Config.xml with us from the .sonarqube\conf folder.

All the best,
Čaba

1 Like