ERPNext Foundation ERPNext Cloud User Manual Blog Discuss Frappé* Donate

bench.utils.CommandFailedError: npm install


#3

No I was not able to, then I installed easy install version.


#4

Have you installed the npm?


#5

Obviously


#6

can you explain what are the steps you followed in installation and the screenshot of the issue you are facing right now?


#7

Hii @arokia I also have the same problem. Do you have a solution.


#8
  • sudo apt-get update

  • sudo apt-get install nodejs

  • sudo apt-get install npm

  • nodejs -v

  • cd ~

  • curl -sL https://deb.nodesource.com/setup_8.x -o nodesource_setup.sh

  • nano nodesource_setup.sh

  • sudo bash nodesource_setup.sh

  • sudo apt-get install nodejs

  • nodejs -v

  • npm -v

  • sudo apt-get install build-essential
    Kindly purge the existing npm and follow the above steps,
    Use this code for installing npm .


Npm Error while installing Frappe bench
Bench install error - CommandFailedError: npm install
Update Error npm install error
Got an error while creating new bench
Getting npm error while bench init
Bench update v11 fails yarn issue
Bench update v11 fails yarn issue
#9

Ok I will give it a try and revert back to you.


#10

Is the above steps helped you or not ?


#11

Yes …Thanks Man.
I Completely removed node from the system.
Then manually installed frappe and it worked.
Thanks for the help.


Cannot Complete the bench init command Please Help
#12

you are welcome…!!!


#13


@arokia Do You have any idea how to solve this problem. I am unable to see the Login Page.


#14

Do you have any ip address for the container ?


#15

@arokia I dont understand What IP Address?


#16

ok type sudo ifconfig in frappe-bench it gives a output copy paste in browser…


#17

Command Not Found


#18

share your screenshot where you entered the command


#19

In frappe bench folder only.


#20

ok are you using the docker container…


#21

No. What does it do.


#22

Hey everyone, I’m having what it seems to be the exact same error than Khadija ( or at least that is what I think based on the log).

I tried the suggested solution about purging nodejs and installing the version 8 with the https://deb.nodesource.com/setup_8.x script followed by the apt install but it doesn’t work for me. I already repeated the same steps many times without any luck, does anybody have another suggestion?

I’m using Debian 9 Stretch, and my log is the following one :

