mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-09-21 18:01:24 +02:00
Compare commits
2 Commits
74513d7f22
...
bc56c066ce
Author | SHA1 | Date | |
---|---|---|---|
|
bc56c066ce | ||
|
2121e472ba |
|
@ -4,15 +4,16 @@ import re
|
|||
from .common import InfoExtractor
|
||||
from ..networking import HEADRequest
|
||||
from ..utils import (
|
||||
InAdvancePagedList,
|
||||
clean_html,
|
||||
determine_ext,
|
||||
float_or_none,
|
||||
InAdvancePagedList,
|
||||
int_or_none,
|
||||
join_nonempty,
|
||||
make_archive_id,
|
||||
mimetype2ext,
|
||||
orderedSet,
|
||||
remove_end,
|
||||
make_archive_id,
|
||||
smuggle_url,
|
||||
strip_jsonp,
|
||||
try_call,
|
||||
|
@ -337,11 +338,10 @@ class ORFRadioIE(InfoExtractor):
|
|||
|
||||
class ORFPodcastIE(InfoExtractor):
|
||||
IE_NAME = 'orf:podcast'
|
||||
|
||||
_STATION_RE = 'noe|wie|bgl|ooe|stm|ktn|sbg|tir|vbg|oe3|oe1|fm4|tv'
|
||||
|
||||
_STATION_RE = '|'.join(map(re.escape, (
|
||||
'bgl', 'fm4', 'ktn', 'noe', 'oe1', 'oe3',
|
||||
'ooe', 'sbg', 'stm', 'tir', 'tv', 'vbg', 'wie')))
|
||||
_VALID_URL = rf'https?://sound\.orf\.at/podcast/(?P<station>{_STATION_RE})/(?P<show>[\w-]+)/(?P<id>[\w-]+)'
|
||||
|
||||
_TESTS = [{
|
||||
'url': 'https://sound.orf.at/podcast/oe3/fruehstueck-bei-mir/nicolas-stockhammer-15102023',
|
||||
'md5': '526a5700e03d271a1505386a8721ab9b',
|
||||
|
@ -366,6 +366,7 @@ class ORFPodcastIE(InfoExtractor):
|
|||
'vcodec': 'none',
|
||||
**traverse_obj(data, ('payload', {
|
||||
'url': ('enclosures', 0, 'url'),
|
||||
'ext': ('enclosures', 0, 'type', {mimetype2ext}),
|
||||
'title': 'title',
|
||||
'description': ('description', {clean_html}),
|
||||
'duration': ('duration', {functools.partial(float_or_none, scale=1000)}),
|
||||
|
|
Loading…
Reference in New Issue
Block a user