]> Raphaƫl G. Git Repositories - youtubedl/blob - youtube_dl/extractor/nextmovie.py
debian/rules: Add commented snippet for conffile removal.
[youtubedl] / youtube_dl / extractor / nextmovie.py
1 # coding: utf-8
2 from __future__ import unicode_literals
3
4 from .mtv import MTVServicesInfoExtractor
5 from ..compat import compat_urllib_parse_urlencode
6
7
8 class NextMovieIE(MTVServicesInfoExtractor):
9 IE_NAME = 'nextmovie.com'
10 _VALID_URL = r'https?://(?:www\.)?nextmovie\.com/shows/[^/]+/\d{4}-\d{2}-\d{2}/(?P<id>[^/?#]+)'
11 _FEED_URL = 'http://lite.dextr.mtvi.com/service1/dispatch.htm'
12 _TESTS = [{
13 'url': 'http://www.nextmovie.com/shows/exclusives/2013-03-10/mgid:uma:videolist:nextmovie.com:1715019/',
14 'md5': '09a9199f2f11f10107d04fcb153218aa',
15 'info_dict': {
16 'id': '961726',
17 'ext': 'mp4',
18 'title': 'The Muppets\' Gravity',
19 },
20 }]
21
22 def _get_feed_query(self, uri):
23 return compat_urllib_parse_urlencode({
24 'feed': '1505',
25 'mgid': uri,
26 })
27
28 def _real_extract(self, url):
29 mgid = self._match_id(url)
30 return self._get_videos_info(mgid)