We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Calling failed() on a taskset returns True if some tasks are still pending (it treats pending tasks as failed tasks right now in other words).
Below patch:
--- a/result.py +++ b/result.py @@ -85,6 +85,14 @@ """ return self.backend.is_successful(self.task_id) + + def failed(self): + """Returns ``True`` if the task failed + + :rtype: bool + + """ + return self.backend.get_status(self.task_id)==states.FAILURE def __str__(self): """``str(self)`` -> ``self.task_id``""" @@ -223,7 +231,7 @@ (i.e., raised an exception) """ - return any((not subtask.successful() + return any((subtask.failed() for subtask in self.itersubtasks())) def waiting(self):
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Calling failed() on a taskset returns True if some tasks are still pending (it treats pending tasks as failed tasks right now in other words).
Below patch:
The text was updated successfully, but these errors were encountered: