From 3b25201ee837845fb338c14a4577dcc22f2cc225 Mon Sep 17 00:00:00 2001 From: Konstantin Beste Date: Wed, 1 Feb 2023 09:14:58 +0100 Subject: [PATCH] Ensure selection of fallback instance type if necessary --- igvm/vm.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/igvm/vm.py b/igvm/vm.py index f7d3764a..ece08d1c 100644 --- a/igvm/vm.py +++ b/igvm/vm.py @@ -659,9 +659,9 @@ def aws_build(self, """ vm_types_overview = self.aws_get_instances_overview() - if vm_types_overview: - vm_types = self.aws_get_fitting_vm_types(vm_types_overview) - else: + vm_types = self.aws_get_fitting_vm_types(vm_types_overview) + + if not vm_types: vm_types = [AWS_FALLBACK_INSTANCE_TYPE] root_device = list(