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

[Azure] Fix empty string for status query #3015

Merged
merged 2 commits into from
Jan 25, 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
4 changes: 4 additions & 0 deletions sky/clouds/azure.py
Original file line number Diff line number Diff line change
Expand Up @@ -651,6 +651,10 @@ def query_status(cls, name: str, tag_filters: Dict[str, str],
assert stdout.strip(), f'No status returned for {name!r}'

original_statuses_list = json.loads(stdout.strip())
if not original_statuses_list:
cblmemo marked this conversation as resolved.
Show resolved Hide resolved
# No nodes found. The original_statuses_list will be empty string.
# Return empty list.
return []
if not isinstance(original_statuses_list, list):
original_statuses_list = [original_statuses_list]
statuses = []
Expand Down