If a git repo has a filename in it with a utf8 encoded char, the template would previously fail to render with an error like:
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 1: ordinal not in range(128)
This adds a filter to convert the utf8 charaters in the templates.
The tests have also been updated to add a file to one of the repos with a non-ascii char.
This won't work on py3, let's use text.encode('utf-8') instead (or text.decode(), I never know which one...)
text.encode('utf-8')
Could we check that the file is indeed on the page as well?
rebased
Pull-Request has been merged by pingou
If a git repo has a filename in it with a utf8 encoded char,
the template would previously fail to render with an error like:
This adds a filter to convert the utf8 charaters in the templates.
The tests have also been updated to add a file to one of the repos
with a non-ascii char.