2
votes

After upgrading to SonarQube 6.7 LTS, many of our projects started failing during "complete SonarQube analysis" task with below error:

[error]java.lang.IllegalArgumentException: No FxCop analysis has been performed on this project, whereas it contains cs files: Verify that you are using the latest version of the SonarQube Scanner for MSBuild, and if you do, please report a bug. In the short term, you can disable all FxCop rules from your quality profile to get rid of this error.

These projects have codeanalysis enabled and produce proper fxcop results.

SonarQube version: 6.7 LTS SonarC# plugin version: 6.6 SonarQube MSBuild Runner: 4.0

Can someone let me know if this is known or any way to find the actual cause of the issue.

2
Did you check your SonarQube Scanner for MSBuild version?Jeroen Heier
Yes, its 4.0. It comes along with the VSTS tasks for SonarQube analysis.sandeep manthri

2 Answers

3
votes

Support for executing FxCop was dropped in v4.0 of the Scanner for MSBuild - see SONARMSBRU-338 for more information.

However, this change should not cause the analysis to fail with the latest version of the sonar-fxcop plugin. Check the version of the sonar-fxcop that you have installed. I can reproduce the error using v1.0 of the plugin, but not with v1.1 or v1.2.

1
votes

this was fixed with Version 1.3 of the FxCop Plugin. But you Need to set some additional parametes, please see the readme.md of the plugin Project: https://github.com/DanielHWe/sonar-fxcop