mirror of
https://gitlab.com/chicken-riders/RcGcDb.git
synced 2025-02-22 00:44:10 +00:00
further fix to logging a failure
This commit is contained in:
parent
3d6a2c5ac0
commit
c8080e60b3
|
@ -486,7 +486,7 @@ class Wiki:
|
|||
request = await self.fetch_wiki(amount=amount)
|
||||
self.client.last_request = request
|
||||
except (aiohttp.ServerTimeoutError, asyncio.TimeoutError, WikiServerError, ServerError) as e:
|
||||
self.statistics.update(Log(type=LogType.CONNECTION_ERROR, title=str(e.exception)))
|
||||
self.statistics.update(Log(type=LogType.CONNECTION_ERROR, title=str(str(e.exception) if hasattr(e, "exception") else repr(e))))
|
||||
amount_of_failures = len(self.statistics.last_connection_failures()[0])
|
||||
if amount_of_failures < 2:
|
||||
await asyncio.sleep(5.0)
|
||||
|
|
Loading…
Reference in a new issue