From: Sergey M․ Date: Tue, 14 Nov 2017 15:39:54 +0000 (+0700) Subject: [vshare] Capture and output error message X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=commitdiff_plain;h=ff31f2d5c3750364b013a9bf59b85cebd0cee1fd;p=youtube-dl [vshare] Capture and output error message --- diff --git a/youtube_dl/extractor/vshare.py b/youtube_dl/extractor/vshare.py index ea39a9051..20ce22e16 100644 --- a/youtube_dl/extractor/vshare.py +++ b/youtube_dl/extractor/vshare.py @@ -5,7 +5,10 @@ import re from .common import InfoExtractor from ..compat import compat_chr -from ..utils import decode_packed_codes +from ..utils import ( + decode_packed_codes, + ExtractorError, +) class VShareIE(InfoExtractor): @@ -42,6 +45,12 @@ class VShareIE(InfoExtractor): title = self._html_search_regex(r'([^<]+)', webpage, 'title') title = title.split(' - ')[0] + error = self._html_search_regex( + r'(?s)]+\bclass=["\']xxx-error[^>]+>(.+?)