$ bench init frappe-bench
INFO:bench.utils:virtualenv -q env -p /usr/bin/python
Already using interpreter /usr/bin/python
INFO:bench.utils:./env/bin/pip -q install --upgrade pip
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
INFO:bench.utils:./env/bin/pip -q install wheel
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
INFO:bench.utils:./env/bin/pip -q install six
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
INFO:bench.utils:./env/bin/pip -q install -e git+https://github.com/frappe/python-pdfkit.git#egg=pdfkit
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
INFO:bench.app:getting app frappe
INFO:bench.utils:git clone https://github.com/frappe/frappe.git   --origin upstream
Cloning into 'frappe'...
remote: Enumerating objects: 58, done.
remote: Counting objects: 100% (58/58), done.
remote: Compressing objects: 100% (35/35), done.
remote: Total 168239 (delta 33), reused 36 (delta 23), pack-reused 168181
Receiving objects: 100% (168239/168239), 192.95 MiB | 2.57 MiB/s, done.
Resolving deltas: 100% (128255/128255), done.
('installing', u'frappe')
INFO:bench.app:installing frappe
INFO:bench.utils:frappe-bench/env/bin/pip install -q  -e frappe-bench/apps/frappe --no-cache-dir
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
Updating node libraries...
INFO:bench.utils:npm install
npm ERR! prepareGitDep 1> 
npm ERR! prepareGitDep > uws@9.14.0 install /home/arreis/.npm/_cacache/tmp/git-clone-bea26042/node_modules/uws
npm ERR! prepareGitDep > node-gyp rebuild > build_log.txt 2>&1 || exit 0
npm ERR! prepareGitDep 
npm ERR! prepareGitDep 
npm ERR! prepareGitDep > wd@1.11.1 install /home/arreis/.npm/_cacache/tmp/git-clone-bea26042/node_modules/wd
npm ERR! prepareGitDep > node scripts/build-browser-scripts
npm ERR! prepareGitDep 
npm ERR! prepareGitDep 
npm ERR! prepareGitDep > sauce-connect-launcher@1.2.4 postinstall /home/arreis/.npm/_cacache/tmp/git-clone-bea26042/node_modules/sauce-connect-launcher
npm ERR! prepareGitDep > node scripts/install.js || nodejs scripts/install.js
npm ERR! prepareGitDep 
npm ERR! prepareGitDep 
npm ERR! prepareGitDep > parchment@2.0.0-dev prepare /home/arreis/.npm/_cacache/tmp/git-clone-bea26042
npm ERR! prepareGitDep > npm run build
npm ERR! prepareGitDep 
npm ERR! prepareGitDep 
npm ERR! prepareGitDep > parchment@2.0.0-dev build /home/arreis/.npm/_cacache/tmp/git-clone-bea26042
npm ERR! prepareGitDep > webpack --config webpack.conf.js
npm ERR! prepareGitDep 
npm ERR! prepareGitDep 
npm ERR! prepareGitDep 2> npm WARN install Usage of the `--dev` option is deprecated. Use `--only=dev` instead.
npm ERR! prepareGitDep npm WARN deprecated istanbul@0.4.5: This module is no longer maintained, try this instead:
npm ERR! prepareGitDep npm WARN deprecated   npm i nyc
npm ERR! prepareGitDep npm WARN deprecated Visit https://istanbul.js.org/integrations for other alternatives.
npm ERR! prepareGitDep npm WARN deprecated babel-preset-es2015@6.24.1: 🙌  Thanks for using Babel: we recommend using babel-preset-env now: please read babeljs.io/env to update! 
npm ERR! prepareGitDep npm WARN deprecated nomnom@1.8.1: Package no longer supported. Contact support@npmjs.com for more info.
npm ERR! prepareGitDep npm WARN deprecated circular-json@0.5.9: CircularJSON is in maintenance only, flatted is its successor.
npm ERR! prepareGitDep npm WARN deprecated nodemailer@2.7.2: All versions below 4.0.1 of Nodemailer are deprecated. See https://nodemailer.com/status/
npm ERR! prepareGitDep npm WARN deprecated uws@9.14.0: New code is available at github.com/uNetworking/uWebSockets.js
npm ERR! prepareGitDep npm WARN deprecated mailcomposer@4.0.1: This project is unmaintained
npm ERR! prepareGitDep npm WARN deprecated socks@1.1.9: If using 2.x branch, please upgrade to at least 2.1.6 to avoid a serious bug with socket data flow and an import issue introduced in 2.1.0
npm ERR! prepareGitDep npm WARN deprecated node-uuid@1.4.8: Use uuid module instead
npm ERR! prepareGitDep npm WARN deprecated buildmail@4.0.1: This project is unmaintained
npm ERR! prepareGitDep npm WARN deprecated boom@2.10.1: This version is no longer maintained. Please upgrade to the latest version.
npm ERR! prepareGitDep npm WARN deprecated cryptiles@2.0.5: This version is no longer maintained. Please upgrade to the latest version.
npm ERR! prepareGitDep npm WARN deprecated hoek@2.16.3: This version is no longer maintained. Please upgrade to the latest version.
npm ERR! prepareGitDep /home/arreis/.npm/_cacache/tmp/git-clone-bea26042/node_modules/webpack-cli/bin/config-yargs.js:89
npm ERR! prepareGitDep 				describe: optionsSchema.definitions.output.properties.path.description,
npm ERR! prepareGitDep 				                                           ^
npm ERR! prepareGitDep 
npm ERR! prepareGitDep TypeError: Cannot read property 'properties' of undefined
npm ERR! prepareGitDep     at module.exports (/home/arreis/.npm/_cacache/tmp/git-clone-bea26042/node_modules/webpack-cli/bin/config-yargs.js:89:48)
npm ERR! prepareGitDep     at /home/arreis/.npm/_cacache/tmp/git-clone-bea26042/node_modules/webpack-cli/bin/webpack.js:60:27
npm ERR! prepareGitDep     at Object.<anonymous> (/home/arreis/.npm/_cacache/tmp/git-clone-bea26042/node_modules/webpack-cli/bin/webpack.js:515:3)
npm ERR! prepareGitDep     at Module._compile (module.js:653:30)
npm ERR! prepareGitDep     at Object.Module._extensions..js (module.js:664:10)
npm ERR! prepareGitDep     at Module.load (module.js:566:32)
npm ERR! prepareGitDep     at tryModuleLoad (module.js:506:12)
npm ERR! prepareGitDep     at Function.Module._load (module.js:498:3)
npm ERR! prepareGitDep     at Module.require (module.js:597:17)
npm ERR! prepareGitDep     at require (internal/module.js:11:18)
npm ERR! prepareGitDep npm ERR! code ELIFECYCLE
npm ERR! prepareGitDep npm ERR! errno 1
npm ERR! prepareGitDep npm ERR! parchment@2.0.0-dev build: `webpack --config webpack.conf.js`
npm ERR! prepareGitDep npm ERR! Exit status 1
npm ERR! prepareGitDep npm ERR! 
npm ERR! prepareGitDep npm ERR! Failed at the parchment@2.0.0-dev build script.
npm ERR! prepareGitDep npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! prepareGitDep 
npm ERR! prepareGitDep npm ERR! A complete log of this run can be found in:
npm ERR! prepareGitDep npm ERR!     /home/arreis/.npm/_logs/2019-03-13T03_43_18_648Z-debug.log
npm ERR! prepareGitDep npm ERR! code ELIFECYCLE
npm ERR! prepareGitDep npm ERR! errno 1
npm ERR! prepareGitDep npm ERR! parchment@2.0.0-dev prepare: `npm run build`
npm ERR! prepareGitDep npm ERR! Exit status 1
npm ERR! prepareGitDep npm ERR! 
npm ERR! prepareGitDep npm ERR! Failed at the parchment@2.0.0-dev prepare script.
npm ERR! prepareGitDep npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! prepareGitDep 
npm ERR! prepareGitDep npm ERR! A complete log of this run can be found in:
npm ERR! prepareGitDep npm ERR!     /home/arreis/.npm/_logs/2019-03-13T03_43_18_802Z-debug.log
npm ERR! prepareGitDep 
npm ERR! code ENOPACKAGEJSON
npm ERR! package.json Non-registry package missing package.json: parchment@github:quilljs/parchment#487850f7eb030a6c4e750ba809e58b09444e0bdb.
npm ERR! package.json npm can't find a package.json file in your current directory.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/arreis/.npm/_logs/2019-03-13T03_43_18_978Z-debug.log
Traceback (most recent call last):
  File "/home/arreis/.local/bin/bench", line 11, in <module>
    sys.exit(cli())
  File "/home/arreis/.local/lib/python2.7/site-packages/bench/cli.py", line 40, in cli
    bench_command()
  File "/home/arreis/.local/lib/python2.7/site-packages/click/core.py", line 764, in __call__
    return self.main(*args, **kwargs)
  File "/home/arreis/.local/lib/python2.7/site-packages/click/core.py", line 717, in main
    rv = self.invoke(ctx)
  File "/home/arreis/.local/lib/python2.7/site-packages/click/core.py", line 1137, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/arreis/.local/lib/python2.7/site-packages/click/core.py", line 956, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/arreis/.local/lib/python2.7/site-packages/click/core.py", line 555, in invoke
    return callback(*args, **kwargs)
  File "/home/arreis/.local/lib/python2.7/site-packages/bench/commands/make.py", line 21, in init
    verbose=verbose, clone_from=clone_from, skip_bench_mkdir=skip_bench_mkdir, skip_redis_config_generation=skip_redis_config_generation)
  File "/home/arreis/.local/lib/python2.7/site-packages/bench/utils.py", line 72, in init
    update_npm_packages(bench_path=path)
  File "/home/arreis/.local/lib/python2.7/site-packages/bench/utils.py", line 442, in update_npm_packages
    exec_cmd('npm install', cwd=bench_path)
  File "/home/arreis/.local/lib/python2.7/site-packages/bench/utils.py", line 140, in exec_cmd
    raise CommandFailedError(cmd)
bench.utils.CommandFailedError: npm install