SonarLint

Add this URL to your Eclipse Installation to reach this solution's update site.

2024-09 (4.33), 2024-06 (4.32), 2024-03 (4.31), 2023-12 (4.30), 2023-09 (4.29), 2023-06 (4.28), 2023-03 (4.27), 2022-12 (4.26), 2022-09 (4.25), 2022-06 (4.24), 2022-03 (4.23), 2021-12 (4.22), 2021-09 (4.21), 2021-06 (4.20), 2021-03 (4.19), 2020-12 (4.18), 2020-09 (4.17), 2020-06 (4.16), 2020-03 (4.15), 2019-12 (4.14), 2019-09 (4.13), 2019-06 (4.12), 2019-03 (4.11), 2018-12 (4.10), 2018-09 (4.9), Photon (4.8)

https://eclipse-uc.sonarlint.org

Learn more...
Solution Description

SonarLint is an extension that helps you detect and fix quality and security issues as you write code. Like a spell checker, SonarLint squiggles flaws so they can be fixed before committing code. You can get it directly from the Eclipse Marketplace, and it will then detect new bugs and quality issues as you code for the following languages: Java/JSP (available with JDT), JavaScript/TypeScript/CSS (available with Node.js), HTML, PHP, and Python.

If your project is analyzed on SonarQube or SonarCloud, SonarLint can connect to it to retrieve the appropriate quality profiles and settings for that project, some additional language support, and see what issues are already present on the server to be synchronised with the local IDE.

In that case, the additional languages are ABAP, Apex, C/C++ (available with CDT), COBOL/JCL (available with a COBOL-IDE), Kotlin, PL/I, PL/SQL, RPG, Ruby, Scala, and T-SQL.

Discover more at https://docs.sonarsource.com/sonarlint/eclipse/

SonarLint requires the IDE to use Java 11+ as its runtime, but you can analyze Java projects targeting older or newer Java versions. IDEs running on Java 8 or older are no longer supported!

To run analyzers from SonarQube 10.5+ and SonarCloud that require a Java 17 runtime, we provide our own one for the analysis if the IDE itself is not running on a sufficient JRE. If you want to use your own one to keep full control, take a look at the dedicated documentation.

For any questions or feedback, including bugs or feature requests, please join the SonarSource Community Forum.

Additional Details

Eclipse Versions: 2024-09 (4.33), 2024-06 (4.32), 2024-03 (4.31), 2023-12 (4.30), 2023-09 (4.29), 2023-06 (4.28), 2023-03 (4.27), 2022-12 (4.26), 2022-09 (4.25), 2022-06 (4.24), 2022-03 (4.23), 2021-12 (4.22), 2021-09 (4.21), 2021-06 (4.20), 2021-03 (4.19), 2020-12 (4.18), 2020-09 (4.17), 2020-06 (4.16), 2020-03 (4.15), 2019-12 (4.14), 2019-09 (4.13), 2019-06 (4.12), 2019-03 (4.11), 2018-12 (4.10), 2018-09 (4.9), Photon (4.8)

Platform Support: Windows, Mac, Linux/GTK

Organization Name: SonarSource S.A

Development Status: Production/Stable

Date Created: Thursday, October 15, 2015 - 14:54

License: LGPL

Date Updated: Friday, November 8, 2024 - 03:59

Submitted by: Julien HENRY

Screenshot
Date Ranking Installs Clickthroughs
November 2024 8/575 2533 17
October 2024 7/663 8606 42
September 2024 7/642 8823 75
August 2024 6/641 7284 61
July 2024 6/663 8194 65
June 2024 7/681 8455 62
May 2024 8/682 8968 208
April 2024 8/687 9420 56
March 2024 7/694 10340 74
February 2024 7/687 9019 332
January 2024 7/691 9155 80
December 2023 8/671 7972 38
View Data for all Listings

Marketplace Drag to Install Button

By adding the following code below to your website you will be able to add an install button for SonarLint.

HTML Code:

Markdown Syntax:

Output:

Drag to your running Eclipse* workspace. *Requires Eclipse Marketplace Client

Reviews Add new review

