Skip to content

[iOS] Update template icons #107873

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 25, 2022
Merged

[iOS] Update template icons #107873

merged 2 commits into from
Jul 25, 2022

Conversation

RockerFlower
Copy link
Contributor

@RockerFlower RockerFlower commented Jul 18, 2022

Updates the AppIcon and LaunchImage assets in the iOS app template to meet Apple's icon guidelines as of iOS. Assets were moved to the flutter_template_images package, which includes them as of version 4.2.0.

Ref: https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons#specifications

Update the test on creating iOS templated icons

Validate that at least one of the iOS templated icons gets downloaded and put in the right spot.

Issue: #106110

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 c: contributor-productivity Team-specific productivity, code health, technical debt. tool Affects the "flutter" command-line tool. See also t: labels. labels Jul 18, 2022
@RockerFlower
Copy link
Contributor Author

@jmagman Sorry to bother you again. 😅

This commit should be based on the latest repository, but the automated check still has errors.

Warning: one or more pubspecs have invalid dependencies. Please run "flutter update-packages --force-upgrade" to update them correctly.

I ran this command, and no files were changed.

$ flutter update-packages --force-upgrade

Upgrading packages...
WARNING: the following packages use hard-coded version constraints:
  - archive: 3.1.11
  - flutter_gallery_assets: 1.0.2
  - flutter_template_images: 4.0.0
  - shelf: 1.1.4
  - video_player: 2.2.11
Running "flutter pub upgrade" in flutter_update_packages.Nz9N8F...         4.9s
Ran pub get in dev/integration_tests/web in 0.5s...
Ran pub get in dev/tools/vitool in 0.8s...
Ran pub get in dev/integration_tests/web_compile_tests in 0.4s...
Ran pub get in dev/tools/gen_keycodes in 1.1s...
Ran pub get in dev/tools/gen_defaults in 1.1s...
Ran pub get in dev/tools in 1.2s...
Ran pub get in dev/integration_tests/ios_platform_view_tests in 1.2s...
Ran pub get in dev/integration_tests/deferred_components_test in 1.3s...
Ran pub get in dev/bots in 1.3s...
Ran pub get in dev/integration_tests/ui in 1.3s...
Ran pub get in dev/integration_tests/release_smoke_test in 0.7s...
Ran pub get in dev/integration_tests/android_views in 1.6s...
Ran pub get in dev/integration_tests/ios_app_with_extensions in 0.6s...
Ran pub get in dev/integration_tests/ios_add2app_life_cycle/flutterapp in 0.6s...
Ran pub get in dev/integration_tests/android_embedding_v2_smoke_test in 0.8s...
Ran pub get in dev/integration_tests/gradle_deprecated_settings in 0.6s...
Ran pub get in dev/integration_tests/non_nullable in 0.6s...
Ran pub get in dev/integration_tests/flavors in 1.1s...
Ran pub get in dev/integration_tests/abstract_method_smoke_test in 0.4s...
Ran pub get in dev/integration_tests/external_ui in 1.2s...
Ran pub get in dev/integration_tests/android_semantics_testing in 1.2s...
Ran pub get in dev/integration_tests/web_e2e_tests in 1.3s...
Ran pub get in dev/manual_tests in 0.6s...
Ran pub get in dev/integration_tests/platform_interaction in 1.1s...
Ran pub get in dev/integration_tests/hybrid_android_views in 1.3s...
Ran pub get in dev/forbidden_from_release_tests in 0.4s...
Ran pub get in dev/tracing_tests in 0.6s...
Ran pub get in dev/integration_tests/channels in 1.1s...
Ran pub get in dev/integration_tests/flutter_gallery in 1.7s...
Ran pub get in dev/customer_testing in 1.2s...
Ran pub get in dev/benchmarks/multiple_flutters/module in 1.0s...
Ran pub get in dev/devicelab in 1.5s...
Ran pub get in dev/benchmarks/complex_layout in 1.4s...
Ran pub get in dev/benchmarks/test_apps/stocks in 1.6s...
Ran pub get in examples/splash in 0.7s...
Ran pub get in dev/benchmarks/platform_views_layout_hybrid_composition in 1.6s...
Ran pub get in dev/benchmarks/platform_views_layout in 1.6s...
Ran pub get in dev/benchmarks/macrobenchmarks in 1.8s...
Ran pub get in dev/benchmarks/microbenchmarks in 1.7s...
Ran pub get in dev/benchmarks/platform_channels_benchmarks in 1.7s...
Ran pub get in examples/platform_view in 0.4s...
Ran pub get in dev/conductor/core in 1.4s...
Ran pub get in examples/flutter_view in 0.4s...
Ran pub get in dev/automated_tests in 1.5s...
Ran pub get in examples/layers in 0.7s...
Ran pub get in examples/image_list in 0.7s...
Ran pub get in packages/integration_test/integration_test_macos in 0.4s...
Ran pub get in examples/hello_world in 1.4s...
Ran pub get in packages/flutter_web_plugins in 0.7s...
Ran pub get in packages/integration_test in 0.7s...
Ran pub get in examples/platform_channel_swift in 1.3s...
Ran pub get in packages/flutter_goldens_client in 0.4s...
Ran pub get in examples/platform_channel in 1.2s...
Ran pub get in packages/flutter_goldens in 0.8s...
Ran pub get in packages/flutter_tools/test/data/asset_test/main in 0.2s...
Ran pub get in packages/flutter/test_private in 0.5s...
Ran pub get in packages/flutter_test/test/test_config/project_root in 0.1s...
Ran pub get in packages/flutter/test_private/test in 0.8s...
Ran pub get in examples/api in 1.3s...
Ran pub get in packages/integration_test/example in 1.3s...
Ran pub get in packages/flutter in 0.7s...
Ran pub get in packages/flutter_localizations in 0.5s...
Ran pub get in packages/flutter_test in 0.4s...
Ran pub get in packages/fuchsia_remote_debug_protocol in 0.7s...
Ran pub get in packages/flutter_driver in 0.7s...
Downloaded lcov data for package:flutter in 0.0s...
Ran pub get in packages/flutter_tools in 1.9s...
Running "flutter pub get" in affected packages...                   7.7s

