]> gitweb @ CieloNegro.org - youtube-dl.git/blobdiff - youtube_dl/extractor/youtube.py
[youtube] Support expanding alternative format of links in description (Closes #8164)
[youtube-dl.git] / youtube_dl / extractor / youtube.py
index 4aac2cc03a0b10886c997d18e0607a54a0d0447f..897641e4283d0c3423adfb47c067f7be03b79cf7 100644 (file)
@@ -1235,10 +1235,10 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
             video_description = re.sub(r'''(?x)
                 <a\s+
                     (?:[a-zA-Z-]+="[^"]+"\s+)*?
-                    title="([^"]+)"\s+
+                    (?:title|href)="([^"]+)"\s+
                     (?:[a-zA-Z-]+="[^"]+"\s+)*?
-                    class="yt-uix-redirect-link"\s*>
-                [^<]+
+                    class="(?:yt-uix-redirect-link|yt-uix-sessionlink[^"]*)".*?>
+                [^<]+\.{3}\s*
                 </a>
             ''', r'\1', video_description)
             video_description = clean_html(video_description)