An error occurred while collecting items to be installed session context was:(profile=DefaultProfile, phase=org.eclipse.equinox.internal.p2.engine.phases.Collect, operand=, action=). Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.buildship,10.5.0.82112. Error reading signed content:C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile10313153783101979647.jar An error occurred while processing the signatures for the file: C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile10313153783101979647.jar Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.cdt,10.5.0.82112. Error reading signed content:C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile10397969022323479977.jar An error occurred while processing the signatures for the file: C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile10397969022323479977.jar Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.core,10.5.0.82112. Error reading signed content:C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile10107203306425454431.jar An error occurred while processing the signatures for the file: C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile10107203306425454431.jar Problems downloading artifact: org.eclipse.update.feature,org.sonarlint.eclipse.feature,10.5.0.82112. Error reading signed content:C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile14422541724515984357.jar An error occurred while processing the signatures for the file: C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile14422541724515984357.jar Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.jdt,10.5.0.82112. Error reading signed content:C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile1531038254240984869.jar An error occurred while processing the signatures for the file: C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile1531038254240984869.jar Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.m2e,10.5.0.82112. Error reading signed content:C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile3249597145876541087.jar An error occurred while processing the signatures for the file: C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile3249597145876541087.jar Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.pydev,10.5.0.82112. Error reading signed content:C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile4880372009050494987.jar An error occurred while processing the signatures for the file: C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile4880372009050494987.jar Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.sloop.windows.x64,10.5.0.82112. Error reading signed content:C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile15444917952980760420.jar An error occurred while processing the signatures for the file: C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile15444917952980760420.jar Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.ui,10.5.0.82112. Error reading signed content:C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile16201894805081509383.jar An error occurred while processing the signatures for the file: C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile16201894805081509383.jar Problems downloading artifact: osgi.bundle,org.sonarsource.sonarlint.core.sonarlint-java-client-osgi,10.3.2.78498. Error reading signed content:C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile17149782351202898254.jar An error occurred while processing the signatures for the file: C:\Users\VINAYA~1\AppData\Local\Temp\signatureFile17149782351202898254.jar

In reply to by Vinayak Naik

Hi Vinayak,

Thank you for reaching out. SonarLint requires the IDE to run on Java 11 as per our documentation but the STS version you have is based on a version of the Eclipse IDE that is running Java 8. Either change the Java runtime of the IDE to match the criteria or install the last version we have that supports Java 8, SonarLint for Eclipse 6.2.0.37299 directly from our Eclipse Update Site.

I would highly recommend updating the version of STS, tho, as the old SonarLint for Eclipse version is not supported anymore like the version of STS you have.

Best,

Tobias

An error occurred while collecting items to be installed
session context was:(profile=DefaultProfile, phase=org.eclipse.equinox.internal.p2.engine.phases.Collect, operand=, action=).
Problems downloading artifact: osgi.bundle,org.slf4j.api,1.7.30.v20200204-2150.
MD5 hash is not as expected. Expected: 5bb2c4b4ca372fe1d13d34b16fc14501 and found 491139742b1bdd4d3de73d82f35eb7ac.

In reply to by Lizandro Caspe

Hello Lizandro,

can you please provide us with more information on that issue? Is scrolling vertically or horizontally not working? Can you scroll when adjusting the SonarLint Rule Description view?

Can you also please provide with the environment you are using?

  • Eclipse Version
  • Operating System (some components are affected by different OSs)

Thank you very much for using SonarLint and raising this issue! Best,

Tobias

Cannot complete the install because some dependencies are not satisfiable
  Software being installed: a.jre.javase 17.0.0
  Software being installed: SonarLint for Eclipse 7.12.0.72679 (org.sonarlint.eclipse.feature.feature.group 7.12.0.72679)
  Cannot satisfy dependency:
    From: SonarLint for Eclipse 7.12.0.72679 (org.sonarlint.eclipse.feature.feature.group 7.12.0.72679)
    To: org.eclipse.equinox.p2.iu; org.sonarlint.eclipse.ui [7.12.0.72679,7.12.0.72679]
  Cannot satisfy dependency:
    From: SonarLint for Eclipse 7.12.0.72679 (org.sonarlint.eclipse.ui 7.12.0.72679)
    To: osgi.ee; (&(osgi.ee=JavaSE)(version=11))

In reply to by Mike Grain

Hello Mike,

could you please provide us with more information regarding the failed installation?

  • What flavour and version of Eclipse do you jave installed?
  • Was there more information on that failure like a log output written?

