Strange i get an error now when trying to run bench
bash: bench: command not found
However i can run it using /usr/local/bin/bench
I get a worse error when trying to turn developer mode off
root@erp-2:/home/frappe/frappe-bench# /usr/local/bin/bench set-config developer_mode 0
Traceback (most recent call last):
File "/usr/lib/python2.7/runpy.py", line 162, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/home/frappe/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 79, in <module>
main()
File "/home/frappe/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 16, in main
click.Group(commands=commands)(prog_name='bench')
File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 716, in __call__
return self.main(*args, **kwargs)
File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 696, in main
rv = self.invoke(ctx)
File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 889, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/core.py", line 534, in invoke
return callback(*args, **kwargs)
File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/click/decorators.py", line 17, in new_func
return f(get_current_context(), *args, **kwargs)
File "/home/frappe/frappe-bench/apps/frappe/frappe/commands.py", line 29, in _func
ret = f(frappe._dict(ctx.obj), *args, **kwargs)
File "/home/frappe/frappe-bench/apps/frappe/frappe/commands.py", line 963, in set_config
frappe.init(site=site)
File "/home/frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 121, in init
local.conf = _dict(get_site_config())
File "/home/frappe/frappe-bench/apps/frappe/frappe/__init__.py", line 175, in get_site_config
raise IncorrectSitePath, "{0} does not exist".format(site_config)
frappe.exceptions.IncorrectSitePath: 404: Not Found
So i checked the /home/frappe/ site-config.json it does not contain anything about developer_mode
{
"db_name": "dbname",
"db_password": "dbpassword"
I also tried a bench update get errors about missing deps i try to install them but they are already installed see below
root@erp-2:/home/frappe/frappe-bench# /usr/local/bin/bench update
INFO:bench.utils:updating bench
Already up-to-date.
Traceback (most recent call last):
File "./env/bin/pip", line 11, in <module>
sys.exit(main())
File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/pip/__init__.py", line 215, in main
locale.setlocale(locale.LC_ALL, '')
File "/home/frappe/frappe-bench/env/lib/python2.7/locale.py", line 579, in setlocale
return _setlocale(category, locale)
locale.Error: unsupported locale setting
Please install these dependencies using the command:
sudo apt-get install -y libtiff5-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms2-dev libwebp-dev tcl8.6-dev tk8.6-dev python-tk
Traceback (most recent call last):
File "/usr/local/bin/bench", line 9, in <module>
load_entry_point('bench==0.0.0', '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 716, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 696, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 889, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 534, in invoke
return callback(*args, **kwargs)
File "/home/frappe/bench-repo/bench/commands/update.py", line 60, in update
_update(pull, patch, build, bench, auto, restart_supervisor, requirements, no_backup, upgrade, force=force)
File "/home/frappe/bench-repo/bench/commands/update.py", line 73, in _update
before_update(bench=bench_path, requirements=requirements)
File "/home/frappe/bench-repo/bench/utils.py", line 587, in before_update
validate_pillow_dependencies(bench, requirements)
File "/home/frappe/bench-repo/bench/utils.py", line 595, in validate_pillow_dependencies
exec_cmd("{pip} install Pillow".format(pip=pip))
File "/home/frappe/bench-repo/bench/utils.py", line 99, in exec_cmd
raise CommandFailedError(cmd)
bench.utils.CommandFailedError: ./env/bin/pip install Pillow
root@erp-2:/home/frappe/frappe-bench#
root@erp-2:/home/frappe/frappe-bench# sudo apt-get install -y libtiff5-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms2-dev libwebp-dev tcl8.6-dev tk8.6-dev python-tk
Reading package lists... Done
Building dependency tree
Reading state information... Done
libjpeg8-dev is already the newest version.
liblcms2-dev is already the newest version.
libwebp-dev is already the newest version.
python-tk is already the newest version.
tcl8.6-dev is already the newest version.
tk8.6-dev is already the newest version.
zlib1g-dev is already the newest version.
libfreetype6-dev is already the newest version.
libtiff5-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
root@erp-2:/home/frappe/frappe-bench# /usr/local/bin/bench update
INFO:bench.utils:updating bench
Already up-to-date.
Traceback (most recent call last):
File "./env/bin/pip", line 11, in <module>
sys.exit(main())
File "/home/frappe/frappe-bench/env/local/lib/python2.7/site-packages/pip/__init__.py", line 215, in main
locale.setlocale(locale.LC_ALL, '')
File "/home/frappe/frappe-bench/env/lib/python2.7/locale.py", line 579, in setlocale
return _setlocale(category, locale)
locale.Error: unsupported locale setting
Please install these dependencies using the command:
sudo apt-get install -y libtiff5-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms2-dev libwebp-dev tcl8.6-dev tk8.6-dev python-tk
Traceback (most recent call last):
File "/usr/local/bin/bench", line 9, in <module>
load_entry_point('bench==0.0.0', '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 716, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 696, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 1060, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 889, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 534, in invoke
return callback(*args, **kwargs)
File "/home/frappe/bench-repo/bench/commands/update.py", line 60, in update
_update(pull, patch, build, bench, auto, restart_supervisor, requirements, no_backup, upgrade, force=force)
File "/home/frappe/bench-repo/bench/commands/update.py", line 73, in _update
before_update(bench=bench_path, requirements=requirements)
File "/home/frappe/bench-repo/bench/utils.py", line 587, in before_update
validate_pillow_dependencies(bench, requirements)
File "/home/frappe/bench-repo/bench/utils.py", line 595, in validate_pillow_dependencies
exec_cmd("{pip} install Pillow".format(pip=pip))
File "/home/frappe/bench-repo/bench/utils.py", line 99, in exec_cmd
raise CommandFailedError(cmd)
bench.utils.CommandFailedError: ./env/bin/pip install Pillow