]> jfr.im git - yt-dlp.git/commitdiff
Make `title` completely non-fatal
authorpukkandan <redacted>
Mon, 6 Feb 2023 19:47:11 +0000 (01:17 +0530)
committerpukkandan <redacted>
Mon, 6 Feb 2023 19:48:04 +0000 (01:18 +0530)
Ref: https://github.com/yt-dlp/yt-dlp/pull/6158#discussion_r1096984349

yt_dlp/YoutubeDL.py

index fd280726f9b66bbf92df344828a0568f51138aa8..e092aed674d03466a3db9d905a42efbd96e35c73 100644 (file)
@@ -2411,11 +2411,7 @@ def check_thumbnails(thumbnails):
     def _fill_common_fields(self, info_dict, final=True):
         # TODO: move sanitization here
         if final:
-            title = info_dict.get('title', NO_DEFAULT)
-            if title is NO_DEFAULT:
-                raise ExtractorError('Missing "title" field in extractor result',
-                                     video_id=info_dict['id'], ie=info_dict['extractor'])
-            info_dict['fulltitle'] = title
+            title = info_dict['fulltitle'] = info_dict.get('title')
             if not title:
                 if title == '':
                     self.write_debug('Extractor gave empty title. Creating a generic title')