Skip to content

Conversation

@andrewkolos
Copy link
Contributor

@andrewkolos andrewkolos commented Apr 20, 2023

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.

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read and followed the Flutter Style Guide, including Features we expect every widget to implement.
  • 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 ///).
  • 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.

@flutter-dashboard flutter-dashboard bot added the tool Affects the "flutter" command-line tool. See also t: labels. label Apr 20, 2023
@andrewkolos andrewkolos marked this pull request as ready for review April 20, 2023 22:01
Co-authored-by: Christopher Fujino <[email protected]>
Copy link
Contributor

@christopherfujino christopherfujino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are you testing if version.major = 2023?

@andrewkolos
Copy link
Contributor Author

Are you testing if version.major = 2023?

No. Instead of this, I could add a "version next" case (e.g. version 999999).

Co-authored-by: Christopher Fujino <[email protected]>
Copy link
Contributor

@christopherfujino christopherfujino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@andrewkolos andrewkolos added the autosubmit Merge PR when tree becomes green via auto submit App label Apr 21, 2023
@auto-submit auto-submit bot merged commit cf76b24 into flutter:master Apr 21, 2023
@andrewkolos andrewkolos deleted the fix-jdk-search branch April 21, 2023 01:13
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 21, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 21, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 22, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 22, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 23, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 23, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 24, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 24, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 24, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 24, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 25, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Apr 25, 2023
…on of Android Studio, assume the version to be the latest (flutter/flutter#125247)
auto-submit bot pushed a commit that referenced this pull request May 1, 2023
…nfigured installation directory (`flutter config --android-studio-dir`) (#125596)

Fixes #121468 (when considered along with #125247).

This applies the pre-existing Android Studio version detection logic to the install configured with `flutter config android-studio-dir`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

autosubmit Merge PR when tree becomes green via auto submit App tool Affects the "flutter" command-line tool. See also t: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[tools] Tool will likely not find the JDK bundled with the next major version of AndroidStudio (e.g. 2023)

2 participants