While install frappe on mac OS X as a dev mode

i meet this error
bench.utils.CommandFailedError: npm install socket.io redis express superagent cookie

@Badrelden_Ahmed This doens’t look at full error but nevertheless typing that error into google gives this result:

Check and see if you have a similar permissions error.

There are several different results with that bit of the error message so you may need to work your way through them to see which is right or provide the full error message:

https://www.google.co.uk/search?num=100&newwindow=1&q="bench.utils.CommandFailedError%3A+npm+install+socket.io+redis+express+superagent+cookie"&oq="bench.utils.CommandFailedError%3A+npm+install+socket.io+redis+express+superagent+cookie"&gs_l=serp.3...30387.32946.0.33070.2.2.0.0.0.0.128.128.0j1.1.0…0…1c.1.64.serp…1.0.0.514Hildje0s

installing frappe
INFO:bench.app:installing frappe
INFO:bench.utils:setting up backups
/bin/sh: npm: command not found
Traceback (most recent call last):
File “/usr/local/bin/bench”, line 9, in
load_entry_point(‘bench==0.0.0’, ‘console_scripts’, ‘bench’)()
File “/Users/badrelden/bench-repo/bench/cli.py”, line 60, in cli
bench()
File “/Library/Python/2.7/site-packages/click/core.py”, line 716, in call
return self.main(*args, **kwargs)
File “/Library/Python/2.7/site-packages/click/core.py”, line 696, in main
rv = self.invoke(ctx)
File “/Library/Python/2.7/site-packages/click/core.py”, line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/Library/Python/2.7/site-packages/click/core.py”, line 889, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “/Library/Python/2.7/site-packages/click/core.py”, line 534, in invoke
return callback(*args, **kwargs)
File “/Users/badrelden/bench-repo/bench/cli.py”, line 166, in init
no_auto_update=no_auto_update, frappe_path=frappe_path, frappe_branch=frappe_branch, verbose=verbose)
File “/Users/badrelden/bench-repo/bench/utils.py”, line 83, in init
setup_socketio(bench=path)
File “/Users/badrelden/bench-repo/bench/utils.py”, line 115, in setup_socketio
exec_cmd(“npm install socket.io redis express superagent cookie”, cwd=bench)
File “/Users/badrelden/bench-repo/bench/utils.py”, line 105, in exec_cmd
raise CommandFailedError(cmd)
bench.utils.CommandFailedError: npm install socket.io redis express superagent cookie

i already tack the permission of the folder and the same error agin

@Badrelden_Ahmed What you are showing is not the full error message. It’s just the last line and on it’s own it tells nothing to the devs. If you provide the full output someone should be able to see what’s going on.

Badreldens-MacBook-Pro:~ badrelden$ bench init frappe-bench && cd frappe-bench
INFO:bench.app:getting app frappe
Cloning into ‘frappe’…
remote: Counting objects: 91862, done.
remote: Compressing objects: 100% (151/151), done.
remote: Total 91862 (delta 78), reused 0 (delta 0), pack-reused 91711
Receiving objects: 100% (91862/91862), 67.00 MiB | 205.00 KiB/s, done.
Resolving deltas: 100% (67307/67307), done.
Checking connectivity… done.
installing frappe
INFO:bench.app:installing frappe
INFO:bench.utils:setting up backups
crontab: no crontab for badrelden
/bin/sh: npm: command not found
Traceback (most recent call last):
File “/usr/local/bin/bench”, line 9, in
load_entry_point(‘bench==0.0.0’, ‘console_scripts’, ‘bench’)()
File “/Users/badrelden/bench-repo/bench/cli.py”, line 60, in cli
bench()
File “/Library/Python/2.7/site-packages/click/core.py”, line 716, in call
return self.main(*args, **kwargs)
File “/Library/Python/2.7/site-packages/click/core.py”, line 696, in main
rv = self.invoke(ctx)
File “/Library/Python/2.7/site-packages/click/core.py”, line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/Library/Python/2.7/site-packages/click/core.py”, line 889, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “/Library/Python/2.7/site-packages/click/core.py”, line 534, in invoke
return callback(*args, **kwargs)
File “/Users/badrelden/bench-repo/bench/cli.py”, line 166, in init
no_auto_update=no_auto_update, frappe_path=frappe_path, frappe_branch=frappe_branch, verbose=verbose)
File “/Users/badrelden/bench-repo/bench/utils.py”, line 83, in init
setup_socketio(bench=path)
File “/Users/badrelden/bench-repo/bench/utils.py”, line 115, in setup_socketio
exec_cmd(“npm install socket.io redis express superagent cookie”, cwd=bench)
File “/Users/badrelden/bench-repo/bench/utils.py”, line 105, in exec_cmd
raise CommandFailedError(cmd)
bench.utils.CommandFailedError: npm install socket.io redis express superagent cookie

command npm not found. Sounds like either npm isn’t installed or it’s in a non standard location.

1 Like

how can i install it or repair

@Badrelden_Ahmed Sorry I’m not sure as I’m not a mac user. I’m sure someone with knowledge of your os will be along to help.