fix(aurora): catch exceptions thrown inside of the expiry handler instead of just stopping the task
This commit is contained in:
parent
d4fe97f247
commit
b91946abeb
1 changed files with 3 additions and 0 deletions
|
@ -1133,6 +1133,9 @@ class Aurora(commands.Cog):
|
||||||
except NotImplementedError:
|
except NotImplementedError:
|
||||||
logger.warning("Expiry handler not implemented for expirable moderation type %s", moderation.type.key)
|
logger.warning("Expiry handler not implemented for expirable moderation type %s", moderation.type.key)
|
||||||
continue
|
continue
|
||||||
|
except Exception as e: # pylint: disable=broad-except
|
||||||
|
logger.exception("Expiry handler failed for moderation %s with the type %s", moderation.id, moderation.type.key, exc_info=e)
|
||||||
|
continue
|
||||||
match moderation.type.key:
|
match moderation.type.key:
|
||||||
case "tempban":
|
case "tempban":
|
||||||
unban_num += num
|
unban_num += num
|
||||||
|
|
Loading…
Reference in a new issue