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

failing with "Configure error" #1040

Closed
heapwolf opened this issue Oct 21, 2016 · 16 comments
Closed

failing with "Configure error" #1040

heapwolf opened this issue Oct 21, 2016 · 16 comments

Comments

@heapwolf
Copy link

I'm using node v6.9.1 (npm 3.10.8), on the latest IE-Preview Windows 10 VM for virtualbox (configured by microsoft and not crippled at all). Python is also found in the path after a few tries.

The problem is, I'm getting a network error when I run node-gyp rebuild --verbose (or just configure). This is odd because I can curl for https://nodejs.org/download/release/v6.9.1/node-v6.9.1-headers.tar.gz and its a 200 (the output below also shows a 200. Here is the output...

C:\work\leveldown>node-gyp rebuild --verbose
gyp info it worked if it ends with ok
gyp verb cli [ 'C:\\Program Files\\nodejs\\node.exe',
gyp verb cli   'C:\\Users\\IEUser\\AppData\\Roaming\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js',
gyp verb cli   'rebuild',
gyp verb cli   '--verbose' ]
gyp info using [email protected]
gyp info using [email protected] | win32 | x64
gyp verb command rebuild []
gyp verb command clean []
gyp verb clean removing "build" directory
gyp verb command configure []
gyp verb check python checking for Python executable "python2" in the PATH
gyp verb `which` failed Error: not found: python2
gyp verb `which` failed     at getNotFoundError (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:14:12)
gyp verb `which` failed     at F (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:69:19)
gyp verb `which` failed     at E (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:81:29)
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:90:16
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\index.js:44:5
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\windows.js:29:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:123:15)
gyp verb `which` failed  python2 { Error: not found: python2
gyp verb `which` failed     at getNotFoundError (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:14:12)
gyp verb `which` failed     at F (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:69:19)
gyp verb `which` failed     at E (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:81:29)
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:90:16
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\index.js:44:5
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\windows.js:29:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:123:15) code: 'ENOENT' }
gyp verb check python checking for Python executable "python" in the PATH
gyp verb `which` succeeded python C:\Python27\python.EXE
gyp verb check python version `C:\Python27\python.EXE -c "import platform; print(platform.python_version());"` returned: "2.7.12\r\n"
gyp verb get node dir no --target version specified, falling back to host node version: 6.9.1
gyp verb command install [ '6.9.1' ]
gyp verb install input version string "6.9.1"
gyp verb install installing version: 6.9.1
gyp verb install --ensure was passed, so won't reinstall if already installed
gyp verb install version not already installed, continuing with install 6.9.1
gyp verb ensuring nodedir is created C:\Users\IEUser\.node-gyp\6.9.1
gyp verb created nodedir C:\Users\IEUser\.node-gyp\6.9.1
gyp http GET https://nodejs.org/download/release/v6.9.1/node-v6.9.1-headers.tar.gz
gyp http 200 https://nodejs.org/download/release/v6.9.1/node-v6.9.1-headers.tar.gz
gyp verb extracted file from tarball include\node\android-ifaddrs.h
gyp verb extracted file from tarball include\node\ares.h
gyp verb extracted file from tarball include\node\ares_build.h
gyp verb extracted file from tarball include\node\ares_rules.h
gyp verb extracted file from tarball include\node\ares_version.h
gyp verb extracted file from tarball include\node\common.gypi
gyp verb extracted file from tarball include\node\config.gypi
gyp verb extracted file from tarball include\node\nameser.h
gyp verb extracted file from tarball include\node\node.h
gyp verb extracted file from tarball include\node\node_buffer.h
gyp verb extracted file from tarball include\node\node_object_wrap.h
gyp verb extracted file from tarball include\node\node_version.h
gyp verb extracted file from tarball include\node\pthread-barrier.h
gyp verb extracted file from tarball include\node\pthread-fixes.h
gyp verb extracted file from tarball include\node\stdint-msvc2008.h
gyp verb extracted file from tarball include\node\tree.h
gyp verb extracted file from tarball include\node\uv-aix.h
gyp verb extracted file from tarball include\node\uv-bsd.h
gyp verb extracted file from tarball include\node\uv-darwin.h
gyp verb extracted file from tarball include\node\uv-errno.h
gyp verb extracted file from tarball include\node\uv-linux.h
gyp verb extracted file from tarball include\node\uv-sunos.h
gyp verb extracted file from tarball include\node\uv-threadpool.h
gyp verb extracted file from tarball include\node\uv-unix.h
gyp verb extracted file from tarball include\node\uv-version.h
gyp verb extracted file from tarball include\node\uv-win.h
gyp verb extracted file from tarball include\node\uv.h
gyp verb extracted file from tarball include\node\v8-debug.h
gyp verb extracted file from tarball include\node\v8-experimental.h
gyp verb extracted file from tarball include\node\v8-platform.h
gyp verb extracted file from tarball include\node\v8-profiler.h
gyp verb extracted file from tarball include\node\v8-testing.h
gyp WARN install got an error, rolling back install
gyp verb command remove [ '6.9.1' ]
gyp verb remove using node-gyp dir: C:\Users\IEUser\.node-gyp
gyp verb remove removing target version: 6.9.1
gyp verb remove removing development files for version: 6.9.1
gyp ERR! configure error
gyp ERR! stack Error: read ECONNRESET
gyp ERR! stack     at exports._errnoException (util.js:1026:11)
gyp ERR! stack     at TLSWrap.onread (net.js:569:26)
gyp ERR! System Windows_NT 10.0.14393
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\IEUser\\AppData\\Roaming\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose"
gyp ERR! cwd C:\work\leveldown
gyp ERR! node -v v6.9.1
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok
@bnoordhuis
Copy link
Member

