I was trying to build a project with the Ubuntu-packaged gradle v4.4.1-10, then after the following error popped up.
FAILURE: Build failed with an exception.
* What went wrong:
Could not determine java version from '11.0.2'.
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
* Get more help at https://help.gradle.org
Thereafter, when when gradle to v7.4.2, the problem still persisted, but after deleting & re-recloning the same repository, it worked.
I’ve thought it was kind of cache problem, but no ./gradle/cache
directories within the project’s directory.
I was curious to understand the root cause behind this! Is there some kind of metadata that gets saved somewhere at some file at the first invocation of gradle within the project’s directory?
Thanks!