Closed zPie033 closed 3 years ago
I guess is not related to harp see https://docs.npmjs.com/getting-started/fixing-npm-permissions
or chown -r yourUser /usr/local/lib/node_modules
It returns this:
chown: illegal option -- r
usage: chown [-fhv] [-R [-H | -L | -P]] owner[:group] file ...
chown [-fhv] [-R [-H | -L | -P]] :group file ...
I tried to follow one of the doc that you sent (option two), this is what I wrote and what it returned:
MacAIRdettinati:~ Pimalo$ mkdir ~/.npm-global
MacAIRdettinati:~ Pimalo$ npm config set prefix '~/.npm-global'
MacAIRdettinati:~ Pimalo$ export PATH=~/.npm-global/bin:$PATH
MacAIRdettinati:~ Pimalo$ source ~/.profile
MacAIRdettinati:~ Pimalo$ npm install harp
npm WARN deprecated connect@2.30.2: connect 2.x series is deprecated
npm WARN deprecated graceful-fs@3.0.11: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
npm WARN deprecated coffee-script@1.12.7: CoffeeScript on NPM has moved to "coffeescript" (no hyphen)
> node-sass@4.7.2 install /Users/Pimalo/node_modules/node-sass
> node scripts/install.js
Downloading binary from https://github.com/sass/node-sass/releases/download/v4.7.2/darwin-x64-57_binding.node
Download complete ░⸩ ⠋ :
Binary saved to /Users/Pimalo/node_modules/node-sass/vendor/darwin-x64-57/binding.node
Caching binary to /Users/Pimalo/.npm/node-sass/4.7.2/darwin-x64-57_binding.node
> node-sass@4.7.2 postinstall /Users/Pimalo/node_modules/node-sass
> node scripts/build.js
Binary found at /Users/Pimalo/node_modules/node-sass/vendor/darwin-x64-57/binding.node
Testing binary
Binary is fine
npm WARN saveError ENOENT: no such file or directory, open '/Users/Pimalo/package.json'
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN enoent ENOENT: no such file or directory, open '/Users/Pimalo/package.json'
npm WARN Pimalo No description
npm WARN Pimalo No repository field.
npm WARN Pimalo No README data
npm WARN Pimalo No license field.
+ harp@0.25.0
then I wrote harp -V
and it returned this:
Error: ENOENT: no such file or directory, scandir '/usr/local/lib/node_modules/harp/node_modules/node-sass/vendor'
at Object.fs.readdirSync (fs.js:904:18)
at Object.getInstalledBinaries (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/extensions.js:128:13)
at foundBinariesList (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/errors.js:20:15)
at foundBinaries (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/errors.js:15:5)
at Object.module.exports.missingBinary (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/errors.js:45:5)
at module.exports (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/binding.js:15:30)
at Object.<anonymous> (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/index.js:14:35)
at Module._compile (module.js:635:30)
at Object.Module._extensions..js (module.js:646:10)
at Module.load (module.js:554:32)
I also tried to do this:
cd /Users/Pimalo
ls
Applications Music
ClownfishForTeamspeak.ini Pictures
Desktop Progetto senza titolo.osp
Documents Public
Downloads node_modules
Library package-lock.json
Movies thumbnail
MacAIRdettinati:~ Pimalo$ npm init
This utility will walk you through creating a package.json file.
It only covers the most common items, and tries to guess sensible defaults.
See `npm help json` for definitive documentation on these fields
and exactly what they do.
Use `npm install <pkg>` afterwards to install a package and
save it as a dependency in the package.json file.
Press ^C at any time to quit.
package name: (pimalo) package
version: (1.0.0)
description:
entry point: (index.js)
test command:
git repository:
keywords:
author:
license: (ISC)
About to write to /Users/Pimalo/package.json:
{
"name": "package",
"version": "1.0.0",
"description": "",
"main": "index.js",
"dependencies": {
"harp": "^0.25.0"
},
"devDependencies": {},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC"
}
Is this ok? (yes) yes
MacAIRdettinati:~ Pimalo$ npm install harp
npm WARN deprecated connect@2.30.2: connect 2.x series is deprecated
npm WARN deprecated graceful-fs@3.0.11: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
npm WARN deprecated coffee-script@1.12.7: CoffeeScript on NPM has moved to "coffeescript" (no hyphen)
npm WARN package@1.0.0 No description
npm WARN package@1.0.0 No repository field.
+ harp@0.25.0
updated 1 package in 12.606s
MacAIRdettinati:~ Pimalo$ harp -V
fs.js:904
return binding.readdir(pathModule._makeLong(path), options.encoding);
^
Error: ENOENT: no such file or directory, scandir '/usr/local/lib/node_modules/harp/node_modules/node-sass/vendor'
at Object.fs.readdirSync (fs.js:904:18)
at Object.getInstalledBinaries (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/extensions.js:128:13)
at foundBinariesList (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/errors.js:20:15)
at foundBinaries (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/errors.js:15:5)
at Object.module.exports.missingBinary (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/errors.js:45:5)
at module.exports (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/binding.js:15:30)
at Object.<anonymous> (/usr/local/lib/node_modules/harp/node_modules/node-sass/lib/index.js:14:35)
at Module._compile (module.js:635:30)
at Object.Module._extensions..js (module.js:646:10)
at Module.load (module.js:554:32)
After that I tried to uninstall and install harp, but it didn't work and I also tried to install it doing npm install -g harp.
I ran brew doctor, and followed the instructions, after that I tried to install harp but it didn't work, these were the commands that I ran before trying to install Harp again:
brew unlink node@8
brew link node
I have the same problem. I am running a clean docker container from Alpine Linux and try to run npm install -g harp
which fails with the same error. There seems to be a call to mkdir
, which must be changed to mkdir -p
, because more than one directory has to be created:
root@base[7ba79354c4a6]:/# mkdir '/usr/lib/node_modules/harp/node_modules/node-sass/vendor'
mkdir: can't create directory '/usr/lib/node_modules/harp/node_modules/node-sass/vendor': No such file or directory
root@base[7ba79354c4a6]:/# mkdir -p '/usr/lib/node_modules/harp/node_modules/node-sass/vendor'
root@base[7ba79354c4a6]:/#
And no, @bgadrian, it is not a permission problem, it is running as root
.
$ docker run --rm -it mwaeckerlin/base
root@base[7ba79354c4a6]:/# apk update
fetch http://dl-cdn.alpinelinux.org/alpine/v3.8/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.8/community/x86_64/APKINDEX.tar.gz
v3.8.1 [http://dl-cdn.alpinelinux.org/alpine/v3.8/main]
v3.8.0-147-g4f5711b187 [http://dl-cdn.alpinelinux.org/alpine/v3.8/community]
OK: 9541 distinct packages available
root@base[7ba79354c4a6]:/# apk add npm python
(1/20) Installing ca-certificates (20171114-r3)
(2/20) Installing c-ares (1.14.0-r0)
(3/20) Installing libcrypto1.0 (1.0.2o-r2)
(4/20) Installing libgcc (6.4.0-r8)
(5/20) Installing http-parser (2.8.1-r0)
(6/20) Installing libssl1.0 (1.0.2o-r2)
(7/20) Installing libstdc++ (6.4.0-r8)
(8/20) Installing libuv (1.20.2-r0)
(9/20) Installing nodejs (8.11.4-r0)
(10/20) Installing npm (8.11.4-r0)
(11/20) Installing libbz2 (1.0.6-r6)
(12/20) Installing expat (2.2.5-r0)
(13/20) Installing libffi (3.2.1-r4)
(14/20) Installing gdbm (1.13-r1)
(15/20) Installing ncurses-terminfo-base (6.1_p20180818-r1)
(16/20) Installing ncurses-terminfo (6.1_p20180818-r1)
(17/20) Installing ncurses-libs (6.1_p20180818-r1)
(18/20) Installing readline (7.0.003-r0)
(19/20) Installing sqlite-libs (3.24.0-r0)
(20/20) Installing python2 (2.7.15-r1)
Executing busybox-1.28.4-r1.trigger
Executing ca-certificates-20171114-r3.trigger
OK: 108 MiB in 33 packages
root@base[7ba79354c4a6]:/# npm install -g harp
npm WARN deprecated connect@2.30.2: connect 2.x series is deprecated
npm WARN notice [SECURITY] debug has the following vulnerability: 1 low. Go here for more details: https://nodesecurity.io/advisories?search=debug&version=2.2.0 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN deprecated graceful-fs@3.0.11: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js
npm WARN notice [SECURITY] lodash has the following vulnerability: 1 low. Go here for more details: https://nodesecurity.io/advisories?search=lodash&version=4.17.4 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN deprecated coffee-script@1.12.7: CoffeeScript on NPM has moved to "coffeescript" (no hyphen)
npm WARN deprecated browserslist@2.11.3: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.
npm WARN deprecated classifier@0.1.0: Package no longer supported. Contact support@npmjs.com for more info.
npm WARN deprecated hoek@2.16.3: The major version is no longer supported. Please update to 4.x or newer
npm WARN notice [SECURITY] base64-url has the following vulnerability: 1 high. Go here for more details: https://nodesecurity.io/advisories?search=base64-url&version=1.2.1 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN notice [SECURITY] mime has the following vulnerability: 1 moderate. Go here for more details: https://nodesecurity.io/advisories?search=mime&version=1.3.6 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN notice [SECURITY] tar has the following vulnerability: 1 critical. Go here for more details: https://nodesecurity.io/advisories?search=tar&version=0.1.20 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN notice [SECURITY] cli has the following vulnerability: 1 low. Go here for more details: https://nodesecurity.io/advisories?search=cli&version=0.11.3 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN notice [SECURITY] mime has the following vulnerability: 1 moderate. Go here for more details: https://nodesecurity.io/advisories?search=mime&version=1.3.4 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN notice [SECURITY] mime has the following vulnerability: 1 moderate. Go here for more details: https://nodesecurity.io/advisories?search=mime&version=1.3.4 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN notice [SECURITY] tunnel-agent has the following vulnerability: 1 moderate. Go here for more details: https://nodesecurity.io/advisories?search=tunnel-agent&version=0.4.3 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN notice [SECURITY] negotiator has the following vulnerability: 1 high. Go here for more details: https://nodesecurity.io/advisories?search=negotiator&version=0.5.3 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN notice [SECURITY] hoek has the following vulnerability: 1 moderate. Go here for more details: https://nodesecurity.io/advisories?search=hoek&version=2.16.3 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
npm WARN notice [SECURITY] fresh has the following vulnerability: 1 high. Go here for more details: https://nodesecurity.io/advisories?search=fresh&version=0.3.0 - Run `npm i npm@latest -g` to upgrade your npm version, and then `npm audit` to get more info.
/usr/bin/harp -> /usr/lib/node_modules/harp/bin/harp
> node-sass@4.9.0 install /usr/lib/node_modules/harp/node_modules/node-sass
> node scripts/install.js
Unable to save binary /usr/lib/node_modules/harp/node_modules/node-sass/vendor/linux_musl-x64-57 : { Error: EACCES: permission denied, mkdir '/usr/lib/node_modules/harp/node_modules/node-sass/vendor'
at Object.fs.mkdirSync (fs.js:885:18)
at sync (/usr/lib/node_modules/harp/node_modules/mkdirp/index.js:71:13)
at Function.sync (/usr/lib/node_modules/harp/node_modules/mkdirp/index.js:77:24)
at checkAndDownloadBinary (/usr/lib/node_modules/harp/node_modules/node-sass/scripts/install.js:114:11)
at Object.<anonymous> (/usr/lib/node_modules/harp/node_modules/node-sass/scripts/install.js:157:1)
at Module._compile (module.js:652:30)
at Object.Module._extensions..js (module.js:663:10)
at Module.load (module.js:565:32)
at tryModuleLoad (module.js:505:12)
at Function.Module._load (module.js:497:3)
errno: -13,
code: 'EACCES',
syscall: 'mkdir',
path: '/usr/lib/node_modules/harp/node_modules/node-sass/vendor' }
> node-sass@4.9.0 postinstall /usr/lib/node_modules/harp/node_modules/node-sass
> node scripts/build.js
Building: /usr/bin/node /usr/lib/node_modules/harp/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
gyp info it worked if it ends with ok
gyp verb cli [ '/usr/bin/node',
gyp verb cli '/usr/lib/node_modules/harp/node_modules/node-gyp/bin/node-gyp.js',
gyp verb cli 'rebuild',
gyp verb cli '--verbose',
gyp verb cli '--libsass_ext=',
gyp verb cli '--libsass_cflags=',
gyp verb cli '--libsass_ldflags=',
gyp verb cli '--libsass_library=' ]
gyp info using node-gyp@3.8.0
gyp info using node@8.11.4 | linux | 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` succeeded python2 /usr/bin/python2
gyp verb check python version `/usr/bin/python2 -c "import sys; print "2.7.15
gyp verb check python version .%s.%s" % sys.version_info[:3];"` returned: %j
gyp verb get node dir no --target version specified, falling back to host node version: 8.11.4
gyp verb command install [ '8.11.4' ]
gyp verb install input version string "8.11.4"
gyp verb install installing version: 8.11.4
gyp verb install --ensure was passed, so won't reinstall if already installed
gyp WARN EACCES user "undefined" does not have permission to access the dev dir "/root/.node-gyp/8.11.4"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/usr/lib/node_modules/harp/node_modules/node-sass/.node-gyp"
gyp verb tmpdir == cwd automatically will remove dev files after to save disk space
gyp verb command install [ '--node_gyp_internal_noretry', '8.11.4' ]
gyp verb install input version string "8.11.4"
gyp verb install installing version: 8.11.4
gyp verb install --ensure was passed, so won't reinstall if already installed
gyp verb install version not already installed, continuing with install 8.11.4
gyp verb ensuring nodedir is created /usr/lib/node_modules/harp/node_modules/node-sass/.node-gyp/8.11.4
gyp WARN install got an error, rolling back install
gyp verb command remove [ '8.11.4' ]
gyp verb remove using node-gyp dir: /usr/lib/node_modules/harp/node_modules/node-sass/.node-gyp
gyp verb remove removing target version: 8.11.4
gyp verb remove removing development files for version: 8.11.4
gyp WARN install got an error, rolling back install
gyp verb command remove [ '8.11.4' ]
gyp verb remove using node-gyp dir: /usr/lib/node_modules/harp/node_modules/node-sass/.node-gyp
gyp verb remove removing target version: 8.11.4
gyp verb remove removing development files for version: 8.11.4
gyp ERR! configure error
gyp ERR! stack Error: EACCES: permission denied, mkdir '/usr/lib/node_modules/harp/node_modules/node-sass/.node-gyp'
gyp ERR! System Linux 4.15.0-33-generic
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/harp/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd /usr/lib/node_modules/harp/node_modules/node-sass
gyp ERR! node -v v8.11.4
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
Build failed with error code: 1
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/harp/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! node-sass@4.9.0 postinstall: `node scripts/build.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the node-sass@4.9.0 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! /root/.npm/_logs/2018-09-13T08_43_44_301Z-debug.log
@mwaeckerlin what version of node are you running?
@mwaeckerlin what version of node are you running?
root@base[6c649da5b76b]:/# npm --version
5.6.0
root@base[6c649da5b76b]:/# node --version
v8.11.4
@mwaeckerlin @sintaxi has this been resolved? Where are we at on this?
It can easily be tested:
> docker run --rm -it mwaeckerlin/base
# apk update
# apk add npm python
# npm install -g harp
The problem would be simple to solve (just create the directory tree, e.g. in bash
using mkdir -p
instead of only mkdir
). The directory can not be created, because the tree where it schould be created in does not exist yet.
I gave up my trials with harp so far and am still waiting for a solution…
@mwaeckerlin thank you for clarifying and following up. We'll get back to you; I've assigned the issue and hopefully you'll see a result earlier rather than later. Thank you!
Incredible to see that a blocking bug like this one is alive and well after almost 6 months. I'm experiencing the same issue. To be honest, it seems to be a node-sass issue, but I'm not sure.
So, with this issue still present there's no way to install Harp again. This should be highlighted on this repo's readme. On the surface it looks like it's all well and good.
@Biggsen please provide more information. I don't think this is still a bug. There should be no issues installing harp.
@sintaxi Can confirm it's working fine. Issue #660 highlights it working on NodeJS v5, and I've got it installed now. Tried NodeJS v8, but it failed on node-sass.
Can give more info on the v8 issue if you like, but I'm happy :)
@Biggsen yes, please provide more info with your install issues on v8 because I’m not having issues installing. Thanks.
I was having this same problem, nothing here worked but this ended working
npm install -g yarn
yarn global add harp
I have MacOS Catalina node v14.2.0 npm v6.14.4 node-sass v.14.4.1
Hope this helps someone else! ❤️
I can confirm that installing with yarn (with some specific versions of node and harp) works without any problems. If anyone needs it, this GitLab CI config is working.
@Syndamia thanks for reporting.
Harp has had a lot of work lately and is in good shape so I'm going to close this ticket.
The latest version of Harp is 18MB down from about 75MB.
Any troubles installing harp moving forward should be addressed in a new issue.
EDIT: Read the comments too please.
Note: I tried with node 9.3.0 and 8.9.3(LTS).
I ran
sudo npm install -g harp
and it returned an error, I don't understand why. This is what it says: npm WARN deprecated connect@2.30.2: connect 2.x series is deprecated npm WARN deprecated graceful-fs@3.0.11: please upgrade to graceful-fs 4 for compatibility with current and future versions of Node.js npm WARN deprecated coffee-script@1.12.7: CoffeeScript on NPM has moved to "coffeescript" (no hyphen) /usr/local/bin/harp -> /usr/local/lib/node_modules/harp/bin/harpUnable to save binary /usr/local/lib/node_modules/harp/node_modules/node-sass/vendor/darwin-x64-59 : { Error: EACCES: permission denied, mkdir '/usr/local/lib/node_modules/harp/node_modules/node-sass/vendor' at Object.fs.mkdirSync (fs.js:905:18) at sync (/usr/local/lib/node_modules/harp/node_modules/node-sass/node_modules/mkdirp/index.js:71:13) at Function.sync (/usr/local/lib/node_modules/harp/node_modules/node-sass/node_modules/mkdirp/index.js:77:24) at checkAndDownloadBinary (/usr/local/lib/node_modules/harp/node_modules/node-sass/scripts/install.js:111:11) at Object. (/usr/local/lib/node_modules/harp/node_modules/node-sass/scripts/install.js:154:1)
at Module._compile (module.js:660:30)
at Object.Module._extensions..js (module.js:671:10)
at Module.load (module.js:573:32)
at tryModuleLoad (module.js:513:12)
at Function.Module._load (module.js:505:3)
errno: -13,
code: 'EACCES',
syscall: 'mkdir',
path: '/usr/local/lib/node_modules/harp/node_modules/node-sass/vendor' }
Building: /usr/local/Cellar/node/9.3.0_1/bin/node /usr/local/lib/node_modules/harp/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library= gyp info it worked if it ends with ok gyp verb cli [ '/usr/local/Cellar/node/9.3.0_1/bin/node', gyp verb cli '/usr/local/lib/node_modules/harp/node_modules/node-gyp/bin/node-gyp.js', gyp verb cli 'rebuild', gyp verb cli '--verbose', gyp verb cli '--libsass_ext=', gyp verb cli '--libsass_cflags=', gyp verb cli '--libsass_ldflags=', gyp verb cli '--libsass_library=' ] gyp info using node-gyp@3.6.2 gyp info using node@9.3.0 | darwin | 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 verbwhich
failed at getNotFoundError (/usr/local/lib/node_modules/harp/node_modules/which/which.js:13:12) gyp verbwhich
failed at F (/usr/local/lib/node_modules/harp/node_modules/which/which.js:68:19) gyp verbwhich
failed at E (/usr/local/lib/node_modules/harp/node_modules/which/which.js:80:29) gyp verbwhich
failed at /usr/local/lib/node_modules/harp/node_modules/which/which.js:89:16 gyp verbwhich
failed at /usr/local/lib/node_modules/harp/node_modules/isexe/index.js:42:5 gyp verbwhich
failed at /usr/local/lib/node_modules/harp/node_modules/isexe/mode.js:8:5 gyp verbwhich
failed at FSReqWrap.oncomplete (fs.js:166:21) gyp verbwhich
failed python2 { Error: not found: python2 gyp verbwhich
failed at getNotFoundError (/usr/local/lib/node_modules/harp/node_modules/which/which.js:13:12) gyp verbwhich
failed at F (/usr/local/lib/node_modules/harp/node_modules/which/which.js:68:19) gyp verbwhich
failed at E (/usr/local/lib/node_modules/harp/node_modules/which/which.js:80:29) gyp verbwhich
failed at /usr/local/lib/node_modules/harp/node_modules/which/which.js:89:16 gyp verbwhich
failed at /usr/local/lib/node_modules/harp/node_modules/isexe/index.js:42:5 gyp verbwhich
failed at /usr/local/lib/node_modules/harp/node_modules/isexe/mode.js:8:5 gyp verbwhich
failed at FSReqWrap.oncomplete (fs.js:166:21) gyp verbwhich
failed stack: 'Error: not found: python2\n at getNotFoundError (/usr/local/lib/node_modules/harp/node_modules/which/which.js:13:12)\n at F (/usr/local/lib/node_modules/harp/node_modules/which/which.js:68:19)\n at E (/usr/local/lib/node_modules/harp/node_modules/which/which.js:80:29)\n at /usr/local/lib/node_modules/harp/node_modules/which/which.js:89:16\n at /usr/local/lib/node_modules/harp/node_modules/isexe/index.js:42:5\n at /usr/local/lib/node_modules/harp/node_modules/isexe/mode.js:8:5\n at FSReqWrap.oncomplete (fs.js:166:21)', gyp verbwhich
failed code: 'ENOENT' } gyp verb check python checking for Python executable "python" in the PATH gyp verbwhich
succeeded python /usr/bin/python gyp verb check python version/usr/bin/python -c "import platform; print(platform.python_version());"
returned: "2.7.10\n" gyp verb get node dir no --target version specified, falling back to host node version: 9.3.0 gyp verb command install [ '9.3.0' ] gyp verb install input version string "9.3.0" gyp verb install installing version: 9.3.0 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" 9 gyp verb needs "installVersion" 9 gyp verb install version is good gyp verb get node dir target node version installed: 9.3.0 gyp verb build dir attempting to create "build" dir: /usr/local/lib/node_modules/harp/node_modules/node-sass/build gyp ERR! configure error gyp ERR! stack Error: EACCES: permission denied, mkdir '/usr/local/lib/node_modules/harp/node_modules/node-sass/build' gyp ERR! System Darwin 16.7.0 gyp ERR! command "/usr/local/Cellar/node/9.3.0_1/bin/node" "/usr/local/lib/node_modules/harp/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library=" gyp ERR! cwd /usr/local/lib/node_modules/harp/node_modules/node-sass gyp ERR! node -v v9.3.0 gyp ERR! node-gyp -v v3.6.2 gyp ERR! not ok Build failed with error code: 1 npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! node-sass@4.7.2 postinstall:node scripts/build.js
npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the node-sass@4.7.2 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! /Users/Pimalo/.npm/_logs/2017-12-29T12_03_12_763Z-debug.log
If I run brew doctor it returns this:
I ran
brew prune
and I tried to donpm install -g harp
but it didn't work.