What happens when you download the tarball manually and pass --tarball node-v6.9.1-headers.tar.gz to node-gyp? You probably also need https://nodejs.org/download/release/v6.9.1/win-x64/node.lib.

@heapwolf
Copy link
Author

If I do the following...

curl -sL https://nodejs.org/download/release/v6.9.1/node-v6.9.1-headers.tar.gz > node-v6.9.1-headers.tar.gz

curl -sL https://nodejs.org/download/release/v6.9.1/win-x64/node.lib > /c/Users/IEUser/.node-gyp/6.9.1/x64/node.lib

node-gyp rebuild --tarball ./node-v6.9.1-headers.tar.gz --verbose

I get this output...

gyp info it worked if it ends with ok
gyp verb cli [ 'C:\\Program Files\\nodejs\\node.exe',
gyp verb cli   'C:\\Users\\IEUser\\AppData\\Roaming\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js',
gyp verb cli   'rebuild',
gyp verb cli   '--tarball',
gyp verb cli   'node-v6.9.1-headers.tar.gz',
gyp verb cli   '--verbose' ]
gyp info using [email protected]
gyp info using [email protected] | win32 | x64
gyp verb command rebuild []
gyp verb command clean []
gyp verb clean removing "build" directory
gyp verb command configure []
gyp verb check python checking for Python executable "python2" in the PATH
gyp verb `which` failed Error: not found: python2
gyp verb `which` failed     at getNotFoundError (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:14:12)
gyp verb `which` failed     at F (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:69:19)
gyp verb `which` failed     at E (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:81:29)
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:90:16
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\index.js:44:5
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\windows.js:29:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:123:15)
gyp verb `which` failed  python2 { Error: not found: python2
gyp verb `which` failed     at getNotFoundError (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:14:12)
gyp verb `which` failed     at F (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:69:19)
gyp verb `which` failed     at E (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:81:29)
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:90:16
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\index.js:44:5
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\windows.js:29:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:123:15) code: 'ENOENT' }
gyp verb check python checking for Python executable "python" in the PATH
gyp verb `which` succeeded python C:\Python27\python.EXE
gyp verb check python version `C:\Python27\python.EXE -c "import platform; print(platform.python_version());"` returned: "2.7.12\r\n"
gyp verb get node dir no --target version specified, falling back to host node version: 6.9.1
gyp verb command install [ '6.9.1' ]
gyp verb install input version string "6.9.1"
gyp verb install installing version: 6.9.1
gyp verb install --ensure was passed, so won't reinstall if already installed
gyp verb install version is already installed, need to check "installVersion"
gyp verb got "installVersion" 0
gyp verb needs "installVersion" 9
gyp verb install version is no good; reinstalling
gyp verb ensuring nodedir is created C:\Users\IEUser\.node-gyp\6.9.1
gyp verb extracted file from tarball include\node\android-ifaddrs.h
gyp verb extracted file from tarball include\node\ares.h
gyp verb extracted file from tarball include\node\ares_build.h
gyp verb extracted file from tarball include\node\ares_rules.h
gyp verb extracted file from tarball include\node\ares_version.h
gyp verb extracted file from tarball include\node\common.gypi
gyp verb extracted file from tarball include\node\config.gypi
gyp verb extracted file from tarball include\node\nameser.h
gyp verb extracted file from tarball include\node\node.h
gyp verb extracted file from tarball include\node\node_buffer.h
gyp verb extracted file from tarball include\node\node_object_wrap.h
gyp verb extracted file from tarball include\node\node_version.h
gyp verb extracted file from tarball include\node\pthread-barrier.h
gyp verb extracted file from tarball include\node\pthread-fixes.h
gyp verb extracted file from tarball include\node\stdint-msvc2008.h
gyp verb extracted file from tarball include\node\tree.h
gyp verb extracted file from tarball include\node\uv-aix.h
gyp verb extracted file from tarball include\node\uv-bsd.h
gyp verb extracted file from tarball include\node\uv-darwin.h
gyp verb extracted file from tarball include\node\uv-errno.h
gyp verb extracted file from tarball include\node\uv-linux.h
gyp verb extracted file from tarball include\node\uv-sunos.h
gyp verb extracted file from tarball include\node\uv-threadpool.h
gyp verb extracted file from tarball include\node\uv-unix.h
gyp verb extracted file from tarball include\node\uv-version.h
gyp verb extracted file from tarball include\node\uv-win.h
gyp verb extracted file from tarball include\node\uv.h
gyp verb extracted file from tarball include\node\v8-debug.h
gyp verb extracted file from tarball include\node\v8-experimental.h
gyp verb extracted file from tarball include\node\v8-platform.h
gyp verb extracted file from tarball include\node\v8-profiler.h
gyp verb extracted file from tarball include\node\v8-testing.h
gyp verb extracted file from tarball include\node\v8-util.h
gyp verb extracted file from tarball include\node\v8-version.h
gyp verb extracted file from tarball include\node\v8.h
gyp verb extracted file from tarball include\node\v8config.h
gyp verb extracted file from tarball include\node\zconf.h
gyp verb extracted file from tarball include\node\zlib.h
gyp verb extracted file from tarball include\node\openssl\aes.h
gyp verb extracted file from tarball include\node\openssl\asn1.h
gyp verb extracted file from tarball include\node\openssl\asn1_mac.h
gyp verb extracted file from tarball include\node\openssl\asn1t.h
gyp verb extracted file from tarball include\node\openssl\bio.h
gyp verb extracted file from tarball include\node\openssl\blowfish.h
gyp verb extracted file from tarball include\node\openssl\bn.h
gyp verb extracted file from tarball include\node\openssl\buffer.h
gyp verb extracted file from tarball include\node\openssl\camellia.h
gyp verb extracted file from tarball include\node\openssl\cast.h
gyp verb extracted file from tarball include\node\openssl\cmac.h
gyp verb extracted file from tarball include\node\openssl\cms.h
gyp verb extracted file from tarball include\node\openssl\comp.h
gyp verb extracted file from tarball include\node\openssl\conf.h
gyp verb extracted file from tarball include\node\openssl\conf_api.h
gyp verb extracted file from tarball include\node\openssl\crypto.h
gyp verb extracted file from tarball include\node\openssl\des.h
gyp verb extracted file from tarball include\node\openssl\des_old.h
gyp verb extracted file from tarball include\node\openssl\dh.h
gyp verb extracted file from tarball include\node\openssl\dsa.h
gyp verb extracted file from tarball include\node\openssl\dso.h
gyp verb extracted file from tarball include\node\openssl\dtls1.h
gyp verb extracted file from tarball include\node\openssl\e_os2.h
gyp verb extracted file from tarball include\node\openssl\ebcdic.h
gyp verb extracted file from tarball include\node\openssl\ec.h
gyp verb extracted file from tarball include\node\openssl\ecdh.h
gyp verb extracted file from tarball include\node\openssl\ecdsa.h
gyp verb extracted file from tarball include\node\openssl\engine.h
gyp verb extracted file from tarball include\node\openssl\err.h
gyp verb extracted file from tarball include\node\openssl\evp.h
gyp verb extracted file from tarball include\node\openssl\hmac.h
gyp verb extracted file from tarball include\node\openssl\idea.h
gyp verb extracted file from tarball include\node\openssl\krb5_asn.h
gyp verb extracted file from tarball include\node\openssl\kssl.h
gyp verb extracted file from tarball include\node\openssl\lhash.h
gyp verb extracted file from tarball include\node\openssl\md4.h
gyp verb extracted file from tarball include\node\openssl\md5.h
gyp verb extracted file from tarball include\node\openssl\mdc2.h
gyp verb extracted file from tarball include\node\openssl\modes.h
gyp verb extracted file from tarball include\node\openssl\obj_mac.h
gyp verb extracted file from tarball include\node\openssl\objects.h
gyp verb extracted file from tarball include\node\openssl\ocsp.h
gyp verb extracted file from tarball include\node\openssl\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\opensslv.h
gyp verb extracted file from tarball include\node\openssl\ossl_typ.h
gyp verb extracted file from tarball include\node\openssl\pem.h
gyp verb extracted file from tarball include\node\openssl\pem2.h
gyp verb extracted file from tarball include\node\openssl\pkcs12.h
gyp verb extracted file from tarball include\node\openssl\pkcs7.h
gyp verb extracted file from tarball include\node\openssl\pqueue.h
gyp verb extracted file from tarball include\node\openssl\rand.h
gyp verb extracted file from tarball include\node\openssl\rc2.h
gyp verb extracted file from tarball include\node\openssl\rc4.h
gyp verb extracted file from tarball include\node\openssl\ripemd.h
gyp verb extracted file from tarball include\node\openssl\rsa.h
gyp verb extracted file from tarball include\node\openssl\safestack.h
gyp verb extracted file from tarball include\node\openssl\seed.h
gyp verb extracted file from tarball include\node\openssl\sha.h
gyp verb extracted file from tarball include\node\openssl\srp.h
gyp verb extracted file from tarball include\node\openssl\srtp.h
gyp verb extracted file from tarball include\node\openssl\ssl.h
gyp verb extracted file from tarball include\node\openssl\ssl2.h
gyp verb extracted file from tarball include\node\openssl\ssl23.h
gyp verb extracted file from tarball include\node\openssl\ssl3.h
gyp verb extracted file from tarball include\node\openssl\stack.h
gyp verb extracted file from tarball include\node\openssl\symhacks.h
gyp verb extracted file from tarball include\node\openssl\tls1.h
gyp verb extracted file from tarball include\node\openssl\ts.h
gyp verb extracted file from tarball include\node\openssl\txt_db.h
gyp verb extracted file from tarball include\node\openssl\ui.h
gyp verb extracted file from tarball include\node\openssl\ui_compat.h
gyp verb extracted file from tarball include\node\openssl\whrlpool.h
gyp verb extracted file from tarball include\node\openssl\x509.h
gyp verb extracted file from tarball include\node\openssl\x509_vfy.h
gyp verb extracted file from tarball include\node\openssl\x509v3.h
gyp verb extracted file from tarball include\node\openssl\archs\VC-WIN64A\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\VC-WIN32\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\solaris64-x86_64-gcc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\solaris-x86-gcc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux64-s390x\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux32-s390x\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-x86_64\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-x32\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-ppc64\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-ppc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-elf\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-armv4\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-aarch64\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\darwin64-x86_64-cc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\darwin-i386-cc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\BSD-x86_64\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\BSD-x86\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\aix64-gcc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\aix-gcc\opensslconf.h
gyp verb extracted file from tarball include\node\libplatform\libplatform.h
gyp verb tarball done parsing tarball
gyp verb on Windows; need to download `node.lib`...
gyp verb 32-bit node.lib dir C:\Users\IEUser\.node-gyp\6.9.1\ia32
gyp verb 64-bit node.lib dir C:\Users\IEUser\.node-gyp\6.9.1\x64
gyp verb `node.lib` 32-bit url https://nodejs.org/download/release/v6.9.1/win-x86/node.lib
gyp verb `node.lib` 64-bit url https://nodejs.org/download/release/v6.9.1/win-x64/node.lib
gyp verb streaming 32-bit node.lib to: C:\Users\IEUser\.node-gyp\6.9.1\ia32\node.lib
gyp http GET https://nodejs.org/download/release/v6.9.1/win-x86/node.lib
gyp verb streaming 64-bit node.lib to: C:\Users\IEUser\.node-gyp\6.9.1\x64\node.lib
gyp http GET https://nodejs.org/download/release/v6.9.1/win-x64/node.lib
gyp http 200 https://nodejs.org/download/release/v6.9.1/win-x86/node.lib
gyp http 200 https://nodejs.org/download/release/v6.9.1/win-x64/node.lib
gyp WARN install got an error, rolling back install
gyp verb command remove [ '6.9.1' ]
gyp verb remove using node-gyp dir: C:\Users\IEUser\.node-gyp
gyp verb remove removing target version: 6.9.1
gyp verb remove removing development files for version: 6.9.1
gyp verb content checksum win-x64/node.lib 9d708a1a85cca7368b24b279e5ead58c94326a3cb17f5c0e04a6279b6df28ae9
gyp verb content checksum win-x86/node.lib 852c091f2e1fc2a1932d89bef78112f14c4e6a051f6800e59074c3e4c45f118b
gyp verb download contents checksum {"win-x64/node.lib":"9d708a1a85cca7368b24b279e5ead58c94326a3cb17f5c0e04a6279b6df28ae9","win-x86/node.lib":"852c091f2e1fc2a1932d89bef78112f14c4e6a051f6800e59074c3e4c45f118b"}
gyp verb validating download checksum for win-x64/node.lib (9d708a1a85cca7368b24b279e5ead58c94326a3cb17f5c0e04a6279b6df28ae9 == undefined)
gyp ERR! configure error
gyp ERR! stack Error: read ECONNRESET
gyp ERR! stack     at exports._errnoException (util.js:1026:11)
gyp ERR! stack     at TLSWrap.onread (net.js:569:26)
gyp ERR! System Windows_NT 10.0.14393
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\IEUser\\AppData\\Roaming\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--tarball" "node-v6.9.1-headers.tar.gz" "--verbose"
gyp ERR! cwd C:\work\voltra
gyp ERR! node -v v6.9.1
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

