Compare commits

...

3 Commits

Author SHA1 Message Date
bashonly
e28449cd2b
video_id => display_id 2023-12-16 04:25:05 +00:00
bashonly
4b6d4967f8
test regex 2023-12-16 04:14:42 +00:00
Tristan Charpentier
8886a6d3fc [RinseFM] Accept both cases of .jpg thumbnails 2023-12-15 19:40:19 -05:00

View File

@ -5,23 +5,23 @@ from ..utils import format_field, parse_iso8601
class RinseFMIE(InfoExtractor):
_VALID_URL = r'https?://(?:www\.)?rinse\.fm/episodes/(?P<id>[^/?#]+)'
_TESTS = [{
'url': 'https://rinse.fm/episodes/cameo-blush-01-09-2023-2300/',
'md5': '9284abbd785e6b86e67d1cdca6224feb',
'url': 'https://rinse.fm/episodes/club-glow-15-12-2023-2000/',
'md5': '76ee0b719315617df42e15e710f46c7b',
'info_dict': {
'id': '1351562',
'id': '1536535',
'ext': 'mp3',
'title': 'Cameo Blush - 01/09/2023 - 23:00',
'thumbnail': r're:^https?://.*\.JPG$',
'release_timestamp': 1693522800,
'release_date': '20230831'
'title': 'Club Glow - 15/12/2023 - 20:00',
'thumbnail': r're:^https://.+\.(?:jpg|JPG)$',
'release_timestamp': 1702598400,
'release_date': '20231215'
}
}]
def _real_extract(self, url):
video_id = self._match_id(url)
webpage = self._download_webpage(url, video_id)
display_id = self._match_id(url)
webpage = self._download_webpage(url, display_id)
entry = self._search_nextjs_data(webpage, display_id)['props']['pageProps']['entry']
entry = self._search_nextjs_data(webpage, video_id)['props']['pageProps']['entry']
return {
'id': entry['id'],
'title': entry.get('title'),