SonarQube tfsvc插件 - 缺少以下文件的责备信息

时间:2016-02-15 08:19:55

标签: tfs version-control sonarqube sonarqube5.3

我正在使用带有tfvc插件2.1和TFS 2015 Update 1的SonarQube 5.3。

我在Sonar.properties中的参数是:

sonar.scm.enabled=true
sonar.scm.provider=tfvc
sonar.tfvc.username=*xxx*
sonar.tfvc.password.secured=*yyy*
sonar.tfvc.collectionuri=*http://mytfs:8080/tfs/mycollection*

当我在TFS vNext版本中使用内置的Sonar任务时(它与XAML版本配合使用),SCM提供程序似乎无法正常工作。我在日志中得到以下错误:

09:04:05.653 INFO  - SCM provider for this project is: tfvc
09:04:05.653 INFO  - 4 files to be analyzed
09:04:05.653 DEBUG - Executing the TFVC annotate command: D:\Builds\Agent1\_work\b33ed2ba\.sonarqube\out\.sonar\.sonartmp\SonarTfsAnnotate1596861656643555411.exe
09:04:05.762 DEBUG - TFS annotating: D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/CalcTest.AddNumbersTest.g.cs
09:04:05.778 INFO  - Unable to TFS annotate the following file which is not in a mapped TFS workspace: D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/CalcTest.AddNumbersTest.g.cs
09:04:05.778 DEBUG - TFS annotating: D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/CalcTest.cs
09:04:05.793 INFO  - Unable to TFS annotate the following file which is not in a mapped TFS workspace: D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/CalcTest.cs
09:04:05.793 DEBUG - TFS annotating: D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/Properties/AssemblyInfo.cs
09:04:05.793 INFO  - Unable to TFS annotate the following file which is not in a mapped TFS workspace: D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/Properties/AssemblyInfo.cs
09:04:05.793 DEBUG - TFS annotating: D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/Properties/PexAssemblyInfo.cs
09:04:05.793 INFO  - Unable to TFS annotate the following file which is not in a mapped TFS workspace: D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/Properties/PexAssemblyInfo.cs
09:04:05.793 INFO  - 0/4 files analyzed
09:04:05.793 WARN  - Missing blame information for the following files:
09:04:05.793 WARN  -   * D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/Properties/PexAssemblyInfo.cs
09:04:05.793 WARN  -   * D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/CalcTest.AddNumbersTest.g.cs
09:04:05.793 WARN  -   * D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/CalcTest.cs
09:04:05.793 WARN  -   * D:/Builds/Agent1/_work/b33ed2ba/s/WindowsFormsApplication2.Tests01/Properties/AssemblyInfo.cs
09:04:05.793 WARN  - This may lead to missing/broken features in SonarQube

有什么建议吗?

2 个答案:

答案 0 :(得分:0)

检查this案例并尝试解决方法,看看它是否有用:“最后我需要在创建工作区后下载代码以使插件正常工作。如果提交由第三个代理制作,该插件不起作用。“

答案 1 :(得分:0)

我比较了XAML构建的SonarQube.Analysis信息,发现我对sonar.tfvc.username有不同的帐户。 XAML使用了TFS构建帐户,当我将其用于vNext构建时,它已经工作了。