Thank you very much for raising the issue. Best,

Tobias

An error occurred while collecting items to be installed
session context was:(profile=epp.package.jee, phase=org.eclipse.equinox.internal.p2.engine.phases.Collect, operand=, action=).
Problems downloading artifact: osgi.bundle,com.squareup.okhttp3,4.10.0.
Error reading signed content:/tmp/signatureFile5101138998048619086.jar
An error occurred while processing the signatures for the file: /tmp/signatureFile5101138998048619086.jar
Problems downloading artifact: osgi.bundle,com.squareup.okio,3.0.0.
Error reading signed content:/tmp/signatureFile2292464475685409738.jar
An error occurred while processing the signatures for the file: /tmp/signatureFile2292464475685409738.jar
Problems downloading artifact: osgi.bundle,org.jetbrains.kotlin.osgi-bundle,1.6.21.
Error reading signed content:/tmp/signatureFile2733007966741328764.jar
An error occurred while processing the signatures for the file: /tmp/signatureFile2733007966741328764.jar
Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.cdt,7.9.0.66038.
Error reading signed content:/tmp/signatureFile13420547606982875001.jar
An error occurred while processing the signatures for the file: /tmp/signatureFile13420547606982875001.jar
Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.core,7.9.0.66038.
Error reading signed content:/tmp/signatureFile6323466438885058579.jar
An error occurred while processing the signatures for the file: /tmp/signatureFile6323466438885058579.jar
Problems downloading artifact: org.eclipse.update.feature,org.sonarlint.eclipse.feature,7.9.0.66038.
Error reading signed content:/tmp/signatureFile3595635860834535674.jar
An error occurred while processing the signatures for the file: /tmp/signatureFile3595635860834535674.jar
Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.jdt,7.9.0.66038.
Error reading signed content:/tmp/signatureFile2186646723593159042.jar
An error occurred while processing the signatures for the file: /tmp/signatureFile2186646723593159042.jar
Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.m2e,7.9.0.66038.
Error reading signed content:/tmp/signatureFile2643212512584881387.jar
An error occurred while processing the signatures for the file: /tmp/signatureFile2643212512584881387.jar
Problems downloading artifact: osgi.bundle,org.sonarlint.eclipse.ui,7.9.0.66038.
Error reading signed content:/tmp/signatureFile16415166959200238188.jar
An error occurred while processing the signatures for the file: /tmp/signatureFile16415166959200238188.jar
Problems downloading artifact: osgi.bundle,org.sonarsource.sonarlint.core.sonarlint-core-osgi,8.14.0.63103.
Error reading signed content:/tmp/signatureFile15013404704064224181.jar
An error occurred while processing the signatures for the file: /tmp/signatureFile15013404704064224181.jar

Adding Sonarlint Software Site using "Help --> Install New Software..." and try to install from https://eclipse-uc.sonarlint.org fails:

ERROR: org.eclipse.equinox.p2.metadata.repository code=1000 No repository found at https://eclipse-uc.sonarlint.org.
  at org.eclipse.equinox.internal.p2.repository.helpers.AbstractRepositoryManager.fail(AbstractRepositoryManager.java:405)

Switching to https://binaries.sonarsource.com/SonarLint-for-Eclipse/releases/7.5.0.5… works, but is not the official update site...

Hello,

In a previous review it is mentioned that plugins can be donwloaded for off-line installations. The site is: binaries.sonarsource.com/SonarLint-for-Eclipse/releases/

However, it does not seem to work at the moment. Is the site changed or in maintenance? 

Where else can I download the Eclipse plugins?

Thanks in advance!

Henk

Cannot complete the install because one or more required items could not be found.
  Software being installed: SonarLint for Eclipse 7.1.0.39158 (org.sonarlint.eclipse.feature.feature.group 7.1.0.39158)
  Missing requirement: SonarLint for Eclipse Core 7.1.0.39158 (org.sonarlint.eclipse.core 7.1.0.39158) requires 'bundle org.eclipse.core.runtime 3.14.0' but it could not be found
  Cannot satisfy dependency:
    From: SonarLint for Eclipse 7.1.0.39158 (org.sonarlint.eclipse.feature.feature.group 7.1.0.39158)
    To: org.sonarlint.eclipse.core [7.1.0.39158]

Hi

I´m trying instal Sonar Lint by Marketplace in CodeReady Studio Version: 12.19.1.GA but I can't. The error is:


