Hello, I cannot install ERPnext v8 for database restore purpose. I cannot upgrade previous instance because of bad install procedure (therefore cannot do $ bench switch-to-branch v9.x.x) and some dependencies are not available on ubuntu 14.04.
My previous instance is:
ERPNext: v8.11.0 (master)
Frappe Framework: v8.10.1 (master)
and I believe it is still on bench v3.x based on README.md
I install new instance using easy-install script and able to access ERPnext normally on v11. To go to v8.x.x I did
$ cd ~/frappe-bench
$ bench switch-to-branch v8.x.x
and here is the result:
remote: Enumerating objects: 158, done.
remote: Counting objects: 100% (103/103), done.
remote: Compressing objects: 100% (12/12), done.
remote: Total 24 (delta 21), reused 13 (delta 12), pack-reused 0
Unpacking objects: 100% (24/24), done.
From https://github.com/frappe/erpnext
c90364f94d..033b1babe8 develop -> upstream/develop
Branch v8.x.x does not exist in Upstream for erpnext
Switching for frappe
INFO:bench.utils:git config --unset-all remote.upstream.fetch
INFO:bench.utils:git config --add remote.upstream.fetch '+refs/heads/*:refs/remotes/upstream/*'
INFO:bench.utils:git fetch upstream
INFO:bench.utils:git checkout v8.x.x
Checking out files: 100% (22587/22587), done.
Switched to branch 'v8.x.x'
Your branch is ahead of 'upstream/v8.x.x' by 1 commit.
(use "git push" to publish your local commits)
INFO:bench.utils:git merge upstream/v8.x.x
Already up to date.
Successfully switched branches for:
frappe
Switched to v8.x.x
Please run `bench update --patch` to be safe from any differences in database schema
this takes my attention: Branch v8.x.x does not exist in Upstream for erpnext
then when I do $ bench update --hard
For some reason of trying to install bench using manual install for trying to resolve it myself, it didn’t work and the error message is same, I cannot do bench update normally, will wipe disk tomorrow to fresh install again.
this is the result:
INFO:bench.utils:updating bench
INFO:bench.utils:git pull
Already up to date.
INFO:bench.utils:./env/bin/pip install Pillow
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.
Requirement already satisfied: Pillow in ./env/lib/python2.7/site-packages (6.0.0)
INFO:bench.app:pulling frappe
INFO:bench.utils:git fetch --all
Fetching upstream
INFO:bench.utils:git reset --hard upstream/v8.x.x
HEAD is now at e8f9fbb7f Prevent duplicate sidebar display in mobile view (#4585)
INFO:bench.utils:find . -name "*.pyc" -delete
INFO:bench.app:pulling erpnext
INFO:bench.utils:git fetch --all
Fetching upstream
INFO:bench.utils:git reset --hard upstream/develop
HEAD is now at 033b1babe8 Merge pull request #17186 from rohitwaghchaure/bank_account_in_bank_reconcilliation
INFO:bench.utils:find . -name "*.pyc" -delete
Updating Python libraries...
INFO:bench.utils:./env/bin/pip 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.
Requirement already up-to-date: pip in ./env/lib/python2.7/site-packages (19.0.3)
INFO:bench.utils:./env/bin/pip install -q -r /home/frappe/bench-repo/requirements.txt
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:installing frappe
INFO:bench.utils:./env/bin/pip install -q -e ./apps/frappe
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.
Command "python setup.py egg_info" failed with error code 1 in /home/frappe/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/frappe/bench-repo/bench/cli.py", line 40, in cli
bench_command()
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 764, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 717, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 1137, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 956, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python2.7/dist-packages/click/core.py", line 555, 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, restart_systemd, requirements, no_backup, force=force, reset=reset)
File "/home/frappe/bench-repo/bench/commands/update.py", line 76, in _update
update_requirements(bench_path=bench_path)
File "/home/frappe/bench-repo/bench/utils.py", line 435, in update_requirements
install_app(app, bench_path=bench_path)
File "/home/frappe/bench-repo/bench/app.py", line 171, in install_app
find_links=find_links))
File "/home/frappe/bench-repo/bench/utils.py", line 159, in exec_cmd
raise CommandFailedError(cmd)
bench.utils.CommandFailedError: ./env/bin/pip install -q -e ./apps/frappe
In my opinion, the problem is these two lines:
INFO:bench.utils:updating bench
.... skip many lines
Command "python setup.py egg_info" failed with error code 1 in /home/frappe/frappe-bench/apps/frappe/
- Bench update forces to update bench to latest version, therefore installing latest pip: version 19.x.x
- when I search for “Command “python setup.py egg_info” failed with error code 1” in this forum, mostly about custom apps, but all tells that it is not compatible with pip version 10 and have to modify setup.py file on specified app.
Doing $ bench update means pulling ~/.bench (I replaced it with ~/bench-repo) ./apps/frappe and ./apps/erpnext so any modifications prior updating is repleaced from branch. Is there any way to install previous versions?