We have TFS vNext builds setup as Gated check-in builds, meaning code changes are checked in only if the builds are successful. This is causing SonarQube to throw the following errors and warnings when running a code analysis.
10:44:08.325 ERROR: Unable to TFS annotate the following file which line 10 has not yet been checked-in (LOCAL): C:/BuildAgents/Agent1/_work/46/s/DotNet/MyProject/File1.cs
10:44:11.746 ERROR: Unable to TFS annotate the following file which line 547 has not yet been checked-in (LOCAL): C:/BuildAgents/Agent1/_work/46/s/DotNet/MyProject/File2.cs
10:44:11.762 WARN: Missing blame information for the following files:
10:44:11.762 WARN: * C:/BuildAgents/Agent1/_work/46/s/DotNet/MyProject/File1.cs 10:44:11.762 WARN: * C:/BuildAgents/Agent1/_work/46/s/DotNet/MyProject/File2.cs
10:44:11.762 WARN: This may lead to missing/broken features in SonarQube
I am passing the below properties. Am I required to pass value for “sonar.tfvc.username” and “sonar.tfvc.password.secured” or would it know to use Windows authentication?
These are the versions we are currently on:
- SonarQube: 5.6.7
- Sonar Analyzer csharp version: 184.108.40.20696
- SonarScanner for MSBuild 4.3.1
- MSBuild 14.0
- Visual Studio 2015
- TFS 2017 Update 2 (on-premise)
- SonarQube Extension 4.2.0
- Java Runtime 8 Update 144