Flexible mapping of SonarLint severity to Eclipse problem severitiy and editor annotations

Hello,

could you please make the Eclipse severity mapping more flexible, and add a severity distinction to the editor annotations?

I suggest something like:

Problems view (preference SonarLint / Severity of SonarLint markers):

  • Replace the drop-down list with five separate drop-down lists, one per SonarLint severity.
  • Add “Ignore” to each drop-down list (like in preference Java / Compiler / Errors/Warnings).

This would also make it possible to configure strange combinations, e.g. Sonar Minor -> Eclipse Error and Sonar Major -> Eclipse Info. But I wouldn’t bother to prohibit that (probably making the dialog less intuitive just to save the user a few clicks).

Editor Annotations (preference General / Editors / Text Editors / Annotations):

  • Replace the single “SonarLint issue” annotation with five separate annotations, one per SonarLint severity.
  • Or maybe three annotations: “SonarLint info”, “SonarLint warning”, “SonarLint error”, refering to the Eclipse severity mapped in preference “SonarLint / Severity of SonarLint markers”. For example, when SonarLint critical has been mapped to Eclipse error, the “SonarLint error” annotation type would be used for criticals.

I favor the former approach, which requires a few clicks more, but is easy and more flexible.

Thanks!

Thanks for the detailed specification.

Update Jan. 2020: We are not sure of the value of this suggestion compared to the effort to implement/maintain. Issue severity is only one parameter, some users are also suggesting to take issue type (bug/code smell/vulnerability) into account for the mapping, which start to make the UI very complicated.
In the past, we also tried to map differently new issues vs previously existing issue.

Keeping this thread open to collect more feedback, but for now we have no plan to implement it.

Thanks for the update.
For me, this feature is still crucial. There are so many infos and minors, that I refuse to treat them all as warnings, so I set all SonarLint issues to minor and therefore only notice those in places I’m currently editing (but can’t stand them cluttering up my overview ruler).

Please don’t treat this feature as more complicated than it is by merging it with others.

BTW, I appreciate your feedback, but this is not what I consider a solution. :slight_smile:

1 Like

No worries, marking a post as solution is the way we found to pin our current “official” position regarding a suggestion. The thread stays open for others to give more inputs or vote. We will re-evaluate our position on a regular basis.

We, too, would be glad if there were a visual distinction of the issue markers and annotations based on an issue’s severity.