diff --git a/gallery_dl/extractor/weibo.py b/gallery_dl/extractor/weibo.py index 7bf52423..54171986 100644 --- a/gallery_dl/extractor/weibo.py +++ b/gallery_dl/extractor/weibo.py @@ -148,7 +148,8 @@ class WeiboExtractor(Extractor): media = max(info["playback_list"], key=lambda m: m["meta"]["quality_index"]) except Exception: - return {"url": (info.get("stream_url_hd") or + return {"url": (info.get("replay_hd") or + info.get("stream_url_hd") or info.get("stream_url") or "")} else: return media["play_info"].copy() diff --git a/test/results/weibo.py b/test/results/weibo.py index 29303c00..75bec21f 100644 --- a/test/results/weibo.py +++ b/test/results/weibo.py @@ -308,6 +308,13 @@ __tests__ = ( "#class" : weibo.WeiboStatusExtractor, }, +{ + "#url" : "https://weibo.com/7926989456/5160875674043425", + "#comment" : "'replay_hd' video (live replay #8339)", + "#class" : weibo.WeiboStatusExtractor, + "#results" : "ytdl:https://live.video.weibocdn.com/4817f457-c9be-47f7-a5a0-8591fd363cb1_index.m3u8", +}, + { "#url" : "https://weibo.com/7117031969/5208376084532264", "#comment" : "'.m3u8' manifest (live replay #8339)",