WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
256280
Webkit PWA in Bad State After Opening in-PWA Webkit Tab
https://bugs.webkit.org/show_bug.cgi?id=256280
Summary
Webkit PWA in Bad State After Opening in-PWA Webkit Tab
goehdavi
Reported
2023-05-03 16:28:17 PDT
When we use window.open(url, "_blank") to bring up a new Safari tab/window with our PWA we see that the document.visibilityState is not updated and then returning to the PWA from the webview/tag results in fetch calls failing with Unhandled Promise Rejection: AbortError: Fetch is aborted. All fetch calls fail until the PWA is refreshed or closed and then opened again.
Attachments
Add attachment
proposed patch, testcase, etc.
goehdavi
Comment 1
2023-05-04 02:22:18 PDT
Upon further investigation it seems document.visibilityState is updated and that clicking Done from the Safari window does not cause the issue. It is only caused when handoff javascript executes in the other window (calls to window.opener.postMessage). We are unsure why this breaks all fetch calls.
Radar WebKit Bug Importer
Comment 2
2023-05-04 02:37:07 PDT
<
rdar://problem/108884055
>
goehdavi
Comment 3
2023-05-05 20:11:56 PDT
It appears the issue is related to the service worker becoming unresponsive. Our service worker has no fetch handler but all network calls failed when a redirect was performed in the new safari tab. Resetting the service worker (unregistering the service worker and then refreshing the page) resolved the issue.
youenn fablet
Comment 4
2023-05-09 07:38:39 PDT
Pull request:
https://github.com/WebKit/WebKit/pull/13639
EWS
Comment 5
2023-05-10 08:22:24 PDT
Committed
263901@main
(7a4f94728cde): <
https://commits.webkit.org/263901@main
> Reviewed commits have been landed. Closing PR #13639 and removing active labels.
EWS
Comment 6
2023-05-15 09:47:42 PDT
Committed
264076@main
(f1665400b299): <
https://commits.webkit.org/264076@main
> Reviewed commits have been landed. Closing PR #13740 and removing active labels.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug