Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The detected jdk version is not compatible with current gradle version #197

Open
yuyully opened this issue Nov 13, 2024 · 4 comments
Open

Comments

@yuyully
Copy link

yuyully commented Nov 13, 2024

Gradle for java: v3.17.0

The detected jdk version is not compatible with current gradle version

Repro steps:

  1. Make sure there is JDK 21/16 in your local machine and JAVA_HOME is not JDK 21/16.
  2. Don't set gradle import java version in vscode settings

Clone and open https://github.com/apache/lucene.git : The detected jdk is 17 but actually 21 is required.
Image

Clone and open https://github.com/SpongePowered/Mixin.git : The detected jdk is 16 but actually it reports an error with jdk 17. (java home=17)
Image

@jdneo
Copy link
Member

jdneo commented Nov 13, 2024

@Tanish-Ranjan Would you like to take this one?

@Tanish-Ranjan
Copy link
Contributor

@jdneo Sure I will look into it.

@yuyully
Copy link
Author

yuyully commented Nov 13, 2024

No idea which jdk version is used for gradle project if there is no this notification message.

Set local JAVA_HOME=1.8, open https://github.com/py4j/py4j/tree/master/py4j-java, there is no such notification and gradle java home is shown as 17. I don't know which jdk version is used for this project. It would be better to print related information in the log.
Image

@yuyully
Copy link
Author

yuyully commented Nov 14, 2024

project: https://github.com/RoaringBitmap/RoaringBitmap.git

Local java home = 17, gradle wrapper of this project is 6.9.4 which is not supported with jdk 17, it doesn't get a compatible jdk version and reports an error as below.

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants