Properly convert errors to strings

This commit is contained in:
Sergey M․ 2015-12-20 05:27:38 +06:00
parent fdae235858
commit 7f8b271465
6 changed files with 17 additions and 19 deletions

View file

@ -26,6 +26,7 @@ from ..compat import (
from ..utils import (
clean_html,
encode_dict,
error_to_str,
ExtractorError,
float_or_none,
get_element_by_attribute,
@ -903,7 +904,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
'https://video.google.com/timedtext?hl=en&type=list&v=%s' % video_id,
video_id, note=False)
except ExtractorError as err:
self._downloader.report_warning('unable to download video subtitles: %s' % compat_str(err))
self._downloader.report_warning('unable to download video subtitles: %s' % error_to_str(err))
return {}
sub_lang_list = {}