Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make Failure.mess robust when no message
Previously, if the exception lacked a `message` method, then it would blow up with a method not found error when trying to display the Failure. Since this can happen via DESTROY for an unhandled Failure, this could happen at pretty much any point in the program. Make it robust in the face of a missing `message` method in the exception. Resolves #2623.
- Loading branch information
d499bd4
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.
OOC, why is it
(try self.exception.?message)
instead of justself.exception.?message
?d499bd4
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.
In case there is a message but it crashes; I followed the same thing that happens in
Exception.gist
.d499bd4
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.
Oddly enough I was looking at that same line of code yesterday :-)
d499bd4
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.
Heh, now that you mention it I even wrote some of those
try
lines inException.gist
. If only I'd remembered that before asking the question...