[comedycentral] fix TDS extended interviews
authorMark Lee <youtube-dl@lazymalevolence.com>
Wed, 26 Mar 2014 05:06:49 +0000 (22:06 -0700)
committerMark Lee <youtube-dl@lazymalevolence.com>
Wed, 26 Mar 2014 17:51:02 +0000 (10:51 -0700)
The new website broke the URL format.
Added "playlist" as a valid ID keyword.

youtube_dl/extractor/comedycentral.py

index 483ae576149de801edb23a570f6fa48ef1a8a726..ea1675cf6f82a50d33d9b3996254ccf9ab737613 100644 (file)
@@ -46,7 +46,7 @@ class ComedyCentralShowsIE(InfoExtractor):
                               (the-colbert-report-(videos|collections)/(?P<clipID>[0-9]+)/[^/]*/(?P<cntitle>.*?))
                               |(watch/(?P<date>[^/]*)/(?P<tdstitle>.*)))|
                           (?P<interview>
-                              extended-interviews/(?P<interID>[0-9]+)/playlist_tds_extended_(?P<interview_title>.*?)/.*?)))
+                              extended-interviews/(?P<interID>[0-9a-z]+)/(?:playlist_tds_extended_)?(?P<interview_title>.*?)(/.*?)?)))
                      $'''
     _TEST = {
         'url': 'http://thedailyshow.cc.com/watch/thu-december-13-2012/kristen-stewart',
@@ -134,7 +134,7 @@ class ComedyCentralShowsIE(InfoExtractor):
             # a URL prefix; so extract the alternate reference
             # and then add the URL prefix manually.
 
-            altMovieParams = re.findall('data-mgid="([^"]*(?:episode|video).*?:.*?)"', webpage)
+            altMovieParams = re.findall('data-mgid="([^"]*(?:episode|video|playlist).*?:.*?)"', webpage)
             if len(altMovieParams) == 0:
                 raise ExtractorError('unable to find Flash URL in webpage ' + url)
             else: