Skip to content
New issue

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

fix: add more status check in wait until ready #4428

Merged
merged 1 commit into from
Jan 19, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions src/bentoml/_internal/cloud/deployment.py
Original file line number Diff line number Diff line change
Expand Up @@ -488,7 +488,22 @@ def wait_until_ready(
)
spinner.spinner_progress.stop_task(spinner_task_id)
return
if status.status in [
DeploymentStatus.Failed.value,
DeploymentStatus.ImageBuildFailed.value,
DeploymentStatus.Terminated.value,
DeploymentStatus.Terminating.value,
DeploymentStatus.Unhealthy.value,
]:
spinner.spinner_progress.update(
spinner_task_id,
action=f'[bold red]Deployment "{self.name}" is not ready. Current status: "{status.status}".[/bold red]',
)
spinner.spinner_progress.stop_task(spinner_task_id)
return

time.sleep(check_interval)

spinner.spinner_progress.update(
spinner_task_id,
action=f'[bold red]Time out waiting for Deployment "{self.name}" ready.[/bold red]',
Expand Down