-
Notifications
You must be signed in to change notification settings - Fork 39
Trigger error handler on DeadlineExceededError #175
Trigger error handler on DeadlineExceededError #175
Conversation
…t inherit from BaseException (such as google.appengine.runtime.DeadlineExceededError) instead of Exception
+1 |
1 similar comment
+1 |
@@ -67,7 +67,7 @@ def run_job(): | |||
except AbortAndRestart as restart: | |||
logging.info('Async job was aborted and restarted: %r', restart) | |||
raise | |||
except Exception as e: | |||
except BaseException as e: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, so Google is inheriting from BaseException
instead of Exception
?
That's not cool. https://docs.python.org/2/library/exceptions.html#exceptions.BaseException
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should someone follow up with Google?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Was this followed up on and do we wish to investigate?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The docs show that google.appengine.runtime.DeadlineExceededError
inherits from BaseException:
https://code.google.com/p/googleappengine/source/browse/trunk/python/google/appengine/runtime/__init__.py
Also of note is the try/except block.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interesting
+1 |
…ling Trigger error handler on DeadlineExceededError
R: @beaulyddon-wf @macleodbroad-wf @erikpetersen-wf
O: @jasonaguilon-wf @rosshendrickson-wf @tylertreat-wf
We will now trigger the failure handler from any exception that inherits from BaseException (such as google.appengine.runtime.DeadlineExceededError) instead of Exception.