All processing exceptions are now logged

All processing exceptions should now be logged, the MediaEntry marked as
failed, the exception re-raised.
This commit is contained in:
Joar Wandborg 2012-08-01 01:16:00 +02:00
parent 65a2eb6694
commit 2891b2c6d0

View File

@ -71,6 +71,14 @@ class ProcessMedia(Task):
mark_entry_failed(entry._id, exc)
except Exception as exc:
_log.error('An unhandled exception was raised while'
+ ' processing {0}'.format(
entry))
mark_entry_failed(entry._id, exc)
raise
def on_failure(self, exc, task_id, args, kwargs, einfo):
"""
If the processing failed we should mark that in the database.