-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[google_maps_flutter] update ios privacy manifest #6511
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
Conversation
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 "@test-exemption-reviewer" in the #hackers channel in Chat (don't just cc them here, they won't see it! Use Discord!). 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. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We're going to do a little digging to figure out why the Maps SDK team is requesting these steps: https://developers.google.com/maps/documentation/ios-sdk/config#add-apple-privacy-manifest-file
@rrpadilla Did you get an App Store warning about the GoogleMaps frameworks specifically? And if you make the google_maps_flutter manifest changes in this PR and resubmit your app, the warning goes away? I wouldn't expect the App Store validator would accept the |
Capturing from discussion elsewhere: it looks like the vendored frameworks in the Pod are static frameworks, and then we're also forcing static build in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we do move forward with this (it's error-prone in the long term, and the static frameworks really should be including this information directly), we will need to make updating the SDK version part of this PR. According to the docs:
Important: These instructions for the Apple Privacy Manifest File apply only to the latest SDK version.
That will also mean changing the min supported iOS version in our podspec.
We will need to do that regardless though, because older versions won't be compliant with the new rules anyway.
The first time I submitted the app to apple store connect I get an email about ITMS-91053: Missing API declaration, specifically the 4 listed below.
I created a privacy file as recommended here and here. This is the privacy file I uploaded and the warning goes away. Basically I just copied the NSPrivacyAccessedAPITypes entries from the privacy manifest provided by google here.
How do I know Google Maps is causing this warning?I build a flutter app with the google_maps_flutter plugin only and when I run the commands listed below (recommended by @stuartmorgan here). Then I confirmed the GoogleMapsPrivacy.bundle was using those entries.
As you can see the Google Maps Flutter iOS privacy file is empty. |
Which should be correct, because the manifest for the plugin should only describe what the code in the plugin does, and its dependencies should have their own manifests that describe what they do. These Google Maps SDK instructions are very unusual. |
@stuartmorgan What is your recommendation?
|
My recommendation is that we wait for this to land anything. |
While we wait for that, feel free to update the PR to change the podspec as described in my earlier comment, as that will need to be done for any version of a PR. That will also involve changing the directories in |
Actually, I can go ahead and do these changes and push them to the PR. They are bit tricky to get right. |
@stuartmorgan Thanks. Maybe we have to do this in the podspec file.
|
Based on offline conversation, we've decided to go ahead with incorporating the stand-alone privacy bundle's manifest into the plugin's manifest for now. The expectation is that future versions of the Google Maps SDK will have it built in as expected, at which point we can unwind the workaround†. I've pushed the following changes:
(†If the version that includes the manifest is also the version that drops iOS 14, which may well be the case based on the timings listed in the SDK release notes, we'll need to think about whether we want to unwind the workaround at the cost of losing iOS 14 support.) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm modulo one comment.
...google_maps_flutter/google_maps_flutter_ios/example/ios14/ios/Flutter/AppFrameworkInfo.plist
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Since we no longer need it, I removed the arm64 simulator workaround, fixing [google_maps_flutter] Update minimum GoogleMaps dependency to a version that supports ARM simulators flutter#94491
I knew this day would eventually come. 🙂
LGTM!
@rrpadilla thanks for bringing the unusual GoogleMaps case to our attention.
flutter/packages@90c876d...d39830e 2024-04-16 [email protected] Manual roll Flutter from 2e748e8 to 3882afb (16 revisions) (flutter/packages#6549) 2024-04-16 [email protected] [image_picker] Add limit parameter to pickMultiImage and pickMultipleMedia to ios and Android (flutter/packages#6201) 2024-04-16 [email protected] [camera] Remove iOS thread-safe result class (flutter/packages#6498) 2024-04-16 [email protected] [google_maps_flutter] update ios privacy manifest (flutter/packages#6511) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC [email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
flutter/packages@90c876d...d39830e 2024-04-16 [email protected] Manual roll Flutter from 2e748e8 to 3882afb (16 revisions) (flutter/packages#6549) 2024-04-16 [email protected] [image_picker] Add limit parameter to pickMultiImage and pickMultipleMedia to ios and Android (flutter/packages#6201) 2024-04-16 [email protected] [camera] Remove iOS thread-safe result class (flutter/packages#6498) 2024-04-16 [email protected] [google_maps_flutter] update ios privacy manifest (flutter/packages#6511) If this roll has caused a breakage, revert this CL and stop the roller using the controls here: https://autoroll.skia.org/r/flutter-packages-flutter-autoroll Please CC [email protected],[email protected] on the revert to ensure that a human is aware of the problem. To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose To report a problem with the AutoRoller itself, please file a bug: https://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
The installation instructions for Google Maps Platform SDKs for iOS now have download links and instructions for **manually** adding Privacy Manifest files for use with the latest versions of the SDKs. You can read more about this [here](googlemaps/google-maps-ios-utils#463 (comment)). This PR synchronizes the iOS privacy manifest with the file provided by Google for the Maps SDK for iOS. The privacy manifest was downloaded from: [https://developers.google.com/maps/documentation/ios-sdk/config#add-apple-privacy-manifest-file](https://developers.google.com/maps/documentation/ios-sdk/config#add-apple-privacy-manifest-file). As you can see in the new **[PrivacyInfo.xcprivacy](packages/google_maps_flutter/google_maps_flutter_ios/ios/Resources/PrivacyInfo.xcprivacy)** file Google Maps SDK is using the following **NSPrivacyAccessedAPITypes**: - **NSPrivacyAccessedAPICategoryDiskSpace** - **NSPrivacyAccessedAPICategorySystemBootTime** - **NSPrivacyAccessedAPICategoryFileTimestamp** - **NSPrivacyAccessedAPICategoryUserDefaults** *Related issues:* - [flutter/flutter/issues/145269](flutter/flutter#145269) - [flutter/flutter/issues/143232](flutter/flutter#143232) - [flutter/flutter/issues/131940](flutter/flutter#131940 (comment)) Fixes flutter/flutter#94491
The installation instructions for Google Maps Platform SDKs for iOS now have download links and instructions for manually adding Privacy Manifest files for use with the latest versions of the SDKs. You can read more about this here.
This PR synchronizes the iOS privacy manifest with the file provided by Google for the Maps SDK for iOS.
The privacy manifest was downloaded from: https://developers.google.com/maps/documentation/ios-sdk/config#add-apple-privacy-manifest-file.
As you can see in the new PrivacyInfo.xcprivacy file Google Maps SDK is using the following NSPrivacyAccessedAPITypes:
Related issues:
Fixes flutter/flutter#94491
Pre-launch Checklist
dart format
.)[shared_preferences]
pubspec.yaml
with an appropriate new version according to the pub versioning philosophy, or this PR is exempt from version changes.CHANGELOG.md
to add a description of the change, following repository CHANGELOG style.///
).If you need help, consider asking for advice on the #hackers-new channel on Discord.