New issue
Advanced search Search tips

Issue 764957 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner:
Closed: Sep 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 1
Type: Bug-Regression



Sign in to add a comment

Unable to add web page shortcut to Home screen on

Project Member Reported by nyquist@chromium.org, Sep 13 2017

Issue description

Chrome Version: 61.0.3163.81 (Stable)
OS Version: Android 8.0.0 Build/OPR1.170623.026
Device: Pixel C tablet
URLs (if applicable) : https://allo.google.com/web
Other browsers tested:
Chrome (Play Store Beta) 61.0.3163.72: FAIL
Chrome (Play Store Dev) 62.0.3202.19: FAIL
Chrome (Play Store Canary) 63.0.3213.0: FAIL

What steps will reproduce the problem?

(1) Go to https://allo.google.com/web
(2) Tap Menu -> Add to Home screen
(3) See that the title is "Allo for web" in the "Add to Home screen" dialog. [add-to-homescreen-dialog.png]
(4) Tap "Add"
(5) See that a toast appears with the text: "Allo for web was added to your Home screen" [added-to-homescreen-toast.png]

What is the expected result?

An icon was added to the home screen.

What happens instead?

Nothing is added to the home screen.

Other notes?

(A) Really this does not work for any URL, so you could also try URLs like: https://en.m.wikipedia.org/wiki/Main_Page
(B) This is using the default Google Pixel Launcher version 7.1.1-3705938
(C) This works fine on a Google Pixel phone, where the new ShortcutManager / pin shortcut popup is used.
(D) The toast that pops up seems to be requested from org.chromium.chrome.browser.ShortcutHelper#showAddedToHomescreenToast(String title).
(E) I've definitely done this before, but I don't know if this is related to a Chrome upgrade or an OS upgrade (to Android O).
 
add-to-homescreen-dialog.png
78.1 KB View Download
added-to-homescreen-toast.png
117 KB View Download
Any version of Chrome that isn't compiled against the O SDK will not be able to add anything to homescreen on O. AFAIK we aren't shipping O compatible builds to the Play Store yet, so that means any Chrome version from the Play Store (i.e. other than M58 which ships with O) won't be able to add anything to homescreen.

The old add to homescreen API (a broadcast intent) was disabled in O and replaced with a new explicit API that requires compiling against the O SDK to access. Can you try uninstalling all Chrome updates to downgrade it back to the stock M58 that shipped with O and check the behaviour again?

This probably worked on your Pixel device because it had the default Chrome 58 that came with O rather than an update from the Play Store.
No, it works fine in Chrome Stable 61.0.3163.81 on my Pixel phone. It's running Android 8.0.0 Build/OPR1.170623.026. See attached dialogs.

Going back to the system-installed 58.0.3029.125 Chrome Stable version on the Pixel C tablet does not work either in fact. It sounds like that might be because we are using an API that has been disabled in Android O?

I think I added the shortcut before I had Android O installed, and that used to work. Now (Android O) I seem to be unable to add any shortcuts.
phone-allo-for-web-shortcut-initial-dialog.png
120 KB View Download
phone-allo-for-web-shortcut-pin-dialog.png
100 KB View Download
Regarding the installed package, it is targeting Android O:
Package: com.android.chrome
Version: 61.0.3163.81 (316308152)
Min SDK: 24
Target SDK: 26

According to amineer@ it has been compiled with the Android O SDK.
Status: WontFix (was: Untriaged)
Thanks for confirming. This might be a Pixel C-specific O regression then, rather than one in Chrome (because it works on the Pixel). I'll cc you on the internal bug.
For completeness, the behaviour you're seeing is because we asked the launcher if it supported the Android O add to homescreen API, and it told us it wasn't supported, so we fell back to trying the old API. That's the Pixel C specific regression I'm referring to (the launcher saying it doesn't support ShortcutManager#requestPinShortcut).

Sign in to add a comment