Ran 'pub get' 66 times and fetched coverage data in 7.7s.

@jmagman
Copy link
Member

jmagman commented Jul 19, 2022

A ha! This is caused by flutter/packages#1951.

This logic is checking if package.packageUriRoot directory exists, which in this case is the flutter_template_images-4.2.0/lib directory, which no longer exists.

if (!fileSystem.directory(package.packageUriRoot).existsSync()) {

Because it doesn't exist, on every run it thinks the pub dependencies are out of date, and pub needs to be run.

@stuartmorgan I see from that PR it says

Removes the empty Dart file, which used to be required by pub.dev checks but no longer is.

I'm not sure what feature this is referencing, is the tool logic correct?

@jmagman
Copy link
Member

jmagman commented Jul 19, 2022

Filed #107957 to track this. Thanks for your patience, please hold 🙂

@stuartmorgan-g
Copy link
Contributor

Removes the empty Dart file, which used to be required by pub.dev checks but no longer is.

I'm not sure what feature this is referencing

It used to be that if you tried to pub publish a package that didn't contain any Dart code, it would error out, so we had packages/plugins (like this one, which exists only to hold images) that had a dummy Dart file in lib/. That restriction was lifted at some point, so I've been cleaning up those dummy files as I find them.

is the tool logic correct?

I'm not sure what that tool logic does exactly, but it shouldn't be assuming that all packages have lib directories.

@jmagman
Copy link
Member

jmagman commented Jul 19, 2022

I'm not sure what that tool logic does exactly, but it shouldn't be assuming that all packages have lib directories.

This is the logic:

for (final Package package in packageConfig.packages) {
if (!fileSystem.directory(package.packageUriRoot).existsSync()) {
return false;
}
}

package.packageUriRoot is lib in this case.
Screen Shot 2022-07-19 at 1 21 03 PM

Need some better way to check this then, I don't see anything else interesting in that package object.

@stuartmorgan-g
Copy link
Contributor

stuartmorgan-g commented Jul 19, 2022

Sorry, I meant I don't know what that logic is for. I.e., I don't know what "lib/ exists" is intended to be a proxy for, and thus what to replace it with. Is there a reason it's checking for something in the package, not the folder itself? Is there a reason it's not checking for pubspec.yaml instead, or was lib/ arbitrary content? Someone who knows the answers to those questions should decide how to fix it :)

@jmagman
Copy link
Member

jmagman commented Jul 19, 2022

Someone who knows the answers to those questions should decide how to fix it :)

Yup, wasn't saying you should fix it, the tool team is already on it. Was just asking for more context since you knew more than I did about how these packages should be formatted. 🙂

@jmagman
Copy link
Member

jmagman commented Jul 21, 2022

Thank you for your patience! Can you try rebasing/merging this on #107968?
And did you want to track this work in #106111 or this PR?

@RockerFlower
Copy link
Contributor Author

