From 3b325b56ab4c396fc319ee3a61094564539fc171 Mon Sep 17 00:00:00 2001 From: Zhanghao Wu Date: Fri, 13 Dec 2024 17:55:54 +0000 Subject: [PATCH 1/2] Bump catalog schema version --- sky/clouds/service_catalog/constants.py | 2 +- sky/clouds/service_catalog/gcp_catalog.py | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/sky/clouds/service_catalog/constants.py b/sky/clouds/service_catalog/constants.py index 1373fd86a03..a125258ac35 100644 --- a/sky/clouds/service_catalog/constants.py +++ b/sky/clouds/service_catalog/constants.py @@ -1,6 +1,6 @@ """Constants used for service catalog.""" HOSTED_CATALOG_DIR_URL = 'https://raw.githubusercontent.com/skypilot-org/skypilot-catalog/master/catalogs' # pylint: disable=line-too-long -CATALOG_SCHEMA_VERSION = 'v5' +CATALOG_SCHEMA_VERSION = 'v6' CATALOG_DIR = '~/.sky/catalogs' ALL_CLOUDS = ('aws', 'azure', 'gcp', 'ibm', 'lambda', 'scp', 'oci', 'kubernetes', 'runpod', 'vsphere', 'cudo', 'fluidstack', diff --git a/sky/clouds/service_catalog/gcp_catalog.py b/sky/clouds/service_catalog/gcp_catalog.py index 8521f6786cc..a83e00d8196 100644 --- a/sky/clouds/service_catalog/gcp_catalog.py +++ b/sky/clouds/service_catalog/gcp_catalog.py @@ -292,7 +292,9 @@ def get_instance_type_for_accelerator( if acc_name in _ACC_INSTANCE_TYPE_DICTS: df = _df[_df['InstanceType'].notna()] - instance_types = _ACC_INSTANCE_TYPE_DICTS[acc_name][acc_count] + instance_types = _ACC_INSTANCE_TYPE_DICTS[acc_name].get(acc_count, None) + if instance_types is None: + return None, [] df = df[df['InstanceType'].isin(instance_types)] # Check the cpus and memory specified by the user. From eefe4684cc32d86d475195ea7cc1d06e7b114188 Mon Sep 17 00:00:00 2001 From: Zhanghao Wu Date: Fri, 13 Dec 2024 18:40:47 +0000 Subject: [PATCH 2/2] trigger CI