The line validating download checksum seems suspect.

@bnoordhuis
Copy link
Member

Can you delete your .node-gyp directory and retry? It looks like node-gyp can't find a matching entry in SHASUMS256.txt but it seems to be using a cached, presumably corrupted version. If it had downloaded the file, there would be a 'checksum url' line in the log.

@heapwolf
Copy link
Author

I deleted my .node-gyp, here is the output

$ node-gyp rebuild --tarball ./node-v6.9.1-headers.tar.gz --verbose
gyp info it worked if it ends with ok
gyp verb cli [ 'C:\\Program Files\\nodejs\\node.exe',
gyp verb cli   'C:\\Users\\IEUser\\AppData\\Roaming\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js',
gyp verb cli   'rebuild',
gyp verb cli   '--tarball',
gyp verb cli   './node-v6.9.1-headers.tar.gz',
gyp verb cli   '--verbose' ]
gyp info using [email protected]
gyp info using [email protected] | win32 | x64
gyp verb command rebuild []
gyp verb command clean []
gyp verb clean removing "build" directory
gyp verb command configure []
gyp verb check python checking for Python executable "python2" in the PATH
gyp verb `which` failed Error: not found: python2
gyp verb `which` failed     at getNotFoundError (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:14:12)
gyp verb `which` failed     at F (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:69:19)
gyp verb `which` failed     at E (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:81:29)
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:90:16
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\index.js:44:5
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\windows.js:29:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:123:15)
gyp verb `which` failed  python2 { Error: not found: python2
gyp verb `which` failed     at getNotFoundError (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:14:12)
gyp verb `which` failed     at F (C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:69:19)
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\which\which.js:90:16
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\index.js:44:5
gyp verb `which` failed     at C:\Users\IEUser\AppData\Roaming\npm\node_modules\node-gyp\node_modules\isexe\windows.js:29:5
gyp verb `which` failed     at FSReqWrap.oncomplete (fs.js:123:15) code: 'ENOENT' }
gyp verb check python checking for Python executable "python" in the PATH
gyp verb `which` succeeded python C:\Python27\python.EXE
gyp verb check python version `C:\Python27\python.EXE -c "import platform; print(platform.python_version());"` returned: "2.7.12\r\n"
gyp verb get node dir no --target version specified, falling back to host node version: 6.9.1
gyp verb command install [ '6.9.1' ]
gyp verb install input version string "6.9.1"
gyp verb install installing version: 6.9.1
gyp verb install --ensure was passed, so won't reinstall if already installed
gyp verb install version not already installed, continuing with install 6.9.1
gyp verb ensuring nodedir is created C:\Users\IEUser\.node-gyp\6.9.1
gyp verb created nodedir C:\Users\IEUser\.node-gyp
gyp verb extracted file from tarball include\node\android-ifaddrs.h
gyp verb extracted file from tarball include\node\ares.h
gyp verb extracted file from tarball include\node\ares_build.h
gyp verb extracted file from tarball include\node\ares_rules.h
gyp verb extracted file from tarball include\node\ares_version.h
gyp verb extracted file from tarball include\node\common.gypi
gyp verb extracted file from tarball include\node\config.gypi
gyp verb extracted file from tarball include\node\nameser.h
gyp verb extracted file from tarball include\node\node.h
gyp verb extracted file from tarball include\node\node_buffer.h
gyp verb extracted file from tarball include\node\node_object_wrap.h
gyp verb extracted file from tarball include\node\node_version.h
gyp verb extracted file from tarball include\node\pthread-barrier.h
gyp verb extracted file from tarball include\node\pthread-fixes.h
gyp verb extracted file from tarball include\node\stdint-msvc2008.h
gyp verb extracted file from tarball include\node\tree.h
gyp verb extracted file from tarball include\node\uv-aix.h
gyp verb extracted file from tarball include\node\uv-bsd.h
gyp verb extracted file from tarball include\node\uv-darwin.h
gyp verb extracted file from tarball include\node\uv-errno.h
gyp verb extracted file from tarball include\node\uv-linux.h
gyp verb extracted file from tarball include\node\uv-sunos.h
gyp verb extracted file from tarball include\node\uv-threadpool.h
gyp verb extracted file from tarball include\node\uv-unix.h
gyp verb extracted file from tarball include\node\uv-version.h
gyp verb extracted file from tarball include\node\uv-win.h
gyp verb extracted file from tarball include\node\uv.h
gyp verb extracted file from tarball include\node\v8-debug.h
gyp verb extracted file from tarball include\node\v8-experimental.h
gyp verb extracted file from tarball include\node\v8-platform.h
gyp verb extracted file from tarball include\node\v8-profiler.h
gyp verb extracted file from tarball include\node\v8-testing.h
gyp verb extracted file from tarball include\node\v8-util.h
gyp verb extracted file from tarball include\node\v8-version.h
gyp verb extracted file from tarball include\node\v8.h
gyp verb extracted file from tarball include\node\v8config.h
gyp verb extracted file from tarball include\node\zconf.h
gyp verb extracted file from tarball include\node\zlib.h
gyp verb extracted file from tarball include\node\openssl\aes.h
gyp verb extracted file from tarball include\node\openssl\asn1.h
gyp verb extracted file from tarball include\node\openssl\asn1_mac.h
gyp verb extracted file from tarball include\node\openssl\asn1t.h
gyp verb extracted file from tarball include\node\openssl\bio.h
gyp verb extracted file from tarball include\node\openssl\blowfish.h
gyp verb extracted file from tarball include\node\openssl\bn.h
gyp verb extracted file from tarball include\node\openssl\buffer.h
gyp verb extracted file from tarball include\node\openssl\camellia.h
gyp verb extracted file from tarball include\node\openssl\cast.h
gyp verb extracted file from tarball include\node\openssl\cmac.h
gyp verb extracted file from tarball include\node\openssl\cms.h
gyp verb extracted file from tarball include\node\openssl\comp.h
gyp verb extracted file from tarball include\node\openssl\conf.h
gyp verb extracted file from tarball include\node\openssl\conf_api.h
gyp verb extracted file from tarball include\node\openssl\crypto.h
gyp verb extracted file from tarball include\node\openssl\des.h
gyp verb extracted file from tarball include\node\openssl\des_old.h
gyp verb extracted file from tarball include\node\openssl\dh.h
gyp verb extracted file from tarball include\node\openssl\dsa.h
gyp verb extracted file from tarball include\node\openssl\dso.h
gyp verb extracted file from tarball include\node\openssl\dtls1.h
gyp verb extracted file from tarball include\node\openssl\e_os2.h
gyp verb extracted file from tarball include\node\openssl\ebcdic.h
gyp verb extracted file from tarball include\node\openssl\ec.h
gyp verb extracted file from tarball include\node\openssl\ecdh.h
gyp verb extracted file from tarball include\node\openssl\ecdsa.h
gyp verb extracted file from tarball include\node\openssl\engine.h
gyp verb extracted file from tarball include\node\openssl\err.h
gyp verb extracted file from tarball include\node\openssl\evp.h
gyp verb extracted file from tarball include\node\openssl\hmac.h
gyp verb extracted file from tarball include\node\openssl\idea.h
gyp verb extracted file from tarball include\node\openssl\krb5_asn.h
gyp verb extracted file from tarball include\node\openssl\kssl.h
gyp verb extracted file from tarball include\node\openssl\lhash.h
gyp verb extracted file from tarball include\node\openssl\md4.h
gyp verb extracted file from tarball include\node\openssl\md5.h
gyp verb extracted file from tarball include\node\openssl\mdc2.h
gyp verb extracted file from tarball include\node\openssl\modes.h
gyp verb extracted file from tarball include\node\openssl\obj_mac.h
gyp verb extracted file from tarball include\node\openssl\objects.h
gyp verb extracted file from tarball include\node\openssl\ocsp.h
gyp verb extracted file from tarball include\node\openssl\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\opensslv.h
gyp verb extracted file from tarball include\node\openssl\ossl_typ.h
gyp verb extracted file from tarball include\node\openssl\pem2.h
gyp verb extracted file from tarball include\node\openssl\pkcs12.h
gyp verb extracted file from tarball include\node\openssl\pkcs7.h
gyp verb extracted file from tarball include\node\openssl\pqueue.h
gyp verb extracted file from tarball include\node\openssl\rand.h
gyp verb extracted file from tarball include\node\openssl\rc2.h
gyp verb extracted file from tarball include\node\openssl\rc4.h
gyp verb extracted file from tarball include\node\openssl\ripemd.h
gyp verb extracted file from tarball include\node\openssl\rsa.h
gyp verb extracted file from tarball include\node\openssl\safestack.h
gyp verb extracted file from tarball include\node\openssl\seed.h
gyp verb extracted file from tarball include\node\openssl\sha.h
gyp verb extracted file from tarball include\node\openssl\srp.h
gyp verb extracted file from tarball include\node\openssl\srtp.h
gyp verb extracted file from tarball include\node\openssl\ssl.h
gyp verb extracted file from tarball include\node\openssl\ssl2.h
gyp verb extracted file from tarball include\node\openssl\ssl23.h
gyp verb extracted file from tarball include\node\openssl\ssl3.h
gyp verb extracted file from tarball include\node\openssl\stack.h
gyp verb extracted file from tarball include\node\openssl\symhacks.h
gyp verb extracted file from tarball include\node\openssl\tls1.h
gyp verb extracted file from tarball include\node\openssl\ts.h
gyp verb extracted file from tarball include\node\openssl\txt_db.h
gyp verb extracted file from tarball include\node\openssl\ui.h
gyp verb extracted file from tarball include\node\openssl\ui_compat.h
gyp verb extracted file from tarball include\node\openssl\whrlpool.h
gyp verb extracted file from tarball include\node\openssl\x509.h
gyp verb extracted file from tarball include\node\openssl\x509_vfy.h
gyp verb extracted file from tarball include\node\openssl\x509v3.h
gyp verb extracted file from tarball include\node\openssl\archs\VC-WIN64A\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\VC-WIN32\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\solaris64-x86_64-gcc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\solaris-x86-gcc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux64-s390x\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux32-s390x\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-x86_64\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-x32\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-ppc64\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-ppc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-elf\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-armv4\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\linux-aarch64\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\darwin64-x86_64-cc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\darwin-i386-cc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\BSD-x86_64\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\BSD-x86\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\aix64-gcc\opensslconf.h
gyp verb extracted file from tarball include\node\openssl\archs\aix-gcc\opensslconf.h
gyp verb extracted file from tarball include\node\libplatform\libplatform.h
gyp verb tarball done parsing tarball
gyp verb on Windows; need to download `node.lib`...
gyp verb 32-bit node.lib dir C:\Users\IEUser\.node-gyp\6.9.1\ia32
gyp verb 64-bit node.lib dir C:\Users\IEUser\.node-gyp\6.9.1\x64
gyp verb `node.lib` 32-bit url https://nodejs.org/download/release/v6.9.1/win-x86/node.lib
gyp verb `node.lib` 64-bit url https://nodejs.org/download/release/v6.9.1/win-x64/node.lib
gyp verb streaming 32-bit node.lib to: C:\Users\IEUser\.node-gyp\6.9.1\ia32\node.lib
gyp http GET https://nodejs.org/download/release/v6.9.1/win-x86/node.lib
gyp verb streaming 64-bit node.lib to: C:\Users\IEUser\.node-gyp\6.9.1\x64\node.lib
gyp http GET https://nodejs.org/download/release/v6.9.1/win-x64/node.lib
gyp http 200 https://nodejs.org/download/release/v6.9.1/win-x86/node.lib
gyp http 200 https://nodejs.org/download/release/v6.9.1/win-x64/node.lib
gyp WARN install got an error, rolling back install
gyp verb command remove [ '6.9.1' ]
gyp verb remove using node-gyp dir: C:\Users\IEUser\.node-gyp
gyp verb remove removing target version: 6.9.1
gyp verb remove removing development files for version: 6.9.1
gyp verb content checksum win-x64/node.lib 685fde4c9104514e91a42ebe092bd0485fa8b4a844a94a7c75f81d23500c71da
gyp ERR! configure error
gyp ERR! stack Error: read ECONNRESET
gyp ERR! stack     at exports._errnoException (util.js:1026:11)
gyp ERR! stack     at TLSWrap.onread (net.js:569:26)
gyp ERR! System Windows_NT 10.0.14393
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\IEUser\\AppData\\Roaming\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--tarball" "./node-v6.9.1-headers.tar.gz" "--verbose"
gyp ERR! cwd C:\work\voltra
gyp ERR! node -v v6.9.1
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok

