From 17bddf3e95873230d85723e306641b2b3fcb87a9 Mon Sep 17 00:00:00 2001 From: pukkandan Date: Mon, 18 Oct 2021 16:10:27 +0530 Subject: [PATCH] Reduce default `--socket-timeout` --- test/parameters.json | 1 - yt_dlp/YoutubeDL.py | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/test/parameters.json b/test/parameters.json index 9ca7d2ca9..8544f1ab2 100644 --- a/test/parameters.json +++ b/test/parameters.json @@ -44,6 +44,5 @@ "writesubtitles": false, "allsubtitles": false, "listsubtitles": false, - "socket_timeout": 20, "fixup": "never" } diff --git a/yt_dlp/YoutubeDL.py b/yt_dlp/YoutubeDL.py index cf97ff21c..50cb11d49 100644 --- a/yt_dlp/YoutubeDL.py +++ b/yt_dlp/YoutubeDL.py @@ -3347,7 +3347,7 @@ def python_implementation(): def _setup_opener(self): timeout_val = self.params.get('socket_timeout') - self._socket_timeout = 600 if timeout_val is None else float(timeout_val) + self._socket_timeout = 20 if timeout_val is None else float(timeout_val) opts_cookiesfrombrowser = self.params.get('cookiesfrombrowser') opts_cookiefile = self.params.get('cookiefile')