Hello community,
I see a comment on SonarCloud that basically says that less 20 lines are not going to be analyzed for New Lines.
I see this ticket open, but not sure if this is only for SonarQube
Hi teams,
I am using Sonarcloud to ensure my company code. I use default quality gate with 80% code coverage need to be done. Then i get caught of this problem which really miss our expectations of the analysis:
When we create a new PR with 16 new lines of code, sonarcloud said that the number of new LOC is too small so they do not scan as “Some Quality Gate conditions on New Code were ignored because of the small number of New Lines”
However, when we merge the PR into master, the analysis fo…
I also saw an older very similar ticket - Problem when PR has less than 20 new LOCs
Can someone let me know if there’s a feature enabled for SonarCloud?
ganncamp
(G Ann Campbell)
July 11, 2023, 3:27pm
2
Hi,
It’s not that fewer than 20 lines aren’t analyzed. It’s that Quality Gate conditions on Coverage on New Code and Duplications on New Code aren’t enforced when there are fewer than 20 new lines.
A toggle to turn off this behavior has been added to SonarQube, but not in SonarCloud.
HTH,
Ann
Thank you Ann for the reply!
Is there any plan for a feature to block this in SonarCloud?
Thanks again
ganncamp
(G Ann Campbell)
July 13, 2023, 3:38pm
4
Hi,
Sorry, but I’m not currently aware of any plan for that.
Ann