NullPointerException on SonarLintImages.getIssueImage

  • Operating system: windows 10

  • SonarLint plugin version:

  • Programming language you’re coding in: java

  • Is connected mode used:

    • Connected to SonarQube enterprise: 8.9.10

And a thorough description of the problem / question:
With Eclipse 4.25 and java 17, I have this error when I click on the view “Sonarlint on the fly” :

!ENTRY org.eclipse.jface 4 2 2022-11-19 17:55:46.883
!MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.jface".
java.lang.NullPointerException: Cannot invoke "String.toLowerCase(java.util.Locale)" because "type" is null
	at org.sonarlint.eclipse.ui.internal.SonarLintImages.getIssueImage(
	at org.sonarlint.eclipse.ui.internal.views.issues.IssueDescriptionField.getImage(
	at org.sonarlint.eclipse.ui.internal.views.issues.IssueDescriptionField.update(
	at org.eclipse.ui.internal.views.markers.MarkerColumnLabelProvider.update(

I saw on github that the getIssueImage method no longer accepts the type parameter to be null, but the IssueDescriptionField class still calls the getIssueImage method passing null for this parameter. I think there is a bug here.

Thank You.

Hi @Ricetrac

Can you confirm you are using some “groupBy” in the SonarLint issues view?


Hi @Julien_HENRY ,

Yes, I use the “group by severity”, and I noticed that the menus were no longer displayed for the “Sonarlint on the fly” view, I can no longer change this setting.

Thank You.

I have created a ticket:

I was able to reproduce, except that on my side I am able to revert to “Group By” → “None”:

Thanks for the feedback!