]>
jfr.im git - yt-dlp.git/blob - yt_dlp/extractor/noodlemagazine.py
1 from .common
import InfoExtractor
9 class NoodleMagazineIE(InfoExtractor
):
10 _VALID_URL
= r
'https?://(?:www|adult\.)?noodlemagazine\.com/watch/(?P<id>[0-9-_]+)'
12 'url': 'https://adult.noodlemagazine.com/watch/-67421364_456239604',
13 'md5': '9e02aa763612929d0b4b850591a9248b',
15 'id': '-67421364_456239604',
16 'title': 'Aria alexander manojob',
17 'thumbnail': r
're:^https://.*\.jpg',
22 'description': 'Aria alexander manojob',
23 'tags': ['aria', 'alexander', 'manojob'],
24 'upload_date': '20190218',
29 def _real_extract(self
, url
):
30 video_id
= self
._match
_id
(url
)
31 webpage
= self
._download
_webpage
(url
, video_id
)
32 title
= self
._og
_search
_title
(webpage
)
33 duration
= parse_duration(self
._html
_search
_meta
('video:duration', webpage
, 'duration', default
=None))
34 description
= self
._og
_search
_property
('description', webpage
, default
='').replace(' watch online hight quality video', '')
35 tags
= self
._html
_search
_meta
('video:tag', webpage
, default
='').split(', ')
36 view_count
= parse_count(self
._html
_search
_meta
('ya:ovs:views_total', webpage
, default
=None))
37 like_count
= parse_count(self
._html
_search
_meta
('ya:ovs:likes', webpage
, default
=None))
38 upload_date
= unified_strdate(self
._html
_search
_meta
('ya:ovs:upload_date', webpage
, default
=''))
40 key
= self
._html
_search
_regex
(rf
'/{video_id}\?(?:.*&)?m=([^&"\'\s,]+)', webpage
, 'key')
41 playlist_info
= self
._download
_json
(f
'https://adult.noodlemagazine.com/playlist/{video_id}?m={key}', video_id
)
42 thumbnail
= self
._og
_search
_property
('image', webpage
, default
=None) or playlist_info
.get('image')
45 'url': source
.get('file'),
46 'quality': source
.get('label'),
47 'ext': source
.get('type'),
48 } for source
in playlist_info
.get('sources')]
50 self
._sort
_formats
(formats
)
56 'thumbnail': thumbnail
,
58 'description': description
,
60 'view_count': view_count
,
61 'like_count': like_count
,
62 'upload_date': upload_date
,