Thank you for your patience! Can you try rebasing/merging this on #107968? And did you want to track this work in #106111 or this PR?

I seem to have made a mistake, so many commits..

@jmagman
Copy link
Member

jmagman commented Jul 21, 2022

I seem to have made a mistake, so many commits..

Looks correct now, you figured it out. 🙂

@RockerFlower
Copy link
Contributor Author

I seem to have made a mistake, so many commits..

Looks correct now, you figured it out. 🙂

Oops, there are still errors.

@jmagman
Copy link
Member

jmagman commented Jul 22, 2022

So flutter update-packages --force-upgrade will need to be run on your PR. That command hasn't been run in a bit, and there are some updates it generates unrelated to your change. I created #108178 which will run it on master, then you can rebase again when that lands. Then you can run flutter update-packages --force-upgrade on your change, and the only diff should be the CHECKSUM in packages/flutter_tools/pubspec.yaml:

-# PUBSPEC CHECKSUM: b869
+# PUBSPEC CHECKSUM: 5d6a

Apologies that you've hit so many rough edges helping us with this change. Thanks again, we're almost there!

@RockerFlower
Copy link
Contributor Author

So flutter update-packages --force-upgrade will need to be run on your PR. That command hasn't been run in a bit, and there are some updates it generates unrelated to your change. I created #108178 which will run it on master, then you can rebase again when that lands. Then you can run flutter update-packages --force-upgrade on your change, and the only diff should be the CHECKSUM in packages/flutter_tools/pubspec.yaml:

-# PUBSPEC CHECKSUM: b869
+# PUBSPEC CHECKSUM: 5d6a

Apologies that you've hit so many rough edges helping us with this change. Thanks again, we're almost there!

I'm delighted to contribute to Flutter!

Do I need to wait for #108198 to be merged?

@jmagman
Copy link
Member

jmagman commented Jul 25, 2022

Do I need to wait for #108198 to be merged?

Yes, once it's in master then merge or rebase to get that change.

@jmagman
Copy link
Member

jmagman commented Jul 25, 2022

Do I need to wait for #108198 to be merged?

It's merged.

Updates the AppIcon and LaunchImage assets in the iOS app template to meet Apple's icon guidelines as of iOS. Assets were moved to the [flutter_template_images][1] package, which includes them as of version 4.2.0.

Ref: https://developer.apple.com/design/human-interface-guidelines/foundations/app-icons#specifications

Update the test on creating iOS templated icons

Validate that at least one of the iOS templated icons gets downloaded and put in the right spot.

Issue: flutter#106110

[1]: https://github.com/flutter/packages/tree/main/packages/flutter_template_images
@RockerFlower
Copy link
Contributor Author

The strange thing is that after I run flutter update-packages --force-upgrade, nothing changes.

@jmagman
Copy link
Member

jmagman commented Jul 25, 2022

Looks like it's passing now, marking ready for review.

@jmagman jmagman marked this pull request as ready for review July 25, 2022 20:04
@RockerFlower
Copy link
Contributor Author

Looks like it's passing now, marking ready for review.

CHECKSUM was changed manually by me because I ran the command without effect.

Copy link
Member

@jmagman jmagman left a comment

Choose a reason for hiding this comment

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

LGTM, thanks again for the contribution!
Adding @christopherfujino for the second review.

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

