问题
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.
回答1:
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.
回答2:
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
来源:https://stackoverflow.com/questions/47750986/analysis-failing-with-error-no-fxcop-analysis-has-been-performed-on-this-projec