Closed fusion809 closed 8 years ago
Thanks. I reported it the nodejs maintener https://bugs.archlinux.org/task/51628.
Seems like this is back? Trying to install packages in Atom gives me the above error. Running APM on the command line gives me same.
What I did was:
npm install git-utils
node_modules
and copy it where Apm needs it: sudo cp -r ./node_modules/* /usr/lib/node_modules/atom-package-manager/node_modules
@Xananax, can you tell me what is the apm command that triggered the error and the exact output?
I was opening the settings view:install packages and themes
panel inside Atom. I also got a separate notification about being unable to update the "React" package.
Unfortunately my memory is really bad, and I was doing a bunch of things at the same time. I triggered the above error by either just simply opening the panel or when I tried to install/update packages.
I didn't even know what APM was, I just got the error in the Atom console at the bottom. I figured it was probably a separate package manager for Atom, I went to a terminal and I'm pretty much certain I just ran apm
with no arguments, but maybe I tried apm react
.
I'm on Arch Linux, using the official atom package, with a fairly frequently updated system (every other day or so).
Actually, I reinstalled the atom package from source, and I get the error again.
I confirm that I get it in atom when updating/installing, and in a terminal by simply running apm
.
module.js:681
return process.dlopen(module, path._makeLong(filename));
^
Error: The module '/usr/lib/node_modules/atom-package-manager/node_modules/git-utils/build/Release/git.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 59. This version of Node.js requires
NODE_MODULE_VERSION 57. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or `npm install`).
at Object.Module._extensions..node (module.js:681:18)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)
at Module.require (module.js:596:17)
at require (internal/module.js:11:18)
at Object.<anonymous> (/usr/lib/node_modules/atom-package-manager/node_modules/git-utils/lib/git.js:8:16)
at Object.<anonymous> (/usr/lib/node_modules/atom-package-manager/node_modules/git-utils/lib/git.js:371:4)
at Module._compile (module.js:652:30)
at Object.Module._extensions..js (module.js:663:10)
Since I don't immediately need apm, I can leave it in that state if you'd like me to help in any way.
Please note that I previously tried pacman -S apm
and it did not trigger the error. Installing atom did.
If I understand correctly you installed atom from source, without building it form this PKGBUILD. The Arch packages of apm and atom are designed so that apm uses the system installed node executable. If you build form source it may download its own version of node which uses NODE_MODULE_VERSION 57
.
BTW, the command to update atom packages from the command line is apm update
.
What version of nodejs are you running?
If I understand correctly you installed atom from source, without building it form this PKGBUILD
I used the default package. However,
What version of nodejs are you running?
I think you put your finger on it; I don't have the regular nodejs
package, I am using, for some reason nodejs-lts-carbon. I have no recollection of this, some package must've needed it and I switched them without thinking.
I confirm that if I uninstall pacman -R nodejs-lts-carbon
and reinstall pacman -S nodejs
, Apm & Atom both work. The problem was on my end, I'm truly sorry for the bother and the waste of time.
Thanks for the support!
Thanks for reporting, I will add the dependency nodejs>=9
in the next release.
I got this error too. But my solution is more simple.
Just go to '/usr/lib/node_modules/atom-package-manager/' and run sudo npm install git-utils
.
Hi,
Whenever I run
apm update
I get the error message:this error message seems to me to be saying you need to re-compile APM against the new Node.js. So please bump APM's pkgrel to get the Arch Linux build servers to do the required rebuild.
Thanks for your time, Brenton