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

Install failing - something about gyp not supporting Python 3? #18

Open
juliavdkris opened this issue Feb 25, 2021 · 9 comments
Open

Install failing - something about gyp not supporting Python 3? #18

juliavdkris opened this issue Feb 25, 2021 · 9 comments
Labels
blocked Something blocks the workflow infos needed Extra informations are needed

Comments

@juliavdkris
Copy link

~ ❯ yarn global add glci                                                                                                                                                                                                               08:33:56
yarn global v1.22.10
[1/4] Resolving packages...
warning glci > nodegit > [email protected]: Please upgrade to @mapbox/node-pre-gyp: the non-scoped node-pre-gyp package is deprecated and only the @mapbox scoped package will recieve updates in the future
warning glci > nodegit > node-gyp > [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142
warning glci > nodegit > node-gyp > request > [email protected]: this library is no longer supported
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
error /home/sam/.config/yarn/global/node_modules/nodegit: Command failed.
Exit code: 1
Command: node lifecycleScripts/preinstall && node lifecycleScripts/install
Arguments: 
Directory: /home/sam/.config/yarn/global/node_modules/nodegit
Output:
[nodegit] Running pre-install script
[nodegit] Running install script
node-pre-gyp
info it worked if it ends with ok
node-pre-gyp
info using [email protected]
node-pre-gyp info using
[email protected] | linux | x64
node-pre-gyp WARN
Using request for node-pre-gyp https download
node-pre-gyp
info check checked for "/home/sam/.config/yarn/global/node_modules/nodegit/build/Release/nodegit.node" (not found)
node-pre-gyp
http GET https://axonodegit.s3.amazonaws.com/nodegit/nodegit/nodegit-v0.27.0-node-v88-linux-x64.tar.gz
node-pre-gyp http 404 https://axonodegit.s3.amazonaws.com/nodegit/nodegit/nodegit-v0.27.0-node-v88-linux-x64.tar.gz
node-pre-gyp WARN Tried to download(404): https://axonodegit.s3.amazonaws.com/nodegit/nodegit/nodegit-v0.27.0-node-v88-linux-x64.tar.gz 
node-pre-gyp
WARN Pre-built binaries not found for [email protected] and [email protected] (node-v88 ABI, glibc) (falling back to source compile with node-gyp) 
node-pre-gyp http 404 status code downloading tarball https://axonodegit.s3.amazonaws.com/nodegit/nodegit/nodegit-v0.27.0-node-v88-linux-x64.tar.gz
gyp

info it worked if it ends with ok
gyp
info using [email protected]
gyp info using [email protected] | linux | x64
gyp
info ok
gyp
info
it worked if it ends with ok
gyp
info using [email protected]
gyp info using [email protected] | linux | x64
gyp
ERR! configure error
gyp
ERR! stack Error: Python executable "/usr/bin/python" is v3.9.2, which is not supported by gyp.
gyp ERR! stack You can pass the --python switch to point to Python >= v2.5.0 & < 3.0.0.
gyp ERR! stack     at PythonFinder.failPythonVersion (/home/sam/.config/yarn/global/node_modules/node-gyp/lib/configure.js:493:19)
gyp ERR! stack     at PythonFinder.<anonymous> (/home/sam/.config/yarn/global/node_modules/node-gyp/lib/configure.js:475:14)
gyp ERR! stack     at ChildProcess.exithandler (node:child_process:317:7)
gyp ERR! stack     at ChildProcess.emit (node:events:378:20)
gyp
ERR! stack     at maybeClose (node:internal/child_process:1067:16)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (node:internal/child_process:301:5)
gyp ERR!
System Linux 5.11.1-zen1-1-zen
gyp ERR! command "/usr/bin/node" "/home/sam/.config/yarn/global/node_modules/node-gyp/bin/node-gyp.js" "configure" "--fallback-to-build" "--module=/home/sam/.config/yarn/global/node_modules/nodegit/build/Release/nodegit.node" "--module_name=nodegit" "--module_path=/home/sam/.config/yarn/global/node_modules/nodegit/build/Release" "--napi_version=7" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v88"
gyp ERR!
cwd /home/sam/.config/yarn/global/node_modules/nodegit
gyp ERR! node -v v15.10.0
gyp ERR! node-gyp -v v4.0.0
gyp ERR!
not ok
node-pre-gyp
ERR! build error
node-pre-gyp ERR!
stack Error: Failed to execute '/usr/bin/node /home/sam/.config/yarn/global/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/home/sam/.config/yarn/global/node_modules/nodegit/build/Release/nodegit.node --module_name=nodegit --module_path=/home/sam/.config/yarn/global/node_modules/nodegit/build/Release --napi_version=7 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v88' (1)
node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/home/sam/.config/yarn/global/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack
at ChildProcess.emit (node:events:378:20)
node-pre-gyp ERR! stack     at maybeClose (node:internal/child_process:1067:16)
node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (node:internal/child_process:301:5)
node-pre-gyp
ERR! System Linux 5.11.1-zen1-1-zen
node-pre-gyp ERR! command "/usr/bin/node" "/home/sam/.config/yarn/global/node_modules/nodegit/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR!
cwd /home/sam/.config/yarn/global/node_modules/nodegit
node-pre-gyp ERR! node -v v15.10.0
node-pre-gyp ERR! node-pre-gyp -v v0.13.0
node-pre-gyp ERR! not ok
Failed to execute '/usr/bin/node /home/sam/.config/yarn/global/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/home/sam/.config/yarn/global/node_modules/nodegit/build/Release/nodegit.node --module_name=nodegit --module_path=/home/sam/.config/yarn/global/node_modules/nodegit/build/Release --napi_version=7 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v88' (1)
[nodegit] ERROR - Could not finish install
[nodegit] ERROR - finished with error code: 1
info Visit https://yarnpkg.com/en/docs/cli/global for documentation about this command.
@gilzow
Copy link

gilzow commented Feb 25, 2021

Just ran into a similar issue as @samvdkris. For me, I had to completely uninstall xcode (even though I already had it installed, and it was working as it should) and reinstall xcode before glci would install correctly.

@juliavdkris
Copy link
Author

I don't have xcode though, I'm on Linux lmao

@mdubourg001
Copy link
Owner

mdubourg001 commented Feb 26, 2021

I did not take the time to fully dig the problem here, by my guess is that the issue comes from the version of node-gyp used by the nodegit dependency: nodegit uses [email protected] while the latest release is [email protected].

Some research work has to be made: does bumping node-gyp in the nodegit package to a fresher release fixes the issue ?

@mdubourg001 mdubourg001 added blocked Something blocks the workflow infos needed Extra informations are needed labels Feb 26, 2021
@ovitor
Copy link

ovitor commented Mar 9, 2021

I'm also have similar issue while installing glci. What kind of information could help you to help me? :D

great tool by the way!

@mdubourg001
Copy link
Owner

I also ran into an issue of this kind lately. If I remember well, running yarn global upgrade before installing glci helped, could you try ?

@ovitor
Copy link

ovitor commented Mar 9, 2021

unfortunately, same error as before

x250:~ $ yarn global add glci
yarn global v1.22.10
[1/4] Resolving packages...
warning glci > nodegit > [email protected]: Please upgrade to @mapbox/node-pre-gyp: the non-scoped node-pre-gyp package is deprecated and only the @mapbox scoped package will recieve updates in the future
warning glci > nodegit > node-gyp > [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142
[2/4] Fetching packages...
warning [email protected]: The engine "git" appears to be invalid.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
error /home/vitor/.config/yarn/global/node_modules/nodegit: Command failed.
Exit code: 1
Command: node lifecycleScripts/preinstall && node lifecycleScripts/install
Arguments:
Directory: /home/vitor/.config/yarn/global/node_modules/nodegit
Output:
[nodegit] Running pre-install script
[nodegit] Running install script
node-pre-gyp
info it worked if it ends with ok
node-pre-gyp
info using [email protected]
node-pre-gyp info using [email protected] | linux | x64
node-pre-gyp WARN
Using request for node-pre-gyp https download
node-pre-gyp
info check checked for "/home/vitor/.config/yarn/global/node_modules/nodegit/build/Release/nodegit.node" (not found)
node-pre-gyp
http GET https://axonodegit.s3.amazonaws.com/nodegit/nodegit/nodegit-v0.27.0-node-v88-linux-x64.tar.gz
node-pre-gyp
http 404 https://axonodegit.s3.amazonaws.com/nodegit/nodegit/nodegit-v0.27.0-node-v88-linux-x64.tar.gz
node-pre-gyp
WARN Tried to download(404): https://axonodegit.s3.amazonaws.com/nodegit/nodegit/nodegit-v0.27.0-node-v88-linux-x64.tar.gz
node-pre-gyp WARN Pre-built binaries not found for [email protected] and [email protected] (node-v88 ABI, glibc) (falling back to source compile with node-gyp)
node-pre-gyp http 404 status code downloading tarball https://axonodegit.s3.amazonaws.com/nodegit/nodegit/nodegit-v0.27.0-node-v88-linux-x64.tar.gz
gyp
info
it worked if it ends with ok
gyp
info using [email protected]
gyp info using [email protected] | linux | x64
gyp
info ok
gyp
info
it worked if it ends with ok
gyp
info using [email protected]
gyp info using [email protected] | linux | x64
gyp
ERR! configure error
gyp

ERR!
stack Error: Python executable "/usr/bin/python" is v3.9.2, which is not supported by gyp.
gyp ERR! stack You can pass the --python switch to point to Python >= v2.5.0 & < 3.0.0.
gyp ERR! stack     at PythonFinder.failPythonVersion (/home/vitor/.config/yarn/global/node_modules/node-gyp/lib/configure.js:493:19)
gyp ERR! stack     at PythonFinder.<anonymous> (/home/vitor/.config/yarn/global/node_modules/node-gyp/lib/configure.js:475:14)
gyp ERR! stack     at ChildProcess.exithandler (node:child_process:317:7)
gyp ERR! stack     at ChildProcess.emit (node:events:378:20)
gyp ERR! stack
at maybeClose (node:internal/child_process:1067:16)
gyp ERR! stack     at Socket.<anonymous> (node:internal/child_process:453:11)
gyp ERR! stack     at Socket.emit (node:events:378:20)
gyp ERR! stack     at Pipe.<anonymous> (node:net:665:12)
gyp ERR! System Linux 5.11.2-arch1-1
gyp ERR! command "/usr/bin/node" "/home/vitor/.config/yarn/global/node_modules/node-gyp/bin/node-gyp.js" "configure" "--fallback-to-build" "--module=/home/vitor/.config/yarn/global/node_modules/nodegit/build/Release/nodegit.node" "--module_name=nodegit" "--module_path=/home/vitor/.config/yarn/global/node_modules/nodegit/build/Release" "--napi_version=7" "--node_abi_napi=napi" "--napi_build_version=0" "--node_napi_label=node-v88"
gyp ERR! cwd /home/vitor/.config/yarn/global/node_modules/nodegit
gyp ERR! node -v
v15.11.0
gyp ERR! node-gyp -v v4.0.0
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR!
stack Error: Failed to execute '/usr/bin/node /home/vitor/.config/yarn/global/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/home/vitor/.config/yarn/global/node_modules/nodegit/build/Release/nodegit.node --module_name=nodegit --module_path=/home/vitor/.config/yarn/global/node_modules/nodegit/build/Release --napi_version=7 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v88' (1)
node-pre-gyp ERR! stack     at ChildProcess.<anonymous> (/home/vitor/.config/yarn/global/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack     at ChildProcess.emit (node:events:378:20)
node-pre-gyp ERR! stack     at maybeClose (node:internal/child_process:1067:16)
node-pre-gyp ERR! stack     at Process.ChildProcess._handle.onexit (node:internal/child_process:301:5)
node-pre-gyp ERR!
System Linux 5.11.2-arch1-1
node-pre-gyp
ERR! command "/usr/bin/node" "/home/vitor/.config/yarn/global/node_modules/nodegit/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build"
node-pre-gyp ERR! cwd /home/vitor/.config/yarn/global/node_modules/nodegit
node-pre-gyp ERR! node -v v15.11.0
node-pre-gyp ERR! node-pre-gyp -v v0.13.0
node-pre-gyp ERR! not ok
Failed to execute '/usr/bin/node /home/vitor/.config/yarn/global/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --module=/home/vitor/.config/yarn/global/node_modules/nodegit/build/Release/nodegit.node --module_name=nodegit --module_path=/home/vitor/.config/yarn/global/node_modules/nodegit/build/Release --napi_version=7 --node_abi_napi=napi --napi_build_version=0 --node_napi_label=node-v88' (1)
[nodegit] ERROR - Could not finish install
[nodegit] ERROR - finished with error code: 1
info Visit https://yarnpkg.com/en/docs/cli/global for documentation about this command.

@SuperSandro2000
Copy link

ERR! stack Error: Python executable "/usr/bin/python" is v3.9.2, which is not supported by gyp.

gyp requires python 2.

@juliavdkris
Copy link
Author

@mdubourg001 Just tried that, same error.

@SuperSandro2000 Yep, that's what I was afraid of... Python 2.x has been EOL for more than a year now, really wished people would stop using it.

You can pass the --python switch to point to Python >= v2.5.0 & < 3.0.0.

@flamendless
Copy link

Getting the same error. Whats the correct command?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked Something blocks the workflow infos needed Extra informations are needed
Projects
None yet
Development

No branches or pull requests

6 participants