Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix/service worker safety #30

Merged
merged 4 commits into from
Dec 29, 2022
Merged

Bugfix/service worker safety #30

merged 4 commits into from
Dec 29, 2022

Conversation

Cellivar
Copy link
Owner

The actual bug here was the service worker wasn't sending a valid fetch response for the raw js files, and when it tried to interpret the CDN requests those failed. Didn't test having a cache haha.

To facilitate recovering from service worker shenanigans I've added a loading indicator and an explicit 'nuke the service worker' button.

Also added an HTTPS-only warning while I was in there.

Also added a Linux udev rule warning while I was in there, it's got a similar issue with the OS providing a conflicting driver by default.

@github-actions
Copy link

Code coverage

Filename Statements Branches Functions Lines
src/Documents/BitmapGRF.ts 51.91% 35.71% 66.67% 53.91%
src/WebZlpError.ts 33.33% 100% 0% 33.33%
src/index.ts 100% 100% 100% 100%
src/Documents/Commands.ts 38.2% 46.88% 8.75% 38.07%
src/Printers/Configuration/PrinterOptions.ts 28.95% 66.67% 7.14% 28.95%
src/Printers/Models/PrinterModel.ts 42.86% 22.22% 6.67% 42.86%
src/Printers/Configuration/SerialPortSettings.ts 100% 100% 100% 100%
src/Printers/Configuration/MediaOptions.ts 70.77% 35.71% 71.43% 70.77%
src/Documents/ConfigDocument.ts 37.5% 0% 33.33% 37.5%
src/Documents/Document.ts 50% 0% 33.33% 55%
src/Documents/LabelDocument.ts 54.17% 66.67% 26.67% 54.17%
src/Documents/ReadyToPrintDocuments.ts 31.82% 100% 0% 33.33%
src/Printers/Communication/LineBreakTransformer.ts 12.5% 100% 0% 14.29%
src/Printers/Communication/PrinterCommunication.ts 84.62% 66.67% 66.67% 84.62%
src/Printers/Communication/UsbPrinterDeviceChannel.ts 7.04% 0% 0% 7.04%
src/Printers/Languages/EplPrinterCommandSet.ts 14.29% 8.62% 9.68% 14.97%
src/Printers/Models/PrinterModelDb.ts 18.52% 0% 0% 18.52%
src/Printers/Models/EplPrinterModels.ts 46.15% 100% 0% 46.15%
src/Printers/Languages/PrinterCommandSet.ts 22.45% 6.25% 12% 23.16%
src/Printers/PrinterCommunicationOptions.ts 25% 100% 100% 25%
src/Printers/Printer.ts 11.43% 0% 0% 11.54%
src/Printers/Languages/ZplPrinterCommandSet.ts 4.35% 0% 0% 4.38%
src/PrinterUsbManager.ts 6.52% 0% 0% 6.82%

@Cellivar Cellivar merged commit 85dfddb into main Dec 29, 2022
@Cellivar Cellivar deleted the bugfix/service-worker-safety branch December 29, 2022 09:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant