Skip to Content
Menu
This question has been flagged
1 Reply
2925 Views

Hi,

I use robroypt/odoo-client PHP Client to use Odoo API (https://packagist.org/packages/robroypt/odoo-client).

I can read and search for records without difficulties but I can't update.

I've got the following error when I try to update a record, can somebody help me ? How can I solve this problem ? 

    [faultCode] => 1
    [faultString] => Traceback (most recent call last):
  File "/home/odoo/src/odoo/10.0/odoo/service/wsgi_server.py", line 56, in xmlrpc_return
    result = odoo.http.dispatch_rpc(service, method, params)
  File "/home/odoo/src/odoo/10.0/odoo/http.py", line 118, in dispatch_rpc
    result = dispatch(method, params)
  File "/home/odoo/src/odoo/10.0/odoo/service/model.py", line 38, in dispatch
    res = fn(db, uid, *params)
  File "/home/odoo/src/odoo/10.0/odoo/service/model.py", line 157, in execute_kw
    return execute(db, uid, obj, method, *args, **kw or {})
  File "/home/odoo/src/odoo/10.0/odoo/service/model.py", line 101, in wrapper
    return f(dbname, *args, **kwargs)
  File "/home/odoo/src/odoo/10.0/odoo/service/model.py", line 164, in execute
    res = execute_cr(cr, uid, obj, method, *args, **kw)
  File "/home/odoo/src/odoo/10.0/odoo/service/model.py", line 153, in execute_cr
    return odoo.api.call_kw(recs, method, args, kw)
  File "/home/odoo/src/odoo/10.0/odoo/api.py", line 689, in call_kw
    return call_kw_multi(method, model, args, kwargs)
  File "/home/odoo/src/odoo/10.0/odoo/api.py", line 678, in call_kw_multi
    recs = self.with_context(context or {}).browse(ids)
  File "/home/odoo/src/odoo/10.0/odoo/models.py", line 4792, in browse
    return self._browse(ids, self.env, prefetch)
  File "/home/odoo/src/odoo/10.0/odoo/models.py", line 4779, in _browse
    prefetch[cls._name].update(ids)
TypeError: unhashable type: 'list'
Avatar
Discard
Best Answer

Same issue here, did you manage to figure it out?

edit: I've found the solution. I made a pull request, hopefully robroy merges it in soon

https://github.com/robroypt/odoo-client/pull/3

Avatar
Discard
Related Posts Replies Views Activity
6
Dec 23
44081
0
Dec 21
920
1
Sep 20
5901
0
Oct 24
134
1
Apr 24
333