mirror of
				https://github.com/yt-dlp/yt-dlp.git
				synced 2025-10-31 14:45:14 +00:00 
			
		
		
		
	[extractor] Allow http_headers to be specified for thumbnails
				
					
				
			This commit is contained in:
		| @@ -3860,7 +3860,7 @@ class YoutubeDL(object): | ||||
|             else: | ||||
|                 self.to_screen(f'[info] Downloading {thumb_display_id} ...') | ||||
|                 try: | ||||
|                     uf = self.urlopen(t['url']) | ||||
|                     uf = self.urlopen(sanitized_Request(t['url'], headers=t.get('http_headers', {}))) | ||||
|                     self.to_screen(f'[info] Writing {thumb_display_id} to: {thumb_filename}') | ||||
|                     with open(encodeFilename(thumb_filename), 'wb') as thumbf: | ||||
|                         shutil.copyfileobj(uf, thumbf) | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 pukkandan
					pukkandan