[AGP 9] Migrate Remaining Plugin Example Apps to Built-in Kotlin#11806
Conversation
There was a problem hiding this comment.
Code Review
This pull request updates multiple example Android applications and validation tests to upgrade Gradle to 9.1.0, the Android Gradle Plugin to 9.0.1, and Kotlin to 2.3.20. It removes the kotlin-android plugin and migrates kotlinOptions to the new kotlin compiler options block targeting JVM 17. Feedback across several files indicates that setting android.builtInKotlin and android.newDsl to false in gradle.properties will cause build failures since the kotlin-android plugin was removed. These flags should be updated to true to enable built-in Kotlin support.
| # This builtInKotlin flag was added automatically by Flutter migrator | ||
| android.builtInKotlin=false | ||
| # This newDsl flag was added automatically by Flutter migrator | ||
| android.newDsl=false |
There was a problem hiding this comment.
Since the goal of this pull request is to migrate the example apps to built-in Kotlin and the new DSL, these flags should be set to true. Setting them to false disables the built-in Kotlin support.
Furthermore, because kotlin-android was removed from build.gradle.kts, having android.builtInKotlin=false will cause Gradle to fail with an error like Extension with name 'kotlin' does not exist because the Kotlin plugin is never applied.
Please update this flag to true across all gradle.properties files in this PR.
# This builtInKotlin flag was added automatically by Flutter migrator
android.builtInKotlin=true
# This newDsl flag was added automatically by Flutter migrator
android.newDsl=true
| # This builtInKotlin flag was added automatically by Flutter migrator | ||
| android.builtInKotlin=false | ||
| # This newDsl flag was added automatically by Flutter migrator | ||
| android.newDsl=false |
There was a problem hiding this comment.
Since the goal of this pull request is to migrate the example apps to built-in Kotlin and the new DSL, these flags should be set to true. Setting them to false disables the built-in Kotlin support.
Furthermore, because kotlin-android was removed from build.gradle.kts, having android.builtInKotlin=false will cause Gradle to fail with an error like Extension with name 'kotlin' does not exist because the Kotlin plugin is never applied.
Please update this flag to true across all gradle.properties files in this PR.
# This builtInKotlin flag was added automatically by Flutter migrator
android.builtInKotlin=true
# This newDsl flag was added automatically by Flutter migrator
android.newDsl=true
|
@stuartmorgan-g I noticed there aren't really any existing validators for configurations like |
I'm pretty sure I just missed adding some validation when I was doing the Kotlin gradle migrations. As I'm sure you're well aware by now, keeping track of which things are in which variants and which ones have been validated is... nontrivial :) |
|
This pull request is not mergeable in its current state, likely because of a merge conflict. Pre-submit CI jobs were not triggered. Pushing a new commit to this branch that resolves the issue will result in pre-submit jobs being scheduled. |
@stuartmorgan-g Ah, gotcha. I added the same validations to the example app |
…r#187739) flutter/packages@13b49f4...bd297cf 2026-06-09 jessiewong401@gmail.com [AGP 9] Migrate Remaining Plugin Example Apps to Built-in Kotlin (flutter/packages#11806) 2026-06-09 stuartmorgan@google.com [tool] Check for any Flutter SDK dependency (flutter/packages#11875) 2026-06-09 22373191+Hari-07@users.noreply.github.com [google_maps_flutter_ios_sdk9] Fix title in google maps sdk9 readme (flutter/packages#11826) 2026-06-08 jmccandless@google.com [Decoupling] Repo-wide changes (flutter/packages#11874) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC flutter-ecosystem@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
…tter#11806) Migrate remaining example apps to built-in kotlin. Refactored validation checks for kotlin configs and added unit tests for example apps. Now both plugin modules and plugin example apps have checks for kotlin configs (includes built-in kotlin configs). Fixes flutter/flutter#187325 ## Pre-Review Checklist **Note**: The Flutter team is currently trialing the use of [Gemini Code Assist for GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code). Comments from the `gemini-code-assist` bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed. [^1]: Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling.
…r#187739) flutter/packages@13b49f4...bd297cf 2026-06-09 jessiewong401@gmail.com [AGP 9] Migrate Remaining Plugin Example Apps to Built-in Kotlin (flutter/packages#11806) 2026-06-09 stuartmorgan@google.com [tool] Check for any Flutter SDK dependency (flutter/packages#11875) 2026-06-09 22373191+Hari-07@users.noreply.github.com [google_maps_flutter_ios_sdk9] Fix title in google maps sdk9 readme (flutter/packages#11826) 2026-06-08 jmccandless@google.com [Decoupling] Repo-wide changes (flutter/packages#11874) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC flutter-ecosystem@google.com on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Migrate remaining example apps to built-in kotlin. Refactored validation checks for kotlin configs and added unit tests for example apps. Now both plugin modules and plugin example apps have checks for kotlin configs (includes built-in kotlin configs).
Fixes flutter/flutter#187325
Pre-Review Checklist
[shared_preferences]///).If you need help, consider asking for advice on the #hackers-new channel on Discord.
Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the
gemini-code-assistbot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.Footnotes
Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling. ↩ ↩2