compressing icon indicating copy to clipboard operation
compressing copied to clipboard

uncompress error: Error: incorrect header check

Open qiufeihong2018 opened this issue 5 years ago • 1 comments

pack.zip是axios请求createWriteStream下载而来的

  compressing.tgz.uncompress(path.join(__dirname, '../../pack.zip'), 'package').then(res => {
    console.log('uncompress success')
    // 解压之后,重启应用即可
    app.relaunch()
    app.exit(0)
  }).catch(err => {
    // 记录错误日志
    console.log(`uncompress error: ${err.toString()}`)
  })

启动后报了这个问题

qiufeihong2018 avatar Sep 23 '20 01:09 qiufeihong2018

The parser is mismatched and thats why you get incorrect header check error.

Simply replace tgz with zip will resolve the issue.

portwatcher avatar Sep 06 '21 05:09 portwatcher

The parser is mismatched and thats why you get incorrect header check error.

Simply replace tgz with zip will resolve the issue.

compressing.zip.uncompress(path.join(__dirname, '../../pack.zip'), 'package').then(res => {
    console.log('uncompress success')
    // 解压之后,重启应用即可
    app.relaunch()
    app.exit(0)
  }).catch(err => {
    // 记录错误日志
    console.log(`uncompress error: ${err.toString()}`)
  })

Thanks, I also encountered this problem.

songpengyuan avatar May 25 '23 11:05 songpengyuan