Template for a good new topic, formatted with Markdown:
ALM used: Bitbucket
CI system used: Jenkins
Languages of the repository: html, sql, json
We have the following problem.
When analizing code from a short-lived branch, all lines of code in the index.html file are analized. But when analize the same code, without changes, in a long-lived branch, not all lines of code in this file are analized. For example, when reviewing the Code tab for the long-lived branch, Lines of Code indicates 620 lines for the file, which is a total of 717 lines that the file contains.
I am using a paid SonarCloud license.
The difference in the quantity of lines is in the code tab, for .js, .html, and .json files.
For .js and .html files, fewer lines are displayed in long-lived branches. For .json files in long-lived branches it doesn’t show any number of lines.
When clicking the file name to view the detail, it contains all the lines of the file, even though the code tab shows fewer or any lines.
From the logs, I cannot identify any difference in execution. The only difference I see is the configuration of the branches (long or short-lived)
I also see what @ganncamp highlighted, as in the past, we experienced issues with caching; however, that meant that your project was not utilising cache at all, which is completely fine and does not lead to this behaviour.
We are looking into it. I will get back to you in the upcoming days.
Thanks for your patience,
We had to look at the project and try to see the problem described, as we could not find anything on the backend side. The difference you see comes from the difference in what lines are used for.
index.html has 717 lines, but 620 is the actual line of code, which gets analyzed. This is the line number which counts in the paid plan.