Compare commits

...

2 Commits

Author SHA1 Message Date
Raphaël Droz
4bb0bc30d7
Update yt_dlp/extractor/lbry.py
Co-authored-by: bashonly <88596187+bashonly@users.noreply.github.com>
2023-10-01 00:16:24 -03:00
Raphaël Droz
2fcf0e10b2
Update yt_dlp/extractor/lbry.py
Co-authored-by: bashonly <88596187+bashonly@users.noreply.github.com>
2023-10-01 00:16:16 -03:00

View File

@ -67,14 +67,13 @@ class LBRYBaseIE(InfoExtractor):
'release_timestamp': ('value', 'release_time', {int_or_none}), 'release_timestamp': ('value', 'release_time', {int_or_none}),
'tags': ('value', 'tags', ..., {lambda x: x or None}), 'tags': ('value', 'tags', ..., {lambda x: x or None}),
'duration': ('value', stream_type, 'duration', {int_or_none}), 'duration': ('value', stream_type, 'duration', {int_or_none}),
'channel': ('signing_channel', 'value', 'title', {str}),
'channel_id': ('signing_channel', 'claim_id', {str}), 'channel_id': ('signing_channel', 'claim_id', {str}),
'uploader_id': ('signing_channel', 'name', {str}),
}) })
info['uploader_id'] = traverse_obj(stream, ('signing_channel', 'normalized_name', {str})) if info.get('uploader_id') and info.get('channel_id'):
channel_name = traverse_obj(stream, ('signing_channel', (('value', 'title'), 'name'), {str}), get_all=False) info['channel_url'] = self._permanent_url(url, info['uploader_id'], info['channel_id'])
info['channel'] = channel_name
if channel_name and info.get('channel_id'):
info['channel_url'] = self._permanent_url(url, channel_name, info['channel_id'])
return info return info