Uninstall S3 and CloudWatch loggers when task is revoked
Revoked task signals are executed twice by Celery, as such a workaround
is needed to ignore the second execution (by checking kwargs['signum']
).
Note: breaks Python 2 support.
Edited by Elouan Martinet