youtube-dl

Another place where youtube-dl lives on
git clone git://git.oshgnacknak.de/youtube-dl.git
Log | Files | Refs | README | LICENSE

commit 2a8137272d7d463648ccf53d25d78660209ad928
parent 762155cc90754fc29c68bf0f0256988f37862c3b
Author: Yen Chi Hsuan <yan12125@gmail.com>
Date:   Thu, 23 Apr 2015 18:24:44 +0800

[ustream] Add an alternative approach to extract title (fixes #5128)

Diffstat:
Myoutube_dl/extractor/ustream.py | 11++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/youtube_dl/extractor/ustream.py b/youtube_dl/extractor/ustream.py @@ -58,7 +58,16 @@ class UstreamIE(InfoExtractor): self.report_extraction(video_id) video_title = self._html_search_regex(r'data-title="(?P<title>.+)"', - webpage, 'title') + webpage, 'title', default=None) + + if not video_title: + try: + video_title = params['moduleConfig']['meta']['title'] + except KeyError: + pass + + if not video_title: + video_title = 'Ustream video ' + video_id uploader = self._html_search_regex(r'data-content-type="channel".*?>(?P<uploader>.*?)</a>', webpage, 'uploader', fatal=False, flags=re.DOTALL)