]> gitweb @ CieloNegro.org - youtube-dl.git/commitdiff
[dailymotion] Fix extraction and update _TESTS
authorYen Chi Hsuan <yan12125@gmail.com>
Wed, 12 Oct 2016 13:45:49 +0000 (21:45 +0800)
committerYen Chi Hsuan <yan12125@gmail.com>
Wed, 12 Oct 2016 13:45:49 +0000 (21:45 +0800)
Closes #10901

Seems all videos use player V5 syntax now

ChangeLog
youtube_dl/extractor/dailymotion.py

index 3e16a2cb3d539b908d359db90d202e6693adf8a4..fd3e8c2fa5d87725c6011d377ddbb85d32371bb3 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -5,6 +5,7 @@ Core
 * [Makefile] Support for GNU make < 4 is fixed; BSD make dropped (#9387)
 
 Extractors
+* [dailymotion] Fix extraction (#10901)
 * [vimeo:review] Fix extraction (#10900)
 * [nhl] Correctly handle invalid formats (#10713)
 * [footyroom] Fix extraction (#10810)
index 62b0747a5c5a73f7628a3e500cbffada661f3212..4a3314ea7d4fc2df95543cda554d32a8caf586ac 100644 (file)
@@ -94,7 +94,8 @@ class DailymotionIE(DailymotionBaseInfoExtractor):
                 'title': 'Leanna Decker - Cyber Girl Of The Year Desires Nude [Playboy Plus]',
                 'uploader': 'HotWaves1012',
                 'age_limit': 18,
-            }
+            },
+            'skip': 'video gone',
         },
         # geo-restricted, player v5
         {
@@ -144,7 +145,8 @@ class DailymotionIE(DailymotionBaseInfoExtractor):
         player_v5 = self._search_regex(
             [r'buildPlayer\(({.+?})\);\n',  # See https://github.com/rg3/youtube-dl/issues/7826
              r'playerV5\s*=\s*dmp\.create\([^,]+?,\s*({.+?})\);',
-             r'buildPlayer\(({.+?})\);'],
+             r'buildPlayer\(({.+?})\);',
+             r'var\s+config\s*=\s*({.+?});'],
             webpage, 'player v5', default=None)
         if player_v5:
             player = self._parse_json(player_v5, video_id)