Skip to content
This repository has been archived by the owner on Oct 2, 2020. It is now read-only.

Error: Generated checksum for "electron-v1.4.13-linux-x64.zip" did not match expected checksum. #264

Closed
andres-lowrie opened this issue Jun 23, 2017 · 11 comments

Comments

@andres-lowrie
Copy link

Getting this error when trying to install with yarn.

From package.json

    "electron-devtools-installer": "^1.1.4",
    "electron-packager": "^8.0.0",
    "electron-prebuilt": "^1.4.6",
    "electron-rebuild": "^1.1.3",

The error:

error /home/andres/Projects/front-end/node_modules/electron: Command failed.
Exit code: 1
Command: sh
Arguments: -c node install.js
Directory: /home/andres/Projects/front-end/node_modules/electron
Output:
/home/andres/Projects/front-end/node_modules/electron/install.js:22
  throw err
  ^

Error: Generated checksum for "electron-v1.4.13-linux-x64.zip" did not match expected checksum.
    at ChecksumMismatchError.ErrorWithFilename (/home/andres/Projects/front-end/node_modules/sumchecker/build.js:41:124)
    at new ChecksumMismatchError (/home/andres/Projects/front-end/node_modules/sumchecker/build.js:56:133)
    at Hash.<anonymous> (/home/andres/Projects/front-end/node_modules/sumchecker/build.js:203:22)
    at emitNone (events.js:105:13)
    at Hash.emit (events.js:207:7)
    at emitReadable_ (_stream_readable.js:500:10)
    at emitReadable (_stream_readable.js:494:7)
    at addChunk (_stream_readable.js:261:7)
    at readableAddChunk (_stream_readable.js:237:11)
    at Hash.Readable.push (_stream_readable.js:195:10)
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

Don't know if this is related to the fact that I'm running latest ubuntu:


DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=17.04
DISTRIB_CODENAME=zesty
DISTRIB_DESCRIPTION="Ubuntu 17.04"
NAME="Ubuntu"
VERSION="17.04 (Zesty Zapus)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 17.04"
VERSION_ID="17.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=zesty
UBUNTU_CODENAME=zesty
@runrog
Copy link

runrog commented Jun 24, 2017

+1

@G07cha
Copy link

G07cha commented Jun 26, 2017

Hi @runrog, please don't comment "+1", if you have a similar problem and don't have additional details to add, please use 👍 emotion on OP's post. This will prevent constant notifications that repo's owners and participants receiving and reduce the number of overall comments so it will be easier to focus on important information.

@james-Airwallex
Copy link

I can confirm the same issue as OP on node:alpine

FROM node:latest

ADD dist /srv/node/web/dist
ADD deployment /srv/node/web

WORKDIR web

RUN npm i --only=dev

ENV BUILD_DIR=dist
ENV PORT=8080

EXPOSE 8080

CMD ["node", "server.js"]

@claygriffiths
Copy link

Rolling back to Node v6.9.2 with nvm fixed this on Bitrise CI.

I tried Node v7.3.0 but ran into the same issue. I'm not sure if malept/sumchecker#5 is the fix but it's in sumchecker 2.0.2 and electron-downloader is using sumchecker 2.0.1.

@zeke
Copy link
Member

zeke commented Aug 8, 2017

We can fix this, but I want to first get a sense of users are still affected by it, as its an older version of Electron.

The electron-prebuilt repo is being retired and its code has been moved into the electron/electron repo. For the sake of historical transparency, we will leave GitHub Issues enabled on this repository, but if you are still affected by the issue reported here, please open a new issue on electron/electron repo and reference this issue from it so people can get the full context. The electron repository has a large and active contributor community, so your issue is more likely to get the attention it deserves there. Thanks!

@zeke zeke closed this as completed Aug 8, 2017
wincent added a commit to wincent/corpus that referenced this issue Aug 11, 2017
Fails to install using Node 8; see:

- electron-userland/electron-prebuilt#264
- malept/sumchecker#5

Tried this:

```
yarn upgrade electron electron-download sumchecker
```

But it blows up due to the checksum "mismatch".

Worked around that by downgrading to 7 temporarily:

```
brew install n
sudo n 7.10.1
yarn upgrade electron
sudo n latest
```
@ghost
Copy link

ghost commented Aug 23, 2017

Getting a similar error while trying to install Electron 1.7.5, on Ubuntu 16.04.