@bnoordhuis
Copy link
Member

The checksum doesn't match, compare it with https://nodejs.org/download/release/v6.9.1/SHASUMS256.txt.

I'm going to guess it's something in your local network, like a virus scanner that doesn't like .lib files or some kind of corporate man-in-the-middle software. Do you have ca or npm_config_ca set in your .npmrc or environment?

@heapwolf
Copy link
Author

This is just a virtualbox image on macos, im not behind a corporate network or anything, all of this software installs fin on my mac (i also have a linux virtualbox with ubuntu and elementaryos, which these packages install fine onto). I haven't installed any additional software onto the OS, i just kept it as-is from Microsoft. I actually didn't make an .npmrc since these are all public repos, do you think that would help?

@bnoordhuis
Copy link
Member

No, a .npmrc shouldn't be necessary in that case. I don't know what is causing your issue though, only that the downloads somehow seem to end up corrupt.

@heapwolf
Copy link
Author

just to be sure curl wasn't downloading node.lib incorrectly, i used chrome to download it and then moved it into place, this was the relevant output I got...

gyp verb remove using node-gyp dir: C:\Users\IEUser\.node-gyp
gyp verb remove removing target version: 6.9.1
gyp verb remove removing development files for version: 6.9.1
gyp verb content checksum win-x64/node.lib c0ef57af7a9aa17ef963a7947ff6ec6ce86656dd22afbf2818f293ea074d4486
gyp verb content checksum win-x86/node.lib 94dedeba6b9823cbfbb6772e3a7a0cc13084e15dfb57b1fd7a478ef6f3207ee2
gyp verb download contents checksum {"win-x64/node.lib":"c0ef57af7a9aa17ef963a7947ff6ec6ce86656dd22afbf2818f293ea074d4486","win-x86/node.lib":"94dedeba6b9823cbfbb6772e3a7a0cc13084e15dfb57b1fd7a478ef6f3207ee2"}
gyp verb validating download checksum for win-x64/node.lib (c0ef57af7a9aa17ef963a7947ff6ec6ce86656dd22afbf2818f293ea074d4486 == undefined)

