Skip to content

[Bug]: "The POSNext service worker is registered at "/assets/pos_next/pos/sw.js" but the POS page is at "/pos". This scope mismatch means offline mode does not work when using the browser install button. #295

@nazirsweats-lab

Description

@nazirsweats-lab

Issue Search Confirmation

  • I have searched existing open and closed issues and this is not a duplicate

Bug Description

"The POSNext service worker is registered at /assets/pos_next/pos/sw.js but the POS page is at /pos. This scope mismatch means offline mode does not work when using the browser install button. Please either move sw.js to the site root or register it with scope: '/' and add the Service-Worker-Allowed: / header."

Steps to Reproduce

"The POSNext service worker is registered at /assets/pos_next/pos/sw.js but the POS page is at /pos. This scope mismatch means offline mode does not work when using the browser install button. Please either move sw.js to the site root or register it with scope: '/' and add the Service-Worker-Allowed: / header."

Expected Behavior

Please either move sw.js to the site root or register it with scope: '/' and add the Service-Worker-Allowed: / header." to work offline properly

Actual Behavior

"The POSNext service worker is registered at /assets/pos_next/pos/sw.js but the POS page is at /pos. This scope mismatch means offline mode does not work when using the browser install button. Please either move sw.js to the site root or register it with scope: '/' and add the Service-Worker-Allowed: / header."

Screenshots / Screen Recordings

Image

Browser Console Errors

"The POSNext service worker is registered at /assets/pos_next/pos/sw.js but the POS page is at /pos. This scope mismatch means offline mode does not work when using the browser install button. Please either move sw.js to the site root or register it with scope: '/' and add the Service-Worker-Allowed: / header."

POS Next Version

1.13.0 (Latest)

Exact Version (if known)

1.16.0

Frappe Framework Version

15

ERPNext Version

15

Browser

Chrome

Browser Version

148.0.7778.179

Operating System

Windows 11

Deployment Type

Frappe Cloud

Bug Frequency

Always (100% reproducible)

Offline Mode

Not sure

Additional Context

"The POSNext service worker is registered at /assets/pos_next/pos/sw.js but the POS page is at /pos. This scope mismatch means offline mode does not work when using the browser install button. Please either move sw.js to the site root or register it with scope: '/' and add the Service-Worker-Allowed: / header."

Server Logs (if applicable)

Pre-submission Checklist

  • I have provided screenshots showing the issue
  • I have included my application version information
  • I have provided clear steps to reproduce the issue
  • I have checked browser console for errors and included them if present

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions