Skip to content
This repository has been archived by the owner on Feb 20, 2023. It is now read-only.

For #11118: Add toggle states to metrics ping #11211

Merged
merged 1 commit into from
Jun 4, 2020

Conversation

sblatz
Copy link
Contributor

@sblatz sblatz commented Jun 3, 2020

Pull Request checklist

  • Tests: This PR includes thorough tests or an explanation of why it does not
  • Screenshots: This PR includes screenshots or GIFs of the changes made or an explanation of why it does not
  • Accessibility: The code in this PR follows accessibility best practices or does not include any user facing features. In addition, it includes a screenshot of a successful accessibility scan to ensure no new defects are added to the product.

After merge

  • Milestone: Make sure issues finished by this pull request are added to the milestone of the version currently in development.

To download an APK when reviewing a PR:

  1. click on Show All Checks,
  2. click Details next to "Taskcluster (pull_request)" after it appears and then finishes with a green checkmark,
  3. click on the "Fenix - assemble" task, then click "Run Artifacts".
  4. the APK links should be on the left side of the screen, named for each CPU architecture

@sblatz
Copy link
Contributor Author

sblatz commented Jun 3, 2020

Request for data collection review form

All questions are mandatory. You must receive review from a data steward peer on your responses to these questions before shipping new data collection.

  1. What questions will you answer with this data?
  • What settings preferences do users have?
  • What % of our users have show_search_suggestions enabled?
  • What % of our users have remote_debugging enabled?
  • What % of our users have telemetry enabled?
  • What % of our users have tracking_protection enabled?
  • What % of our users have search_bookmarks enabled?
  • What % of our users have search_browsing_history enabled?
  • What % of our users have search_clipboard_suggestion enabled?
  • What % of our users have search_shortcuts enabled?
  • What % of our users have open_links_in_private_tab enabled?
  • What % of our users have signed into FxA?
  • What % of our users sync certain items via FxA?
  • What % of our users have voice_search enabled?
  • What % of our users have search_suggestions_private enabled?
  • What % of our users have top vs. bottom toolbar?
  • What % of our users have accessibility_services enabled?
  1. Why does Mozilla need to answer these questions? Are there benefits for users? Do we need this information to address product or business requirements?
  • It is crucial we know what types of user segments we have so we can prioritize certain features. It is also important for helping us drive decisions around resourcing. This data will help us better slice our user population & figure out retention metrics.
  1. What alternative methods did you consider to answer these questions? Why were they not sufficient?
  • We currently have preferenceToggled events for most of these. Unfortunately these queries are incredibly expensive to run and can often be error prone. Because of this, we are approaching it with a simpler metrics ping.
  1. Can current instrumentation answer these questions?
  • No, see above.
  1. List all proposed measurements and indicate the category of data collection for each measurement, using the Firefox data collection categories on the found on the Mozilla wiki.
  • All data is Category 2.
  1. How long will this data be collected?
  • Until 09/01/2020
  1. What populations will you measure?
  • All release, beta, and nightly users with telemetry enabled.
  1. Please provide a general description of how you will analyze this data.
  • Glean / Amplitude
  1. Where do you intend to share the results of your analysis?
  • Only on Glean, Amplitude and with mobile teams.

@codecov-commenter
Copy link

codecov-commenter commented Jun 3, 2020

Codecov Report

Merging #11211 into master will increase coverage by 0.05%.
The diff coverage is 63.88%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #11211      +/-   ##
============================================
+ Coverage     20.49%   20.55%   +0.05%     
  Complexity      680      680              
============================================
  Files           372      372              
  Lines         15415    15478      +63     
  Branches       2075     2090      +15     
============================================
+ Hits           3160     3182      +22     
- Misses        11958    11994      +36     
- Partials        297      302       +5     
Impacted Files Coverage Δ Complexity Δ
...la/fenix/components/metrics/GleanMetricsService.kt 12.96% <60.60%> (+4.27%) 3.00 <1.00> (ø)
.../src/main/java/org/mozilla/fenix/utils/Settings.kt 68.60% <100.00%> (+0.25%) 33.00 <0.00> (ø)
...ozilla/fenix/collections/CollectionCreationView.kt 34.61% <0.00%> (-1.00%) 6.00% <0.00%> (ø%)
...a/org/mozilla/gecko/search/SearchWidgetProvider.kt 1.35% <0.00%> (-0.88%) 1.00% <0.00%> (ø%)
...nix/collections/CollectionCreationBottomBarView.kt 97.50% <0.00%> (ø) 8.00% <0.00%> (ø%)
...ix/home/sessioncontrol/SessionControlController.kt 70.79% <0.00%> (+0.88%) 0.00% <0.00%> (ø%)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9272026...8b44b5c. Read the comment docs.

