VSTS SonarCloud warning shown as errors

sonarcloud
vsts

(loshurik) #1

Hello, I’m using VSTS SonarCloud extension (v.1.*) to scan a js-based project.
I get warnings that are recognized as errors:

WARN: Metric ‘comment_lines_data’ is deprecated. Provided value is ignored.
WARN: Access to the multi-values/property set property ‘sonar.typescript.eslint.reportPaths’ should be made using ‘getStringArray’ method. The SonarQube plugin using this property should be updated.

Here are all my Sonar settings used for the project:

sonar.exclusions=node_modules/**,dist/**
sonar.sourceEncoding=UTF-8
sonar.branch.name=develop
sonar.coverage.exclusions=**/*

Is it possible to set warnings to appear as warnings, not errors?
How can I clear these warnings?


(Julien Henry) #4

Hi,

We made the choice to write WARN logs to stderr:

The result is that those logs are reported as error in the VSTS UI. To me this is good, otherwise no one would look at those WARN logs.


(Elena Vilchik) #5

(Jorn Vennix) #6

It would be good, if your users could do anything with it. However it’s a deprecated method in the scanner/sonar which now fails complete builds and renders the standard Sonar components in VSTS/Azure DevOps totally useless.

Either the warning needs to be changed to stdOut or solved in general.

Else you might as well pull out the Sonar components from the VSTS Marketplace, because they will not be usable because of this error message.


(Julien Henry) #7

Why do you say it fails your build? From your screenshot, I can see “Build process succeeded”. This is just to help me better understand.