Skip to Content
Menu
This question has been flagged
1944 Views

Hello!

I'm having issues trying to acces the Products and Product Variants in the Inventory Aplication, and accessing the Purchase application as well. I'm usign the image from dockerHub with the tag latest (odoo 12).

In the error there always says that some Field does not exists, and i'ts giving an n/a in all the contexts. As example when opening the Products tab:

Odoo Server Error
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 654, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 312, in _handle_exception
    raise pycompat.reraise(type(exception), exception, sys.exc_info()[2])
  File "/usr/lib/python3/dist-packages/odoo/tools/pycompat.py", line 87, in reraise
    raise value
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 696, in dispatch
    result = self._call_function(**self.params)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 344, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/service/model.py", line 97, in wrapper
    return f(dbname, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 337, in checked_call
    result = self.endpoint(*a, **kw)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 939, in __call__
    return self.method(*args, **kw)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 517, in response_wrap
    response = f(*args, **kw)
  File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 962, in call_kw
    return self._call_kw(model, method, args, kwargs)
  File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 954, in _call_kw
    return call_kw(request.env[model], method, args, kwargs)
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 745, in call_kw
    return _call_kw_model(method, model, args, kwargs)
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 718, in _call_kw_model
    result = method(recs, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 1376, in load_views
    for [v_id, v_type] in views
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 1376, in <dictcomp>
    for [v_id, v_type] in views
  File "/usr/lib/python3/dist-packages/odoo/addons/mail/models/mail_thread.py", line 410, in fields_view_get
    res = super(MailThread, self).fields_view_get(view_id=view_id, view_type=view_type, toolbar=toolbar, submenu=submenu)
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 1462, in fields_view_get
    xarch, xfields = View.postprocess_and_fields(self._name, etree.fromstring(result['arch']), view_id)
  File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_ui_view.py", line 1096, in postprocess_and_fields
    self.raise_view_error(message, view_id)
  File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_ui_view.py", line 548, in raise_view_error
    raise ValueError(message)
ValueError: Field `purchase_line_warn` does not exist

Error context:
View `n/a`
[view_id: n/a, xml_id: n/a, model: n/a, parent_id: n/a]

I've seen that a when the context is clear, the table where to look is easy to get, but as long as I
don't get any Context I don't know where to look.

When opening the purchase application it says:


Odoo Server Error
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 1039, in get
    value = self._data[key][field][record._ids[0]]
KeyError: 447

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/odoo/fields.py", line 980, in __get__
    value = record.env.cache.get(record, self)
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 1041, in get
    raise CacheMiss(record, field)
odoo.exceptions.CacheMiss: ('ir.actions.act_window(447,).search_view', None)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 654, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 312, in _handle_exception
    raise pycompat.reraise(type(exception), exception, sys.exc_info()[2])
  File "/usr/lib/python3/dist-packages/odoo/tools/pycompat.py", line 87, in reraise
    raise value
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 696, in dispatch
    result = self._call_function(**self.params)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 344, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/service/model.py", line 97, in wrapper
    return f(dbname, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 337, in checked_call
    result = self.endpoint(*a, **kw)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 939, in __call__
    return self.method(*args, **kw)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 517, in response_wrap
    response = f(*args, **kw)
  File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 1262, in load
    action = request.env[action_type].browse([action_id]).read()
  File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_actions.py", line 210, in read
    result = super(IrActionsActWindow, self).read(fields, load=load)
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 2782, in read
    vals[name] = convert(record[name], record, use_name_get)
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 5088, in __getitem__
    return self._fields[key].__get__(self, type(self))
  File "/usr/lib/python3/dist-packages/odoo/fields.py", line 984, in __get__
    self.determine_value(record)
  File "/usr/lib/python3/dist-packages/odoo/fields.py", line 1095, in determine_value
    self.compute_value(recs)
  File "/usr/lib/python3/dist-packages/odoo/fields.py", line 1051, in compute_value
    self._compute_value(records)
  File "/usr/lib/python3/dist-packages/odoo/fields.py", line 1042, in _compute_value
    getattr(records, self.compute)()
  File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_actions.py", line 170, in _compute_search_view
    fvg = self.env[act.res_model].fields_view_get(act.search_view_id.id, 'search')
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 821, in __getitem__
    return self.registry[model_name]._browse((), self)
  File "/usr/lib/python3/dist-packages/odoo/modules/registry.py", line 176, in __getitem__
    return self.models[model_name]
KeyError: 'purchase.order'
Thank you in advance

Edit 1:
I've tried to intall the purchases Application (it's supposed to be installed but seems like not) and I'm getting the following error 


Odoo Server Error
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 757, in parse
    self._tags[rec.tag](rec, de, mode=mode)
  File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 662, in _tag_record
    record = model.with_context(rec_context)._load_records([data], self.mode == 'update')
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 3811, in _load_records
    data['record']._load_records_write(data['values'])
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 3749, in _load_records_write
    self.write(values)
  File "/usr/lib/python3/dist-packages/odoo/addons/stock/models/stock_warehouse.py", line 167, in write
    warehouse._create_or_update_global_routes_rules()
  File "/usr/lib/python3/dist-packages/odoo/addons/stock/models/stock_warehouse.py", line 247, in _create_or_update_global_routes_rules
    self[rule_field] = self.env['stock.rule'].create(values)
  File "<decorator-gen-3>", line 2, in create
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 451, in _model_create_multi
    return create(self, [arg])
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 3533, in create
    records = self._create(data_list)
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 3633, in _create
    cr.execute(query, params)
  File "/usr/lib/python3/dist-packages/odoo/sql_db.py", line 148, in wrapper
    return f(self, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/sql_db.py", line 225, in execute
    res = self._obj.execute(query, params)
psycopg2.IntegrityError: null value in column "location_id" violates not-null constraint
DETAIL:  Failing row contains (34, WH: False (Buy), t, none, null, buy, 20, 1, null, null, 29, make_to_stock, null, null, 0, null, t, 1, null, manual, 1, 2019-07-15 17:48:50.290492, 1, 2019-07-15 17:48:50.290492).


During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 654, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 312, in _handle_exception
    raise pycompat.reraise(type(exception), exception, sys.exc_info()[2])
  File "/usr/lib/python3/dist-packages/odoo/tools/pycompat.py", line 87, in reraise
    raise value
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 696, in dispatch
    result = self._call_function(**self.params)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 344, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/service/model.py", line 97, in wrapper
    return f(dbname, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 337, in checked_call
    result = self.endpoint(*a, **kw)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 939, in __call__
    return self.method(*args, **kw)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 517, in response_wrap
    response = f(*args, **kw)
  File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 966, in call_button
    action = self._call_kw(model, method, args, {})
  File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 954, in _call_kw
    return call_kw(request.env[model], method, args, kwargs)
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 749, in call_kw
    return _call_kw_multi(method, model, args, kwargs)
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 736, in _call_kw_multi
    result = method(recs, *args, **kwargs)
  File "<decorator-gen-61>", line 2, in button_immediate_install
  File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_module.py", line 74, in check_and_log
    return method(self, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_module.py", line 445, in button_immediate_install
    return self._button_immediate_function(type(self).button_install)
  File "/usr/lib/python3/dist-packages/odoo/addons/base/models/ir_module.py", line 561, in _button_immediate_function
    modules.registry.Registry.new(self._cr.dbname, update_module=True)
  File "/usr/lib/python3/dist-packages/odoo/modules/registry.py", line 86, in new
    odoo.modules.load_modules(registry._db, force_demo, status, update_module)
  File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 421, in load_modules
    loaded_modules, update_module, models_to_check)
  File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 313, in load_marked_modules
    perform_checks=perform_checks, models_to_check=models_to_check
  File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 222, in load_module_graph
    load_data(cr, idref, mode, kind='data', package=package, report=report)
  File "/usr/lib/python3/dist-packages/odoo/modules/loading.py", line 68, in load_data
    tools.convert_file(cr, package.name, filename, idref, mode, noupdate, kind, report)
  File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 801, in convert_file
    convert_xml_import(cr, module, fp, idref, mode, noupdate, report)
  File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 864, in convert_xml_import
    obj.parse(doc.getroot(), mode=mode)
  File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 754, in parse
    self.parse(rec, mode)
  File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 763, in parse
    exc_info[2]
  File "/usr/lib/python3/dist-packages/odoo/tools/pycompat.py", line 86, in reraise
    raise value.with_traceback(tb)
  File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 757, in parse
    self._tags[rec.tag](rec, de, mode=mode)
  File "/usr/lib/python3/dist-packages/odoo/tools/convert.py", line 662, in _tag_record
    record = model.with_context(rec_context)._load_records([data], self.mode == 'update')
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 3811, in _load_records
    data['record']._load_records_write(data['values'])
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 3749, in _load_records_write
    self.write(values)
  File "/usr/lib/python3/dist-packages/odoo/addons/stock/models/stock_warehouse.py", line 167, in write
    warehouse._create_or_update_global_routes_rules()
  File "/usr/lib/python3/dist-packages/odoo/addons/stock/models/stock_warehouse.py", line 247, in _create_or_update_global_routes_rules
    self[rule_field] = self.env['stock.rule'].create(values)
  File "<decorator-gen-3>", line 2, in create
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 451, in _model_create_multi
    return create(self, [arg])
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 3533, in create
    records = self._create(data_list)
  File "/usr/lib/python3/dist-packages/odoo/models.py", line 3633, in _create
    cr.execute(query, params)
  File "/usr/lib/python3/dist-packages/odoo/sql_db.py", line 148, in wrapper
    return f(self, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/sql_db.py", line 225, in execute
    res = self._obj.execute(query, params)
odoo.tools.convert.ParseError: "null value in column "location_id" violates not-null constraint
DETAIL:  Failing row contains (34, WH: False (Buy), t, none, null, buy, 20, 1, null, null, 29, make_to_stock, null, null, 0, null, t, 1, null, manual, 1, 2019-07-15 17:48:50.290492, 1, 2019-07-15 17:48:50.290492).
" while parsing /usr/lib/python3/dist-packages/odoo/addons/purchase_stock/data/purchase_stock_data.xml:15, near
<record id="stock.warehouse0" model="stock.warehouse">
            <field name="buy_to_resupply" eval="True"/>
        </record>
Avatar
Discard