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

Remove old Gitlab and Azure Devops summary comments on new decoration #997

Closed mc1arke closed 5 days ago

mc1arke commented 6 days ago

The plugin historically left old comments in place but resolved conversations where comments had become outdated or the underlying issue had been resolved. However, in Gitlab, the summary comments always remained visible even when resolved as they were the first comment in the thread so were not minimised by the Gitlab UI. For a merge request being scanned multiple times as issues are being fixed, other review comments responded to, and rebasing activities performed, this can lead to a number of summary comments being added where the last comment is typically only the one that developers are about.

As editing comments is not good practice since it's unclear what any resulting comments in the thread are referring to and Gitlab does not send emails to notify that comments have changed, the summary comment is continuing to be posted as a new comment, but the old summary comments are now being deleted. Where a thread has spawned from an old summary comment, that comment will not be deleted, but a note added to notify the users that the summary comment is outdated and the thread can be resolved once the discussion reaches a conclusion.

sonarcloud[bot] commented 5 days ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
85.5% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarQube Cloud