WPIntell

Source evidence

404 pages for the plugin scripts

PWA · support · 2024-02-07T08:07:00+00:00

complaintsentiment
mediumseverity
0.92relevance
7replies
Evidence linked to opportunitycommercial context

Proof Health

Open evidence

Commercial opportunities need traceable source links before they are treated as build-worthy.

2 / 16 rows with source links

12.5% of this page's analysis has direct source links.

0 build-decision rows missing links

0 rows here require auditable proof before promotion.

14 rows with no attached evidence

0 rows have source counts but still need direct links.

Conversation

support
krysiek unresolved
Hi I have a RankMath plugin that has a monitor of 404 pages. In there i can see a lot of entries to the PWA plugin like this one wp-content/plugins/pwa/wp-includes/js/workbox-v6.5.3/workbox-core.prod.js I’m not sure, but those shows up in “batches”. A lot of those errors in a timeframe, then no errors for longer period of time. I do use wp-rocket as a cache plugin. I don’t know if this is related to your plugin or to something else, but just starting here my investigation. I have read https://wordpress.org/support/topic/404s-looking-for-pwa-files/ Kind Regards Krysiek The page I need help with: [ log in to see the link] https://ibb.co/BKzmwFT Here is a screenshot of the 404 report This reply was modified 2 years, 3 months ago by krysiek . I’m noticing that your service worker is failing to install on your site. I see an error: Uncaught (in promise) DOMException: Failed to register a ServiceWorker for scope (‘ https://wypiekibeaty.com.pl/’ ;) with script (‘ https://wypiekibeaty.com.pl/wp.serviceworker’ ;): The script resource is behind a redirect, which is disallowed. This is because https://wypiekibeaty.com.pl/wp.serviceworker is redirecting to https://wypiekibeaty.com.pl/wp.serviceworker/ which perhaps is something that WP Rocket is doing? Or perhaps RankMath? In any case, the reason why https://wypiekibeaty.com.pl/wp-content/plugins/pwa/wp-includes/js/workbox-v6.5.3/workbox-core.prod.js would be now 404’ing is because the latest version of the PWA plugin upgrades workbox to 7.0.0 so the new URL is https://wypiekibeaty.com.pl/wp-content/plugins/pwa/wp-includes/js/workbox-v7.0.0/workbox-core.prod.js Nevertheless, it seems your visitors aren’t able to get the new version installed because of that redirect which is adding a trailing slash to the service worker URL. Hi Thanks for the info. I do have the redirect to the / at the end – that’s true. So to resolve that isse i just need to disable that one redirect and allow access to the /wp.serviceworker? (that i already did) Thanks Krysiek Additinal question, sicne i stil lsee those errors. Should all those goes away, once all the users will update it to the new version? Yes, those errors should go away once the new service worker is installed automatically for your users. Hi Unfortunatelly i’m still seeing those. IS there something else i should check ? wp-content/plugins/pwa/wp-includes/js/workbox-v6.5.3/workbox-window.prod.js can I just create that path and put new script there ? I’m not sure. I just tried accessing your site again and I only see that https://wypiekibeaty.com.pl/wp-content/plugins/pwa/wp-includes/js/workbox-v7.0.0/workbox-window.prod.js is being referenced: <script type="rocketlazyloadscript" data-rocket-type="module"> import { Workbox } from "https:\/\/wypiekibeaty.com.pl\/wp-content\/plugins\/pwa\/wp-includes\/js\/workbox-v7.0.0\/workbox-window.prod.js"; if ( 'serviceWorker' in navigator ) { window.wp = window.wp || {}; window.wp.serviceWorkerWindow = new Workbox( "https:\/\/wypiekibeaty.com.pl\/wp.serviceworker", {"scope":"\/"} ); window.wp.serviceWorkerWindow.register(); } </script> If there are pages that are still attempting to load v6.5.3 instead of v7.0.0, then it seems you still have some cached pages, perhaps by WP Rocket. I would be surprised if it is still holding onto cached pages even now, however. I’m not familiar with how RankMath does 404 detection, so I can’t help with that.

Comments

7 shown
krysiek 2024-02-07T08:10:00+00:00

https://ibb.co/BKzmwFT Here is a screenshot of the 404 report This reply was modified 2 years, 3 months ago by krysiek .

Weston Ruter 2024-02-07T18:20:00+00:00

I’m noticing that your service worker is failing to install on your site. I see an error: Uncaught (in promise) DOMException: Failed to register a ServiceWorker for scope (‘ https://wypiekibeaty.com.pl/’ ;) with script (‘ https://wypiekibeaty.com.pl/wp.serviceworker’ ;): The script resource is behind a redirect, which is disallowed. This is because https://wypiekibeaty.com.pl/wp.serviceworker is redirecting to https://wypiekibeaty.com.pl/wp.serviceworker/ which perhaps is something that WP Rocket is doing? Or perhaps RankMath? In any case, the reason why https://wypiekibeaty.com.pl/wp-content/plugins/pwa/wp-includes/js/workbox-v6.5.3/workbox-core.prod.js would be now 404’ing is because the latest version of the PWA plugin upgrades workbox to 7.0.0 so the new URL is https://wypiekibeaty.com.pl/wp-content/plugins/pwa/wp-includes/js/workbox-v7.0.0/workbox-core.prod.js Nevertheless, it seems your visitors aren’t able to get the new version installed because of that redirect which is adding a trailing slash to the service worker URL.

krysiek 2024-02-08T06:34:00+00:00

Hi Thanks for the info. I do have the redirect to the / at the end – that’s true. So to resolve that isse i just need to disable that one redirect and allow access to the /wp.serviceworker? (that i already did) Thanks Krysiek

krysiek 2024-02-08T10:24:00+00:00

Additinal question, sicne i stil lsee those errors. Should all those goes away, once all the users will update it to the new version?

Weston Ruter 2024-02-08T16:58:00+00:00

Yes, those errors should go away once the new service worker is installed automatically for your users.

krysiek 2024-03-06T21:59:00+00:00

Hi Unfortunatelly i’m still seeing those. IS there something else i should check ? wp-content/plugins/pwa/wp-includes/js/workbox-v6.5.3/workbox-window.prod.js can I just create that path and put new script there ?

Weston Ruter 2024-03-12T19:07:00+00:00

I’m not sure. I just tried accessing your site again and I only see that https://wypiekibeaty.com.pl/wp-content/plugins/pwa/wp-includes/js/workbox-v7.0.0/workbox-window.prod.js is being referenced: <script type="rocketlazyloadscript" data-rocket-type="module"> import { Workbox } from "https:\/\/wypiekibeaty.com.pl\/wp-content\/plugins\/pwa\/wp-includes\/js\/workbox-v7.0.0\/workbox-window.prod.js"; if ( 'serviceWorker' in navigator ) { window.wp = window.wp || {}; window.wp.serviceWorkerWindow = new Workbox( "https:\/\/wypiekibeaty.com.pl\/wp.serviceworker", {"scope":"\/"} ); window.wp.serviceWorkerWindow.register(); } </script> If there are pages that are still attempting to load v6.5.3 instead of v7.0.0, then it seems you still have some cached pages, perhaps by WP Rocket. I would be surprised if it is still holding onto cached pages even now, however. I’m not familiar with how RankMath does 404 detection, so I can’t help with that.