Hi,
I am facing issue with code analysis of a c# project.
Any ideas how to solve this?
Thank you, Peter
Must-share information (formatted with Markdown):
- which versions are you using (SonarQube, Scanner, Plugin, and any relevant extension)
SonarQube Version 9.3 (build 51899)
SonarScanner for MSBuild 5.7.1
csharp version 8.34.0.42011
MSBuild 15.9.21+g9802d43bc3 for .NET Framework
- what are you trying to achieve
Code analysis for a smaller c# project.
Build works without errors.
Code analysis works for .sql and .xml files, however all .cs file show â-â Lines of Code in the user interface under âCodeâ.
The log shows:
09:52:08.98 Dumping content of sonar-project.properties
ACB2D2DA-29B2-48E4-8118-4AC29DD257E0.sonar.cs.analyzer.projectOutPaths=
âC:\Users\âremovedâ\Build\.sonarqube\out\0â
09:52:14.063 INFO: Sensor C# Analysis Log [csharp]
09:52:14.071 DEBUG: Project âremovedâ: Analyzer working directory does not exist: âC:\Users*âremovedâ\Build.sonarqube\out\0\output-csâ. Analyzer results wonât be loaded from this directory.
09:52:14.071 INFO: Sensor C# Analysis Log [csharp] (done) | time=8ms
09:52:14.071 INFO: Sensor C# Properties [csharp]
09:52:14.071 DEBUG: Project âremovedâ: Analyzer working directory does not exist: 'C:\Users*âremovedâ\Build.sonarqube\out\0\output-csâ. Analyzer results wonât be loaded from this directory.
09:52:15.499 INFO: Sensor C# Project Type Information [csharp]
09:52:15.499 INFO: Sensor C# Project Type Information [csharp] (done) | time=0ms
09:52:15.499 INFO: Sensor C# Analysis Log [csharp]
09:52:15.499 DEBUG: Project âSBFDâ: Property missing: âsonar.cs.analyzer.projectOutPathsâ. No protobuf files will be loaded for this project.
09:52:15.499 INFO: Sensor C# Analysis Log [csharp] (done) | time=0ms
09:52:15.499 INFO: Sensor C# Properties [csharp]
09:52:15.499 DEBUG: Project âSBFDâ: Property missing: âsonar.cs.analyzer.projectOutPathsâ. No protobuf files will be loaded for this project.
09:52:15.499 DEBUG: Project âSBFDâ: No Roslyn issues reports have been found.
09:52:15.499 INFO: Sensor C# Properties [csharp] (done) | time=0ms
- what have you tried so far to achieve this
Tried various versions of MSBuild (14, 15, 16)
Tried various version of SonarScanner for .net (5.4.0, 5.5.3, 5.6.0)