Error on bench init for frappe v7.x.x

Hello everyone,

Currently trying to create a separate frappe-bench folder for a v7 but I’m experiencing problems after INFO:bench.utils:frappe-bench/env/bin/pip install -q -e frappe-bench/apps/frappe --no-cache-dir

Note: I have v10 installed with a new site and it works perfectly. Bench version is 4.1.0 on develop branch. OS is Ubuntu 16.04.4.

Here’s the complete traceback:

~$ bench init frappe-bench --frappe-branch v7.x.x
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
INFO:bench.utils:./env/bin/pip -q install wheel
INFO:bench.utils:./env/bin/pip -q install -e git+ app frappe
INFO:bench.utils:git clone --branch v7.x.x  --origin upstream
Cloning into 'frappe'...
remote: Counting objects: 146548, done.
remote: Total 146548 (delta 0), reused 0 (delta 0), pack-reused 146548
Receiving objects: 100% (146548/146548), 157.43 MiB | 855.00 KiB/s, done.
Resolving deltas: 100% (110696/110696), done.
Checking connectivity... done.
('installing', u'frappe') frappe
INFO:bench.utils:frappe-bench/env/bin/pip install -q  -e frappe-bench/apps/frappe --no-cache-dir
Command "python egg_info" failed with error code 1 in /home/littlehera/frappe-bench/apps/frappe/
Traceback (most recent call last):
  File "/usr/local/bin/bench", line 11, in <module>
    load_entry_point('bench', 'console_scripts', 'bench')()
  File "/home/littlehera/bench/bench/", line 40, in cli
  File "/usr/local/lib/python2.7/dist-packages/click/", line 722, in __call__
    return self.main(*args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/click/", line 697, in main
    rv = self.invoke(ctx)
  File "/usr/local/lib/python2.7/dist-packages/click/", line 1066, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/local/lib/python2.7/dist-packages/click/", line 895, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/local/lib/python2.7/dist-packages/click/", line 535, in invoke
    return callback(*args, **kwargs)
  File "/home/littlehera/bench/bench/commands/", 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/littlehera/bench/bench/", line 64, in init
    get_app(frappe_path, branch=frappe_branch, bench_path=path, build_asset_files=False, verbose=verbose)
  File "/home/littlehera/bench/bench/", line 76, in get_app
    install_app(app=app_name, bench_path=bench_path, verbose=verbose)
  File "/home/littlehera/bench/bench/", line 107, in install_app
  File "/home/littlehera/bench/bench/", line 140, in exec_cmd
    raise CommandFailedError(cmd)
bench.utils.CommandFailedError: frappe-bench/env/bin/pip install -q  -e frappe-bench/apps/frappe --no-cache-dir

Any help will be appreciated.


1 Like

Got things working by doing a lot of work. Recording the steps here in case anyone needs it:

  • Reformatted laptop (had done too many things in the past 2 days just to get v7 working lol)
  • Downloaded the bench repo and followed manual install instructions
  • Changed the bench branch to a previous branch/commit
  • Reverted pip to version 9.0.3 using sudo pip install --force-reinstall pip==9.0.3 (to prevent errors looking for pip.req)
  • bench init frappe-bench --frappe-branch v7.x.x
  • cd frappe-bench; bench get-app --branch v7.x.x erpnext the_erpnext_repo*

Afterwards, tried bench start which didn’t work because procfile wasn’t auto-generated, nginx wasn’t running, etc. To fix this:

  • run bench setup procfile, socketio, redis.
  • check if nginx was running on localhost:80. If it’s not running and installation can’t be found, install nginx via sudo apt-get install nginx
  • try bench start (it should be working by now)