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

[Release] Instructions for updating to/staying on v10/v11

release

#1

V11 will be release to master branch soon. Here are the instructions you need to follow based on the scenario applicable to you:

Scenario One: You want to upgrade to v11 from v10 (master ==> master)

bench update

Scenario Two: You want to stay on v11 (staging ==> master)

bench switch-to-branch master frappe erpnext --upgrade
bench update --patch

Scenario Three: You want to stay on v10 (master ==> v10.x.x)

bench switch-to-branch v10.x.x frappe erpnext
bench update --patch

OPTIONAL: Remove foundation and frappe_io apps (run only if they exist in your bench’s app directory):

bench remove-app frappe_io
bench remove-app foundation

IMPORTANT: Please clear your browser’s cache too: Ctrl + Shift + R
If after clearing your browser cache you cannot see the chat icon (v11), run bench build and clear cache again.


[Release Notes] Version 11.1.0!
Update to V11 master; The resource you are looking for is not available
Can I stay on v10 and update to the latest v10 release?
General Ledger not showing after update to ver11 master
Same problem after 10 tries of reinstalling!
Upgrade from V9 to V11
Getting TypeError: a bytes-like object is required, not ‘list’ on switching from staging to master v11
Error encountered while migrating from V11 (Staging) to V11 (Master)
Can I stay on v10 and update to the latest v10 release? (Other thread was closed without a solution)
#6

#7

You can refer to the release notes and a list of contributors here.


Is there any way to install erpnext v10 now?
#8

tried to do this as follows:

cd frappe-bench
bench update --reset
bench switch-to-branch master frappe
bench switch-to-branch master erpnext
bench update --patch
bench setup requirements
bench --site mysite.local migrate
bench restart

result … frappe has switched to master, but erpnext remains on staging


#9

Are the instructions same for updating my VM instance?
I tried running the command in the terminal but there was some error


#10

@Manan_Shah Can you please post the error log here?


#11

Are you sure --upgrade is a real switch?

/frappe-bench$ bench update --upgrade

Usage: bench update [OPTIONS]
Try "bench update --help" for help.

Error: no such option: --upgrade
$ bench update --help
Usage: bench update [OPTIONS]

  Update bench

Options:
  --pull                Pull changes in all the apps in bench
  --patch               Run migrations for all sites in the bench
  --build               Build JS and CSS artifacts for the bench
  --bench               Update bench
  --requirements        Update requirements
  --restart-supervisor  restart supervisor processes after update
  --restart-systemd     restart systemd units after update
  --auto
  --no-backup
  --force
  --reset               Hard resets git branch's to their new states
                        overriding any changes and overriding rebase on pull
  --help                Show this message and exit.

#12

Apologies, I’ve updated the instructions. This used to be a flag.


#13

Hi, sorry for late reply.

This worked perfectly on a client instance of mine.

Try this manually:

cd apps/erpnext
git checkout master

#14


I am trying to update from v10 to v11
I tried command bench update


#15

you must run the command from your frappe-bench directory :slight_smile:


#17

Thanks. Worked!:+1:


#18

upon the switch-to-branch master erpnext I just noted that I got a
Branch master does not exist in Upstream for erpnext


throws “error: pathspec ‘master’ did not match any file(s) known to git.” back at me


#19

Hi @vrms,

Go to ERPNext’s folder, open .git/config and make sure it is set up to fetch all branches in upstream:

fetch = +refs/heads/*:refs/remotes/upstream/*


#20

After this run git fetch too.
Then you will be able to run bench switch-to-branch ...

This happens due to shallow cloning.


#21

thanks @chdecultot

my erpnext/.git.config (after replacing the staging with * looks like this now

[core]
       repositoryformatversion = 0
       filemode = true
       bare = false
       logallrefupdates = true
[remote "upstream"]
       url = https://github.com/frappe/erpnext
       fetch = +refs/heads/staging:refs/remotes/upstream/*
[branch "staging"]
       remote = upstream
       merge = refs/heads/staging

even though this is the same as in the config file of frappe it is still not working out

~/frappe-bench$ bench switch-to-branch master erpnext --upgrade
fatal: Invalid refspec '+refs/heads/staging:refs/remotes/upstream/*'
Branch master does not exist in Upstream for erpnext
Switched to master
Please run `bench update --patch` to be safe from any differences in database schema

#22
[core]
       repositoryformatversion = 0
       filemode = true
       bare = false
       logallrefupdates = true
[remote "upstream"]
       url = https://github.com/frappe/erpnext
       fetch = +refs/heads/*:refs/remotes/upstream/*
[branch "staging"]
       remote = upstream
       merge = refs/heads/staging

@vrms this is what you want

and this too:


#23

looks like this is what I have (see above)

~/frappe-bench/apps/erpnext$ git fetch
fatal: Invalid refspec '+refs/heads/staging:refs/remotes/upstream/*'

#24

use the config from here:


[Release] ERPNext Version 12
#25

This worked for me. Thank you!