ERPNext v5 upgradation problem

Hello everyone,

I was running ERPNext v4 for the last few months and today I have upgraded it to ERPNext V5 as per the guideline given here: ERPNext Upgrade to Version 5 · frappe/erpnext Wiki · GitHub

All the steps works out without any error and now once I run the following command :

service nginx restart
supervisorctl reload

My site shows: 502 Bad Gateway/nginx 1.6.2 as you can find my site here:

I think my application was previously in developer mode.

Anyone, let me know how to resolve this issue.

Any help will be appreciated.

Only started using this so don’t know very much but what I do know is that in developer more I have to run

bench start

In the terminal every time I restart the erpnext instance.

That might work and if not I’m sure those with much more experience will be along to help.

@kumar try

bench restart to start all processes again. Also try restarting nginx

When I do “bench restart” I found the the following errors as shown:

frappe-worker: ERROR (abnormal termination)
frappe-web: started
frappe-workerbeat: ERROR (abnormal termination)

What it mean? and how to rectify.


Can you paste the output of this command at and send us the link.

tail -n 50 logs/worker.error.log



I have pasted here:

I have given the last 100. Please do check out and thanks for your concern.

Continuing the discussion from No module named num2words in worker error log:


‘bench update’ could n’t solve the issue of “No module named num2words in worker error log”

output of my ‘bench update’ pasted here:

I have already updated the pip also.

And output of ‘bench start’ pasted here:

It still shows the issue as “No module named num2words”

I have installed the num2words module using ‘root’ but it seems like it doesn’t reflect
to the frappe users.

Still I find the errors when ‘bench start’ as the following:

12:19:15 workerbeat.1  | /home/frappe/frappe-bench/sites/../env/bin/python: No module named num2words
12:19:15 worker.1      | /home/frappe/frappe-bench/sites/../env/bin/python: No module named num2words

‘bench update’ couldn’t resolve the issue.

Goto frappe-bech, activate virtual environment using source ./env/bin/activate, then install numwords(without sudo or root).

Then execute bench start


I have done the same as you have mentioned and my site at
shows the following errors:

Traceback (innermost last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/”, line 60, in application
response =
File “/home/frappe/frappe-bench/apps/frappe/frappe/website/”, line 54, in render
data = render_page(path)
File “/home/frappe/frappe-bench/apps/frappe/frappe/website/”, line 124, in render_page
return build(path)
File “/home/frappe/frappe-bench/apps/frappe/frappe/website/”, line 133, in build
return build_method(path)
File “/home/frappe/frappe-bench/apps/frappe/frappe/website/”, line 149, in build_page
context = get_context(path)
File “/home/frappe/frappe-bench/apps/frappe/frappe/website/”, line 29, in get_context
context = build_context(context)
File “/home/frappe/frappe-bench/apps/frappe/frappe/website/”, line 75, in build_context
ret = module.get_context(context)
File “/home/frappe/frappe-bench/apps/frappe/frappe/templates/pages/”, line 11, in get_context
print frappe.get_traceback()
IOError: [Errno 32] Broken pipe

While running in Chrome it shows black color page but while running in Firefox it shows the error.

What may be the reason for this error?

I feel that many others also faced the same issue as I found in other posts also.

But there was no solution at all. Why is it so?

run bench update again and try.

Most users have been able to migrate to v5 smoothly.