i have upgraded flutter to the newest version but getting this error now.
`* What went wrong:
Execution failed for task ‘:device_info_plus:compileDebugJavaWithJavac’.
error: invalid source release: 17
- 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 38s
Error: Gradle task assembleDebug failed with exit code 1
`
I have tried building clean and deleting .gradle folder, still not working
2
Answers
hi you need to check you jdk version from android/build.gradle file, you can set the sourceCompatibility and targetCompatibility to match your Java version
The problem was solved by updating Android Studio to the latest version