From 6637787de1bb27dca0dbd4bc1153bfd9b2e80b3e Mon Sep 17 00:00:00 2001 From: DentorDev <92227212+Dentordev@users.noreply.github.com> Date: Thu, 20 Mar 2025 13:40:02 -0500 Subject: [PATCH] Fix Quotes in speedrun.py --- yt_dlp/extractor/speedrun.py | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/yt_dlp/extractor/speedrun.py b/yt_dlp/extractor/speedrun.py index 4430aaf021..b0208aeb83 100644 --- a/yt_dlp/extractor/speedrun.py +++ b/yt_dlp/extractor/speedrun.py @@ -1,19 +1,22 @@ from .common import InfoExtractor -# Speedrun.com has the ability to host twitch embeds as well which is why this script was needed. +# Speedrun.com has the ability to host twitch embeds as well which is why this +# script was needed, otherwise there would've been no use for it. +# However the Youtube embed scraper is prone to flase positives hence +# this script's existance. class SpeedRunIE(InfoExtractor): - IE_NAME = "speedrun" + IE_NAME = 'speedrun' _VALID_URL = r'https?://(?:www\.)?speedrun\.com/[^/?#]+/runs/(?P[^?/#]+)' - + _TESTS = [{ - "url":"https://www.speedrun.com/smg1/runs/yvnjr9om", - 'only_matching': True + 'url':'https://www.speedrun.com/smg1/runs/yvnjr9om', + 'only_matching': True, }, { - "url":"https://www.speedrun.com/pm64/runs/y96x462y", - 'only_matching': True + 'url':'https://www.speedrun.com/pm64/runs/y96x462y', + 'only_matching': True, }] - + def _real_extract(self, url): video_id = self._match_id(url) webpage = self._download_webpage(url, video_id)