- 14 Jul, 2023 1 commit
-
-
gmackall authored
This migrator will upgrade the minSdkVersion used in the [module-level build.gradle](https://developer.android.com/build#module-level) file to flutter.minSdkVersion. The PR also makes a small refactor to `AndroidProject` to add a getter for the module level build.gradle file, and uses that getter in places where we were getting that file (previously it was being gotten directly via `hostAppGradleRoot.childDirectory('app').childFile('build.gradle')`. Part of the work for deprecating support for the Jelly Bean android apis.
-
- 21 Jun, 2023 1 commit
-
-
Christopher Fujino authored
Works around part of https://github.com/flutter/flutter/issues/128866
-
- 07 Jun, 2023 2 commits
-
-
chunhtai authored
fixes https://github.com/flutter/flutter/issues/120408 Added two gradle tasks, one for grabing the application id, one for grabbing app link domains. Added a new vmservices to call these two gradle tasks and return the result. The expected work flow is that the devtool will first call a vmservices to grab all avaliable build variants. It will then choose one of the build variant and call this new services to get application id and app link domains.
-
Andrew Kolos authored
Closes https://github.com/flutter/flutter/issues/106416. This PR adds a new `flutter config` setting named `jdk-dir`. When set, the tool will use the JDK found at this location for all Java-dependent tool operations such as building Android apps via gradle and running Android SDK tools.
-
- 01 Jun, 2023 2 commits
-
-
Andrew Kolos authored
Fixes #122081. When validating an Android Studio installation, add a warning validation message when we are unable to detect the version. This is because we have logic throughout the tool (JDK/JRE-searching) that is at higher risk of failing when we don't know the version.
-
Andrew Kolos authored
Fixes #124252, finishing work on the umbrella tracking issue, #126126. Essentially, after this PR, no (non-test) code should be be referencing/invoking the java home or binary paths.
-
- 26 May, 2023 1 commit
-
-
Phil Quitslund authored
The newly updated lint will soon flag for-each in collections. See discussion: https://github.com/dart-lang/linter/pull/4383 /cc @goderbauer
-
- 20 May, 2023 1 commit
-
-
Andrew Kolos authored
Relands #126086, which was reverted by #126569.
-
- 19 May, 2023 1 commit
-
-
Felix Angelov authored
Fixes the `findBundleFile` method in `gradle.dart` to correctly locate app bundles generated from multiple flavor dimensions. - closes https://github.com/flutter/flutter/issues/92316 - closes https://github.com/flutter/flutter/issues/65264
-
- 15 May, 2023 1 commit
-
-
Tomasz Gucio authored
-
- 11 May, 2023 2 commits
-
-
Andrew Kolos authored
Reverts flutter/flutter#126086. This PR changed the interfaces of some classes, namely `AndroidSdk`, and deleted a global. These classes had custom overrides in g3 that were not updated with a g3fix, so this PR has broken tests. See https://b.corp.google.com/issues/281945232 (non-public link)
-
Andrew Kolos authored
This is the first step in unifying Java-finding logic across the tool. If curious, see #126029 for an example of what all the changes will probably entail. Moves java-related functionality like `AndroidSdk.findJavaHome` to a new class, `Java`. See tracking issue https://github.com/flutter/flutter/issues/126126 for more.
-
- 05 May, 2023 1 commit
-
-
Kevin Moore authored
-
- 03 May, 2023 1 commit
-
-
gmackall authored
[Reland] Add migrator to upgrade gradle version when conflict with Android Studio bundled Java version is detected (#125836) This is an attempt to reland https://github.com/flutter/flutter/pull/124085. Differences from this attempt and the last: 1. Adds a check for null android studio versions and a test for this case. 2. Wraps the migrate code in a try-catch [per the suggestion here](https://github.com/flutter/flutter/pull/125728/files#r1181747899). Old PR description: This PR adds an android project migrator that checks the version of android studio and the version of gradle for conflicts, and upgrades to 7.4 if a conflict is detected. For more detail about the particular conflict, see https://github.com/flutter/flutter/issues/122376. The PR also upgrades older gradle versions being used in integration testing to 7.4. Fixes/related to: https://github.com/flutter/flutter/issues/122376 and https://github.com/flutter/flutter/issues/123636
-
- 01 May, 2023 2 commits
-
-
Andrew Kolos authored
[tools] Apply Android Studio version detection logic to explicitly configured installation directory (`flutter config --android-studio-dir`) (#125596) Fixes #121468 (when considered along with https://github.com/flutter/flutter/pull/125247). This applies the pre-existing Android Studio version detection logic to the install configured with `flutter config android-studio-dir`.
- 28 Apr, 2023 1 commit
-
-
Flutter GitHub Bot authored
This PR was generated by `flutter update-packages --force-upgrade`.
-
- 27 Apr, 2023 2 commits
-
-
gmackall authored
Add migrator to upgrade gradle version when conflict with Android Studio bundled Java version is detected (#124085) This PR adds an android project migrator that checks the version of android studio and the version of gradle for conflicts, and upgrades to 7.4 if a conflict is detected. For more detail about the particular conflict, see https://github.com/flutter/flutter/issues/122376. The PR also upgrades older gradle versions being used in integration testing to 7.4. Fixes/related to: https://github.com/flutter/flutter/issues/122376 and https://github.com/flutter/flutter/issues/123636
-
Dan Field authored
See https://docs.flutter.dev/reference/supported-platforms I don't expect this to break anything, but if it does we can revert and figure out what else needs to happen first. Without this change, engine changes upstream will get flagged in default flutter created apps.
-
- 21 Apr, 2023 2 commits
-
-
Christopher Fujino authored
Will fix transient network failures as in: https://github.com/flutter/flutter/issues/125108#issuecomment-1516519929
-
Andrew Kolos authored
When searching for the JDK bundled with an unrecognized version of Android Studio, assume the version to be the latest (#125247) Fixes #125246 by restoring the intended behavior of #101862. That is, when searching for a JDK and we encounter an Android Studio version we don't recognize, assume it to be the latest version `flutter` is aware of. Also does some light refactoring in the tests, like using test objects instead of referencing `globals`.
-
- 19 Apr, 2023 1 commit
-
-
Bartek Pacia authored
Refactor Flutter Gradle Plugin so it can be applied using the declarative `plugins {}` block (#123511) This PR aims to resolve #121552. Resources used: - [Developing Plugins](https://docs.gradle.org/current/userguide/custom_plugins.html) - [Using Gradle Plugins](https://docs.gradle.org/current/userguide/plugins.html#sec:plugins_block) - [Composite Builds Plugin Development Sample](https://docs.gradle.org/current/samples/sample_composite_builds_plugin_development.html) This PR also paves way for #121541, because apps will no longer have: ```groovy apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" ``` hardcoded. Instead, they'll use: ```groovy plugins { // ... id "dev.flutter.flutter-gradle-plugin" // the exact name is tentative } ```
-
- 18 Apr, 2023 1 commit
-
-
- 15 Apr, 2023 1 commit
-
-
Andrew Kolos authored
Fixes #124756 by removing the concept of `Version.unknown`. `Version` fields that needed the ability to represent an unknown version have been made nullable. Assigning `null` to them represents an unknown version.
-
- 14 Apr, 2023 1 commit
-
-
Kevin Moore authored
flutter-tool: enum cleanup
-
- 13 Apr, 2023 1 commit
-
-
Reid Baker authored
#123643 - Add task to projects evaluated by flutter.gradle that will print the java version. - Add integration test for the existence of javaVersion and the expected format. - Add gradle util to get the gradlew version for a specific platform (gradlew everywhere but windows). Why does this code need to exist? Figuring out what version of java is used by flutter/gradle is done in a few different ways that are not always aligned. See this issue https://github.com/flutter/flutter/issues/122609 , this issue https://github.com/flutter/flutter/issues/121501 this feature request https://github.com/flutter/flutter/issues/106416 As examples of why assuming the java version is dangerous. This task is code flutter can build upon and is the version gradle is using to build no matter how it is configured. ## 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] All existing and new tests are passing. --------- Co-authored-by:
Mitchell Goodwin <58190796+MitchellGoodwin@users.noreply.github.com> Co-authored-by:
Greg Spencer <gspencergoog@users.noreply.github.com> Co-authored-by:
Victoria Ashworth <vashworth@google.com> Co-authored-by:
Christopher Fujino <christopherfujino@gmail.com> Co-authored-by:
Jackson Gardner <jacksongardner@google.com> Co-authored-by:
Rydmike <m.rydstrom@gmail.com> Co-authored-by:
keyonghan <54558023+keyonghan@users.noreply.github.com> Co-authored-by:
chunhtai <47866232+chunhtai@users.noreply.github.com> Co-authored-by:
Taha Tesser <tessertaha@gmail.com> Co-authored-by:
Ben Konyi <bkonyi@google.com> Co-authored-by:
engine-flutter-autoroll <engine-flutter-autoroll@skia.org> Co-authored-by:
hellohuanlin <41930132+hellohuanlin@users.noreply.github.com> Co-authored-by:
Danny Tuppeny <danny@tuppeny.com> Co-authored-by:
Chris Bracken <chris@bracken.jp> Co-authored-by:
Kate Lovett <katelovett@google.com> Co-authored-by:
Michael Goderbauer <goderbauer@google.com> Co-authored-by:
Elias Yishak <42216813+eliasyishak@users.noreply.github.com> Co-authored-by:
Christopher Fujino <fujino@google.com>
-
- 12 Apr, 2023 1 commit
-
-
Camille Simon authored
Update re-thrown error for incompatible Java/Gradle versions to include migration guide
-
- 07 Apr, 2023 2 commits
-
-
Reid Baker authored
Update gradle_utils.dart and flutter.gradle to have the same versions as the documentation in file says is required. (#123213) This was an oversight from pr https://github.com/flutter/flutter/pull/116146/files. Comments in both files indicate that the versions should be bumped together. ## 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]. - [ ] I listed at least one issue that this PR fixes in the description above. - [ ] 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]. - [ ] All existing and new tests are passing. If you need help, consider asking for advice on the #hackers-new channel on [Discord].
-
Reid Baker authored
https://github.com/flutter/flutter/issues/123917 Missed feedback from https://github.com/flutter/flutter/pull/123916 - Handle commented out lines in gradle-wrapper.properties This is 1 of 2 prs to handle missed feedback. Formatting will be done in the second whereas this one captures a weakness missed in the last pr. ## 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] All existing and new tests are passing.
-
- 05 Apr, 2023 3 commits
-
-
Camille Simon authored
Catches and re-throws Gradle error indicating that the Gradle version is incompatible with the Java version that Flutter is using to tell users how to fix the issue. Related issue: https://github.com/flutter/flutter/issues/122376 ## 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]. - [ ] All existing and new tests are passing. <!-- Links --> [Contributor Guide]: https://github.com/flutter/flutter/wiki/Tree-hygiene#overview [Tree Hygiene]: https://github.com/flutter/flutter/wiki/Tree-hygiene [test-exempt]: https://github.com/flutter/flutter/wiki/Tree-hygiene#tests [Flutter Style Guide]: https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo [Features we expect every widget to implement]: https://github.com/flutter/flutter/wiki/Style-guide-for-Flutter-repo#features-we-expect-every-widget-to-implement [CLA]: https://cla.developers.google.com/ [flutter/tests]: https://github.com/flutter/tests [breaking change policy]: https://github.com/flutter/flutter/wiki/Tree-hygiene#handling-breaking-changes [Discord]: https://github.com/flutter/flutter/wiki/Chat --------- Co-authored-by:
Reid Baker <hamilton.reid.baker@gmail.com> Co-authored-by:
Christopher Fujino <fujino@google.com> Co-authored-by:
Christopher Fujino <christopherfujino@gmail.com>
-
Andrew Kolos authored
Normalize Java SDK (JDK) location logic across the tool
-
Reid Baker authored
https://github.com/flutter/flutter/issues/123917 Doc covering a broad set of issues related to android studio updating. https://docs.google.com/document/d/1hTXkjbUrBnXgu8NQsth1c3aEqo77rWoEj8CcsQ39wwQ/edit?pli=1# Specifically this pr: - Adds new functions to find a projects AGP, Gradle and java versions, and tests. - Adds new functions that take versions and parse if the versions are compatible with each other, and tests. - Adds validator for `flutter analyze --suggestions` that evaluates the java/gradle/agp versions and checks if they are compatible, and integration test. - Updates the version of gradle used by dev/integration_tests/flutter_gallery/ to the minimum supported by java 18 so that the integration tests pass (It is unknown why the java version is 18.9 instead of 11) - Moves `isWithinVersionRange` to version.dart, and tests. - Adds FakeAndroidStudio to fakes to be used in multiple tests but does not remove existing copies. Metrics will be included as part of the definition of done for this bug but not as part of this cl. It is already too big. Known work still left in this pr: * Understand why analyze integration tests are failing. Example output if Java and gradle are not compatible: ``` ┌───────────────────────────────────────────────────────────────────┐ │ General Info │ │ [✓] App Name: espresso_example │ │ [✓] Supported Platforms: android │ │ [✓] Is Flutter Package: yes │ │ [✓] Uses Material Design: yes │ │ [✓] Is Plugin: no │ │ [✗] Java/Gradle/Android Gradle Plugin: │ │ │ │ Incompatible Java/Gradle versions. │ │ │ │ Java Version: 17.0.6, Gradle Version: 7.0.2 │ │ │ │ See the link below for more information. │ │ https://docs.gradle.org/current/userguide/compatibility.html#java │ │ │ └───────────────────────────────────────────────────────────────────┘ ``` Example output if Gradle and AGP are not compatible ``` ┌─────────────────────────────────────────────────────────────────────────────┐ │ General Info │ │ [✓] App Name: espresso_example │ │ [✓] Supported Platforms: android │ │ [✓] Is Flutter Package: yes │ │ [✓] Uses Material Design: yes │ │ [✓] Is Plugin: no │ │ [✗] Java/Gradle/Android Gradle Plugin: Incompatible Gradle/AGP versions. │ │ │ │ Gradle Version: 7.0.2, AGP Version: 7.4.2 │ │ │ │ Update gradle to at least "7.5". │ │ See the link below for more information: │ │ https://developer.android.com/studio/releases/gradle-plugin#updating-gradle │ │ │ │ Incompatible Java/Gradle versions. │ │ │ │ Java Version: 17.0.6, Gradle Version: 7.0.2 │ │ │ │ See the link below for more information: │ │ https://docs.gradle.org/current/userguide/compatibility.html#java │ │ │ └─────────────────────────────────────────────────────────────────────────────┘ ``` Example output if Java/Gradle/Agp are not compatible. ``` ┌─────────────────────────────────────────────────────────────────────────────┐ │ General Info │ │ [✓] App Name: espresso_example │ │ [✓] Supported Platforms: android │ │ [✓] Is Flutter Package: yes │ │ [✓] Uses Material Design: yes │ │ [✓] Is Plugin: no │ │ [✗] Java/Gradle/Android Gradle Plugin: Incompatible Gradle/AGP versions. │ │ │ │ Gradle Version: 7.0.2, AGP Version: 7.4.2 │ │ │ │ Update gradle to at least "7.5". │ │ See the link below for more information: │ │ https://developer.android.com/studio/releases/gradle-plugin#updating-gradle │ │ │ │ Incompatible Java/Gradle versions. │ │ │ │ Java Version: 17.0.6, Gradle Version: 7.0.2 │ │ │ │ See the link below for more information: │ │ https://docs.gradle.org/current/userguide/compatibility.html#java │ │ │ └─────────────────────────────────────────────────────────────────────────────┘ ``` Commit messages - Add function to gradle_utils.dart that gets the gradle version from wrapper or system and add a test for each situation - Add method to get agp version, add method to validate agp against gradle version, update documentation, add tests for agp validation. - Update dart doc for validateGradleAndAgp to describe where the info came from and corner case behavior, create function to validate java and gradle and hardcode return to false - Fill out and test java gradle compatibility function in gradle_utils - Hook up java gradle evaluateion to hasValidJavaGradleAgpVersions with hardcoded java version - Add java --version output parsing and tests - Add getJavaBinary test - Update comment in android_sdk for mac behavior with java_home -v ## 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]. - [ ] All existing and new tests are passing.
-
- 31 Mar, 2023 1 commit
-
-
Chinmay Garde authored
[Impeller] Plumb through the impeller-force-gl flag.
-
- 30 Mar, 2023 1 commit
-
-
Chinmay Garde authored
[Impeller] Plumb through the enable-vulkan-validation flag.
-
- 23 Mar, 2023 1 commit
-
-
Dan Field authored
Ignore spam from SurfaceSyncer
-
- 22 Mar, 2023 1 commit
-
-
Michael Goderbauer authored
Remove 1745 decorative breaks
-
- 21 Mar, 2023 2 commits
-
-
Bartek Pacia authored
Fix Gradle warning in a freshly `flutter create`ed Android project
-
Zachary Anderson authored
-
- 15 Mar, 2023 1 commit
-
-
Victoria Ashworth authored
Separate attached and wireless devices
-
- 09 Mar, 2023 1 commit
-
-
Tim Maffett authored
fix devtool instructional messages after `flutter build ... --analyze-size `. Fixes #122229 (#122230) fix devtool instructional messages after `flutter build ... --analyze-size `. Fixes #122229
-