New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 691898 link

Starred by 5 users

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 1
Type: Bug



Sign in to add a comment

Messaging for notifications disabled at system level in site settings

Project Member Reported by awdf@chromium.org, Feb 14 2017

Issue description

Reported by rolfe@:
"For location we have messaging in page info/site settings to tell users to turn location back on again but currently don't do anything for Notifications."

Since Android N, we can actually check if notifications for Chrome are enabled at the system level (via NotificationManager.areNotificationsEnabled) - so we could do something similar to location permission messaging in our notification site settings, and perhaps provide a shortcut to android settings to re-enable them.
 

Comment 2 by rolfe@chromium.org, Feb 15 2017

Cc: k...@chromium.org
+ktam as FYI for later triage

Comment 3 by k...@chromium.org, Feb 15 2017

Thanks Anita. Do you know if we have any metrics about how many users have notifications disabled? That would seem like a good first step if we don't.

Comment 4 by peter@chromium.org, Feb 15 2017

This is a great idea!

The Notifications.AppNotificationStatus UMA tells me that 8.5% of users(!!) has disabled notifications for Chrome at the system level. There's been a very strong increase since December 7th, which I can't explain but definitely is something we should look in to.

( Issue 683292  tracks adding this metric for WebAPKs as well.)

Comment 5 by rolfe@chromium.org, Feb 15 2017

ktam - I think we have location disabled metrics too right? Would be interesting to compare.

Comment 6 by k...@chromium.org, Feb 15 2017

Cc: dah...@chromium.org
The histogram code seems to imply that we can tell if users disabled notifications post-KitKat, is that correct?

And yep, if you look at user counts, you get ~6.7% of users who have disabled notifications though this will be biased to users who use web notifications.

+dahlke, do you know if we track if notifications are blocked for downloads? Might be interesting to see if we need a UI for downloads to tell users they need to enable notifications to see download progress.

Comment 7 by k...@chromium.org, Feb 15 2017

