diff --git a/yt_dlp/networking/_websockets.py b/yt_dlp/networking/_websockets.py index d808213da4..8b8dd180e4 100644 --- a/yt_dlp/networking/_websockets.py +++ b/yt_dlp/networking/_websockets.py @@ -47,6 +47,12 @@ if urllib3_version and urllib3_version >= (1, 26, 17): urllib3_supported = True + +# Disable apply_mask C implementation +import websockets.frames +from websockets.utils import apply_mask +websockets.frames.apply_mask = apply_mask + import websockets.sync.client from websockets.uri import parse_uri