Incompatible version of Kotlin error after upgrading to 4.9.2
harshpatel63 opened this issue · 3 comments
Describe the bug
I was upgrading the library for my project from 4.7.0 to 4.9.2 due to the latest changes to Android 14.
After upgrading, the build failed and gave me this error.
Module was compiled with an incompatible version of Kotlin. The binary version of its metadata is 1.8.0, expected version is 1.6.0.
OS and Lib versions (please complete the following information):
- Android Upload Service version: 4.9.2
- Android version and API version: Android 14
- HTTP stack: Okhttp
Other info:
I am aware that I need to upgrade a few dependencies of my project, but not sure what to upgrade. Are there any requirements around the Kotlin version, AGP, or Gradle versions for this library?
Hi! It should be sufficient to bump your Kotlin dependency. As a best practice, always keep AGP and Gradle to latest available versions in your projects.
Thanks for the quick reply!
Have tried bumping them up, but ran into tons of errors. No worries, will try to upgrade them once again with the newer Android Studio.
Upgrading to new Kotlin versions would also require other libraries to support the same version. In my case, upgrading epoxy by Airbnb fixed the issue.
This might help someone.