mr-orange/Sick-Beard — pull request #145 by sildur (2013-04-21 19:52:54+00:00)
Title: Fix UnicodeEncodeError when processing files with unicode characters

If you try to post-process a directory with files with unicode characters in the name (such as ó) you will get this error:

Traceback (most recent call last):
File "/home/k/SickBeard/cherrypy/_cprequest.py", line 660, in respond
response.body = self.handler()
File "/home/k/SickBeard/cherrypy/lib/encoding.py", line 193, in __call__
self.body = self.oldhandler(*args, **kwargs)
File "/home/k/SickBeard/cherrypy/_cpdispatch.py", line 25, in __call__
return self.callable(*self.args, **self.kwargs)
File "/home/k/SickBeard/sickbeard/webserve.py", line 2055, in processEpisode
result = processTV.processDir(dir, nzbName)
File "/home/k/SickBeard/sickbeard/processTV.py", line 124, in processDir
process_result = processor.process()
File "/home/k/SickBeard/sickbeard/postProcessor.py", line 738, in process
if os.path.isdir(self.file_path):
File "/usr/lib/python2.7/genericpath.py", line 41, in isdir
st = os.stat(s)
UnicodeEncodeError: 'ascii' codec can't encode character u'\xf3' in position 61: ordinal not in range(128)