YouTube-Music: App fails to load https://music.youtube.com with error
I’ve started getting a blank screen when opening the app. I built from source, enabled the inspector, and I’m seeing this error:
[Error] FetchEvent.respondWith received an error: TypeError: undefined is not an object (evaluating 'a.preloadResponse.then')
[Error] Cannot load https://music.youtube.com/.
[Error] Failed to load resource: FetchEvent.respondWith received an error: TypeError: undefined is not an object (evaluating 'a.preloadResponse.then') (music.youtube.com, line 0)
I can get it to go to any other page, including Youtube itself. But Youtube Music fails every time now.
About this issue
- Original URL
- State: open
- Created 2 years ago
- Comments: 20 (8 by maintainers)
Commits related to this issue
- Block service worker from loading, see #163 — committed to jscheel/YouTube-Music by jscheel 2 years ago
- Block service worker from loading, see #163 (#164) — committed to steve228uk/YouTube-Music by jscheel 2 years ago
1.3.3 seems to have fixed it for me. Thanks @jscheel @TimOliver 🙇!
I’m thinking we might have to add code to force-unregister the service workers that are already installed for people. I’ll make an update for that asap.
On Tue, May 3, 2022 at 9:19 AM mark-pictor-csec @.***> wrote:
Ok, I have a possible solution. It’s a hammer, but it seems to be working: I’ve set up a ContentRuleList in the WkWebView to prevent
sw.jsfrom loading. This prevents the service worker from registering, which in turn prevents the prefetching/caching of the code that seems to be broken for some reason. I need to clean up all my other test code to make sure this works consistently.Should Close this no, as I don’t see this anymore as well
Thanks @jscheel! I’ve merged your PR and released a new update. It should download the next time you open the app.
@mark-pictor-csec Try opening the app and downloading the latest update, and see if the problem persists for you after that. 😃