mc1arke / sonarqube-community-branch-plugin

A plugin that allows branch analysis and pull request decoration in the Community version of Sonarqube
GNU Lesser General Public License v3.0
2.26k stars 527 forks source link

Spammy reporting #981

Closed gtrias closed 1 month ago

gtrias commented 1 month ago

Describe the bug

GitHub comments are being added for each commit when running CI, which leads to excessive noise in PRs and a poor developer experience.

To Reproduce Steps to reproduce the behavior:

  1. Set up the Github Devops in Sonarqube
  2. Open a Pull request with the Sonarqube plugin.
  3. Start iterating the PR by submitting commits
  4. For every CI cycle, sonarqube-community-branch-plugin is appending a new comment to the PR.

Expected behavior

Screenshots image

Software Versions

mc1arke commented 1 month ago

This isn't a bug - it's working as intended. When pushing new commits you're making changes to the code base so impact coverage and quality. If you'd expected your changes to reach a certain coverage level or to not have issues but your coverage isn't high enough of you do have issues then you're likely to want to know about it.

The point about deleting old comments is a reasonable direction I've mentioned in other areas (we've had conversations similar to this about the Gitlab decorator), but that would be a feature request rather than a bug

gtrias commented 1 month ago

This isn't a bug - it's working as intended. When pushing new commits you're making changes to the code base so impact coverage and quality. If you'd expected your changes to reach a certain coverage level or to not have issues but your coverage isn't high enough of you do have issues then you're likely to want to know about it.

The point about deleting old comments is a reasonable direction I've mentioned in other areas (we've had conversations similar to this about the Gitlab decorator), but that would be a feature request rather than a bug

I see. Sorry for the noise then. I understand we get that many because I have code coverage analysis broken :(

Sorry, I was looking for a way to suggest features such as "replace" older comments with newer ones, but I was not able to find the template when creating the issue. Sonarqube Enterprise works like this. It does not keep older irrelevant comments when new ones appear.

gtrias commented 3 weeks ago

Then, considering your answer, should I also get comments like this one? It clearly passed, so I don't get any value from it

image

mc1arke commented 3 weeks ago

Yes, we currently report any time sonarqube performs an analysis

gtrias commented 3 weeks ago

Yes, we currently report any time sonarqube performs an analysis

Got it. Thanks :)

Is there any future plans to tweak or configure how this report behavior is performed?