Scrape tags

This commit is contained in:
DarkFighterLuke 2022-02-23 23:34:11 +01:00
parent 2ffd1b4747
commit 84b91bbb74

View File

@ -20,6 +20,7 @@ class SxyPrnIE(InfoExtractor):
'thumbnail': r're:^https?://.*\.jpg$',
'duration': 165,
'age_limit': 18,
'tags': ['porn', 'gratis porno', 'anal', 'free porn videos', 'videos', 'movies'],
},
'params': {
'skip_download': True,
@ -56,6 +57,9 @@ class SxyPrnIE(InfoExtractor):
r'duration\s*:\s*<[^>]+>([\d:]+)', webpage, 'duration',
default=None))
tags = self._search_regex(r'<meta name="keywords".+content="(?P<tags>.+)"', webpage, 'tags', group='tags').split(', ')
print(tags)
return {
'id': video_id,
'url': video_url,
@ -64,4 +68,5 @@ class SxyPrnIE(InfoExtractor):
'duration': duration,
'age_limit': 18,
'ext': 'mp4',
'tags': tags,
}