From 1bd38adbf6637c7eeffc8cf96e8c409f2a73d06c Mon Sep 17 00:00:00 2001 From: biggestsonicfan <9744201+biggestsonicfan@users.noreply.github.com> Date: Tue, 22 Oct 2024 13:45:04 -0700 Subject: [PATCH 1/3] [ie/youtube] Add membership data to comments --- yt_dlp/extractor/youtube.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/yt_dlp/extractor/youtube.py b/yt_dlp/extractor/youtube.py index 5148e82619..65fa53b067 100644 --- a/yt_dlp/extractor/youtube.py +++ b/yt_dlp/extractor/youtube.py @@ -3634,6 +3634,8 @@ class YoutubeIE(YoutubeBaseInfoExtractor): 'author_thumbnail': ('author', 'avatarThumbnailUrl', {url_or_none}), 'author_is_uploader': ('author', 'isCreator', {bool}), 'author_is_verified': ('author', 'isVerified', {bool}), + 'author_is_member': ('author', 'sponsorBadgeA11y', {str}), + 'author_member_badge': ('author', 'sponsorBadgeUrl', {url_or_none}), 'author_url': ('author', 'channelCommand', 'innertubeCommand', ( ('browseEndpoint', 'canonicalBaseUrl'), ('commandMetadata', 'webCommandMetadata', 'url'), ), {lambda x: urljoin('https://www.youtube.com', x)}), From 444d959d814035163df7ccd13c6b6f337bd8ad42 Mon Sep 17 00:00:00 2001 From: biggestsonicfan <9744201+biggestsonicfan@users.noreply.github.com> Date: Tue, 22 Oct 2024 14:00:02 -0700 Subject: [PATCH 2/3] Remove trailing whitespace --- yt_dlp/extractor/youtube.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yt_dlp/extractor/youtube.py b/yt_dlp/extractor/youtube.py index 65fa53b067..8e812c73c0 100644 --- a/yt_dlp/extractor/youtube.py +++ b/yt_dlp/extractor/youtube.py @@ -3635,7 +3635,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor): 'author_is_uploader': ('author', 'isCreator', {bool}), 'author_is_verified': ('author', 'isVerified', {bool}), 'author_is_member': ('author', 'sponsorBadgeA11y', {str}), - 'author_member_badge': ('author', 'sponsorBadgeUrl', {url_or_none}), + 'author_member_badge': ('author', 'sponsorBadgeUrl', {url_or_none}), 'author_url': ('author', 'channelCommand', 'innertubeCommand', ( ('browseEndpoint', 'canonicalBaseUrl'), ('commandMetadata', 'webCommandMetadata', 'url'), ), {lambda x: urljoin('https://www.youtube.com', x)}), From 5874c459b37e79fb26fe80c88020479494329c60 Mon Sep 17 00:00:00 2001 From: biggestsonicfan <9744201+biggestsonicfan@users.noreply.github.com> Date: Tue, 22 Oct 2024 14:02:08 -0700 Subject: [PATCH 3/3] Twice, twice even --- yt_dlp/extractor/youtube.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/yt_dlp/extractor/youtube.py b/yt_dlp/extractor/youtube.py index 8e812c73c0..d2e1a533a5 100644 --- a/yt_dlp/extractor/youtube.py +++ b/yt_dlp/extractor/youtube.py @@ -3635,7 +3635,7 @@ class YoutubeIE(YoutubeBaseInfoExtractor): 'author_is_uploader': ('author', 'isCreator', {bool}), 'author_is_verified': ('author', 'isVerified', {bool}), 'author_is_member': ('author', 'sponsorBadgeA11y', {str}), - 'author_member_badge': ('author', 'sponsorBadgeUrl', {url_or_none}), + 'author_member_badge': ('author', 'sponsorBadgeUrl', {url_or_none}), 'author_url': ('author', 'channelCommand', 'innertubeCommand', ( ('browseEndpoint', 'canonicalBaseUrl'), ('commandMetadata', 'webCommandMetadata', 'url'), ), {lambda x: urljoin('https://www.youtube.com', x)}),