@classmethod
def from_exception(cls, exception):
    """Creates a failure object from a exception instance."""
    exc_info = type(exception), exception, getattr(exception,
        '__traceback__', None)
    return cls(exc_info=exc_info)
