aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Sawicki <37424085+Grub4K@users.noreply.github.com>2022-09-30 18:52:52 +0200
committerGitHub <noreply@github.com>2022-09-30 22:22:52 +0530
commit2e0f8d4f6e4dd546044c9432ec6aa223f67178bb (patch)
tree317354973dabed435202dd7237a361931f6516d9
parent7e378287c4502d82aedb5272b8e9d5f6c1681fad (diff)
downloadhypervideo-pre-2e0f8d4f6e4dd546044c9432ec6aa223f67178bb.tar.lz
hypervideo-pre-2e0f8d4f6e4dd546044c9432ec6aa223f67178bb.tar.xz
hypervideo-pre-2e0f8d4f6e4dd546044c9432ec6aa223f67178bb.zip
[extractor/yandexvideopreview] Update _VALID_URL (#5084)
Closes #5065 Authored by: Grub4K
-rw-r--r--yt_dlp/extractor/yandexvideo.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/yt_dlp/extractor/yandexvideo.py b/yt_dlp/extractor/yandexvideo.py
index 37ff514b3..eadb1aaee 100644
--- a/yt_dlp/extractor/yandexvideo.py
+++ b/yt_dlp/extractor/yandexvideo.py
@@ -147,7 +147,7 @@ class YandexVideoIE(InfoExtractor):
class YandexVideoPreviewIE(InfoExtractor):
- _VALID_URL = r'https?://(?:www\.)?yandex\.ru/video/preview(?:/?\?.*?filmId=|/)(?P<id>\d+)'
+ _VALID_URL = r'https?://(?:www\.)?yandex\.\w{2,3}(?:\.(?:am|ge|il|tr))?/video/preview(?:/?\?.*?filmId=|/)(?P<id>\d+)'
_TESTS = [{ # Odnoklassniki
'url': 'https://yandex.ru/video/preview/?filmId=10682852472978372885&text=summer',
'info_dict': {
@@ -174,6 +174,9 @@ class YandexVideoPreviewIE(InfoExtractor):
}, { # Odnoklassniki
'url': 'https://yandex.ru/video/preview/?text=Francis%20Lai%20-%20Le%20Bon%20Et%20Les%20MC)chants&path=wizard&parent-reqid=1643208087979310-1481782809207673478-sas3-0931-2f9-sas-l7-balancer-8080-BAL-9380&wiz_type=vital&filmId=12508152936505397283',
'only_matching': True,
+ }, { # Odnoklassniki
+ 'url': 'https://yandex.com/video/preview/?text=dossier%2051%20film%201978&path=yandex_search&parent-reqid=1664361087754492-8727541069609384458-sas2-0340-sas-l7-balancer-8080-BAL-8045&noreask=1&from_type=vast&filmId=5794987234584444632',
+ 'only_matching': True,
}]
def _real_extract(self, url):