jgm/CommonMark — pull request #250 by cirosantilli (2014-12-21 13:41:02+00:00)
Title: Don't raise exception on invalid UTF-8 output

This could be reproduced with:

./test/spec_tests.py --program kramdown --pattern Enti

with Kramdown version 1.5.0.

The main problem is that it would stop future tests from being carried out.

After this commit it is just counted as a failure.

The error message printed is of the form:

Unicode error: 'utf8' codec can't decode byte 0xfc in position 8: invalid start byte
'

# \xd3\x92 \xcf\xa0 \xef\xbf\xbd

\n'
'

# \xd3\x92 \xcf\xa0 \xfc\x85\xb8\xb0\xa9\xb8

\n'