• Resolved Mike Castro Demaria

    (@mikecastrodemaria)


    Hi, I have the following error message in the console :

    – SuperPWA service worker ready register-sw.js:4:33
    – SuperPWA service worker installation superpwa-sw.js:17:2
    – SuperPWA service worker caching dependencies superpwa-sw.js:20:4

    – Service worker event waitUntil() was passed a promise that rejected with ‘InvalidStateError: An attempt was made to use an object that is not, or is no longer, usable’. superpwa-sw.js:18:1
    – TypeError: ServiceWorker script at /superpwa-sw.js for scope … encountered an error during installation.

    I’ll give you and non dev server URL for test soon, but now it’s a local install.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hello @mikecastrodemaria

    Good day and thanks for using SuperPWA plugin.

    Upon localhost our plugin won’t work perfectly.

    As for registering Service Worker upon any browser, the website should be served fully via https:// due to that and most of the websites are not forcefully redirecting https:// to https:// the URLs generated upon manifest and service worker was https:// earlier. As you know, if a single https:// request within a website can change a secured to non-secure (in our case the Service Worker won’t get registered in that scenario). As considering this, right now we are fully forcing all the URLs within our Manifest and Service Worker to https://. The error that you mentioned may be because of that.

    Can you try this upon a staging server (secured with SSL) and let me know whether the issue exists.

    Looking forward.

    Have you got some time to test the website upon any staging server?

    Looking forward.

    Closing this thread due to lack of activity. If you still have any issues, please open this thread and let me know.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘ServiceWorker script encountered an error during installation.’ is closed to new replies.