1
0
Fork 0

[cleanup] Bump ruff to 0.13.x (#14293)

Authored by: bashonly
This commit is contained in:
bashonly 2025-09-11 10:18:01 -05:00 committed by GitHub
commit ba80446855
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
20 changed files with 34 additions and 33 deletions

View file

@ -476,7 +476,7 @@ class ZingMp3UserIE(ZingMp3BaseIE):
class ZingMp3HubIE(ZingMp3BaseIE):
IE_NAME = 'zingmp3:hub'
_VALID_URL = r'https?://(?:mp3\.zing|zingmp3)\.vn/(?P<type>hub)/(?P<regions>[^/]+)/(?P<id>[^\.]+)'
_VALID_URL = r'https?://(?:mp3\.zing|zingmp3)\.vn/(?P<type>hub)/[^/?#]+/(?P<id>[^./?#]+)'
_TESTS = [{
'url': 'https://zingmp3.vn/hub/Nhac-Moi/IWZ9Z0CA.html',
'info_dict': {
@ -496,7 +496,7 @@ class ZingMp3HubIE(ZingMp3BaseIE):
}]
def _real_extract(self, url):
song_id, regions, url_type = self._match_valid_url(url).group('id', 'regions', 'type')
song_id, url_type = self._match_valid_url(url).group('id', 'type')
hub_detail = self._call_api(url_type, {'id': song_id})
entries = self._parse_items(traverse_obj(hub_detail, (
'sections', lambda _, v: v['sectionId'] == 'hub', 'items', ...)))