The last line seems suspicious.

@bnoordhuis
Copy link
Member

It means node-gyp couldn't find an entry in SHA256SUMS.txt. However, the checksum isn't right to start with. I just downloaded https://nodejs.org/download/release/v6.9.1/win-x64/node.lib and it checksums correctly to 3951aefa4afd6fb836ab06468b1fc2a69fa75bd66ec2f5a0e08c4e32547681e3.

@heapwolf
Copy link
Author

If I curl node.lib and then sha256sum.exe ~/.node-gyp/6.9.1/x64/node.lib I get the same hash as you though.

IEUser@MSEDGEWIN10 MINGW64 /c/work/voltra (master)
$ curl -sL https://nodejs.org/download/release/v6.9.1/win-x64/node.lib > ~/.node-gyp/6.9.1/x64/node.lib

IEUser@MSEDGEWIN10 MINGW64 /c/work/voltra (master)
$ sha256sum.exe ~/.node-gyp/6.9.1/x64/node.lib
3951aefa4afd6fb836ab06468b1fc2a69fa75bd66ec2f5a0e08c4e32547681e3 */c/Users/IEUser/.node-gyp/6.9.1/x64/node.lib

@bnoordhuis
Copy link
Member

I suppose it's possible there is a bug in node-gyp somewhere but I can't reproduce locally and I haven't received similar bug reports so whatever it is, it must be fairly subtle and infrequent. If you have time and inclination, you could start by peppering log statements all over lib/install.js.

