mirror of
				https://github.com/yt-dlp/yt-dlp.git
				synced 2025-10-31 14:45:14 +00:00 
			
		
		
		
	[cleanup] Minor fixes (See desc)
* [youtube] Fix `--youtube-skip-dash-manifest` * [build] Use `$()` in `Makefile`. Closes #3684 * Fix bug in385ffb467b* Fix bug in43d7f5a5d0* [cleanup] Remove unnecessary `utf-8` from `str.encode`/`bytes.decode` * [utils] LazyList: Expose unnecessarily "protected" attributes and other minor cleanup
This commit is contained in:
		| @@ -47,7 +47,7 @@ class YoutubeLiveChatFD(FragmentFD): | ||||
|                     replay_chat_item_action = action['replayChatItemAction'] | ||||
|                     offset = int(replay_chat_item_action['videoOffsetTimeMsec']) | ||||
|                 processed_fragment.extend( | ||||
|                     json.dumps(action, ensure_ascii=False).encode('utf-8') + b'\n') | ||||
|                     json.dumps(action, ensure_ascii=False).encode() + b'\n') | ||||
|             if offset is not None: | ||||
|                 continuation = try_get( | ||||
|                     live_chat_continuation, | ||||
| @@ -89,7 +89,7 @@ class YoutubeLiveChatFD(FragmentFD): | ||||
|                     'isLive': True, | ||||
|                 } | ||||
|                 processed_fragment.extend( | ||||
|                     json.dumps(pseudo_action, ensure_ascii=False).encode('utf-8') + b'\n') | ||||
|                     json.dumps(pseudo_action, ensure_ascii=False).encode() + b'\n') | ||||
|             continuation_data_getters = [ | ||||
|                 lambda x: x['continuations'][0]['invalidationContinuationData'], | ||||
|                 lambda x: x['continuations'][0]['timedContinuationData'], | ||||
| @@ -183,7 +183,7 @@ class YoutubeLiveChatFD(FragmentFD): | ||||
|                     request_data['context']['clickTracking'] = {'clickTrackingParams': click_tracking_params} | ||||
|                 headers = ie.generate_api_headers(ytcfg=ytcfg, visitor_data=visitor_data) | ||||
|                 headers.update({'content-type': 'application/json'}) | ||||
|                 fragment_request_data = json.dumps(request_data, ensure_ascii=False).encode('utf-8') + b'\n' | ||||
|                 fragment_request_data = json.dumps(request_data, ensure_ascii=False).encode() + b'\n' | ||||
|                 success, continuation_id, offset, click_tracking_params = download_and_parse_fragment( | ||||
|                     url, frag_index, fragment_request_data, headers) | ||||
|             else: | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 pukkandan
					pukkandan