[utils] clean_podcast_url: Handle more trackers (#7556)

Authored by: mabdelfattah, bashonly
Closes #7544
This commit is contained in:
Mahmoud Abdel-Fattah
2023-07-11 05:00:38 +04:00
committed by GitHub
parent 325191d0c9
commit 2af4eeb772
2 changed files with 9 additions and 3 deletions

View File

@@ -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)