redhat-developer / redhat-developer/vscode-java
Runtime at `'/home/user/.sdkman/candidates/java/21.ea.28-open'` is not compatible with the `'JavaSE-21'` environment"
Open
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 2.3k
- Forks
- 546
- Avg merge
- 20h 1m
- Merged PRs (30d)
- 11
Description
Environment
- Operating System: WSL2 Fedora Rawhide
- JDK version:
21.ea.28-open - Visual Studio Code version:
Version: 1.80.0-insider (user setup)
Commit: c1bca6d7cc2c5f71ae04deda90c0cf50819ffde4
Date: 2023-06-29T07:44:44.659Z
Electron: 22.3.14
ElectronBuildId: 21893604
Chromium: 108.0.5359.215
Node.js: 16.17.1
V8: 10.8.168.25-electron.0
OS: Windows_NT x64 10.0.22631
- Java extension version:
v1.21.2023063004 Pre-Release
Steps To Reproduce
Configure .vscode/settings.json like below:
{
"java.jdt.ls.java.home": "/home/user/.sdkman/candidates/java/21.ea.28-open",
"java.configuration.runtimes": [
{
"name": "JavaSE-21",
"path": "/home/user/.sdkman/candidates/java/21.ea.28-open",
"default": true
}
]
}
Current Result
[Error - 5:09:27 PM] Jun 30, 2023, 5:09:27 PM Runtime at '/home/user/.sdkman/candidates/java/21.ea.28-open' is not compatible with the 'JavaSE-21' environment
[Trace - 5:09:27 PM] Received notification 'telemetry/event'.
Params: {
"name": "java.ls.error",
"properties": {
"message": "Runtime at '/home/user/.sdkman/candidates/java/21.ea.28-open' is not compatible with the 'JavaSE-21' environment"
}
}
Expected Result
It works
Additional Informations
Setting name to JavaSE-20 makes it work
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the configuration in .vscode/settings.json on WSL2 Fedora Rawhide with the listed JDK and Java extension versions. Compare the JavaSE-21 configuration with the reported working JavaSE-20 setting, then verify that JavaSE-21 is accepted without the compatibility error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, typescript, vscode
- Domain
- developer-experience, devtools
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100