Fix: Removed use of private exception classes

removed referenfces to:
- concurrent.futures._base.CancelledError
- asyncio.exceptions.CancelledError
This commit is contained in:
Jylpah committed 2021-01-18 09:23:41 +02:00
1 parent c9745fcf5c
commit 3e27bd995e
2 files changed
+5 -5

No files matched your search

+2 -2
View File
@@ -1408,7 +1408,7 @@ async def main(argv):
bu.error(exception=err)
except UserWarning as err:
bu.warning(str(err))
except asyncio.exceptions.CancelledError:
except asyncio.CancelledError:
pass
except Exception as err:
bu.error(exception=err)
@@ -1798,7 +1798,7 @@ async def stat_worker(queue : asyncio.Queue, workerID: int, args : argparse.Name
bu.error('Unexpected error', err, id=workerID)
queue.task_done()
except (asyncio.CancelledError, concurrent.futures._base.CancelledError):
except (asyncio.CancelledError, concurrent.futures.CancelledError):
bu.debug('Stats queue is empty', id=workerID)
except Exception as err:
bu.error(exception=err, id=workerID)