Comment 2 for bug 1744973

Revision history for this message
Kevin Pouget (kpouget) wrote :

Hi Mistral team !

We probably have the same issue, this occurs when utf8 chars are present in a published task output. We are running mistral with python 2.7.

01/10/2019|19:19:25|ERROR|oslo_messaging.rpc.server|Exception during message handling
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/site-packages/oslo_messaging/rpc/server.py", line 166, in _process_incoming
    res = self.dispatcher.dispatch(message)
  File "/usr/local/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 265, in dispatch
    return self._do_dispatch(endpoint, method, ctxt, args)
  File "/usr/local/lib/python2.7/site-packages/oslo_messaging/rpc/dispatcher.py", line 194, in _do_dispatch
    result = func(ctxt, **new_args)
  File "/usr/local/lib/python2.7/site-packages/mistral/engine/engine_server.py", line 153, in on_action_complete
    result.cut_repr()
  File "/usr/local/lib/python2.7/site-packages/mistral_lib/actions/types.py", line 36, in cut_repr
    utils.cut(self.data), utils.cut(self.error), str(self.cancel)
  File "/usr/local/lib/python2.7/site-packages/mistral_lib/utils/__init__.py", line 139, in cut
    return cut_dict(data, length=length)
  File "/usr/local/lib/python2.7/site-packages/mistral_lib/utils/__init__.py", line 35, in cut_dict
    v = str(value)
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe9' in position 1: ordinal not in range(128)

The issue seems to be related to the display of the task results.