* What went wrong:
Execution failed for task ':gradle:compileGroovy'.
> BUG! exception in phase 'semantic analysis' in source unit 'C:UsersACERAndroidStudioProjectsflutterpackagesflutter_toolsgradlesrcmaingroovyapp_pl
ugin_loader.groovy' Unsupported class file major version 65
* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 10s
1 actionable task: 1 executed
<-------------> 0% WAITING
> IDLE
2
Answers
yes , i can install java 17 with gradle version and its works if any one use flutter to find SHA key then is necessary that java compatible with gradle version
The error tells you, that you use Java 21 to run a Gradle version that is not compatible with running on Java 21.
Please have a look at https://docs.gradle.org/current/userguide/compatibility.html to find which version of Java is compatible with the version of Gradle you are using.