aboutsummaryrefslogtreecommitdiffstats
path: root/yt_dlp/utils/_utils.py
diff options
context:
space:
mode:
authorMahmoud Abdel-Fattah <accounts@abdel-fattah.net>2023-07-11 05:00:38 +0400
committerGitHub <noreply@github.com>2023-07-11 06:30:38 +0530
commit2af4eeb77246b8183aae75a0a8d19f18c08115b2 (patch)
tree1a0fadbd677635c9d6f3b80cf3d43f6fe214fa90 /yt_dlp/utils/_utils.py
parent325191d0c9bf3fe257b8a7c2eb95080f44f6ddfc (diff)
downloadhypervideo-pre-2af4eeb77246b8183aae75a0a8d19f18c08115b2.tar.lz
hypervideo-pre-2af4eeb77246b8183aae75a0a8d19f18c08115b2.tar.xz
hypervideo-pre-2af4eeb77246b8183aae75a0a8d19f18c08115b2.zip
[utils] `clean_podcast_url`: Handle more trackers (#7556)
Authored by: mabdelfattah, bashonly Closes #7544
Diffstat (limited to 'yt_dlp/utils/_utils.py')
-rw-r--r--yt_dlp/utils/_utils.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/yt_dlp/utils/_utils.py b/yt_dlp/utils/_utils.py
index 82d9ba4d5..3023c33b2 100644
--- a/yt_dlp/utils/_utils.py
+++ b/yt_dlp/utils/_utils.py
@@ -5123,14 +5123,18 @@ def clean_podcast_url(url):
(?:
chtbl\.com/track|
media\.blubrry\.com| # https://create.blubrry.com/resources/podcast-media-download-statistics/getting-started/
- play\.podtrac\.com
- )/[^/]+|
+ play\.podtrac\.com|
+ chrt\.fm/track|
+ mgln\.ai/e
+ )(?:/[^/.]+)?|
(?:dts|www)\.podtrac\.com/(?:pts/)?redirect\.[0-9a-z]{3,4}| # http://analytics.podtrac.com/how-to-measure
flex\.acast\.com|
pd(?:
cn\.co| # https://podcorn.com/analytics-prefix/
st\.fm # https://podsights.com/docs/
- )/e
+ )/e|
+ [0-9]\.gum\.fm|
+ pscrb\.fm/rss/p
)/''', '', url)
return re.sub(r'^\w+://(\w+://)', r'\1', url)