[karaoketv] Update and mark as not _WORKING
[youtube-dl] / youtube_dl / extractor / karaoketv.py
1 # coding: utf-8
2 from __future__ import unicode_literals
3
4 from .common import InfoExtractor
5
6
7 class KaraoketvIE(InfoExtractor):
8     '''
9     In api_play.php there's a video-cdn.com <iframe>. The latter plays an
10     unencrypted RTMP stream. However I can't download it with rtmpdump.
11     '''
12     _WORKING = False
13
14     _VALID_URL = r'http://www.karaoketv.co.il/[^/]+/(?P<id>\d+)'
15     _TEST = {
16         'url': 'http://www.karaoketv.co.il/%D7%A9%D7%99%D7%A8%D7%99_%D7%A7%D7%A8%D7%99%D7%95%D7%A7%D7%99/58356/%D7%90%D7%99%D7%96%D7%95%D7%9F',
17         'info_dict': {
18             'id': '58356',
19             'ext': 'flv',
20             'title': 'קריוקי של איזון',
21         }
22     }
23
24     def _real_extract(self, url):
25         video_id = self._match_id(url)
26         webpage = self._download_webpage(url, video_id)
27
28         api_page_url = self._html_search_regex(
29             r'<iframe[^>]+src="(http://www.karaoke.co.il/api_play.php?[^"]+)"',
30             webpage, 'API play URL')
31
32         return {
33             '_type': 'url_transparent',
34             'id': video_id,
35             'title': self._og_search_title(webpage),
36             'url': api_page_url,
37         }