Bulk asynchronous downloader for multiple file hosts
Python asynciobunkrcyberdropdownloaderdropboxfilestergofilegoogle-drivemediafiremegamega-nzonedrivepatreonpawchivepinterestpixeldraintransfer-ittwitchtwittervk
fix: increase number of max redirects (#1442)
NTFSvolumebbe4840fd114
diff --git a/cyberdrop_dl/constants.py b/cyberdrop_dl/constants.pyindex 0e9ba8672..74435e570 100644--- a/cyberdrop_dl/constants.py+++ b/cyberdrop_dl/constants.py@@ -21,7 +21,7 @@ LOGS_DATE_FORMAT = "%Y_%m_%d"STARTUP_TIME_STR = STARTUP_TIME.strftime(LOGS_DATETIME_FORMAT)STARTUP_TIME_UTC_STR = STARTUP_TIME_UTC.strftime(LOGS_DATETIME_FORMAT)DNS_RESOLVER: type[AsyncResolver] | type[ThreadedResolver] | None = None-MAX_REDIRECTS: Final[int] = 3+MAX_REDIRECTS: Final[int] = 8# loggingdiff --git a/cyberdrop_dl/utils/utilities.py b/cyberdrop_dl/utils/utilities.pyindex 880d89026..7d8cb6590 100644--- a/cyberdrop_dl/utils/utilities.py+++ b/cyberdrop_dl/utils/utilities.py@@ -4,7 +4,6 @@ import contextlibimport dataclassesimport inspectimport itertools-import jsonimport osimport platformimport re@@ -28,7 +27,7 @@ from typing import (overload,)-from aiohttp import ClientConnectorError+from aiohttp import ClientConnectorError, TooManyRedirectsfrom pydantic import ValidationErrorfrom yarl import URL@@ -44,6 +43,7 @@ from cyberdrop_dl.exceptions import (create_error_msg,get_origin,)+from cyberdrop_dl.utils import jsonfrom cyberdrop_dl.utils.logger import log, log_with_colorif TYPE_CHECKING:@@ -87,6 +87,10 @@ def error_handling_context(self: Crawler | Downloader, item: ScrapeItem | MediaIexcept NotImplementedError as e:error_log_msg = ErrorLogMessage("NotImplemented")exc_info = e+ except TooManyRedirects as e:+ ui_failure = "Too Many Redirects"+ info = json.dumps({"url": e.request_info.real_url, "history": [r.real_url for r in e.history]}, indent=4)+ error_log_msg = ErrorLogMessage(ui_failure, f"{ui_failure}\n{info}")except TimeoutError as e:error_log_msg = ErrorLogMessage("Timeout", repr(e))except ClientConnectorError as e: