From 42e948584d6475e0bbcdb6994d0ece3088324b44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mike=20F=C3=A4hrmann?= Date: Mon, 6 Nov 2017 21:52:42 +0100 Subject: [PATCH] fix downloader error handling RequestException being a subclass of OSError caused all exceptions during file downloads to be ignored/re-raised. --- gallery_dl/downloader/common.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/gallery_dl/downloader/common.py b/gallery_dl/downloader/common.py index f94ab273..f96885f3 100644 --- a/gallery_dl/downloader/common.py +++ b/gallery_dl/downloader/common.py @@ -12,6 +12,7 @@ import os import time import logging from .. import config, util +from requests.exceptions import RequestException class DownloaderBase(): @@ -101,9 +102,7 @@ class DownloaderBase(): # download content try: self.receive(file) - except OSError: - raise - except Exception as exc: + except RequestException as exc: msg = exc continue