Code completion in Java Language Server is not working
See original GitHub issueWhen I open my java project the language server is loaded correctly but when I start editing code completion does not work. Cleaning the Java Language Server workspace does not help. The following exception is raised by the language server.
!ENTRY org.eclipse.jdt.ls.core 4 2 2021-04-16 13:57:00.647
!MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.jdt.ls.core".
!STACK 0
java.lang.NoSuchMethodError: 'org.eclipse.lsp4j.TextEdit org.eclipse.lsp4j.CompletionItem.getTextEdit()'
at com.microsoft.jdtls.intellicode.core.vscode.VSCodeCompletionItem.<init>(VSCodeCompletionItem.java:76)
at com.microsoft.jdtls.intellicode.core.CommandHandler.lambda$0(CommandHandler.java:64)
at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195)
at java.base/java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1654)
at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484)
at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474)
at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:913)
at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:578)
at com.microsoft.jdtls.intellicode.core.CommandHandler.executeCommand(CommandHandler.java:64)
Environment
- Operating System:
Ubuntu 20.04.2 LTS - JDK version:
openjdk 11.0.7 2020-04-14 - Visual Studio Code version:
VSCodium 1.55.2 - Java extension version:
v0.77.0
Steps To Reproduce
- Open a java project in VSCodium
- Start editing a java file.
Full language server logs: https://gist.github.com/zguesmi/619d2871dc4ff27e1203b888a8592e06
Current Result
The code completion does not work.
Expected Result
The code completion should be working.
Additional Informations
Issue Analytics
- State:
- Created 2 years ago
- Comments:9 (1 by maintainers)
Top Results From Across the Web
VSCode not suggesting and autocompleting java code
Open VScode and go to Preferences -> Settings; Search java.configuration.runtimes; Select Edit in settings.json and paste the follwing: "java.
Read more >Code-completion not working with Language Support for Java ...
VScode fails to show code-completion on fields. This happens if Language Support for Java and Visual Studio IntelliCode - Preview are installed ...
Read more >IntelliSense in Visual Studio Code
VS Code IntelliSense offers different types of completions, including language server suggestions, snippets, and simple word based textual completions.
Read more >Java on Visual Studio Code Update – March 2022
Regarding the code completion, one of the top issues is that when writing a constructor in VS Code, developers expect that the suggestion...
Read more >Language Server
Language Maintainer Repository
Ada AdaCore github.com/AdaCore/ada_language_server
ANTLR Ken Domino github.com/kaby76/AntlrVSIX
Apache Camel Camel Tooling github.com/camel‑tooling/camel‑language‑server
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

yes, since it’s fixed, we could close it.
@testforstephen should we close this?