Couldn't start client Language Support for Java (Syntax Server)
See original GitHub issueI have just freshly installed VS Code 1.48.1 and installed the extension “Language support for Java by Red Hat” (https://marketplace.visualstudio.com/items?itemName=redhat.java). But if I now open a Java directory, it shows two error messages: Couldn't start client Language Support for Java (Syntax Server)
and Couldn't start client Language Support for Java
.
Next to that the cpu usage also jumps to 100% and the spinning circle in the bottom right does not stop spinning. If I open the developer tools, I get about 1000 errors/second which all look like this:
[[object Object]]Internal error.
Error: Internal error.
at c:\Users\my_computer\.vscode\extensions\redhat.java-0.65.0\dist\extension.js:1:76457
at c:\Users\my_computer\.vscode\extensions\redhat.java-0.65.0\dist\extension.js:1:76751
at Immediate.<anonymous> (c:\Users\my_computer\.vscode\extensions\redhat.java-0.65.0\dist\extension.js:1:77112)
at processImmediate (internal/timers.js:439:21)
as well as a warning for each error:
rejected promise not handled within 1 second: Error: Internal error.
stack trace: Error: Internal error.
at c:\Users\my_computer\.vscode\extensions\redhat.java-0.65.0\dist\extension.js:1:76457
at c:\Users\my_computer\.vscode\extensions\redhat.java-0.65.0\dist\extension.js:1:76751
at Immediate.<anonymous> (c:\Users\my_computer\.vscode\extensions\redhat.java-0.65.0\dist\extension.js:1:77112)
at processImmediate (internal/timers.js:439:21)
What I have tried to fix it:
- Checked the JAVA_HOME of both the WSL 2 system I am using as well as the windows environmental variable (what was suggested in many other issues with the same. But I think they are correct:
C:\Users\my_computer>echo %JAVA_HOME% C:\Program Files\Java\jdk-14.0.2
I have also added “java.home” with the same location to the preferences, but that didn’t fix it either. - Clean install of VS Code and the extension
- Run VS Code as administrator
Environment
- Operating System: Windows 10
- JDK version:
openjdk version "14.0.2" 2020-07-14, OpenJDK Runtime Environment (build 14.0.2+12-46), OpenJDK 64-Bit Server VM (build 14.0.2+12-46, mixed mode, sharing)
(from https://jdk.java.net/14/) - Visual Studio Code version: 1.48.1
- Java extension version: 0.65.0
Steps To Reproduce
- Install newest version of VS Code
- Install Java Red Hat Extension
- Open a Java Project with VS Code
Current Result
See above
Expected Result
No errors
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:9
Top Results From Across the Web
visual studio code - couldn't start client language support for java
1 Answer 1 · Went to the installed extension (Command Pallette, Extensions: Installed Extensions) · found "Language suppoort for Java(TM) by Red ...
Read more >Does anyone know how to fix this? I have all the ... - Reddit
I have all the necessary extensions installed, still can't run Java. r/vscode - O Couldn't start client Java Language Server Source: Java.
Read more >Language Support for Java(TM) by Red Hat
Provides Java ™ language support via Eclipse ™ JDT Language Server, which utilizes ... The tooling JDK will be used to launch the...
Read more >VSCode Java: The One With Java 17 support - YouTube
This demo provides a run -through of how to get started with Java 17 using Language Support for Java by Red Hat. The...
Read more >Windows 10 Couldn't start client Java Language Server even ...
When I open a java project in VSCode and click on a .java file, I get the error - "Couldn't start client Java...
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
Based on conversations in https://github.com/redhat-developer/vscode-java/issues/785, I had this same error when opening a project that was in WSL 2 (\\wsl$). Moving the project to some directory in windows (C:\) solved my issue.
I was able to get my project working while leaving it in WSL by using Remote development in WSL (https://code.visualstudio.com/docs/remote/wsl-tutorial)
Make sure you have opened a WSL window in VSCode:
I was having the same problem time and again, until I somehow remembered I needed to open a WSL window. It lets VSCode take control in a different environment. I started to have this issue because one day I closed every VSCode window I had, and when I opened a new one the next day it started in a Windows 10 window by default which, by the way, works but has a collision with the “Language Support for Java” extension when it comes to Java projects.