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

Error: invalid signature: 0x7d70fadf #32

Open
imaffett opened this issue Aug 29, 2013 · 6 comments
Open

Error: invalid signature: 0x7d70fadf #32

imaffett opened this issue Aug 29, 2013 · 6 comments

Comments

@imaffett
Copy link

I've got a script that downloads zips from github and unzips them into a temporary directory.

On machines with 4 gigs or less, it's crashing on any file over 2 megs.

https://github.com/gomobile/sample-counting-beads - that is a sample that I'm getting the zip from.

Below is the message I am seeing. The signature changes each time, but it happens on mac, linux, and windows. On my macbook pro with 8 gigs of ram, it works fine (I've pulled down 20 meg files).

Error: invalid signature: 0x7d70fadf
    at C:\my_project\node_modules\unzip\lib\parse.js:1:1127
    at process._tickCallback (node.js:351:13)
@tphalp
Copy link

tphalp commented Aug 30, 2013

I got this error, and it turned out to be a bad zip file. Worked once the zip file was valid.

@cscott
Copy link

cscott commented Nov 19, 2013

I got this error because there was a 'stored' (not 'deflated') entry in the zip file. That's perfectly valid, but node-unzip chokes on it.

@0cv
Copy link

0cv commented Nov 23, 2013

like @cscott - having the same problem with a "STORE" compression. It has successfully unextracted one folder but fails on the rest of the archive

@nathggns
Copy link

Getting the same issue here. Same zip, works on my Mac, not on a FreeBSD server.

@Alexsey
Copy link

Alexsey commented Jul 25, 2014

Getting such error some times on extracting file via ftp. Solution was to subscribe stream to 'error' event. Simplified to fs, like

function unzipFile(file, callback) {
    fs.createReadStream(file).pipe(unzip.Parse())
        .once('error', function () {
            unzipFile(file, callback)
         })
        .on('entry', function (entry) {
            var data = ''
            entry.on('data', function (chunk) {
                data += chunk
            }
            entry.on('end', function () {
                callback(null, data)
         }
    }

Should work, if you get this error not permanent, but from time to time

@Oneway102
Copy link

FYI. in case anyone still need the solution: patches in http://github.com/glebdmitriew/node-unzip-2 just resolved the problem.

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

No branches or pull requests

7 participants