Sonarlint prompts internal error

image
There is nothing in the panel, and clicking the button will prompt an internal error in the lower right corner
image
May I ask what is causing this, can anyone help me? After the first installation, it was successfully started, but after I accidentally clicked some buttons on the warning, nothing was prompted. I hope some kind people can help me solve this problem. thank you very much

Hello, welcome to the community! And thank you for reporting this.

Could you please have a look at the SonarLint Output and paste here (enclosed in a code block with ```) any error message/stack trace?

You can reach it through the command palette (Ctrl+Shift+P, “SonarLint: Show SonarLint Output”).

If there is nothing in the SonarLint Output, you might want to try to look at VSCode’s developer console (Ctrl+Shift+I, or “Help > Toggle Developer Tools”).

Also, it would be nice if you can provide:

  • Your OS and version (looks like Windows from your screenshots)
  • The versions of VSCode and SonarLint
  • The vendor and version of the JRE that is used to run SonarLint’s Language Server

Hello, thanks for coming to help, my system is Windows, the editor used is Visual Studio code, the following part is the output information of SonarLint:

[Info  - 22:37:43.054] Started security hotspot handler on port 64120
[Error - 22:37:43.493] Error starting standalone SonarLint engine
[Error - 22:37:43.495] java.lang.IllegalStateException: Unable to read plugin manifest from jar : C:\Users\27322\.sonarlint\plugins\72aa920901457ef288c793b1c87f64ca\sonarjava.jar
    at org.sonarsource.sonarlint.core.plugin.PluginManifest.<init>(PluginManifest.java:75)
    at org.sonarsource.sonarlint.core.plugin.PluginInfo.create(PluginInfo.java:352)
    at org.sonarsource.sonarlint.core.plugin.PluginInfosLoader.loadPlugins(PluginInfosLoader.java:78)
    at org.sonarsource.sonarlint.core.plugin.PluginInfosLoader.load(PluginInfosLoader.java:68)
    at org.sonarsource.sonarlint.core.plugin.PluginRepository.start(PluginRepository.java:54)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.base/java.lang.reflect.Method.invoke(Method.java:566)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.lifecycle.ReflectionLifecycleStrategy.invokeMethod(ReflectionLifecycleStrategy.java:110)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.lifecycle.ReflectionLifecycleStrategy.start(ReflectionLifecycleStrategy.java:89)
    at org.sonarsource.sonarlint.core.container.ComponentContainer$1.start(ComponentContainer.java:272)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.injectors.AbstractInjectionFactory$LifecycleAdapter.start(AbstractInjectionFactory.java:84)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.behaviors.AbstractBehavior.start(AbstractBehavior.java:169)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.behaviors.Stored$RealComponentLifecycle.start(Stored.java:132)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.behaviors.Stored.start(Stored.java:110)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.DefaultPicoContainer.potentiallyStartAdapter(DefaultPicoContainer.java:1016)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.DefaultPicoContainer.startAdapters(DefaultPicoContainer.java:1009)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.DefaultPicoContainer.start(DefaultPicoContainer.java:767)
    at org.sonarsource.sonarlint.core.container.ComponentContainer.startComponents(ComponentContainer.java:125)
    at org.sonarsource.sonarlint.core.StandaloneSonarLintEngineImpl.start(StandaloneSonarLintEngineImpl.java:66)
    at org.sonarsource.sonarlint.core.StandaloneSonarLintEngineImpl.<init>(StandaloneSonarLintEngineImpl.java:49)
    at org.sonarsource.sonarlint.ls.EnginesFactory.newStandaloneEngine(EnginesFactory.java:105)
    at org.sonarsource.sonarlint.ls.EnginesFactory.createStandaloneEngine(EnginesFactory.java:95)
    at org.sonarsource.sonarlint.ls.standalone.StandaloneEngineManager.getOrCreateStandaloneEngine(StandaloneEngineManager.java:37)
    at org.sonarsource.sonarlint.ls.CommandManager.listAllStandaloneRules(CommandManager.java:208)
    at org.sonarsource.sonarlint.ls.SonarLintLanguageServer.lambda$listAllRules$4(SonarLintLanguageServer.java:302)
    at java.base/java.util.concurrent.CompletableFuture$UniApply.tryFire(CompletableFuture.java:642)
    at java.base/java.util.concurrent.CompletableFuture$Completion.exec(CompletableFuture.java:479)
    at java.base/java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:290)
    at java.base/java.util.concurrent.ForkJoinPool$WorkQueue.topLevelExec(ForkJoinPool.java:1020)
    at java.base/java.util.concurrent.ForkJoinPool.scan(ForkJoinPool.java:1656)
    at java.base/java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1594)
    at java.base/java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:183)
Caused by: java.util.zip.ZipException: zip END header not found
    at java.base/java.util.zip.ZipFile$Source.zerror(ZipFile.java:1597)
    at java.base/java.util.zip.ZipFile$Source.findEND(ZipFile.java:1488)
    at java.base/java.util.zip.ZipFile$Source.initCEN(ZipFile.java:1495)
    at java.base/java.util.zip.ZipFile$Source.<init>(ZipFile.java:1299)
    at java.base/java.util.zip.ZipFile$Source.get(ZipFile.java:1262)
    at java.base/java.util.zip.ZipFile$CleanableResource.<init>(ZipFile.java:733)
    at java.base/java.util.zip.ZipFile$CleanableResource.get(ZipFile.java:842)
    at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:248)
    at java.base/java.util.zip.ZipFile.<init>(ZipFile.java:177)
    at java.base/java.util.jar.JarFile.<init>(JarFile.java:350)
    at java.base/java.util.jar.JarFile.<init>(JarFile.java:321)
    at java.base/java.util.jar.JarFile.<init>(JarFile.java:287)
    at org.sonarsource.sonarlint.core.plugin.PluginManifest.<init>(PluginManifest.java:70)
    ... 33 more

Vendor and version of JRE:
java jdk-11.0.13

Thank you, that was quick :slight_smile:

It looks like the Java analyzer’s JAR file got corrupted somehow. Could you please try to:

  • Close VSCode
  • Delete folder C:\Users\27322\.sonarlint\plugins
  • Restart VSCode

I believe this should fix the issue, by forcing SonarLint to re-extract the required JAR files.

1 Like

Because I was very anxious, there was no answer in the Internet search, so I waited for a reply online and solved it according to the method you gave! Thank you very much! ! ! :heart:

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.