@jmagman jmagman added the autosubmit Merge PR when tree becomes green via auto submit App label Jul 25, 2022
@auto-submit auto-submit bot merged commit 5f67b47 into flutter:master Jul 25, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/plugins that referenced this pull request Jul 26, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jul 26, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jul 26, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jul 26, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jul 26, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jul 26, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jul 26, 2022
stuartmorgan-g pushed a commit to flutter/plugins that referenced this pull request Jul 27, 2022
* 2142b2e Roll Flutter Engine from cd7e2ec4037b to c31036f2381c (1 revision) (flutter/flutter#108299)

* 178e444 Revert "Add optional flag to determine assertiveness level in aria announcement for flutter web" (flutter/flutter#108262)

* 8a7b359 flutter update-packages --force-upgrade + analyzer fix (flutter/flutter#108198)

* b3f5d3f Roll Flutter Engine from c31036f2381c to 54b0ac3059bf (1 revision) (flutter/flutter#108302)

* 2f4299a [flutter_tools] Remove unused parameter when connected DAP to VM Service (flutter/flutter#108285)

* e74b9b5 Migrate InputDecorator to Material 3 (flutter/flutter#107943)

* e3b851a Fix Tamil DateTime representation of AM/PM (flutter/flutter#108185)

* 43d6e2b Roll Flutter Engine from 54b0ac3059bf to 705072522c00 (4 revisions) (flutter/flutter#108308)

* 6929ad1 Roll Flutter Engine from 705072522c00 to 3964cf62cdf8 (1 revision) (flutter/flutter#108316)

* 5f67b47 [iOS] Update template icons (flutter/flutter#107873)

* 606954d Added iconSize parameter in ButtonStyle (flutter/flutter#108268)

* b3814c7 Roll Flutter Engine from 3964cf62cdf8 to 7f8925b1f6f3 (2 revisions) (flutter/flutter#108320)

* ca6cecf Upgrade Gradle and AGP versions to 7.5/7.2 and migrate examples/tests (flutter/flutter#108197)

* d155bc1 Revert "Upgrade Gradle and AGP versions to 7.5/7.2 and migrate examples/tests (#108197)" (flutter/flutter#108349)

* 4056d3f Explain the "patching" protocol in `KeyMessageManager.keyMessageHandler` and add an example (flutter/flutter#105280)

* b035ef1 [flutter_tools] Remove more shuffles (flutter/flutter#107759)

* be14858 Roll Flutter Engine from 7f8925b1f6f3 to 8eca26d130a2 (1 revision) (flutter/flutter#108326)

* 3eb638f Roll Flutter Engine from 8eca26d130a2 to f1f9b4de82b6 (5 revisions) (flutter/flutter#108350)

* 401b556 Roll Flutter Engine from f1f9b4de82b6 to 11d927ac3e9b (2 revisions) (flutter/flutter#108353)

* 925bee9 Roll Flutter Engine from 11d927ac3e9b to 5dcaeae6561b (1 revision) (flutter/flutter#108356)

* 5d31b07 [flutter_tools] [dap] Ensure DAP sends app.stop/app.detach during terminate (flutter/flutter#108310)

* c8b5d10 Roll Flutter Engine from 5dcaeae6561b to 89e117b89c63 (1 revision) (flutter/flutter#108367)

* e3d08fb Hide the debug banner in the PopupMenuButton example (flutter/flutter#108324)
@RockerFlower
Copy link
Contributor Author

CHECKSUM was changed manually by me because I ran the command without effect.

@jmagman When I updated my own copy of flutter, I became aware of this: by running flutter update-packages —force-upgrade, I was updating the flutter code that I set the path to, so the copy I cloned did not change. 🤦‍♂️

@jmagman
Copy link
Member

jmagman commented Aug 8, 2022

CHECKSUM was changed manually by me because I ran the command without effect.

@jmagman When I updated my own copy of flutter, I became aware of this: by running flutter update-packages —force-upgrade, I was updating the flutter code that I set the path to, so the copy I cloned did not change. 🤦‍♂️

That would do it!

camsim99 pushed a commit to camsim99/flutter that referenced this pull request Aug 10, 2022
yutaaraki-toydium pushed a commit to yutaaraki-toydium/plugins that referenced this pull request Aug 12, 2022
* 2142b2e Roll Flutter Engine from cd7e2ec4037b to c31036f2381c (1 revision) (flutter/flutter#108299)

* 178e444 Revert "Add optional flag to determine assertiveness level in aria announcement for flutter web" (flutter/flutter#108262)

* 8a7b359 flutter update-packages --force-upgrade + analyzer fix (flutter/flutter#108198)

* b3f5d3f Roll Flutter Engine from c31036f2381c to 54b0ac3059bf (1 revision) (flutter/flutter#108302)

* 2f4299a [flutter_tools] Remove unused parameter when connected DAP to VM Service (flutter/flutter#108285)

* e74b9b5 Migrate InputDecorator to Material 3 (flutter/flutter#107943)

* e3b851a Fix Tamil DateTime representation of AM/PM (flutter/flutter#108185)

* 43d6e2b Roll Flutter Engine from 54b0ac3059bf to 705072522c00 (4 revisions) (flutter/flutter#108308)

* 6929ad1 Roll Flutter Engine from 705072522c00 to 3964cf62cdf8 (1 revision) (flutter/flutter#108316)

* 5f67b47 [iOS] Update template icons (flutter/flutter#107873)

* 606954d Added iconSize parameter in ButtonStyle (flutter/flutter#108268)

* b3814c7 Roll Flutter Engine from 3964cf62cdf8 to 7f8925b1f6f3 (2 revisions) (flutter/flutter#108320)

* ca6cecf Upgrade Gradle and AGP versions to 7.5/7.2 and migrate examples/tests (flutter/flutter#108197)

* d155bc1 Revert "Upgrade Gradle and AGP versions to 7.5/7.2 and migrate examples/tests (#108197)" (flutter/flutter#108349)

* 4056d3f Explain the "patching" protocol in `KeyMessageManager.keyMessageHandler` and add an example (flutter/flutter#105280)

* b035ef1 [flutter_tools] Remove more shuffles (flutter/flutter#107759)

* be14858 Roll Flutter Engine from 7f8925b1f6f3 to 8eca26d130a2 (1 revision) (flutter/flutter#108326)

* 3eb638f Roll Flutter Engine from 8eca26d130a2 to f1f9b4de82b6 (5 revisions) (flutter/flutter#108350)

* 401b556 Roll Flutter Engine from f1f9b4de82b6 to 11d927ac3e9b (2 revisions) (flutter/flutter#108353)

* 925bee9 Roll Flutter Engine from 11d927ac3e9b to 5dcaeae6561b (1 revision) (flutter/flutter#108356)

* 5d31b07 [flutter_tools] [dap] Ensure DAP sends app.stop/app.detach during terminate (flutter/flutter#108310)

* c8b5d10 Roll Flutter Engine from 5dcaeae6561b to 89e117b89c63 (1 revision) (flutter/flutter#108367)

* e3d08fb Hide the debug banner in the PopupMenuButton example (flutter/flutter#108324)
mauricioluz pushed a commit to mauricioluz/plugins that referenced this pull request Jan 26, 2023
* 2142b2e Roll Flutter Engine from cd7e2ec4037b to c31036f2381c (1 revision) (flutter/flutter#108299)

* 178e444 Revert "Add optional flag to determine assertiveness level in aria announcement for flutter web" (flutter/flutter#108262)

* 8a7b359 flutter update-packages --force-upgrade + analyzer fix (flutter/flutter#108198)

* b3f5d3f Roll Flutter Engine from c31036f2381c to 54b0ac3059bf (1 revision) (flutter/flutter#108302)

* 2f4299a [flutter_tools] Remove unused parameter when connected DAP to VM Service (flutter/flutter#108285)

* e74b9b5 Migrate InputDecorator to Material 3 (flutter/flutter#107943)

* e3b851a Fix Tamil DateTime representation of AM/PM (flutter/flutter#108185)

* 43d6e2b Roll Flutter Engine from 54b0ac3059bf to 705072522c00 (4 revisions) (flutter/flutter#108308)

* 6929ad1 Roll Flutter Engine from 705072522c00 to 3964cf62cdf8 (1 revision) (flutter/flutter#108316)

* 5f67b47 [iOS] Update template icons (flutter/flutter#107873)

* 606954d Added iconSize parameter in ButtonStyle (flutter/flutter#108268)

* b3814c7 Roll Flutter Engine from 3964cf62cdf8 to 7f8925b1f6f3 (2 revisions) (flutter/flutter#108320)

* ca6cecf Upgrade Gradle and AGP versions to 7.5/7.2 and migrate examples/tests (flutter/flutter#108197)

* d155bc1 Revert "Upgrade Gradle and AGP versions to 7.5/7.2 and migrate examples/tests (#108197)" (flutter/flutter#108349)

* 4056d3f Explain the "patching" protocol in `KeyMessageManager.keyMessageHandler` and add an example (flutter/flutter#105280)

* b035ef1 [flutter_tools] Remove more shuffles (flutter/flutter#107759)

* be14858 Roll Flutter Engine from 7f8925b1f6f3 to 8eca26d130a2 (1 revision) (flutter/flutter#108326)

* 3eb638f Roll Flutter Engine from 8eca26d130a2 to f1f9b4de82b6 (5 revisions) (flutter/flutter#108350)

* 401b556 Roll Flutter Engine from f1f9b4de82b6 to 11d927ac3e9b (2 revisions) (flutter/flutter#108353)

* 925bee9 Roll Flutter Engine from 11d927ac3e9b to 5dcaeae6561b (1 revision) (flutter/flutter#108356)

* 5d31b07 [flutter_tools] [dap] Ensure DAP sends app.stop/app.detach during terminate (flutter/flutter#108310)

* c8b5d10 Roll Flutter Engine from 5dcaeae6561b to 89e117b89c63 (1 revision) (flutter/flutter#108367)

* e3d08fb Hide the debug banner in the PopupMenuButton example (flutter/flutter#108324)
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 c: contributor-productivity Team-specific productivity, code health, technical debt. tool Affects the "flutter" command-line tool. See also t: labels.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants