banacorn / language-agda

Agda language support for the Atom editor
https://atom.io/packages/language-agda
MIT License
13 stars 5 forks source link

Installation problems of the version 1.0.3 #12

Closed jonaprieto closed 6 years ago

jonaprieto commented 6 years ago
Installing “language-agda@1.0.3” failed.Hide output…

> tree-sitter-agda@1.0.8 install /private/var/folders/fr/rw0k3h0n79ldnb43hd98w4dh0000gn/T/apm-install-dir-11865-38850-z53r23.ve6dm18aor/node_modules/language-agda/node_modules/tree-sitter-agda
> node-gyp rebuild

gyp ERR! configure error 
gyp ERR! stack Error: Python executable "/Applications/Atom.app/Contents/Resources/app/apm/bin/python-interceptor.sh" is v3.6.5, 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 failPythonVersion (/Applications/Atom.app/Contents/Resources/app/apm/node_modules/node-gyp/lib/configure.js:454:14)
gyp ERR! stack     at /Applications/Atom.app/Contents/Resources/app/apm/node_modules/node-gyp/lib/configure.js:443:9
gyp ERR! stack     at ChildProcess.exithandler (child_process.js:197:7)
gyp ERR! stack     at emitTwo (events.js:106:13)
gyp ERR! stack     at ChildProcess.emit (events.js:191:7)
gyp ERR! stack     at maybeClose (internal/child_process.js:877:16)
gyp ERR! stack     at Socket.<anonymous> (internal/child_process.js:334:11)
gyp ERR! stack     at emitOne (events.js:96:13)
gyp ERR! stack     at Socket.emit (events.js:188:7)
gyp ERR! stack     at Pipe._handle.close [as _onclose] (net.js:498:12)
gyp ERR! System Darwin 17.6.0
gyp ERR! command "/Applications/Atom.app/Contents/Resources/app/apm/bin/node" "/Applications/Atom.app/Contents/Resources/app/apm/node_modules/.bin/node-gyp" "rebuild"
gyp ERR! cwd /private/var/folders/fr/rw0k3h0n79ldnb43hd98w4dh0000gn/T/apm-install-dir-11865-38850-z53r23.ve6dm18aor/node_modules/language-agda/node_modules/tree-sitter-agda
gyp ERR! node -v v6.9.5
gyp ERR! node-gyp -v v3.4.0
gyp ERR! not ok 
npm WARN enoent ENOENT: no such file or directory, open '/private/var/folders/fr/rw0k3h0n79ldnb43hd98w4dh0000gn/T/apm-install-dir-11865-38850-z53r23.ve6dm18aor/package.json'
npm WARN apm-install-dir-11865-38850-z53r23.ve6dm18aor No description
npm WARN apm-install-dir-11865-38850-z53r23.ve6dm18aor No repository field.
npm WARN apm-install-dir-11865-38850-z53r23.ve6dm18aor No README data
npm WARN apm-install-dir-11865-38850-z53r23.ve6dm18aor No license field.
npm ERR! Darwin 17.6.0
npm ERR! argv "/Applications/Atom.app/Contents/Resources/app/apm/bin/node" "/Applications/Atom.app/Contents/Resources/app/apm/node_modules/npm/bin/npm-cli.js" "--globalconfig" "/Users/jonaprieto/.atom/.apm/.apmrc" "--userconfig" "/Users/jonaprieto/.atom/.apmrc" "install" "/private/var/folders/fr/rw0k3h0n79ldnb43hd98w4dh0000gn/T/d-11865-38850-zuf82o.afcxh1714i/package.tgz" "--runtime=electron" "--target=2.0.3" "--arch=x64" "--global-style"
npm ERR! node v6.9.5
npm ERR! npm  v3.10.10
npm ERR! code ELIFECYCLE

npm ERR! tree-sitter-agda@1.0.8 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the tree-sitter-agda@1.0.8 install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the tree-sitter-agda package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs tree-sitter-agda
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls tree-sitter-agda
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /private/var/folders/fr/rw0k3h0n79ldnb43hd98w4dh0000gn/T/apm-install-dir-11865-38850-z53r23.ve6dm18aor/npm-debug.log
jonaprieto commented 6 years ago

It seems that this an issue about my python version which is 3.6.x. I fixed the problem for the installation to use python 2.7 modifying the following file:

/Applications/Atom.app/Contents/Resources/app/apm/bin/python-interceptor.sh

image

banacorn commented 6 years ago

Hmm interesting, didn't Atom comes with its version of Python for compiling these things?

jonaprieto commented 6 years ago

Yes, that's what I thought. But It didn't work after reinstalling Atom and test other things, only this trick works.

banacorn commented 6 years ago

Ran into the same problem (in #FLOLAC'18, on a student's laptop), I think this issue should be kept opened.

MatthijsBlom commented 6 years ago

I think running (as Administrator)

> npm install --global --production windows-build-tools

may solve this problem, as it says it installs Python 2.7. I'm not sure I have tested this myself, though.

banacorn commented 6 years ago

@MatthijsBlom thanks!

banacorn commented 6 years ago

I've managed to pre-build the binaries for all platforms on the CI services.

I'm closing this issue, please reopen it if there's any problem after installing the latest version (v1.0.8)