Debugging Service Worker Download Stalling in Firefox
๐ Bug Fixes
- web: Fixed Service Worker downloads stalling at a random percentage (e.g. 0%, 13%, 21%) on Firefox with fast network connections. The
pull()handler was processing all buffered ECE records in a single call, enqueuing multiple chunks at once. Firefox v128+ enforces thehighWaterMark: 0pull-based contract more strictly and loses its backpressure state whenpull()enqueues more than one chunk, causing the ReadableStream to stop requesting more data mid-download. The inner loop is now replaced with a single-record-per-pull()pattern followed by an earlyreturn, which gives Firefox's download manager time to consume each chunk before the next one is produced.
๐งช Tests
- web: Added
console.debugdiagnostic logging to the Service Worker'spull()andreadMore()functions.
๐ณ Docker
- Image:
skyfay/skysend:v2.9.3 - Also tagged as:
latest,v2 - Platforms: linux/amd64, linux/arm64