An error occurred while uninstalling
session context was:(profile=devstudio, phase=org.eclipse.equinox.internal.p2.engine.phases.Uninstall, operand=[R]com.google.protobuf 2.4.0.v201105131100 --> null, action=org.eclipse.equinox.internal.p2.touchpoint.eclipse.actions.UninstallBundleAction).
Could not acquire the framework manipulator service.
Could not acquire the framework manipulator service.

Any suggestions?

 

In reply to by daniel guimaraes

Hello Daniel,

I don't understand why the message mentions 'uninstalling'. Are you using Windows ? I found a bug report that lists some causes here (https://bugs.eclipse.org/bugs/show_bug.cgi?id=517181)

May I ask you to report this issue on our community forum (https://community.sonarsource.com/c/help/sl/11) ? It will get better visibility and we could better help you.

Thanks

Error during execution of SonarLint analysis
java.lang.IllegalStateException: Unable to load component class org.sonarsource.sonarlint.core.analyzer.sensor.SensorsExecutor
    at org.sonarsource.sonarlint.core.container.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:60)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:678)
    at org.sonarsource.sonarlint.core.container.ComponentContainer.getComponentByType(ComponentContainer.java:251)
    at org.sonarsource.sonarlint.core.container.analysis.AnalysisContainer.doAfterStart(AnalysisContainer.java:133)
    at org.sonarsource.sonarlint.core.container.ComponentContainer.startComponents(ComponentContainer.java:126)
    at org.sonarsource.sonarlint.core.container.ComponentContainer.execute(ComponentContainer.java:111)
    ...
Caused by: java.lang.IllegalStateException: Unable to load component class org.sonar.plugins.javascript.JavaScriptSensor
    at org.sonarsource.sonarlint.core.container.ComponentContainer$ExtendedDefaultPicoContainer.getComponent(ComponentContainer.java:60)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.DefaultPicoContainer.getComponent(DefaultPicoContainer.java:632)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.parameters.BasicComponentParameter$1.resolveInstance(BasicComponentParameter.java:118)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.parameters.ComponentParameter$1.resolveInstance(ComponentParameter.java:136)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.injectors.SingleMemberInjector.getParameter(SingleMemberInjector.java:78)
    at org.sonarsource.sonarlint.shaded.org.picocontainer.injectors.ConstructorInjector$CtorAndAdapters.getParameterArguments(ConstructorInjector.java:309)
    ...
Caused by: java.lang.ExceptionInInitializerError
    at com.sonar.sslr.api.typed.ActionParser.<init>(ActionParser.java:59)
    at org.sonar.javascript.parser.JavaScriptParser.<init>(JavaScriptParser.java:33)
    at org.sonar.javascript.parser.JavaScriptParserBuilder.createParser(JavaScriptParserBuilder.java:31)
    at org.sonar.plugins.javascript.JavaScriptSensor.<init>(JavaScriptSensor.java:115)
    at org.sonar.plugins.javascript.JavaScriptSensor.<init>(JavaScriptSensor.java:85)
    at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    ...
Caused by: net.sf.cglib.core.CodeGenerationException: java.lang.reflect.InaccessibleObjectException-->Unable to make protected final java.lang.Class java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain) throws java.lang.ClassFormatError accessible: module java.base does not "opens java.lang" to unnamed module @1ebfd535
    at net.sf.cglib.core.ReflectUtils.defineClass(ReflectUtils.java:464)
    at net.sf.cglib.core.AbstractClassGenerator.generate(AbstractClassGenerator.java:336)
    at net.sf.cglib.core.AbstractClassGenerator$ClassLoaderData$3.apply(AbstractClassGenerator.java:93)
    at net.sf.cglib.core.AbstractClassGenerator$ClassLoaderData$3.apply(AbstractClassGenerator.java:91)
    at net.sf.cglib.core.internal.LoadingCache$2.call(LoadingCache.java:54)
    at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
    ...
Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make protected final java.lang.Class java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int,java.security.ProtectionDomain) throws java.lang.ClassFormatError accessible: module java.base does not "opens java.lang" to unnamed module @1ebfd535
    at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:357)
    at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
    at java.base/java.lang.reflect.Method.checkCanSetAccessible(Method.java:199)
    at java.base/java.lang.reflect.Method.setAccessible(Method.java:193)
    at net.sf.cglib.core.ReflectUtils$1.run(ReflectUtils.java:61)
    at java.base/java.security.AccessController.doPrivileged(AccessController.java:554)
    ...

