diff --git a/tendrl/commons/flows/unmanage_cluster/__init__.py b/tendrl/commons/flows/unmanage_cluster/__init__.py index ac131e9d..8c6c3f93 100644 --- a/tendrl/commons/flows/unmanage_cluster/__init__.py +++ b/tendrl/commons/flows/unmanage_cluster/__init__.py @@ -111,7 +111,7 @@ def run(self): time.sleep(5) finished = True job = NS.tendrl.objects.Job(job_id=_job_id).load() - if job.status != "finished": + if job.status not in ['finished', 'failed']: finished = False if finished: break diff --git a/tendrl/commons/objects/cluster/atoms/unmanage_cluster/__init__.py b/tendrl/commons/objects/cluster/atoms/unmanage_cluster/__init__.py index d7e04b4c..2b564205 100644 --- a/tendrl/commons/objects/cluster/atoms/unmanage_cluster/__init__.py +++ b/tendrl/commons/objects/cluster/atoms/unmanage_cluster/__init__.py @@ -112,7 +112,7 @@ def run(self): child_job = NS.tendrl.objects.Job( job_id=child_job_id ).load() - if child_job.status != "finished": + if child_job.status not in ['finished', 'failed']: finished = False break if finished: