From 2d52e78d851190fed56592ee95f01c626e461fbc Mon Sep 17 00:00:00 2001 From: JustAnotherArchivist Date: Wed, 24 Apr 2019 23:02:42 +0000 Subject: [PATCH] Fix reference to aiohttp.CientError --- qwarc/utils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/qwarc/utils.py b/qwarc/utils.py index fb062a7..298970d 100644 --- a/qwarc/utils.py +++ b/qwarc/utils.py @@ -1,4 +1,5 @@ from qwarc.const import * +import aiohttp import asyncio import os @@ -146,7 +147,7 @@ async def handle_response_default(url, attempt, response, exc): return ACTION_RETRY, True if response.status in (401, 403, 404, 405, 410): return ACTION_IGNORE, True - if exc is not None and isinstance(exc, (asyncio.TimeoutError, _aiohttp.ClientError)): + if exc is not None and isinstance(exc, (asyncio.TimeoutError, aiohttp.ClientError)): await asyncio.sleep(5) return ACTION_RETRY, True if response.status in (200, 204, 206, 304):