Skip to content

android_hardware_smoke_test failing in CI due to AGP migration #189083

Description

@andywolff

A recent PR #189024 migrated most Flutter test apps to these new templates, but missed dev/integration_tests/android_hardware_smoke_test/android/app/build.gradle.kts. Under AGP 9.1.0, the legacy configurations (id("kotlin-android") and kotlinOptions { jvmTarget = "17" }) are compilation errors.

https://logs.chromium.org/logs/flutter/buildbucket/cr-buildbucket/8676911887534353377/+/u/run_test.dart_for_android_hardware_smoke_opengles_tests_shard_and_subshard_None/stdout

FAILURE: Build failed with an exception.

* Where:
Build file '/b/s/w/ir/x/w/flutter/dev/integration_tests/android_hardware_smoke_test/android/app/build.gradle.kts' line: 12

* What went wrong:
Script compilation errors:

  Line 12: android {
           ^ 'fun Project.android(configure: Action<BaseAppModuleExtension>): Unit' is deprecated. Replaced by com.android.build.api.dsl.ApplicationExtension.
               This class is not used for the public extensions in AGP when android.newDsl=true, which is the default in AGP 9.0, and will be removed in AGP 10.0.

  Line 22:     kotlinOptions {
               ^ 'fun BaseAppModuleExtension.kotlinOptions(configure: Action<DeprecatedKotlinJvmOptions>): Unit' is deprecated. Please migrate to the compilerOptions DSL. More details are here: https://kotl.in/u1r8ln.

  Line 23:         jvmTarget = "17"
                   ^ 'var jvmTarget: String' is deprecated. Please migrate to the compilerOptions DSL. More details are here: https://kotl.in/u1r8ln.

Activity

  1. andywolff commented on Jul 7, 2026

    @andywolff
    ContributorAuthor

    Fixed

  2. github-actions commented on Jul 21, 2026

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  3. locked as resolved and limited conversation to collaborators on Jul 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions