customerio / customerio-flutter

Flutter plugin for Customer.io
https://www.customer.io/docs/sdk/flutter/getting-started/
MIT License
12 stars 10 forks source link

Build failed : invalid source release: 17 (JVM) #124

Closed MickaelHrndz closed 1 month ago

MickaelHrndz commented 1 month ago

I'm encountering this error when trying to build my app after upgrading Flutter:

FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':customer_io:compileReleaseJavaWithJavac'.
> error: invalid source release: 17

I suspect that it is caused by targeted jvm version specified in the build.gradle: https://github.com/customerio/customerio-flutter/blob/e6862c9a6b145d7264cfea95e7977c6f805eff52/android/build.gradle#L38

Ahmed-Ali commented 1 month ago

JVM 17 is requirement for Gradle 8. Does the answer here helps?

MickaelHrndz commented 1 month ago

Ok my bad, I recently upgraded the whole project, and the build was successful locally but not on the CI pipeline. Turns out there's a pipeline action to set the Java version. I did and it solves the issue. I should've digged a little further before opening the issue, sorry for the inconvenience.