UnicodeDecodeError when running command

15 views
Skip to first unread message

Tavi

unread,
Sep 17, 2014, 3:48:56 PM9/17/14
to pytho...@googlegroups.com
I get the following when I run a command from a dodo.py file:

Exception in thread Thread-1:
Traceback (most recent call last):
  File "/home/utils/python/2.7.6/lib/python2.7/threading.py", line 810, in __bootstrap_inner
    self.run()
  File "/home/utils/python/2.7.6/lib/python2.7/threading.py", line 763, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/home/utils/python/2.7.6/lib/python2.7/site-packages/doit/action.py", line 142, in _print_process_output
    line = input_.readline().decode('utf-8')
  File "/home/utils/python/2.7.6/lib/python2.7/encodings/utf_8.py", line 16, in decode
    return codecs.utf_8_decode(input, errors, True)
UnicodeDecodeError: 'utf8' codec can't decode byte 0xa9 in position 10: invalid start byte


It seems that doit cannot handle non utf8 encoded output. In my case, the tool I am running outputs the coyright symbol to stdout.

Is there a workaround for this issue? 


--Tavi

Eduardo Schettino

unread,
Sep 17, 2014, 7:24:22 PM9/17/14
to python-doit

Please create an issue on github[1] including a small example that reproduces the failure.

[1] https://github.com/pydoit/doit/issues

Tavi

unread,
Sep 18, 2014, 1:33:18 PM9/18/14
to pytho...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages