From 151d7b38d3d22969b2feeea2017952afa9024867 Mon Sep 17 00:00:00 2001 From: bashonly <88596187+bashonly@users.noreply.github.com> Date: Mon, 11 Nov 2024 21:55:58 +0000 Subject: [PATCH] make findall pattern more robust --- yt_dlp/extractor/goplay.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yt_dlp/extractor/goplay.py b/yt_dlp/extractor/goplay.py index 6e69492aae..32300f75c2 100644 --- a/yt_dlp/extractor/goplay.py +++ b/yt_dlp/extractor/goplay.py @@ -85,7 +85,7 @@ class GoPlayIE(InfoExtractor): webpage = self._download_webpage(url, display_id) nextjs_data = traverse_obj( - re.findall(r'', webpage), + re.findall(r']*>\s*self\.__next_f\.push\(\s*(\[.+?\])\s*\);?\s*', webpage), (..., {js_to_json}, {json.loads}, ..., {self._find_json}, ...)) meta = traverse_obj(nextjs_data, ( ..., lambda _, v: v['meta']['path'] == urllib.parse.urlparse(url).path, 'meta', any))