At 10.24AM we started getting this error accross all GitHub Action executions
INFO: ------------- Run sensors on project
INFO: Sensor C# [csharp]
WARN: No protobuf reports found - no metrics and highlighting will be imported.
INFO: ------------------------------------------------------------------------
INFO: EXECUTION FAILURE
INFO: ------------------------------------------------------------------------
INFO: Total time: 2:07.008s
ERROR: Error during SonarQube Scanner execution
INFO: Final Memory: 29M/100M
java.lang.IllegalStateException: No Roslyn issue reports were found.
at org.sonarsource.dotnet.shared.plugins.DotNetSensor.executeInternal(DotNetSensor.java:101)
at org.sonarsource.dotnet.shared.plugins.DotNetSensor.execute(DotNetSensor.java:71)
at org.sonar.scanner.sensor.AbstractSensorWrapper.analyse(AbstractSensorWrapper.java:45)
at org.sonar.scanner.sensor.ProjectSensorsExecutor.execute(ProjectSensorsExecutor.java:38)
at org.sonar.scanner.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:378)
at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:122)
at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:108)
at org.sonar.scanner.bootstrap.GlobalContainer.doAfterStart(GlobalContainer.java:126)
at org.sonar.core.platform.ComponentContainer.startComponents(ComponentContainer.java:122)
at org.sonar.core.platform.ComponentContainer.execute(ComponentContainer.java:108)
at org.sonar.batch.bootstrapper.Batch.doExecute(Batch.java:58)
at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:52)
at org.sonarsource.scanner.api.internal.batch.BatchIsolatedLauncher.execute(BatchIsolatedLauncher.java:46)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
For a commit in the same PR submitted 40 minutes earlier I had no error and this output instead:
INFO: ------------- Run sensors on project
INFO: Sensor C# [csharp]
INFO: Sensor C# [csharp] (done) | time=0ms
INFO: Sensor Zero Coverage Sensor
INFO: Sensor Zero Coverage Sensor (done) | time=118ms
Could you please explain what the error message means?
We’re also seeing this error on our Run Code Analysis task within our Azure DevOps builds of .NET SQL applications however our .NET web application builds are running fine. WARN: No protobuf reports found - no metrics and highlighting will be imported.
We’re also in the process of updating our Java version from 1.8.0_112: ##[warning]WARN: The version of Java (1.8.0_112) you have used to run this analysis is deprecated and we will stop accepting it from October 2020. Please update to at least Java 11.
@mickaelcaro just wanted to bring this to your attention as it seems several of us are seeing this on our environments, so maybe something which is widespread.
I previously had this message in all the successful executions:
INFO: Sensor C# Properties [csharp]
WARN: Property missing: 'sonar.cs.analyzer.projectOutPaths'. No protobuf files will be loaded for this project.
WARN: No Roslyn issues report found for this project.
INFO: Sensor C# Properties [csharp] (done) | time=1ms
Now, in the GitHub actions which fail I have this message in lieu
INFO: No UCFGs have been included for analysis.
INFO: Sensor PythonSecuritySensor [security] (done) | time=0ms
INFO: ------------- Run sensors on project
INFO: Sensor C# [csharp]
INFO: Sensor C# [csharp] (done) | time=0ms
INFO: Sensor C# Tests Coverage Report Import [csharp]
WARN: Could not find any coverage report file matching the pattern '**/*.coveragexml'.
INFO: Sensor C# Tests Coverage Report Import [csharp] (done) | time=1094ms
INFO: Sensor Zero Coverage Sensor
INFO: Sensor Zero Coverage Sensor (done) | time=266ms
(Analysis would then execute successfully)
New output:
INFO: No UCFGs have been included for analysis.
INFO: Sensor PythonSecuritySensor [security] (done) | time=0ms
INFO: ------------- Run sensors on project
INFO: Sensor C# [csharp]
WARN: No protobuf reports found - no metrics and highlighting will be imported.
INFO: ------------------------------------------------------------------------
INFO: EXECUTION FAILURE
INFO: ------------------------------------------------------------------------
INFO: Total time: 1:05.907s
INFO: Final Memory: 41M/794M
INFO: ------------------------------------------------------------------------
##[error]ERROR: Error during SonarScanner execution
An explanation: We deployed a new version (8.13) of the C# and VB .NET plugins this morning (Europe timezone) . For issue #3593 we decided to fail the analysis in case the roslyn reports are not found (which means that msbuild didn’t run). It appears that there are usage scenarios we didn’t consider, and thanks a lot for your reactions.
What we’ll do: We are going to revert the C# and VB .NET plugin version ASAP to the previous one (8.12). I will give an update when the revert is done. And then follow up to understand your usage scenarios.
In this action we’re using the msbuild scanner for analysis of .js (cf. GitHub Action yaml file at the top of my first message).
We have a separate action which uses dotnet sonarscanner for C# analysis.
I don’t think so. Your use case of analyzing only the JS code in a C# project is a valid one. I opened #3615 and we’ll do a bugfix. We’ll also add regression tests for your cases.