mirror of
https://github.com/ansible/awx.git
synced 2024-11-01 16:51:11 +03:00
treat canceled jobs in wf the same as failed jobs
* Also fix spelling mistake that caused workflows to be falsely marked successful in the case of a canceled job.
This commit is contained in:
parent
4a6a3b27fa
commit
d6a8ad0b33
@ -90,7 +90,7 @@ class WorkflowDAG(SimpleDAG):
|
||||
continue
|
||||
|
||||
if obj.job:
|
||||
if obj.job.status in ['failed', 'error']:
|
||||
if obj.job.status in ['failed', 'error', 'canceled']:
|
||||
nodes.extend(self.get_dependencies(obj, 'failure_nodes') +
|
||||
self.get_dependencies(obj, 'always_nodes'))
|
||||
elif obj.job.status == 'successful':
|
||||
@ -127,7 +127,7 @@ class WorkflowDAG(SimpleDAG):
|
||||
failed_nodes = []
|
||||
for node in self.nodes:
|
||||
obj = node['node_object']
|
||||
if obj.job and obj.job.status in ['failed', 'anceled', 'error']:
|
||||
if obj.job and obj.job.status in ['failed', 'canceled', 'error']:
|
||||
failed_nodes.append(node)
|
||||
for node in failed_nodes:
|
||||
obj = node['node_object']
|
||||
|
Loading…
Reference in New Issue
Block a user