[ie/wistia] Support password-protected videos (#11100)
[yt-dlp3.git] / yt_dlp / extractor / teachingchannel.py
blob5791292a9590f31b234b937089dc076f80bc5770
1 from .common import InfoExtractor
4 class TeachingChannelIE(InfoExtractor):
5 _WORKING = False
6 _VALID_URL = r'https?://(?:www\.)?teachingchannel\.org/videos?/(?P<id>[^/?&#]+)'
8 _TEST = {
9 'url': 'https://www.teachingchannel.org/videos/teacher-teaming-evolution',
10 'info_dict': {
11 'id': '3swwlzkT',
12 'ext': 'mp4',
13 'title': 'A History of Teaming',
14 'description': 'md5:2a9033db8da81f2edffa4c99888140b3',
15 'duration': 422,
16 'upload_date': '20170316',
17 'timestamp': 1489691297,
19 'params': {
20 'skip_download': True,
22 'add_ie': ['JWPlatform'],
25 def _real_extract(self, url):
26 display_id = self._match_id(url)
27 webpage = self._download_webpage(url, display_id)
28 mid = self._search_regex(
29 r'(?:data-mid=["\']|id=["\']jw-video-player-)([a-zA-Z0-9]{8})',
30 webpage, 'media id')
32 return self.url_result('jwplatform:' + mid, 'JWPlatform', mid)