Open Bug 1880000 Opened 2 years ago Updated 5 months ago

Unable to open PWA application by clicking PWA web page notification

Categories

(Firefox for Android :: Push, defect, P5)

Firefox 122
All
Android
defect

Tracking

()

People

(Reporter: ax+ch8ggaxy, Unassigned)

References

Details

Attachments

(1 obsolete file)

User Agent: Mozilla/5.0 (Android 13; Mobile; rv:122.0) Gecko/122.0 Firefox/122.0

Steps to reproduce:

  1. The PWA app pushed me a notification.
  2. Click on this notification.

Actual results:

Without opening the PWA, the web page which pushed me the notification is not opened in the browser, just open a blank page (home page) in the browser.

Expected results:

Click Notification to start the corresponding PWA application, or at least the corresponding web page.

See Also: → 1825910

Thank you for the report!

In order to confirm this ticket, please provide us more details:

  • which PWA app was it?
  • on which device did you encounter this issue on?
  • could you attach a short video for better understanding this (under 10MB)?
  1. X (twitter)
  2. vivo V2232A (Android 13)
  3. Same as the video in the issue 1825910.

Basically the same as issue 1825910, but I found this problem when I was using the pwa application. So this issue is more like a feature request than 1825910: if the corresponding website sending the notification is already installed as a pwa application, clicking on the notification should start the pwa application.

Attachment #9383181 - Attachment is obsolete: true

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

For more information, please visit BugBot documentation.

Flags: needinfo?(jboek)
Severity: -- → S3
Priority: -- → P5
Flags: needinfo?(jboek)
Duplicate of this bug: 1807430
Status: UNCONFIRMED → NEW
Ever confirmed: true

Could you verify this with the latest Firefox Nightly? I believe that this is fixed.

Flags: needinfo?(fxzxmicah)

Team is the issue fixed for FireFox Nightly? Still I could see that upon clicking push notifications its not redirected to PWA app instead it opens corresponding page in the new tab on the browser.

Expectation: Upon clicking push notification, it should open PWA application.

Version: 136.0a1 (Build #2016069927)
Phone: OnePlus 12
Android: 15

Duplicate of this bug: 1944539
Duplicate of this bug: 1796440

Redirect a needinfo that is pending on an inactive user to the triage owner.
:boek, since the bug has recent activity, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(fxzxmicah) → needinfo?(jboek)
Flags: needinfo?(jboek)

I have the same issue. Clicking on a notification does not bring up the PWA, but the normal browser on a blank page. Funny thing it that the PWA actually navigates to the URL like it should, the focusing is just not working. I am working on mbin.

The event listener calls this code:

            const promiseChain = self.clients.matchAll({type: "window"})
                .then((clientList) => {
                    if (clientList.length > 0) {
                        const client = clientList.at(0)
                        console.log("got a windowclient", client)
                        return client.navigate(url)
                            .then(client => {
                                console.log("navigated to url", url)
                                if (client && client.focus) {
                                    console.log("focusing to client")
                                    return client.focus();
                                }
                            })
                    }
                    if (self.clients.openWindow) {
                        console.log("opening new window")
                        return self.clients.openWindow(url);
                    }
                })

            event.waitUntil(promiseChain)

And I also tried this (same result):

            const promiseChain = self.clients.matchAll({type: "window", includeUncontrolled: true})
                .then((clientList) => {
                    if (clientList.filter(c => c.url).length > 0) {
                        const client = clientList.filter(c => c.url).at(0)
                        console.log("got a windowclient", client)
                        client.focus();
                        return client.navigate(url)
                    }
                    if (self.clients.openWindow) {
                        console.log("opening new window")
                        return self.clients.openWindow(url);
                    }
                })

            event.waitUntil(promiseChain)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: