Skip to content

Commit 0295820

Browse files
committed
simplify checking cluster state
1 parent 6f499c7 commit 0295820

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

assistedInstaller.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -140,10 +140,7 @@ def start_until_success(self, cluster_name: str) -> None:
140140
except Exception:
141141
pass
142142

143-
cluster = list(filter(lambda e: e["name"] == cluster_name, self.list_clusters()))
144-
status = cluster[0]["status"]
145-
146-
if status == "installing":
143+
if self.cluster_state(cluster_name) == "installing":
147144
logger.info(f"Cluster {cluster_name} is in state installing")
148145
break
149146
time.sleep(10)

0 commit comments

Comments
 (0)