Many java.lang.NullPointerException in Console view

Please provide

  • Operating system: Linux
  • IDE name and flavor/env: Eclipse Version: 2022-03 (4.23.0) with OpenJDK 17 (tried 11 too)
  • SonarLint plugin version: SonarSource SonarLint for Eclipse
  • Is connected mode used: no

And a thorough description of the problem / question:

after each modification an error occurs in Console view:

Caused by: java.lang.NullPointerException
	at java.base/java.util.Objects.requireNonNull(
	at com.sonarsource.secrets.B.P.A(Unknown Source)
	at com.sonarsource.secrets.B.P.<init>(Unknown Source)
	at com.sonarsource.secrets.B.D.<init>(Unknown Source)
	at com.sonarsource.secrets.B.K.<init>(Unknown Source)
	at jdk.internal.reflect.GeneratedConstructorAccessor107.newInstance(Unknown Source)
	at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(
	at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(
	at java.base/java.lang.reflect.Constructor.newInstance(
	at org.sonarsource.sonarlint.core.plugin.commons.pico.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(
	... 43 more

Hello @thmarkus,

Sorry answer took so long.
Looks like secrets analyzer got corrupted somehow. You can try to reinstall sonarlint. But Eclipse maybe will try to be smart and cache the files.
If re installation didn’t help or you want to investigate, I’d ask you to find secrets plugin file and check it’s md5 hash. On linux plugin jar should be located somewhere like ~/eclipse/java-2021-12/eclipse/configuration/org.eclipse.osgi.
There you will see folders named with numbers. You will need to use search to find file “sonar-secrets-plugin-”. Full path to the file will look like ~/eclipse/java-2021-12/eclipse/configuration/org.eclipse.osgi/665/0/.cp/plugins/.
So when you will find it, please compute it’s md5 hashsum using terminal command:
md5sum sonar-secrets-plugin-
Please come back with checksum and we can figure out what to do next.