Skip to content

Clean up null assumptions for Gradle classes - #83443

Merged
fluttergithubbot merged 1 commit into
flutter:masterfrom
jmagman:android-prep-null
May 28, 2021
Merged

fluttergithubbot merged 1 commit into
flutter:masterfrom
jmagman:android-prep-null

Conversation

@jmagman

@jmagman jmagman commented May 26, 2021

Copy link
Copy Markdown
Member

I started migrating project.dart and all its dependencies, and the diff was huge.
Pull out the Gradle class cleanup parts that can be done without actually migrating to null safety.

Part of #71511

@jmagman jmagman self-assigned this May 26, 2021
@flutter-dashboard flutter-dashboard Bot added the tool Affects the "flutter" command-line tool. See also t: labels. label May 26, 2021
@flutter-dashboard

Copy link
Copy Markdown

It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact Hixie on the #hackers channel in Chat.

If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix?

Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing.

@google-cla google-cla Bot added the cla: yes label May 26, 2021
@jmagman
jmagman force-pushed the android-prep-null branch from 7235bd0 to d28fffe Compare May 26, 2021 21:44

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Null outputDirectoryPath defaults to project.android.buildDirectory on line 197.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

It's possible to pass a nullable androidPackage here. Since it's just used for informational printing, default to "unknown".

Comment on lines 32 to 35

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

These are always passed in and assumed to be nonnull.

@jmagman
jmagman requested a review from jonahwilliams May 26, 2021 22:19

@jonahwilliams jonahwilliams left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@fluttergithubbot
fluttergithubbot merged commit 6d03cb6 into flutter:master May 28, 2021
@jmagman
jmagman deleted the android-prep-null branch June 1, 2021 19:58
@jmagman jmagman added the a: null-safety Support for Dart's null safety feature label Aug 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

a: null-safety Support for Dart's null safety feature tool Affects the "flutter" command-line tool. See also t: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants