Open Bug 1828304 Opened 2 years ago Updated 2 years ago

Open Library "Sign in with google" popup is blank, when viewed as "installed" web app

Categories

(Fenix :: PWA, defect, P5)

All
Android

Tracking

(Not tracked)

People

(Reporter: dholbert, Unassigned)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

Steps to reproduce

  1. Visit https://testing.openlibrary.org/ in Firefox for Android
  2. In the Firefox menu, choose "Install", and tap "Add to home screen"
  3. Launch the newly-installed version of Open Library from your home screen.
  4. Tap the Open Library's hamburger menu at top right.
  5. Choose "Sign in with Google"

Expected behavior

A "sign in with google" full-screen popup should appear.

Actual behavior

The popup appears, but it's blank.

Device information

  • Firefox version: 114.0a1 Nightly 2023-04-15
  • Android device model: Pixel 6a
  • Android OS version: 13

Any additional information?

If I perform the STR in Chrome (using "install" etc), then I get expected results.

If I perform the STR directly in Firefox (a regular Firefox tab rather than the PWA), then I get expected results; the sign-in-with-google page opens properly in a new tab. It's only the "installed" PWA version that has this issue.

If I use about:debugging on desktop to watch what's going on when I follow the STR on my phone, and I compare doing the STR in a regular Firefox tab (fine) vs. the PWA approach (broken), I notice something interesting:

  • From a regular Firefox tab, I get one new tab that appears in the about:debugging tab list, for the sign-in-with-Google popup.
  • vs. from the PWA, I get two new tabs that simultaneously appear in the about:debugging tab list, for the sign-in-with-Google popup.

Of the two tabs that appear with the PWA, the foreground one has an essentially empty DOM -- so, no wonder it's blank -- and it shows this in its web console:

Uncaught TypeError: can't access property "postMessage", window.opener is null

...vs the other tab (which I can't visually see anywhere but I can inspect in about:debugging) seems to have a proper DOM that seems the same as the one that I get for the sign-in-with-google popup from a regular Firefox tab.

Attached video screencast of bug (deleted) —

I should also note: once you've dismissed the blank popup (and returned to looking at the Open Library PWA main page), subsequent taps on the "Sign in with Google" button don't work anymore. You can see this in my screencast at ~0:08s (after I've dismissed the blank popup and then try to tap the button again).

I suspect this has to do with the fact that 2 popups were somehow spawned (per comment 1), and the one that works is just hidden for some reason, and it's still there in the background somewhere even after you dismiss the visible broken/blank one (as can be confirmed on about:debugging from a USB-connected desktop machine) .

The severity field is not set for this bug.
:jonalmeida, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(jonalmeida942)

This is a PWA bug that might be because of a new window request that is not displayed correctly as comment 3 suggests.

A possible workaround is to visit the site in the main browser, sign-in and then use the homescreen shortcut to launch the app from the shortcut.

Adding this to the custom-tab-refresh meta, because fixing this would make custom tabs better too.

Severity: -- → S3
Flags: needinfo?(jonalmeida942)
Priority: -- → P5
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: