Skip to content

[google_maps_flutter] Add Android and iOS attribution ID#11731

Merged
auto-submit[bot] merged 6 commits into
flutter:mainfrom
stuartmorgan-g:maps-attribution
May 26, 2026
Merged

[google_maps_flutter] Add Android and iOS attribution ID#11731
auto-submit[bot] merged 6 commits into
flutter:mainfrom
stuartmorgan-g:maps-attribution

Conversation

@stuartmorgan-g

Copy link
Copy Markdown
Collaborator

Adds an attribution ID to allow association of Google Maps usage to this plugin in backend metrics. Known caveats:

  • This only does Android and iOS since there's a blocker on web.
  • On iOS, the necessary API was added in 9.2.0, and we still support back to 8.4.0 (for iOS 14 support), so iOS will only have attribution for apps build supporting iOS 15+ (in theory not all of those either since apps supporting iOS 15+ could have 9.0 or 9.1 in their podspec lock, but we don't expect that to be a significant number of users).

This can't be meaningfully tested because they are setters on static SDK objects that aren't inspectable. In theory we could make wrappers and then inject replacement global objects but the untestable parts of that setup would be more complex than the code in question so there's no value in doing that. Instead this will be verified on the backend. This call has no user-facing effect, so regression risk is also extremely low.

Part of flutter/flutter#168529

Pre-Review Checklist

Footnotes

  1. Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling. 2

@stuartmorgan-g stuartmorgan-g requested a review from jmagman May 18, 2026 17:22
@flutter-dashboard flutter-dashboard Bot added the CICD Run CI/CD label May 18, 2026
@flutter-dashboard

Copy link
Copy Markdown

It looks like this pull request may not have tests. Please make sure to add tests or get an explicit test exemption before merging.

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. If you believe this PR qualifies for a test exemption, contact "@test-exemption-reviewer" in the #hackers channel in Discord (don't just cc them here, they won't see it!). The test exemption team is a small volunteer group, so all reviewers should feel empowered to ask for tests, without delegating that responsibility entirely to the test exemption group.

@stuartmorgan-g

Copy link
Copy Markdown
Collaborator Author

test-exempt: can't be meaningfully tested; no client-discernable effect

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request adds internal usage attribution IDs for the Google Maps SDK across Android and various iOS implementations, including standard, SDK 9, and SDK 10 versions. The changes involve calling addInternalUsageAttributionId in the Android plugin and conditionally calling addInternalUsageAttributionID in the iOS plugins. Version numbers and changelogs have been updated accordingly. I have no feedback to provide.

@github-actions github-actions Bot removed the CICD Run CI/CD label May 26, 2026
@flutter-dashboard flutter-dashboard Bot added the CICD Run CI/CD label May 26, 2026
@stuartmorgan-g stuartmorgan-g added the autosubmit Merge PR when tree becomes green via auto submit App label May 26, 2026
@auto-submit auto-submit Bot merged commit 6da2737 into flutter:main May 26, 2026
87 checks passed
pull Bot pushed a commit to mikeyhodl/flutter that referenced this pull request May 26, 2026
…r#187114)

flutter/packages@69cf959...fc795e5

2026-05-26 [email protected] Roll Flutter from
e03b91f to f3a4b98 (63 revisions) (flutter/packages#11789)
2026-05-26 [email protected] [google_maps_flutter] Add Android and
iOS attribution ID (flutter/packages#11731)
2026-05-26 49699333+dependabot[bot]@users.noreply.github.com
[dependabot]: Bump org.json:json from 20251224 to 20260522 in
/packages/in_app_purchase/in_app_purchase_android/example/android/app
(flutter/packages#11776)
2026-05-26 [email protected] [google_maps_flutter] Add a
pinned-SDK web example app (flutter/packages#11761)

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] 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
@stuartmorgan-g stuartmorgan-g deleted the maps-attribution branch June 1, 2026 15:12
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 CICD Run CI/CD p: google_maps_flutter platform-android platform-ios

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants