Bench Update Error on Production Image

Dear ALL ,

I have downloaded production image from (https://erpnext.com/download) . Everything is working fine but recently i have run
" bench update " . Which generates many errors please help .

BenchUpdateerrors

Looks like some network issue with git. can you paste the error messages instead of the screenshot.

Initially there was no issue when i update bench first time 3 days before but from last night i am getting same issue many time created new VM but no success . I cannot copy text because console not allowing me to copy .

I am able to ping github.com

after running bench update again error message changes . please help

image

if a new VM - Virtual image - production
install then
after
bench update
the same error occurs as above.

Details:

More precisely:

Welcome to Ubuntu 14.04.5 LTS (GNU/Linux 3.13.0-79-generic i686)

 * Documentation:  https://help.ubuntu.com/

 ERPNext VM (built on October 10, 2017)

 Please access ERPNext by going to http://localhost:8080 on the host system.
 Use port 3022 for SSH.

 We provide rock solid hosting for ERPNext : erpnext.com/pricing

 To update, login as
 username: frappe
 password: frappe

 ERPNext Administrator Login:
 username: Administrator
 password: admin

 cd frappe-bench
 bench update

Last login: Tue Feb 20 00:28:45 2018
frappe@erpnext:~$ cd frappe-bench
frappe@erpnext:~/frappe-bench$ bench update
INFO:bench.utils:updating bench
INFO:bench.utils:git pull
Already up-to-date.
INFO:bench.utils:./env/bin/pip install Pillow
Requirement already satisfied: Pillow in ./env/lib/python2.7/site-packages
Requirement already satisfied: olefile in ./env/lib/python2.7/site-packages (from Pillow)
INFO:bench.app:pulling frappe
INFO:bench.utils:git pull  upstream master
From https://github.com/frappe/frappe
 * branch            master     -> FETCH_HEAD
Already up-to-date.
INFO:bench.utils:find . -name "*.pyc" -delete
INFO:bench.app:pulling erpnext
INFO:bench.utils:git pull  upstream master
From https://github.com/frappe/erpnext
 * branch            master     -> FETCH_HEAD
Already up-to-date.
INFO:bench.utils:find . -name "*.pyc" -delete
INFO:bench.app:pulling erpnext_demo
INFO:bench.utils:git pull  upstream master
From https://github.com/frappe/erpnext_demo
 * branch            master     -> FETCH_HEAD
Already up-to-date.
INFO:bench.utils:find . -name "*.pyc" -delete
Updating Python libraries...
INFO:bench.utils:./env/bin/pip install --upgrade pip
Requirement already up-to-date: pip in ./env/lib/python2.7/site-packages
INFO:bench.utils:./env/bin/pip install -q -r /home/frappe/bench-repo/requirements.txt
INFO:bench.utils:./env/bin/pip install -q -r ./apps/erpnext/requirements.txt
INFO:bench.utils:./env/bin/pip install -q -r ./apps/erpnext_demo/requirements.txt
INFO:bench.utils:./env/bin/pip install -q -r ./apps/frappe/requirements.txt
Updating node libraries...
INFO:bench.utils:npm install yarn
npm WARN deprecated yarn@1.3.2: It is recommended to install Yarn using the native installation method for your environment. See https://yarnpkg.com/en/docs/install
npm WARN prefer global yarn@1.3.2 should be installed with -g
frappe@ /home/frappe/frappe-bench/apps/frappe
└── yarn@1.3.2  extraneous

npm WARN optional Skipping failed optional dependency /chokidar/fsevents:
npm WARN notsup Not compatible with your operating system or architecture: fsevents@1.1.3
INFO:bench.utils:./node_modules/.bin/yarn install
yarn install v1.3.2
info No lockfile found.
[1/4] Resolving packages...
[2/4] Fetching packages...
info fsevents@1.1.3: The platform "linux" is incompatible with this module.
info "fsevents@1.1.3" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[1/2] ⠁ uws
[2/2] ⠁ chromedriver
[-/2] ⠂ waiting...
[-/2] ⠂ waiting...
error /home/frappe/frappe-bench/apps/frappe/node_modules/chromedriver: Command failed.
Exit code: 1
Command: node install.js
Arguments: 
Directory: /home/frappe/frappe-bench/apps/frappe/node_modules/chromedriver




Traceback (most recent call last):
  File "/usr/local/bin/bench", line 11, in <module>
    load_entry_point('bench', 'console_scripts', 'bench')()
  File "/home/frappe/bench-repo/bench/cli.py", line 40, in cli
    bench_command()
  File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 722, in __call__
    return self.main(*args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 697, in main
    rv = self.invoke(ctx)
  File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 1066, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 895, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 535, in invoke
    return callback(*args, **kwargs)
  File "/home/frappe/bench-repo/bench/commands/update.py", line 58, in update
    _update(pull, patch, build, bench, auto, restart_supervisor, requirements, no_backup, force=force, reset=reset)
  File "/home/frappe/bench-repo/bench/commands/update.py", line 75, in _update
    update_npm_packages(bench_path=bench_path)
  File "/home/frappe/bench-repo/bench/utils.py", line 440, in update_npm_packages
    exec_cmd('{yarn} install'.format(yarn=yarn_executable), cwd=app_path)
  File "/home/frappe/bench-repo/bench/utils.py", line 142, in exec_cmd
    raise CommandFailedError(cmd)
bench.utils.CommandFailedError: ./node_modules/.bin/yarn install
frappe@erpnext:~/frappe-bench$

@krnkris the issue is due to a recent update:

Can you do a bench update once again? The issue should be resolved.

Hi @kennethsequeira

Assume it merged to develop,
I’m in production.

I made
bench update
in production
no change yet

Try this:

  • run npm install -g yarn
  • cd to frappe folder (something like ./apps/frappe. It should contain a yarn.lock file
  • run yarn
1 Like

another possible fix

Thanks its resolved my issue .

1 Like