Merge lp:~julian-edwards/maas/log-celery-exceptions-bug-1184589 into lp:~maas-committers/maas/trunk
Proposed by
Julian Edwards
Status: | Merged |
---|---|
Approved by: | Julian Edwards |
Approved revision: | no longer in the source branch. |
Merged at revision: | 2041 |
Proposed branch: | lp:~julian-edwards/maas/log-celery-exceptions-bug-1184589 |
Merge into: | lp:~maas-committers/maas/trunk |
Diff against target: |
215 lines (+45/-3) 1 file modified
src/provisioningserver/tasks.py (+45/-3) |
To merge this branch: | bzr merge lp:~julian-edwards/maas/log-celery-exceptions-bug-1184589 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Gavin Panella (community) | Approve | ||
Review via email: mp+208723@code.launchpad.net |
Commit message
Make sure failing celery jobs log the exception text
Description of the change
I make no apologies for this hideous hack, but when you're dealing with stupidity, you sometimes have to fight with more stupid.
The comment I added at the top of the code will suffice to explain:
# The tasks catch bare exceptions in an attempt to circumvent Celery's
# bizarre exception handling which prints a stack trace but not the
# error message contained in the exception itself! The message is
# printed and then the exception re-raised so that it marks the task as
# failed - in doing so it logs the stack trace, which is why the code
# does not do a simple logger.
To post a comment you must log in.
Fight Fire With Fire!