1
0
Fork 0

[cleanup] Add more ruff rules (#10149)

Authored by: seproDev

Reviewed-by: bashonly <88596187+bashonly@users.noreply.github.com>
Reviewed-by: Simon Sawicki <contact@grub4k.xyz>
This commit is contained in:
sepro 2024-06-12 01:09:58 +02:00 committed by GitHub
commit add96eb9f8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
915 changed files with 7028 additions and 7247 deletions

View file

@ -11,7 +11,7 @@ class SlutloadIE(InfoExtractor):
'ext': 'mp4',
'title': 'virginie baisee en cam',
'age_limit': 18,
'thumbnail': r're:https?://.*?\.jpg'
'thumbnail': r're:https?://.*?\.jpg',
},
}, {
# mobile site
@ -29,14 +29,14 @@ class SlutloadIE(InfoExtractor):
video_id = self._match_id(url)
embed_page = self._download_webpage(
'http://www.slutload.com/embed_player/%s' % video_id, video_id,
f'http://www.slutload.com/embed_player/{video_id}', video_id,
'Downloading embed page', fatal=False)
if embed_page:
def extract(what):
return self._html_search_regex(
r'data-video-%s=(["\'])(?P<url>(?:(?!\1).)+)\1' % what,
embed_page, 'video %s' % what, default=None, group='url')
rf'data-video-{what}=(["\'])(?P<url>(?:(?!\1).)+)\1',
embed_page, f'video {what}', default=None, group='url')
video_url = extract('url')
if video_url:
@ -47,11 +47,11 @@ class SlutloadIE(InfoExtractor):
'url': video_url,
'title': title,
'thumbnail': extract('preview'),
'age_limit': 18
'age_limit': 18,
}
webpage = self._download_webpage(
'http://www.slutload.com/video/_/%s/' % video_id, video_id)
f'http://www.slutload.com/video/_/{video_id}/', video_id)
title = self._html_search_regex(
r'<h1><strong>([^<]+)</strong>', webpage, 'title').strip()
info = self._parse_html5_media_entries(url, webpage, video_id)[0]