mirror of
				https://github.com/yt-dlp/yt-dlp.git
				synced 2025-10-31 06:35:12 +00:00 
			
		
		
		
	[YoutubeDL] check annotations availabilty(closes #18582)
This commit is contained in:
		| @@ -1783,6 +1783,8 @@ class YoutubeDL(object): | |||||||
|             annofn = replace_extension(filename, 'annotations.xml', info_dict.get('ext')) |             annofn = replace_extension(filename, 'annotations.xml', info_dict.get('ext')) | ||||||
|             if self.params.get('nooverwrites', False) and os.path.exists(encodeFilename(annofn)): |             if self.params.get('nooverwrites', False) and os.path.exists(encodeFilename(annofn)): | ||||||
|                 self.to_screen('[info] Video annotations are already present') |                 self.to_screen('[info] Video annotations are already present') | ||||||
|  |             elif not info_dict.get('annotations'): | ||||||
|  |                 self.report_warning('There are no annotations to write.') | ||||||
|             else: |             else: | ||||||
|                 try: |                 try: | ||||||
|                     self.to_screen('[info] Writing video annotations to: ' + annofn) |                     self.to_screen('[info] Writing video annotations to: ' + annofn) | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Remita Amine
					Remita Amine