@sblatz sblatz force-pushed the telem-in-metrics branch from f76f9d9 to 5f06089 Compare June 3, 2020 22:18
@sblatz sblatz requested a review from liuche June 3, 2020 22:18
@sblatz sblatz added the needs:data-review PR is awaiting a data review label Jun 3, 2020
@sblatz sblatz force-pushed the telem-in-metrics branch 5 times, most recently from 80ae8f2 to 37aa0c0 Compare June 3, 2020 23:04
Copy link
Contributor

@liuche liuche left a comment

Choose a reason for hiding this comment

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

data + code review r+wn

glad these are going to be collected in metrics ping rather than events!

Data Review Form (to be filled by Data Stewards)

  1. Is there or will there be documentation that describes the schema for the ultimate data set in a public, complete, and accurate way?

Yes, updates metrics.md

  1. Is there a control mechanism that allows the user to turn the data collection on and off?

Yes, telemetry settings in Fenix

  1. If the request is for permanent data collection, is there someone who will monitor the data over time?

Expires

  1. Using the category system of data types on the Mozilla wiki, what collection type of data do the requested measurements fall under?

Type 2, settings

  1. Is the data collection request for default-on or default-off?

default on

  1. Does the instrumentation include the addition of any new identifiers (whether anonymous or otherwise; e.g., username, random IDs, etc. See the appendix for more details)?

No, app settings and accessibility settings

  1. Is the data collection covered by the existing Firefox privacy notice?

yes

  1. Does there need to be a check-in in the future to determine whether to renew the data? (Yes/No) (If yes, set a todo reminder or file a bug if appropriate)**

No, has expiry

  1. Does the data collection use a third-party collection tool? If yes, escalate to legal.

no

app/metrics.yaml Outdated Show resolved Hide resolved
app/metrics.yaml Show resolved Hide resolved
app/metrics.yaml Show resolved Hide resolved
app/metrics.yaml Show resolved Hide resolved
app/metrics.yaml Outdated Show resolved Hide resolved
@@ -331,6 +331,11 @@ class Settings private constructor(
default = false
)

val useStandardTrackingProtection by booleanPreference(
Copy link
Contributor

Choose a reason for hiding this comment

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

Oh, so did we not have this before?

It's a little weird that this isn't a radio preference...in theory does that mean that the settings could get messed up and more than one of these could be selected? 🤔 (out of scope for this bug I know)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Let me touch base with Emily about this. I think the Radio Group does prevent these from getting sent to multiple true vales.

Copy link
Contributor

Choose a reason for hiding this comment

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

docs/metrics.md Outdated
@@ -247,6 +247,21 @@ The following metrics are added to the ping:
| perf.awesomebar.session_suggestions |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Duration of a session awesomebar suggestion query. |[1](https://github.com/mozilla-mobile/fenix/pull/10276#pullrequestreview-411101979)||2020-09-15 |
| perf.awesomebar.shortcuts_suggestions |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Duration of a shortcuts awesomebar suggestion query. |[1](https://github.com/mozilla-mobile/fenix/pull/10276#pullrequestreview-411101979)||2020-09-15 |
| perf.awesomebar.synced_tabs_suggestions |[timing_distribution](https://mozilla.github.io/glean/book/user/metrics/timing_distribution.html) |Duration of a synced tabs awesomebar suggestion query. |[1](https://github.com/mozilla-mobile/fenix/pull/10276#pullrequestreview-411101979)||2020-09-15 |
| preferences.accessibility_services |[string_list](https://mozilla.github.io/glean/book/user/metrics/string_list.html) |Whether or not the user has touch exploration or switch services enabled default: "" |[1](https://github.com/mozilla-mobile/fenix/pull/11211)||2020-09-01 |
Copy link
Contributor

Choose a reason for hiding this comment

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

thank goodness for glean 🙏 and not having to write this manually

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
needs:data-review PR is awaiting a data review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants