class Async::Task
def failed!(exception = false, propagate = true)
def failed!(exception = false, propagate = true) @result = exception @status = :failed if exception if propagate raise exception elsif @finished.nil? # If no one has called wait, we log this as a warning: Console.logger.warn(self, "Task may have ended with unhandled exception.", exception) else Console.logger.debug(self, exception) end end end