-
Notifications
You must be signed in to change notification settings - Fork 1.3k
For #10261: PWA Telemetry #11859
For #10261: PWA Telemetry #11859
Conversation
Codecov Report
@@ Coverage Diff @@
## master #11859 +/- ##
============================================
- Coverage 28.43% 28.35% -0.09%
Complexity 1033 1033
============================================
Files 418 418
Lines 16761 16826 +65
Branches 2180 2190 +10
============================================
+ Hits 4766 4771 +5
- Misses 11650 11710 +60
Partials 345 345
Continue to review full report at Codecov.
|
328ece5
to
516f7c0
Compare
Waiting on mozilla-mobile/android-components#7493 to be merged |
516f7c0
to
7a7b8c6
Compare
Request for data collection review formAll questions are mandatory. You must receive review from a data steward peer on your responses to these questions before shipping new data collection.
|
app/src/main/java/org/mozilla/fenix/components/toolbar/BrowserToolbarController.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/org/mozilla/fenix/components/toolbar/BrowserToolbarController.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/org/mozilla/fenix/components/toolbar/BrowserToolbarController.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/org/mozilla/fenix/shortcut/PwaOnboardingDialogFragment.kt
Outdated
Show resolved
Hide resolved
68eaf19
to
520d7eb
Compare
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.
Should events also be added for when the actual PWA is in foreground?
app/src/main/java/org/mozilla/fenix/components/metrics/Metrics.kt
Outdated
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.
data-review+ only, pending questions about the time ms collected - is that useful to DS?
Data Review Form (to be filled by Data Stewards)
- Is there or will there be documentation that describes the schema for the ultimate data set in a public, complete, and accurate way?
Yes, these probes are documented in metrics.md
- Is there a control mechanism that allows the user to turn the data collection on and off?
Yes, this telemetry is controlled by Fenix data settings
-
If the request is for permanent data collection, is there someone who will monitor the data over time?
Has expiry -
Using the category system of data types on the Mozilla wiki, what collection type of data do the requested measurements fall under?
Type 2, interaction with PWA
- Is the data collection request for default-on or default-off?
Default on
- 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
- Is the data collection covered by the existing Firefox privacy notice?
yes
- 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
- Does the data collection use a third-party collection tool? If yes, escalate to legal.
No
app/src/main/java/org/mozilla/fenix/components/metrics/Metrics.kt
Outdated
Show resolved
Hide resolved
app/src/main/java/org/mozilla/fenix/components/metrics/Metrics.kt
Outdated
Show resolved
Hide resolved
app/metrics.yaml
Outdated
extra_keys: | ||
duration: | ||
description: | | ||
The current time in ms when the intent was foregrounded. |
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.
Is the idea that DS will do this calculation themselves? Can you verify with Marissa that that is the case, or if the client should calculate that duration between foreground/background when backgrounding the activity? Personally I'd prefer for the client to do this duration calculation and send that number, rather than sending 2 timestamps.
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.
This is all done in AC and they don't want calculations like this to happen 😢
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.
Also we haven't defined what time we want between foreground/bg, so Marissa can change it as needed without needing a code fix
520d7eb
to
3cef53d
Compare
Changes changes changes! Let's move everything to AC :j
app/src/main/java/org/mozilla/fenix/customtabs/ExternalAppBrowserFragment.kt
Show resolved
Hide resolved
ca9687d
to
2214d0b
Compare
AC changes didn't make it into 52.0.0, so this needs to wait to merge so it doesn't break when we cut for beta tonight |
Track events for add to homescreen and install. Map PWA facts to events
Add events pings to fragments Supress long method for events Move install event to AC and collect facts Retrieve fg and bg events from Facts. Do not track intent fg/bg events, only views
…nal app fragment. Track foreground and bg locally in fenix, and route install and home screen taps from AC facts
2214d0b
to
566ef33
Compare
For #10261
Depends on mozilla-mobile/android-components#7493 and mozilla-mobile/android-components#7805
Events in Fenix:
Event.ProgressiveWebAppOpenFromHomescreenTap
-> map toHOMESCREEN_ICON_TAP
Event.ProgressiveWebAppForeground
-> map toENTER_FOREGROUND
Event.ProgressiveWebAppBackground
-> map toENTER_BACKGROUND
Event.ProgressiveWebAppInstallAsShortcut
: An event ping when tapping the ‘Install’ menu. -> map to `ProgressiveWebAppFacts.Items.INSTALL_SHORTCUTDistinguish between ‘Install’ PWA vs ‘Add to homescreen’ shortcut.There is no differentiation here ATM. In AC, we treat both as creating a shortcut and then map that to either the PWA or "bookmark" when it's opened. This install ping is added in AC instead of fenix (see below)Events needing AC
Facts
:ProgressiveWebAppFacts.Items.ENTER_FOREGROUND
: An event ping when putting a PWA to the foreground with the current system timeProgressiveWebAppFacts.Items.ENTER_BACKGROUND
: An event ping when putting a PWA to the background with the current system timeProgressiveWebAppFacts.Items.HOMESCREEN_ICON_TAP
: An event ping when tapping PWA homescreen icons.ProgressiveWebAppFacts.Items.INSTALL_SHORTCUT
: An event ping when installing a PWA.Pull Request checklist
After merge
To download an APK when reviewing a PR: