We’re using SonarCloud with Azure DevOps build pipelines, and notice we get inconsistent results on analysis of builds.
Possibly the most telling is the lines of code count jumps down and up like a mad thing.
For the most noticeable pipeline, it’s had several builds this month:
December 3rd, 10:08 - 301,968 lines of code; 1,783 classes
December 3rd, 12:48 - 301,968 lines of code; 1,783 classes
December 4th, 12:00 - 301,968 lines of code; 1,783 classes
December 8th, 16:29 - 218,772 lines of code; 1,290 classes
December 9th, 9:36 - 213,167 lines of code; 1,240 classes
December 11th, 12:00 - 302,042 lines of code; 1,784 classes
December 14th, 16:20 - 213,167 lines of code; 1,240 classes
December 15th, 10:30 - 302,039 lines of code; 1,784 classes
December 15th, 15:32 - 302,004 lines of code; 1,784 classes
December 15th, 16:02 - 213,128 lines of code; 1,240 classes
Now whilst I expect a little build on build variance - suddenly losing about 30% of the code base looks to be a massive outlier, especially as it came back pretty quickly (and reviewing changesets confirms no mass refactoring going on here)
Also, reviewing the logs shows nothing obvious to the untrained eye.
It does appear to affect multiple pipelines of ours, and as the code is vanishing, and coming back, we were seeing security hotspots constantly being flagged as new, with all the old comments having been destroyed on the new version of an old hotspot - this does seem like it may have been mitigated with the new security hotspot workflow, but it might just be that the vanishing sections don’t have any hotspots any more