I added kotlin to an exhausting Java project. Everything compiled and works until adding kapt for annotation processing. Now, I am getting
java.lang.IllegalStateException: failed to analyze: org.jetbrains.kotlin.kapt3.diagnostic.KaptError: Error while annotation processing
and a bunch of the warnings dispalyed are
e: @Retention(RetentionPolicy.SOURCE)
e: ^
e: symbol: class Retention
e: location: class RegistryDef
and
e: @StringDef({ASCENDING_ORDER, DESCENDING_ORDER, SortOrder.UNKNOWN})
e: ^
e: symbol: class StringDef
e: location: class RegistryDef
I added the support annotations explicitly to the project just to ensure they are included and use Gradle to force all versions to the latest.
Has anyone experienced this and how did you solve it?