@tex0l
Copy link

tex0l commented Oct 26, 2016

Hi,
I have the exact same issue with a node 6.9.1, node-gyp 3.4.0 running on Windows 10 with a virtualbox Version 5.0.28 r111378 running on OSX 10.11.6.
It seems the connection resets each for an unknown reason, and then the file gets corrupted (checksums don't match).

@tex0l
Copy link

tex0l commented Oct 26, 2016

Ok, I've found the problem for me:
The 5.0.28 version of VirtualBox along with the 5.1.8 have an issue that randomly resets connections see: https://www.virtualbox.org/ticket/16084

I've upgraded from 5.0.28 to 5.1.6, and it works fine. Downgrading to 5.0.26 would have been fine too I suppose.

@heapwolf
Copy link
Author

@tex0l that was it for me! im satisfied.

@wotbstars
Copy link

wotbstars commented May 17, 2017

Getting the same error. Using OSX and VirtualBox/docker containers.

[root@7d0532304033 x-Node]# node-gyp-install
node-gyp-install http request https://nodejs.org/dist/v6.9.5/node-v6.9.5.tar.gz
node-gyp-install http 200 https://nodejs.org/dist/v6.9.5/node-v6.9.5.tar.gz
Error: unexpected end of file

And yes VirtualBox upgrade helped

@philippzentner
Copy link

Same issue is happening again with Virtual Box 6.0.10

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

5 participants