I have spent days tracking this down. On a suggestion I rearranged my installation automation to follow the manual install rather than use install.py
. After doing all that … the Wizard STILL won’t complete.
Right now, whether I hit retry when it times out, <ctrl><alt>R the browser and reenter the data or completely rebuild the server from scratch and reenter the data … the failure is the same:
[2020-02-16 11:11:31 -0500] [1544] [CRITICAL] WORKER TIMEOUT (pid:1918)
[2020-02-16 11:11:31 -0500] [1918] [ERROR] Error handling request /api/method/frappe.desk.page.setup_wizard.setup_wizard.setup_complete
Traceback (most recent call last):
File "/home/erpnext/frappe-bench/apps/frappe/frappe/app.py", line 60, in application
response = frappe.api.handle()
File "/home/erpnext/frappe-bench/apps/frappe/frappe/api.py", line 55, in handle
return frappe.handler.handle()
File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 22, in handle
data = execute_cmd(cmd)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/handler.py", line 61, in execute_cmd
return frappe.call(method, **frappe.form_dict)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/__init__.py", line 1042, in call
return fn(*args, **newargs)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/desk/page/setup_wizard/setup_wizard.py", line 71, in setup_complete
task.get('fn')(task.get('args'))
File "/home/erpnext/frappe-bench/apps/erpnext/erpnext/setup/setup_wizard/setup_wizard.py", line 92, in stage_fixtures
fixtures.install(args.get('country'))
File "/home/erpnext/frappe-bench/apps/erpnext/erpnext/setup/setup_wizard/operations/install_fixtures.py", line 276, in install
set_more_defaults()
File "/home/erpnext/frappe-bench/apps/erpnext/erpnext/setup/setup_wizard/operations/install_fixtures.py", line 296, in set_more_defaults
add_uom_data()
File "/home/erpnext/frappe-bench/apps/erpnext/erpnext/setup/setup_wizard/operations/install_fixtures.py", line 327, in add_uom_data
}).insert(ignore_permissions=True)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/model/document.py", line 259, in insert
self.run_post_save_methods()
File "/home/erpnext/frappe-bench/apps/frappe/frappe/model/document.py", line 929, in run_post_save_methods
self.run_method('on_change')
File "/home/erpnext/frappe-bench/apps/frappe/frappe/model/document.py", line 787, in run_method
out = Document.hook(fn)(self, *args, **kwargs)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/model/document.py", line 1058, in composer
return composed(self, method, *args, **kwargs)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/model/document.py", line 1043, in runner
add_to_return_value(self, f(self, method, *args, **kwargs))
File "/home/erpnext/frappe-bench/apps/frappe/frappe/social/doctype/energy_point_rule/energy_point_rule.py", line 90, in process_energy_points
if not is_energy_point_enabled():
File "/home/erpnext/frappe-bench/apps/frappe/frappe/social/doctype/energy_point_settings/energy_point_settings.py", line 15, in is_energy_point_enabled
return frappe.get_cached_value('Energy Point Settings', None, 'enabled')
File "/home/erpnext/frappe-bench/apps/frappe/frappe/__init__.py", line 712, in get_cached_value
doc = get_cached_doc(doctype, name)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/__init__.py", line 697, in get_cached_doc
doc = get_doc(*args, **kwargs)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/__init__.py", line 740, in get_doc
doc = frappe.model.document.get_doc(*args, **kwargs)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/model/document.py", line 70, in get_doc
return controller(*args, **kwargs)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/model/document.py", line 105, in __init__
self.load_from_db()
File "/home/erpnext/frappe-bench/apps/frappe/frappe/model/document.py", line 135, in load_from_db
single_doc = frappe.db.get_singles_dict(self.doctype)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/database/database.py", line 519, in get_singles_dict
""", doctype)
File "/home/erpnext/frappe-bench/apps/frappe/frappe/database/database.py", line 156, in sql
self._cursor.execute(query, values)
File "/home/erpnext/frappe-bench/env/lib/python3.6/site-packages/pymysql/cursors.py", line 170, in execute
result = self._query(query)
File "/home/erpnext/frappe-bench/env/lib/python3.6/site-packages/pymysql/cursors.py", line 328, in _query
conn.query(q)
File "/home/erpnext/frappe-bench/env/lib/python3.6/site-packages/pymysql/connections.py", line 517, in query
self._affected_rows = self._read_query_result(unbuffered=unbuffered)
File "/home/erpnext/frappe-bench/env/lib/python3.6/site-packages/pymysql/connections.py", line 732, in _read_query_result
result.read()
File "/home/erpnext/frappe-bench/env/lib/python3.6/site-packages/pymysql/connections.py", line 1082, in read
self._read_result_packet(first_packet)
File "/home/erpnext/frappe-bench/env/lib/python3.6/site-packages/pymysql/connections.py", line 1152, in _read_result_packet
self._read_rowdata_packet()
File "/home/erpnext/frappe-bench/env/lib/python3.6/site-packages/pymysql/connections.py", line 1186, in _read_rowdata_packet
packet = self.connection._read_packet()
File "/home/erpnext/frappe-bench/env/lib/python3.6/site-packages/pymysql/connections.py", line 674, in _read_packet
recv_data = self._read_bytes(bytes_to_read)
File "/home/erpnext/frappe-bench/env/lib/python3.6/site-packages/pymysql/connections.py", line 691, in _read_bytes
data = self._rfile.read(num_bytes)
File "/home/erpnext/frappe-bench/env/lib/python3.6/site-packages/gunicorn/workers/base.py", line 201, in handle_abort
sys.exit(1)
SystemExit: 1
The key line seems to be …
File "/home/erpnext/frappe-bench/apps/erpnext/erpnext/setup/setup_wizard/operations/install_fixtures.py", line 327, in add_uom_data
}).insert(ignore_permissions=True)
… but I could be wrong.
Comparing before and after database snapshots it is obvious that the middle tier is able to write to MariaDb.
I was advancing well with ErpNext until a week ago. Now I am completely stonewalled.