]> gitweb @ CieloNegro.org - youtube-dl.git/commitdiff
[comedycentral] Allow URLs with query parts (fixes #2661)
authorPhilipp Hagemeister <phihag@phihag.de>
Mon, 31 Mar 2014 22:25:11 +0000 (00:25 +0200)
committerPhilipp Hagemeister <phihag@phihag.de>
Mon, 31 Mar 2014 22:25:11 +0000 (00:25 +0200)
test/test_all_urls.py
youtube_dl/extractor/comedycentral.py

index dffe3f95854d965bac5746cd7f741fd5cc4601da..ed041ffda0614a956b5410b011b9d784b3b618c4 100644 (file)
@@ -150,6 +150,9 @@ class TestAllURLsMatching(unittest.TestCase):
         self.assertMatch(
             'http://thecolbertreport.cc.com/videos/29w6fx/-realhumanpraise-for-fox-news',
             ['ComedyCentralShows'])
+        self.assertMatch(
+            'http://thecolbertreport.cc.com/videos/gh6urb/neil-degrasse-tyson-pt--1?xrs=eml_col_031114',
+            ['ComedyCentralShows'])
 
 if __name__ == '__main__':
     unittest.main()
index cbc212065cf9635a2b23fe8d5536f88fcb2f05ea..ed0c6ea2ca00366fd3f43213e7f265519611a4ef 100644 (file)
@@ -45,10 +45,11 @@ class ComedyCentralShowsIE(InfoExtractor):
                           (?P<clip>
                               (?:videos/[^/]+/(?P<videotitle>[^/?#]+))
                               |(the-colbert-report-(videos|collections)/(?P<clipID>[0-9]+)/[^/]*/(?P<cntitle>.*?))
-                              |(watch/(?P<date>[^/]*)/(?P<tdstitle>.*)))|
+                              |(watch/(?P<date>[^/]*)/(?P<tdstitle>.*))
+                          )|
                           (?P<interview>
                               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',
         'md5': '4e2f5cb088a83cd8cdb7756132f9739d',