The autopkgtest policy basically turns adt_ppas into a list, so let's handle the case where the autopkgtest policy runs first.

This commit is contained in:
Łukasz 'sil2100' Zemczak 2023-02-13 14:40:38 +01:00
parent be55223a67
commit b2b1da42fa

View File

@ -69,7 +69,9 @@ class CloudPolicy(BasePolicy):
self.failure_emails = getattr(self.options, "cloud_failure_emails", self.DEFAULT_EMAILS)
self.error_emails = getattr(self.options, "cloud_error_emails", self.DEFAULT_EMAILS)
adt_ppas = getattr(self.options, "adt_ppas", "").split()
adt_ppas = getattr(self.options, "adt_ppas", "")
if not isinstance(adt_ppas, list):
adt_ppas = adt_ppas.split()
ppas = self._parse_ppas(adt_ppas)
if len(ppas) == 0: