Bug 254938 - REGRESSION (iOS 16.4): Our page crashes on page load due to service workers
Summary: REGRESSION (iOS 16.4): Our page crashes on page load due to service workers
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Service Workers (show other bugs)
Version: Safari 16
Hardware: All iOS 16
: P2 Critical
Assignee: youenn fablet
URL:
Keywords: BrowserCompat, InRadar
Depends on: 245425
Blocks:
  Show dependency treegraph
 
Reported: 2023-04-03 13:13 PDT by Jesper van den Ende
Modified: 2023-04-11 19:50 PDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jesper van den Ende 2023-04-03 13:13:49 PDT
Since iOS 16.4 was released we started getting reports that our site crashes on page load.
After trial and error I managed to find out that it was the service worker causing this.
Though I'm not sure what exactly it is that makes our page crash, since other sites with a service worker seem fine.
That said our service worker does not seem that complex: https://narrow.one/js/sw.js

For now I have disabled the service worker in production using `navigator.userAgent.includes("AppleWebKit/605.1.15")`,
but it can be enabled using /?serviceWorker=true.

So the steps to reproduce are:
1. Visit https://narrow.one/?serviceWorker=true
2. Wait a few seconds for the service worker to install
3. Reload the page.

I've verified these steps on both iOS/Safari, iOS/Chrome and macOS/Safari.

I hope that helps. Let me know if you have any questions.
Comment 1 Radar WebKit Bug Importer 2023-04-04 02:11:53 PDT
<rdar://problem/107602025>
Comment 2 Alexey Proskuryakov 2023-04-04 09:32:56 PDT
Reproduces on macOS too.
Comment 3 Peter Elliott 2023-04-04 12:21:15 PDT
appears to reproduce in 16.5 beta on macOS, but not in safari technology preview 166
Comment 4 Karl Dubost 2023-04-04 20:09:45 PDT
After running regression testing
This has been regressed by https://github.com/WebKit/WebKit/commit/599d00ac6774a1c036faa6f6adf3f96fb95d337f

Bug 245425
Comment 5 youenn fablet 2023-04-05 13:04:15 PDT
Pull request: https://github.com/WebKit/WebKit/pull/12418
Comment 6 EWS 2023-04-06 08:48:00 PDT
Committed 262666@main (96af04c5e6b2): <https://commits.webkit.org/262666@main>

Reviewed commits have been landed. Closing PR #12418 and removing active labels.
Comment 7 EWS 2023-04-11 19:50:12 PDT
Committed 259548.632@safari-7615-branch (e727241d7c3d): <https://commits.webkit.org/259548.632@safari-7615-branch>

Reviewed commits have been landed. Closing PR #542 and removing active labels.