gildas-lormeau / zip.js

JavaScript library to zip and unzip files supporting multi-core compression, compression streams, zip64, split files and encryption.
https://gildas-lormeau.github.io/zip.js
BSD 3-Clause "New" or "Revised" License
3.33k stars 506 forks source link

Uncaught (in promise) TypeError: Failed to fetch #431

Closed yufeng1524 closed 1 year ago

yufeng1524 commented 1 year ago

Hi

we are using zipjs 2.6.63, and meet below error when zip file for sometimes, but not every time:

Uncaught (in promise) TypeError: Failed to fetch

webworker is configured for zipjs.

Additionally, we found there's same issue in #370 , and the issue has been fixed in 2.6.37 which is older than we used. And we didn't abort zip writer when meet the error.

Any idea about this issue?

gildas-lormeau commented 1 year ago

Why don't you use the last version?

yufeng1524 commented 1 year ago

Why don't you use the last version?

thanks for quick responding.

by the way, is it a known issue?

gildas-lormeau commented 1 year ago

This issue should be fixed but it's a bit old. I guess the version 2.6.82 fixes your issue, see https://github.com/gildas-lormeau/zip.js/releases/tag/v2.6.82. It's very similar to the fix in the version 2.6.37, see https://github.com/gildas-lormeau/zip.js/commit/9ce18f61902de331245e6f5fbbadf4ae75b67683 (v2.6.82) and https://github.com/gildas-lormeau/zip.js/commit/e8e5269541f2eb3a58e4ec3c23c8ef91fa32cff9 (v2.6.37).