You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
We should take a stronger stance on making sure devs:
Provide users with a way to opt-out, and know that they should.
Collect metrics by default.
Know about the Settings.bundle option.
In working on metrics testing for #1491, I couldn't figure out why my metrics weren't behaving properly. It turns out my test app (test/ios/ios-tests.xcodeproj) didn't implement a Settings.bundle and was not collecting any metrics.
We should probably take a stronger approach, such as:
Asserting that a Settings.bundle exists at first run instead of just logging about it.
Allowing for a class method (e.g. [MGLMapboxEvents setShowsOptOutInApp:YES]) which a dev has to implement in their code to work around the above.
stronger stance on making sure devs:
provide users with a way to opt-out
Great point @incanus. We should make an awesome page on this, maybe even put a section on the new /mobile. Other mapping apps, especially Apple, have it so buried on how to opt out. We really should push opting out as a feature; something that is great for anyone that wants super low battery usage or just folks that don't like the idea of anyone collecting their data.
It turns out my test app (test/ios/ios-tests.xcodeproj) didn't implement a Settings.bundle and was not collecting any metrics.
I fixed this in e839c2a for #1491. In that PR, the default works even if you don’t provide an opt-out. The issue was that -[NSUserDefaults registerDefaults:] was being called in -init instead of +initialize.
PR #1520 was erroneously setup vs the master branch instead of today's new ios-beta1 branch. The correct PR is now #1521. Thanks @jfirebaugh for catching this!
If we dev off of ios-b1, things should merge cleanly later, but if we commit b1-critical stuff to master, then cherry pick them over to ios-b1, they definitely will.
That only gets ahead of metrics collection once a map view has been shown, though.
Hrm, I hadn't considered never-sending-metrics as a problem Mapbox was addressing. Theoretically, a user could download a MBGL-using app, open up Settings.app, turn off metrics, and then launch the app, never sending metrics data in.
But it seems like, practically speaking, unless there's an opt-in alert prompt (which isn't on the table and would be a terrible UX/business decision), virtually every user will have some metrics collected before they're able to opt out. It also seems to me that most users likely won't ever be aware there is something to opt out of, if a Settings.app switch is enough.
Just implemented the fixes that @1ec5 suggested in his code review from last night. The technical core of this issue has now been implemented and tested. The ℹ️ issue is tracked elsewhere, so once Travis approves we should be good to merge this into master and then cherrypick back to ios-b1 if we're feeling good about things.
Travis just approved and I merged #1520 into master. It's ready to be merged into ios-b1 should we choose. I'll leave this issue open to remind us to think about this later today.
If we take these changes for beta 1, we should update the wiki and mapbox/mapbox-gl-ios to point out the extra step when implementing the opt-out in-app.
Activity
friedbunny commentedon May 12, 2015
The ℹ️ button will be a good place to always offer the opt-out, once that becomes more a custom view.
incanus commentedon May 12, 2015
That only gets ahead of metrics collection once a map view has been shown, though.
tighten up & fix tests; work around #1516 for now
gundersen commentedon May 12, 2015
Great point @incanus. We should make an awesome page on this, maybe even put a section on the new /mobile. Other mapping apps, especially Apple, have it so buried on how to opt out. We really should push opting out as a feature; something that is great for anyone that wants super low battery usage or just folks that don't like the idea of anyone collecting their data.
1ec5 commentedon May 12, 2015
I fixed this in e839c2a for #1491. In that PR, the default works even if you don’t provide an opt-out. The issue was that
-[NSUserDefaults registerDefaults:]was being called in-initinstead of+initialize.#1516 - Adding explicit checks for developer implementation of user O…
bleege commentedon May 12, 2015
Added explicit checks for End User Opt Out ability to be implemented by the developer in 48e21ae. This can done via 2 ways:
[MGLAccountManager setShowsOptOutInApp:YES]in AppDelegateSettings.bundlefile via NSAssert that fails program if not satisfiedThis code is based off the latest
ios-b1branch and is available in the1516-opt-out-checkingbranch.bleege commentedon May 12, 2015
PR #1520 was erroneously setup vs the
masterbranch instead of today's newios-beta1branch. The correct PR is now #1521. Thanks @jfirebaugh for catching this!incanus commentedon May 12, 2015
If we dev off of
ios-b1, things should merge cleanly later, but if we commit b1-critical stuff tomaster, then cherry pick them over toios-b1, they definitely will.friedbunny commentedon May 12, 2015
Hrm, I hadn't considered never-sending-metrics as a problem Mapbox was addressing. Theoretically, a user could download a MBGL-using app, open up Settings.app, turn off metrics, and then launch the app, never sending metrics data in.
But it seems like, practically speaking, unless there's an opt-in alert prompt (which isn't on the table and would be a terrible UX/business decision), virtually every user will have some metrics collected before they're able to opt out. It also seems to me that most users likely won't ever be aware there is something to opt out of, if a Settings.app switch is enough.
1ec5 commentedon May 12, 2015
Filed as #1519.
bleege commentedon May 12, 2015
Re-switched PRs so that #1520 is now the primary as it has the correct flow of
dev_branch-->master-->ios-b1.#1516 - Renaming setShowsOptOutInApp to setMapboxMetricsEnabledSettin…
bleege commentedon May 12, 2015
Just implemented the fixes that @1ec5 suggested in his code review from last night. The technical core of this issue has now been implemented and tested. The ℹ️ issue is tracked elsewhere, so once Travis approves we should be good to merge this into
masterand then cherrypick back toios-b1if we're feeling good about things.bleege commentedon May 12, 2015
Travis just approved and I merged #1520 into
master. It's ready to be merged intoios-b1should we choose. I'll leave this issue open to remind us to think about this later today.#1516 - Adding public setter method to MGLAccountManager.h. Fixing ex…
1ec5 commentedon May 12, 2015
If we take these changes for beta 1, we should update the wiki and mapbox/mapbox-gl-ios to point out the extra step when implementing the opt-out in-app.