Skip to content

Commit 0ac47fc

Browse files
authored
Fix CLI exiting while master starting (#2757)
1 parent 856a442 commit 0ac47fc

File tree

1 file changed

+1
-6
lines changed
  • src/dstack/_internal/cli/services/configurators

1 file changed

+1
-6
lines changed

src/dstack/_internal/cli/services/configurators/run.py

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -166,12 +166,7 @@ def apply_configuration(
166166
# We can attach to run multiple times if it goes from running to pending (retried).
167167
while True:
168168
with MultiItemStatus(f"Launching [code]{run.name}[/]...", console=console) as live:
169-
while run.status in (
170-
RunStatus.SUBMITTED,
171-
RunStatus.PENDING,
172-
RunStatus.PROVISIONING,
173-
RunStatus.TERMINATING,
174-
):
169+
while not _is_ready_to_attach(run):
175170
table = get_runs_table([run])
176171
live.update(table)
177172
time.sleep(5)

0 commit comments

Comments
 (0)