Skip to Content
Menu
This question has been flagged
1714 Views

Hello, I am trying to upgrade base but I am getting the below error. What does the error mean and how can I solve it?

Any Kinda assistance will be highly appreciated, thank you.


Failed to initialize database `db_name`. 
Traceback (most recent call last):
File "/home/odoo/src/odoo/odoo/tools/ convert.py", line 683, in _tag_root
f(rec)
File "/home/odoo/src/odoo/odoo/ tools/ convert.py", line 486, in _tag_menuitem
menu = self.env[' ir.ui.menu']._load_records([data], self.mode == 'update')
File "/home/odoo/src /odoo/odoo/ models.py", line 4420, in _load_records
data['record']._load_records_write(data['values'])
File "/home/odoo/src/odoo/odoo/ models.py", line 4344, in _load_records_write
self.
File "/home/odoo/src/user/bi_advance_hide_show_menu/models/ res_user.py", line 101, in write
request.env[' ir.ui.menu'].load_menus(request.session.debug)
File "/usr /lib/python3/dist-packages/werkzeug/ local.py", line 348, in __getattr__
return getattr(self._get_current_object(), name)
File "/usr/lib/python3/dist-packages/werkzeug/ local.py ", line 307, in _get_current_object
return self.__local()
File "/usr/lib/python3/dist-packages/werkzeug/ local.py", line 137, in _lookup
raise RuntimeError("object unbound")
RuntimeError: object unbound

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "/home/odoo/src/odoo/odoo/service/ server.py", line 1260, in preload_registries
registry = Registry.new (dbname, update_module=update_module)
File "/home/odoo/src/odoo/odoo/modules/ registry.py", line 87, in new
odoo.modules.load_modules(registry, force_demo, status, update_module)
File "/home /odoo/src/odoo/odoo/modules/ loading.py", line 470, in load_modules
processed_modules += load_marked_modules(cr, graph,
File "/home/odoo/src/odoo/odoo/modules/ loading.py", line 363, in load_marked_modules
loaded, processed = load_module_graph(
File "/home/odoo/src/odoo/odoo/modules/ loading.py", line 222, in load_module_graph load_data
(cr, idref, mode, kind='data', package=package)
File "/home/odoo/src/odoo/odoo/modules/ loading.py", line 69, in
load_data tools.convert_file(cr, package.name, filename, idref, mode, noupdate, kind)
File "/home/odoo /src/odoo/odoo/tools/ convert.py", line 748, in convert_file
convert_xml_import(cr, module, fp, idref, mode, noupdate)
File "/home/odoo/src/odoo/odoo/tools/ convert. py", line 814, in convert_xml_import
obj.parse(doc.getroot())
File "/home/odoo/src/odoo/odoo/tools/ convert.py", line 734, in parse
self._tag_root(de)
File "/home/odoo/src/odoo/odoo/tools/ convert.py" , line 696, in _tag_root
raise ParseError('while parsing %s:%s, somewhere inside\n%s' % (
odoo.tools.convert.ParseError: while parsing /home/odoo/src/odoo/addons/iap/ views/iap_views.xml:43, somewhere inside

Avatar
Discard

I see the below line in your error code:

Failed to initialize database `db_name`.

If you are upgrading Odoo for command line, you need to pass the database name. make sure first to stop the Odoo service.

python [ODOO PATH]/odoo-bin -c [Path to your config file] -u base -d [DB NAME]

How did you upgrade it?

Author

@Waleed
This is how I upgraded: odoo-bin -u base --stop-after-init

Pass config file and database name:
odoo-bin -c [Path to your config file] -u base -d [DB NAME] --stop-after-init

Related Posts Replies Views Activity
2
Dec 24
3133
1
Dec 24
356
4
Nov 24
1366
1
Sep 24
1137
1
Sep 24
1203