1
0
mirror of https://github.com/yt-dlp/yt-dlp.git synced 2025-05-07 14:30:09 +00:00

[ie/reddit] Support --ignore-no-formats-error (#12993)

Closes #12987
Authored by: bashonly
This commit is contained in:
bashonly 2025-04-28 17:31:34 -05:00 committed by GitHub
parent a3e91df30a
commit 28f04e8a5e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -388,7 +388,8 @@ class RedditIE(InfoExtractor):
})
if entries:
return self.playlist_result(entries, video_id, **info)
raise ExtractorError('No media found', expected=True)
self.raise_no_formats('No media found', expected=True, video_id=video_id)
return {**info, 'id': video_id}
# Check if media is hosted on reddit:
reddit_video = traverse_obj(data, (