Hi i'm getting this error when i close one of my point of sale on odoo.
Erreur:
Odoo Server Error
Traceback (most recent call last):
File "/home/odoo/odoo/odoo/fields.py", line 944, in __get__
value = record.env.cache.get(record, self)
File "/home/odoo/odoo/odoo/api.py", line 960, in get
value = self._data[field][record.id][key]
KeyError: <odoo.api.Environment object at 0x7fd2f32bf668>
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/odoo/odoo/odoo/http.py", line 646, in _handle_exception
return super(JsonRequest, self)._handle_exception(exception)
File "/home/odoo/odoo/odoo/http.py", line 307, in _handle_exception
raise pycompat.reraise(type(exception), exception, sys.exc_info()[2])
File "/home/odoo/odoo/odoo/tools/pycompat.py", line 87, in reraise
raise value
File "/home/odoo/odoo/odoo/http.py", line 683, in dispatch
result = self._call_function(**self.params)
File "/home/odoo/odoo/odoo/http.py", line 339, in _call_function
return checked_call(self.db, *args, **kwargs)
File "/home/odoo/odoo/odoo/service/model.py", line 97, in wrapper
return f(dbname, *args, **kwargs)
File "/home/odoo/odoo/odoo/http.py", line 332, in checked_call
result = self.endpoint(*a, **kw)
File "/home/odoo/odoo/odoo/http.py", line 927, in __call__
return self.method(*args, **kw)
File "/home/odoo/odoo/odoo/http.py", line 512, in response_wrap
response = f(*args, **kw)
File "/home/odoo/odoo/addons/web/controllers/main.py", line 928, in call_button
action = self._call_kw(model, method, args, {})
File "/home/odoo/odoo/addons/web/controllers/main.py", line 916, in _call_kw
return call_kw(request.env[model], method, args, kwargs)
File "/home/odoo/odoo/odoo/api.py", line 689, in call_kw
return call_kw_multi(method, model, args, kwargs)
File "/home/odoo/odoo/odoo/api.py", line 680, in call_kw_multi
result = method(recs, *args, **kwargs)
File "/home/odoo/odoo/addons/point_of_sale/models/pos_session.py", line 257, in action_pos_session_closing_control
session.action_pos_session_close()
File "/home/odoo/odoo/addons/point_of_sale/models/pos_session.py", line 285, in action_pos_session_close
self.with_context(ctx)._confirm_orders()
File "/home/odoo/odoo/addons/point_of_sale/models/pos_session.py", line 29, in _confirm_orders
orders.with_context(force_company=company_id)._create_account_move_line(session, move)
File "/home/odoo/odoo/addons/point_of_sale/models/pos_order.py", line 360, in _create_account_move_line
move.sudo().post()
File "/home/odoo/odoo/addons/account/models/account_move.py", line 166, in post
return self.write({'state': 'posted'})
File "/home/odoo/odoo/addons/l10n_fr_certification/models/account.py", line 92, in write
'l10n_fr_hash': move._get_new_hash(new_number)}
File "/home/odoo/odoo/addons/l10n_fr_certification/models/account.py", line 39, in _get_new_hash
return self._compute_hash(prev_move.l10n_fr_hash if prev_move else '')
File "/home/odoo/odoo/addons/l10n_fr_certification/models/account.py", line 45, in _compute_hash
hash_string = sha256(previous_hash + self.l10n_fr_string_to_hash)
File "/home/odoo/odoo/odoo/fields.py", line 948, in __get__
self.determine_value(record)
File "/home/odoo/odoo/odoo/fields.py", line 1059, in determine_value
self.compute_value(recs)
File "/home/odoo/odoo/odoo/fields.py", line 1015, in compute_value
self._compute_value(records)
File "/home/odoo/odoo/odoo/fields.py", line 1006, in _compute_value
getattr(records, self.compute)()
File "/home/odoo/odoo/addons/l10n_fr_certification/models/account.py", line 68, in _compute_string_to_hash
separators=(',',':'))
File "/usr/lib/python3.5/json/__init__.py", line 237, in dumps
**kw).encode(obj)
TypeError: __init__() got an unexpected keyword argument 'encoding'
i don t have modify anything on my odoo instance.
Thanks for help.
Please read the traceback and do not only copy/paste it. That way you can learn that you have a very clear and specific problem in your module l10n_fr_certification. Now provide this information in your question title and you improve your chance to get a valuable answer. Not that difficult, isn't it?
You don't have to be a jerk dude! It is a legit question. Not everyone is an expert.