Hi,

I'm developing a module with a wizard splitted into 3 steps with its own 
views. I developed the first two views separately and when I load each one 
separately (both of them at first step), they work fine. The problem is 
that when I load the second after the first, it raises this traceback.

Traceback (most recent call last):
  File "/trytond/protocols/jsonrpc.py", line 150, in _marshaled_dispatch
    response['result'] = dispatch_method(method, params)
  File "/trytond/protocols/jsonrpc.py", line 179, in _dispatch
    res = dispatch(*args)
  File "/trytond/protocols/dispatcher.py", line 161, in dispatch
    result = rpc.result(meth(*c_args, **c_kwargs))
  File "/trytond/wizard/wizard.py", line 249, in execute
    return wizard._execute(state_name)
  File "/trytond/wizard/wizard.py", line 280, in _execute
    result = self._execute(transition())
  File "/trytond/wizard/wizard.py", line 283, in _execute
    self._save()
  File "/trytond/wizard/wizard.py", line 307, in _save
    data = json.dumps(data, cls=JSONEncoder)
  File "/json/__init__.py", line 238, in dumps
    **kw).encode(obj)
  File "/json/encoder.py", line 201, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "/json/encoder.py", line 264, in iterencode
    return _iterencode(o, 0)
  File "/trytond/protocols/jsonrpc.py", line 80, in default
    return marshaller(obj)
  File "/json/encoder.py", line 178, in default
    raise TypeError(repr(o) + " is not JSON serializable")
TypeError: Pool().get('ir.lang')(1) is not JSON serializable

I have not any idea about what can be the issue because only the first view 
has fields related to ir.lang model (and it works fine), but the second one 
does not have any field related to ir.lang model.

Any clue?

Cheers,

Reply via email to