Error The following solutions are not available: SonarLint 6.2 (id=org.sonarlint.eclipse.feature.feature.group, site=(https://(eclipse-uc.sonarlint.org) Unable to connect to (https://)repository binaries.sonarsource.com/SonarLint-for-Eclipse/releases/6.2.0.37299/content.xml

Getting following error while installing SonarLint version 5.9 on eclipse version 2020-06 (4.16.0) from the marketplace

 

Cannot complete the install because some dependencies are not satisfiable
  Software being installed: a.jre.javase 16.0.0
  Software currently installed: BOSH Language Server Feature 4.9.0.202012131915 (org.springframework.tooling.bosh.ls.feature.feature.group 4.9.0.202012131915)
  Cannot satisfy dependency:
    From: Language Server Protocol client for Eclipse IDE (Incubation) 0.13.4.202011121435 (org.eclipse.lsp4e 0.13.4.202011121435)
    To: osgi.ee; (&(osgi.ee=JavaSE)(version=11))
  Cannot satisfy dependency:
    From: BOSH Language Server Feature 4.9.0.202012131915 (org.springframework.tooling.bosh.ls.feature.feature.group 4.9.0.202012131915)
    To: org.eclipse.equinox.p2.iu; org.eclipse.lsp4e 0.0.0

In reply to by Kiran Jawale

Hello Kiran,

Thanks for using SonarLint for Eclipse and reporting this. I don't see any reference to SonarLint in the error message that you posted, could you double check installing SonarLint really is the cause of the issue ? If you had the 'Contact all update sites during install to find required software' option activated, could you try to unselect it ?

If you still face the issue, I invite you to post a new thread on https://community.sonarsource.com/c/help/sl/11 so we can better help you. It could also benefit other users having the same issue.

Thanks

Getting following error:

Unable to read repository at https:\/\/eclipse-uc.sonarlint.org/content.xml.
PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

In reply to by Filip K

I, too get:

Unable to read repository at (https) eclipse-uc.sonarlint.org/content.xml.
PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

Can hit other websites from eclipse and external browner, but both (https) eclipse-uc.sonarlint.org/content.xml and (http) eclipse-uc.sonarlint.org are not found. Not Found doesn't appear to be a java keystore issue, as some of the help links suggest. Is something else wrong? Is there a way to simply download the plugin rather than install it from marketplace?

Thanks!

In reply to by Julien HENRY

<p>Hey Julien, can you check again please? We are having troubles again with the following error:<br />
Unable to read repository at &lt;url&gt;<br />
PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target</p>

Also having the same issue with regards to lombok. 

Using Eclipse Neon Release (4.6.0), SonarLint 5.1, Lombok 1.18.12.

Error:
When opening a Java file in Eclipse that uses Lombok annotations an exception is shown in the IDE: 
An internal error occurred during: “SonarLint processing file /…java”.
lombok/launch/PatchFixesHider$Transform

Other related posts/forums suggest updating Lombok to 1.18.12 which did not resolve the issue for me.

 

 

We use Lombok (https://projectlombok.org/) to reduce boilerplate in our Java code. Lombok also runs as an agent to show the generated boilerplate code in the IDE. That seems to be a problem for SonarLint as it produces these messages:

An internal error occurred during: "SonarLint processing file /platform-api/src/test/java/com/elavon/eliminator/platform/authentication/LdapAuthenticationServiceTest.java".
lombok/launch/PatchFixesHider$Transform

I had to uninstall the SonarLint plugin because of that.

In reply to by Felix L J Mayer

Hello, thank you for your feedback.

There were a few reports on our community forum about problems due to interaction with Lombok - see e.g https://community.sonarsource.com/t/sonarlint-eclipse-plugin-eclipse-wi…

Could you please update to the lastest versions of both SonarLint and Lombok? In case of any issue, please report them on the aforementioned forum so that we can track them.

Hi, I am getting below issue during SonarLint installation in Eclipse Photon. Though it was working fine in Oxygen and Neon. Unable to read repository at https:eclipse-uc.sonarlint.org compositeContent.xml sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target Can anyone help me?