Skip to Content
Menu
This question has been flagged
1467 Views

When installing the Odoo Account module and going to the chart of accounts throw this exception


This is Traceback

Traceback (most recent call last):
  File "/home/odoo/src/odoo/16.0/odoo/http.py", line 1579, in _serve_db
    return service_model.retrying(self._serve_ir_http, self.env)
  File "/home/odoo/src/odoo/16.0/odoo/service/model.py", line 134, in retrying
    result = func()
  File "/home/odoo/src/odoo/16.0/odoo/http.py", line 1608, in _serve_ir_http
    response = self.dispatcher.dispatch(rule.endpoint, args)
  File "/home/odoo/src/odoo/16.0/odoo/http.py", line 1805, in dispatch
    result = self.request.registry['ir.http']._dispatch(endpoint)
  File "/home/odoo/src/odoo/16.0/odoo/addons/base/models/ir_http.py", line 144, in _dispatch
    result = endpoint(**request.params)
  File "/home/odoo/src/odoo/16.0/odoo/http.py", line 698, in route_wrapper
    result = endpoint(self, *args, **params_ok)
  File "/home/odoo/src/odoo/16.0/addons/web/controllers/dataset.py", line 42, in call_kw
    return self._call_kw(model, method, args, kwargs)
  File "/home/odoo/src/odoo/16.0/addons/web/controllers/dataset.py", line 33, in _call_kw
    return call_kw(request.env[model], method, args, kwargs)
  File "/home/odoo/src/odoo/16.0/odoo/api.py", line 457, in call_kw
    result = _call_kw_model(method, model, args, kwargs)
  File "/home/odoo/src/odoo/16.0/odoo/api.py", line 430, in _call_kw_model
    result = method(recs, *args, **kwargs)
  File "/home/odoo/src/odoo/16.0/addons/web/models/models.py", line 62, in web_search_read
    records = self.search_read(domain, fields, offset=offset, limit=limit, order=order)
  File "/home/odoo/src/odoo/16.0/odoo/models.py", line 4951, in search_read
    records = self.search(domain or [], offset=offset, limit=limit, order=order)
  File "/home/odoo/src/odoo/16.0/odoo/models.py", line 1536, in search
    res = self._search(domain, offset=offset, limit=limit, order=order, count=count)
  File "/home/odoo/src/odoo/16.0/odoo/models.py", line 4629, in _search
    self._apply_ir_rules(query, 'read')
  File "/home/odoo/src/odoo/16.0/odoo/models.py", line 4424, in _apply_ir_rules
    expression.expression(domain, self.sudo(), self._table, query)
  File "/home/odoo/src/odoo/16.0/odoo/osv/expression.py", line 447, in __init__
    self.parse()
  File "/home/odoo/src/odoo/16.0/odoo/osv/expression.py", line 672, in parse
    raise ValueError("Invalid field %s.%s in leaf %s" % (model._name, path[0], str(leaf)))
ValueError: Invalid field account.account.department in leaf ('department', '=', 8)

This is the error message

ValueError: Invalid field account.account.department in leaf ('department', '=', 8)

 


Avatar
Discard

There is no model named "account.account.department" in Odoo 16,

Do you have any custom module?

Author

no, this is a clean database

Make sure that there is no custom module added even if it's not installed. because some modules set to true in auto_install so if all depends installed, it will be installed automatically.

Please post the log details for Odoo log, It will give us more details about the module which cause the issue.