Inconsistent JVM-target compatibility detected for tasks 'compileJava' (23) and 'compileKotlin' (20)

I also faced the same issue recently and I fixed it by changing the kotlin jvm version to 2.1.0 in build.gradle.kts

2 Likes