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.