Skip to content

Intercom flutter 9.6.0 - 9.6.15 kotlin metadata mismatch #642

Description

@joshkoma

I get this on my log when I run intercom flutter from SDK 18.0.0 onwards
e: file:///C:/Users/Josh/AppData/Local/Pub/Cache/hosted/pub.dev/intercom_flutter-9.6.16/android/src/main/kotlin/io/maido/intercom/IntercomFlutterPlugin.kt:316:46 Class 'io.intercom.android.sdk.ui.theme.ThemeMode' was compiled with an incompatible version of Kotlin. The binary version of its metadata is 2.0.0, expected version is 1.8.0.
The class is loaded from C:/Users/Josh/.gradle/caches/8.14.4/transforms/f15815914addc2940bfbf246c2203807/transformed/jetified-intercom-sdk-ui-18.4.0-api.jar!/io/intercom/android/sdk/ui/theme/ThemeMode.class
e: file:///C:/Users/Josh/AppData/Local/Pub/Cache/hosted/pub.dev/intercom_flutter-9.6.16/android/src/main/kotlin/io/maido/intercom/IntercomFlutterPlugin.kt:316:56 Class 'io.intercom.android.sdk.ui.theme.ThemeMode' was compiled with an incompatible version of Kotlin. The binary version of its metadata is 2.0.0, expected version is 1.8.0.

I have tried running the app alone and it complies, but when I add dependencies to my pubspec suddenly the build fails. It seems there are transitive dependencies that pull 1.8 metadata, but then again when I run the app without intercom it builds properly. This is a problem from the 18.0.0 SDK onwards, because 17.4.7 and below works well. Has anyone else experienced this? Changing the gradle wrapper, kotlin or AGP versions does nothing. I have tried all versions from Gradle 8.9 up to 9.5.6 and the error is the same

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions