SonarCloud Analysis for Azure Databricks Scala notebooks

Hi Team,

I have a Azure Databricks Scala notebooks, I wanted to analyse the code in Azure DevOps pipeline. Please help me with steps to integrate or add a SonarCloud task for scala code in Azure DevOps.

Thanks
Sathish

Hi,

You can try to use the Standalone scanner, with prepapre analysis configuration / run code analysis task, and it should work !

You can read more about importing external issues and test coverage / execution in our documentation :
https://sonarcloud.io/documentation/analysis/languages/scala/

Let us know it if helps.

Mickaël

Hi @mickaelcaro i am trying to do the same. I used stand alone scanner as a build tool. My azure pipeline ran successfully and got report published on the sonarqube portal as well. But it shows code coverage as zero percentage. Can you guide me how to generate code coverage when I am using standalone scanner?

Hi @Explorer and welcome to the community.

We don’t generate at all code coverage on Scanner side. All you have to do is to generate one by yourself, and pass the path as a sonar property, described in the documentation linked above.

HTH,
Mickaël

1 Like