Error: Generated checksum for "electron-v1.7.5-linux-x64.zip" did not match expected checksum.
    at ChecksumMismatchError.ErrorWithFilename (/path/to/project/node_modules/sumchecker/build.js:41:124)
    at new ChecksumMismatchError (/path/to/project/node_modules/sumchecker/build.js:56:133)
    at Hash.<anonymous> (/path/to/project/node_modules/sumchecker/build.js:203:22)
    at emitNone (events.js:105:13)
    at Hash.emit (events.js:207:7)
    at emitReadable_ (_stream_readable.js:516:10)
    at emitReadable (_stream_readable.js:510:7)
    at addChunk (_stream_readable.js:277:7)
    at readableAddChunk (_stream_readable.js:253:11)
    at Hash.Readable.push (_stream_readable.js:211:10)

@c7pt7in
Copy link

c7pt7in commented Sep 19, 2017

updating electron-packager worked for me

npm install electron-packager -g

@tarruda
Copy link

tarruda commented May 24, 2018

For anyone still facing this issue, try this fix

@nZeus
Copy link

nZeus commented Jul 31, 2018

I'm still facing this issue,

npm install electron-packager -g didn't help, resolutions didn't help...

Trying to install electron@2.0.5:

C:\Projects\GIS>npm install                                                                                                                                      
                                                                                                                                                                 
> electron@2.0.5 postinstall C:\Projects\GIS\node_modules\electron                                                                                               
> node install.js                                                                                                                                                
                                                                                                                                                                 
Downloading electron-v2.0.5-win32-x64.zip                                                                                                                        
[============================================>] 100.0% of 50.7 MB (11.93 MB/s)                                                                                   
C:\Projects\GIS\node_modules\electron\install.js:47                                                                                                              
  throw err                                                                                                                                                      
  ^                                                                                                                                                              
                                                                                                                                                                 
Error                                                                                                                                                            
    at ChecksumMismatchError.ErrorWithFilename (C:\Projects\GIS\node_modules\sumchecker\build.js:41:124)                                                         
    at new ChecksumMismatchError (C:\Projects\GIS\node_modules\sumchecker\build.js:56:127)                                                                       
    at Hash.<anonymous> (C:\Projects\GIS\node_modules\sumchecker\build.js:196:22)                                                                                
    at Hash.emit (events.js:180:13)                                                                                                                              
    at emitReadable_ (_stream_readable.js:520:10)                                                                                                                
    at emitReadable (_stream_readable.js:514:7)                                                                                                                  
    at addChunk (_stream_readable.js:280:7)                                                                                                                      
    at readableAddChunk (_stream_readable.js:256:11)                                                                                                             
    at Hash.Readable.push (_stream_readable.js:213:10)                                                                                                           
    at Hash.Transform.push (_stream_transform.js:146:32)                                                                                                         
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents):                                                                          
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
                                                                                                                                                                 
npm ERR! code ELIFECYCLE                                                                                                                                         
npm ERR! errno 1                                                                                                                                                 
npm ERR! electron@2.0.5 postinstall: `node install.js`                                                                                                           
npm ERR! Exit status 1                                                                                                                                           
npm ERR!                                                                                                                                                         
npm ERR! Failed at the electron@2.0.5 postinstall script.                                                                                                        
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.                                                               
                                                                                                                                                                 
npm ERR! A complete log of this run can be found in:                                                                                                             
npm ERR!     C:\Users\i.tsvetkov\AppData\Roaming\npm-cache\_logs\2018-07-31T09_51_36_988Z-debug.log                                                              

@nZeus
Copy link

nZeus commented Jul 31, 2018

... But then I switched to node 6.12.0, and I could finally install it :/

@fincha
Copy link

fincha commented Sep 11, 2018

have the same issue with node 8, ubuntu 18

Error: Generated checksum for "electron-v2.0.9-linux-x64.zip" did not match expected checksum.
at ChecksumMismatchError.ErrorWithFilename (/usr/local/lib/node_modules/electron/node_modules/sumchecker/build.js:41:124)
at new ChecksumMismatchError (/usr/local/lib/node_modules/electron/node_modules/sumchecker/build.js:56:133)
at Hash. (/usr/local/lib/node_modules/electron/node_modules/sumchecker/build.js:203:22)
at emitNone (events.js:106:13)
at Hash.emit (events.js:208:7)
at emitReadable_ (_stream_readable.js:513:10)
at emitReadable (_stream_readable.js:507:7)
at addChunk (_stream_readable.js:274:7)
at readableAddChunk (_stream_readable.js:250:11)
at Hash.Readable.push (_stream_readable.js:208:10)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

10 participants