flutter/packages/flutter_tools/lib
Reid Baker f20bc39cc0
Add kotlin compatability to build file validation (#167143)
Fixes https://github.com/flutter/flutter/issues/161443 

* adds a new gradle task like `javaVersion` named `kgpVersion` that
prints the version of kgp.
* adds gradle_utils.dart method for getting kgp version
* * kgp method is moved to utilities and we attempt to use a plugin
method before reflection.
* adds methods or  evaluating KGP + gradle and KGP + AGP compatibility. 
* * It turns out that we have been using incompatible versions that
happen to work with the subset of kotlin we are using.
* Uses new kgp methods in flutter analyze --suggestions as part of the
existing agp/java/gradle compatibility matrix.
* adds new tests for all new functionality
* Adds comments to sections of the code I found could use them. 
* Modifies flutter gallery to use a compatible version of kotlin and
update its lockfiles.


## Pre-launch Checklist

- [x] I read the [Contributor Guide] and followed the process outlined
there for submitting PRs.
- [x] I read the [Tree Hygiene] wiki page, which explains my
responsibilities.
- [x] I read and followed the [Flutter Style Guide], including [Features
we expect every widget to implement].
- [x] I signed the [CLA].
- [x] I listed at least one issue that this PR fixes in the description
above.
- [x] I updated/added relevant documentation (doc comments with `///`).
- [X] I added new tests to check the change I am making, or this PR is
[test-exempt].
- [x] I followed the [breaking change policy] and added [Data Driven
Fixes] where supported.
- [x] All existing and new tests are passing.
2025-04-18 16:32:08 +00:00
..
src Add kotlin compatability to build file validation (#167143) 2025-04-18 16:32:08 +00:00
executable.dart Reland "[ Widget Preview ] Add initial support for communications over the Dart Tooling Daemon (DTD) (#166698)" (#166877) 2025-04-11 14:55:29 +00:00
runner.dart Auto-format Framework (#160545) 2024-12-19 20:06:21 +00:00