mirror of
				https://github.com/yt-dlp/yt-dlp.git
				synced 2025-10-30 22:25:19 +00:00 
			
		
		
		
	Suppress help for all deprecated options and print warning when used
This commit is contained in:
		| @@ -328,11 +328,21 @@ class YoutubeDL(object): | ||||
|         self.params.update(params) | ||||
|         self.cache = Cache(self) | ||||
|  | ||||
|         if self.params.get('cn_verification_proxy') is not None: | ||||
|             self.report_warning('--cn-verification-proxy is deprecated. Use --geo-verification-proxy instead.') | ||||
|         def check_deprecated(param, option, suggestion): | ||||
|             if self.params.get(param) is not None: | ||||
|                 self.report_warning( | ||||
|                     '%s is deprecated. Use %s instead.' % (option, suggestion)) | ||||
|                 return True | ||||
|             return False | ||||
|  | ||||
|         if check_deprecated('cn_verification_proxy', '--cn-verification-proxy', '--geo-verification-proxy'): | ||||
|             if self.params.get('geo_verification_proxy') is None: | ||||
|                 self.params['geo_verification_proxy'] = self.params['cn_verification_proxy'] | ||||
|  | ||||
|         check_deprecated('autonumber_size', '--autonumber-size', 'output template with %(autonumber)0Nd, where N in the number of digits') | ||||
|         check_deprecated('autonumber', '--auto-number', '-o "%(autonumber)s-%(title)s.%(ext)s"') | ||||
|         check_deprecated('usetitle', '--title', '-o "%(title)s-%(id)s.%(ext)s"') | ||||
|  | ||||
|         if params.get('bidi_workaround', False): | ||||
|             try: | ||||
|                 import pty | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Sergey M․
					Sergey M․