(and yes, we have location disabled metrics but it is very low if I recall since it's by default enabled before M)

Comment 8 by peter@chromium.org, Feb 15 2017

Yes, we make a best effort to determine availability, but it's only supported on KitKat and beyond. Android added an actual API for this in N, but we're not using that yet.

Tracking whether notifications are disabled for other purposes too sounds like a great idea to me.

Comment 9 by rolfe@chromium.org, Feb 15 2017

Cc: owe...@chromium.org
Adding owemcn@ for triage when things settle (as peter@'s team will likely handle UI changes.)

ktam@ for FYI on front-end Chrome on Android changes, but feel free to remove yourself if the bug becomes bothersome.
Thanks! Great to track this messaging, the broader issue of why people are disabling very concerning and I really hope we can get to the bottom of it very soon and get mitigations in place!
Could also integrate messaging into downloads snackbar (and other places if applicable, such as Casting/media playing perhaps.)

Comment 12 by rolfe@chromium.org, Mar 27 2017

Mocks for basic 1:1 matching with location sent through UI Review:
https://groups.google.com/a/google.com/forum/#!topic/chrome-ui-review/NBWIzzRnci4

Comment 13 by rolfe@chromium.org, Mar 31 2017

Cc: chowse@chromium.org
Implementation deck draft started (getting a jumpstart on things)
https://docs.google.com/a/google.com/presentation/d/19hwdQe_xcW8dCYlsV1ca6OrZ_BY1A2xcLkLkuj-VpNo/edit?usp=sharing

Comment 14 by rolfe@chromium.org, Apr 10 2017

UI Review asked for a revisit of strings. I'm meeting with srahim@ to figure that out.

Comment 15 by rolfe@chromium.org, Apr 14 2017

Approved by UI Review. Ready for eng. If there's no eng work done in the next 3-six months, check in with chowse@ or UX for the latest status on how we're treating page info. (This proposal may be out of date.)

Some non-blocking comments from ainslie@:
- Because of the way the strings are written, we'll need to flag this as something to check in on with every major Android release. 
- The alert icon might be too strong

Approved mocks:
https://folio.googleplex.com/chrome-ux/mocks/428-o-notifications/041117_Messaging#%2F01_Messaging.png%3Fz=width

Implementation deck (if needed) when build is ready:
https://docs.google.com/presentation/d/19hwdQe_xcW8dCYlsV1ca6OrZ_BY1A2xcLkLkuj-VpNo/edit#slide=id.g184b91d95f_2_0

Comment 16 by rolfe@chromium.org, Apr 14 2017

Cc: -rolfe@chromium.org

Comment 17 by k...@chromium.org, Apr 18 2017

Great thanks! It's on the frontend tracker as eng ready.

Do we want to do anything for when we attempt to show notifications, e.g. when downloading?

Comment 18 by k...@chromium.org, Feb 15 2018

Cc: -k...@chromium.org
Project Member

Comment 19 by bugdroid1@chromium.org, Jul 12

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/dfb08c4ccef342639df17f6a423643df1784b767

commit dfb08c4ccef342639df17f6a423643df1784b767
Author: Anita Woodruff <awdf@chromium.org>
Date: Thu Jul 12 08:05:32 2018

[Android PageInfo] Refactor PageInfoController to enable testing

- Extracted PermissionParamsListBuilder from PageInfoController
to handle all the permission-related logic when displaying
permissions in page info. This new class requires fewer
hard-to-unit-test dependencies so its logic can now be tested.

Bug: 691898
Change-Id: Iddbea30642a0dc31dae26110381e2dad9feb2af4
Reviewed-on: https://chromium-review.googlesource.com/1103564
Commit-Queue: Anita Woodruff <awdf@chromium.org>
Reviewed-by: Tibor Goldschwendt <tiborg@chromium.org>
Reviewed-by: Ted Choc <tedchoc@chromium.org>
Cr-Commit-Position: refs/heads/master@{#574502}
[modify] https://crrev.com/dfb08c4ccef342639df17f6a423643df1784b767/chrome/android/java/src/org/chromium/chrome/browser/page_info/PageInfoController.java
[add] https://crrev.com/dfb08c4ccef342639df17f6a423643df1784b767/chrome/android/java/src/org/chromium/chrome/browser/page_info/PermissionParamsListBuilder.java
[add] https://crrev.com/dfb08c4ccef342639df17f6a423643df1784b767/chrome/android/java/src/org/chromium/chrome/browser/page_info/SystemSettingsActivityRequiredListener.java
[modify] https://crrev.com/dfb08c4ccef342639df17f6a423643df1784b767/chrome/android/java_sources.gni
[add] https://crrev.com/dfb08c4ccef342639df17f6a423643df1784b767/chrome/android/junit/src/org/chromium/chrome/browser/page_info/PermissionParamsListBuilderUnitTest.java

Project Member

Comment 20 by bugdroid1@chromium.org, Jul 16

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d

commit bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d
Author: Anita Woodruff <awdf@chromium.org>
Date: Mon Jul 16 12:00:51 2018

[Android UI] Messaging for app notifications being off in PageInfo

- This is the first part of some UI changes to inform users when
notifications are disabled for the whole app.

- The feature is hidden behind a flag in about://flags ('Enable
app notification status messaging')

R=bauerb@chromium.org, peter@chromium.org

Bug: 691898
Change-Id: I967eca469b3a462d5f8e1e11df3ef8716884806a
Reviewed-on: https://chromium-review.googlesource.com/1089062
Reviewed-by: Tommy Nyquist <nyquist@chromium.org>
Reviewed-by: Bernhard Bauer <bauerb@chromium.org>
Reviewed-by: Peter Beverloo <peter@chromium.org>
Commit-Queue: Anita Woodruff <awdf@chromium.org>
Cr-Commit-Position: refs/heads/master@{#575230}
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/base/android/java/src/org/chromium/base/ApiCompatibilityUtils.java
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/chrome/android/java/src/org/chromium/chrome/browser/ChromeFeatureList.java
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/chrome/android/java/src/org/chromium/chrome/browser/page_info/PermissionParamsListBuilder.java
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/chrome/android/junit/src/org/chromium/chrome/browser/page_info/PermissionParamsListBuilderUnitTest.java
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/chrome/browser/about_flags.cc
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/chrome/browser/android/chrome_feature_list.cc
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/chrome/browser/flag_descriptions.cc
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/chrome/browser/flag_descriptions.h
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/chrome/common/chrome_features.cc
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/chrome/common/chrome_features.h
[modify] https://crrev.com/bfcd1e5a550464c20cdf5dcb81a2998fa5e7bf7d/tools/metrics/histograms/enums.xml

Labels: -Pri-3 Pri-2
Owner: awdf@chromium.org
Status: Started (was: Available)
Project Member

Comment 22 by bugdroid1@chromium.org, Jul 18

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/76445864dbc311daf00b2afebdda97c52ff18c10

commit 76445864dbc311daf00b2afebdda97c52ff18c10
Author: Anita Woodruff <awdf@chromium.org>
Date: Wed Jul 18 14:20:48 2018

[Android Site Settings] Warn if notifications disabled

This CL has two effects when notifications are disabled for Chrome:

  1. Adds a link to 'Turn on permissions for Chrome' to the
  site settings of websites that have allowed/blocked notifications.

  2. Replaces Settings > Site Settings > Notifications page with a
  link to 'Turn on permission for Chrome in Android Settings'.

See screenshots at https://goo.gl/hVqEwN

These effects are guarded behind a flag in about://flags ('Enable
app notification status messaging').

Bug: 691898
Change-Id: Ib7b59905cfc4edcc2a80cd6aad45700714502abc
Reviewed-on: https://chromium-review.googlesource.com/1140633
Reviewed-by: Theresa <twellington@chromium.org>
Commit-Queue: Anita Woodruff <awdf@chromium.org>
Cr-Commit-Position: refs/heads/master@{#576038}
[add] https://crrev.com/76445864dbc311daf00b2afebdda97c52ff18c10/chrome/android/java/src/org/chromium/chrome/browser/preferences/website/NotificationCategory.java
[modify] https://crrev.com/76445864dbc311daf00b2afebdda97c52ff18c10/chrome/android/java/src/org/chromium/chrome/browser/preferences/website/SingleWebsitePreferences.java
[modify] https://crrev.com/76445864dbc311daf00b2afebdda97c52ff18c10/chrome/android/java/src/org/chromium/chrome/browser/preferences/website/SiteSettingsCategory.java
[modify] https://crrev.com/76445864dbc311daf00b2afebdda97c52ff18c10/chrome/android/java_sources.gni

Owner: peter@chromium.org
Status: Assigned (was: Started)
This still needs some work to match the exact strings in the approved mocks in #15 (including when location is disabled), but the major pieces (to show a warning in page info & site settings when notifications are off) are now done, behind the flag.


Assigning to Peter to decide next steps here.
Hi,

I have prepared CL https://chromium-review.googlesource.com/c/chromium/src/+/1225975, where:

1. I remove APP_NOTIFICATION_STATUS_MESSAGE flag

2. disable ability of changing Notification settings inside Settings->Site Settings and inside Settings->Site Settings->Notifications when Notifications are disabled for app

3. show info about disabled Notifications in Page Popup

This looks like final step in this series (#23 say also about cleaning strings and I would be more than happy to do it)

Peter, could you decide what are/should be next steps for this?
Labels: -Pri-2 Pri-1
Friendly ping - can we make any decision here?
Friendly ping - could you at least point, who could make decision here?

Sign in to add a comment