Lines of Code Jumped 130K overnight

We upgraded to xunit v3 back in April. We did have some problems with coverage stats changing which no one from sonar was able to help us with. See Code Coverage Dropped Greatly when switch to xUnit.v3. But the overall line count did not change. We just lived with the coverage metrics not matching those that are shown in Azure Devops from the same coverage files uploaded to sonar.

The recent test changes were not very large. We added the Respawn package and some helpers for resetting test db state and updated a handful of tests to call the reset.

It does not seem to be a project vs test detection issue as per my last post, the analysis on the previously successful branches is now failing as well. The fact that it fails with the exact same line count as the new analysis with the updated test code seems to indicate that the new lines of code added to the test project in the recent commits are not being counted. I can speculate that is because the test lines are being counted correctly and something else is off in the line of code counting logic either in the scanner or in the way the server billing checks are handled.

At this point Sonar Cloud is pretty much non functional and I’m not sure what to do? We keep having analysis metric changes that non one from sonar can seem to explain or help us with with. I understand we don’t have a dedicated support plan but sonar is offered as a commercial service and it seems that large scale metric changes should be investigated. I hope you would agree that this is a pretty big issue and someone from sonar may need to look at our logs to figure out why the change occurred as it is pretty clear this 130K line count jump is a cause of a recent change to some Sonar code. Thanks.