javaversion-controlsonarqubecvs

Ignoring blame result since provider returned 120 blame lines but file something.java has 226 lines for CVS Sonar


I want the blame information of all the authors who committed the code on CVS through SONAR as I'm writing a java code for getting the issues according to author name. I have installed the sonar-scm-cvs-1.1.1 plugin for sonar 7.2, and though it is retrieving the blame info for some files, it is ignoring most of the files. giving me trace something like this.

F**O] 11:35:54.394 SCM provider for this project is: cvs
FO] 11:35:54.398 18 files to be analyzed
BUG] 11:35:54.402 Working directory: 16.20\ws.network.connectivity.NSICIdentityMgmtConnectivityService.v2
BUG] 11:35:55.148 Executing CVS command: annotate pom.xml
BUG] 11:35:56.263 Ignoring blame result since provider returned 118 blame lines but file pom.xml has 120 lines  
.
.
.
This may lead to missing/broken features in SonarQube.**

Hence, there is no blame info for these files for CVS.


Solution

  • CVS will always blame the remote content of the file, so one explanation could be that you have local modifications to the file.

    Also cvs annotate returns information from server for the given file in HEAD revision. If you are working on a branch you have to manually pass the branch using -Dsonar.cvs.revision=xxxx command line argument to the scanner.