[Weekly Privacy Report] privacy_report_notification_not_sent event is never emitted when notifications are disabled at system level
Categories
(Firefox for Android :: Experimentation and Telemetry, defect)
Tracking
()
People
(Reporter: apetridean, Assigned: towhite)
References
(Blocks 1 open bug)
Details
Prerequisites
Firefox Beta installed with Enhanced Tracking Protection (ETP) set to Standard.
Tracking history populated (e.g., browsed sites with trackers, contentblocking.trackers_blocked_count > 0).
Glean Debug Drawer enabled with a custom debug tag;
In Android System Settings, disable all notifications for Firefox:
Settings > Apps > Firefox Beta > Notifications > All Firefox notifications = OFF.
Steps to Reproduce
- Launch Firefox Beta.
- Navigate to Settings > Secret Settings > Glean Debug Drawer, select metrics, and tap Send Ping.
- Inspect the ping in the Glean Debug Viewer and confirm that tracking_protection.privacy_report_notification_availability is recorded as "app_notifications_disabled".
- Advance device system clock by 7+ days, open Firefox (app resume), and send it to the background.
- In Glean Debug Drawer, select events and tap Send Ping (or monitor the incoming privacy-report-notification ping).
- Inspect the resulting ping in the Glean Debug Viewer.
Expected behavior
No system notification is displayed in the Android shade (correct UI suppression).
The worker executes and submits telemetry recording the failed send attempt:
Exactly one tracking_protection.privacy_report_notification_worker_ran event.
Exactly one tracking_protection.privacy_report_notification_not_sent event with extra.reason = "app_notifications_disabled" (or "notifications_disabled").
Metric counter tracking_protection.privacy_report_notification_worker_run_count increments by 1.
tracking_protection.privacy_report_notification_sent is not present.
Actual behavior
No system notification is displayed (as expected).
No tracking_protection telemetry events are recorded.
Neither privacy_report_notification_worker_ran nor privacy_report_notification_not_sent is emitted.
No privacy-report-notification custom ping is generated.
In the metrics ping, tracking_protection.privacy_report_notification_worker_scheduled remains false.
Telemetry / Glean Evidence
Availability Confirmed (metrics ping):
Document ID: 3f982f29-bf11-4c41-af58-0ffb8cc67454
tracking_protection.privacy_report_notification_availability: "app_notifications_disabled"
contentblocking.trackers_blocked_count: 87
tracking_protection.privacy_report_notification_worker_scheduled: false
** Trigger Executed (events ping):**
Document ID: 2622b1db-85ba-45f9-a307-e0c42200938e (and 71ce5165-bcd1-49d5-becb-bad5faea4dcd)
Shows normal session and UI navigation events (toolbar.button_tapped, events.browser_menu_action), but the tracking_protection category is completely missing.
Device information
- Firefox version: Nightly 161.0a1from 27.10.2026, Firefox 160.0a1
- Android device model: Xiaomi Pad5 (Android 13), Pixel 7Pro (Android 17)
Thanks Adina! This looks to be working as intended; the mismatch is between what the telemetry is designed to capture and what the test plan expected, so no code change is needed.
What's happening
PrivacyReportNotificationScheduler re-evaluates every time the app resumes. When app-level notifications are off, it records the reason in privacy_report_notification_availability and cancels the worker rather than scheduling it. The worker_ran and not_sent events and the privacy-report-notification ping are only recorded from inside the worker, so with no worker run there is nothing to emit. The values in comment 0 (availability = "app_notifications_disabled", worker_scheduled = false, no tracking_protection events) are exactly what that path produces.
The not_sent event covers a narrower case: the worker was already scheduled, and notifications were turned off before it fired. Users with notifications off from the start are tracked via the availability metric instead, which avoids waking the app weekly for them.
Expected results for the steps as written
- No notification shown.
- Metrics ping:
availability = "app_notifications_disabled",worker_scheduled = false. - No
worker_ranornot_sentevents, noprivacy-report-notificationping.
Steps to reach the not_sent path
- With Firefox notifications enabled, complete onboarding and land on the home screen. Send a metrics ping and confirm
worker_scheduled = true. - Swipe Firefox away from Recents and leave it closed until the worker has run.
- In Android Settings, turn off all notifications for Firefox Beta.
- Advance the clock 7+ days, landing between 12:00 and 17:00 local time, and wait for WorkManager to run the worker. Logcat shows
Not sending the privacy report notificationwhen it does. - Open Firefox and send an events ping.
Expected: one worker_ran event, one not_sent event with reason = "app_notifications_disabled", worker_run_count incremented by 1, one privacy-report-notification ping, no notification shown.
| Reporter | ||
Comment 2•27 days ago
|
||
Thanks for the explanation, Tom!
That makes complete sense. The test case suggested that not_sent should be triggered whenever notifications were turned off, which caused the confusion on our end.
Since no notification is displayed and the availability metric properly captures app_notifications_disabled, this is working as intended.
Closing this as RESOLVED / WORKSFORME. Thanks again!
Description
•