Skip to content

[Android] segment_analytics still applies Kotlin Gradle Plugin and triggers Flutter built-in Kotlin warning #204

@amrgetment

Description

@amrgetment

What happened

When segment_analytics is added to a Flutter app on Flutter 3.44.x, Flutter reports that this plugin still applies the Kotlin Gradle Plugin directly on Android.

Current warning:

WARNING: Your app uses the following plugins that apply Kotlin Gradle Plugin (KGP): segment_analytics
Future versions of Flutter will fail to build if your app uses plugins that apply KGP.

What I expected

The plugin should rely on Flutter/AGP built-in Kotlin support and stop applying KGP directly.

Steps to reproduce

  1. Create a Flutter app on Flutter 3.44.x.
  2. Add segment_analytics: ^1.1.11.
  3. Run flutter build apk or flutter run for Android.
  4. Observe the KGP warning mentioning segment_analytics.

Additional context

This warning is currently non-fatal, but Flutter indicates it will become a build error in a future release.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions