Commit 6d371f48 authored by Rafael Monnerat's avatar Rafael Monnerat

slapos_subscription_request: Adjust assertion to only check errors from started instances

parent 9cdac07c
...@@ -7,15 +7,13 @@ software_instance_list = portal.portal_catalog( ...@@ -7,15 +7,13 @@ software_instance_list = portal.portal_catalog(
# Check if at least one software Instance is Allocated # Check if at least one software Instance is Allocated
for instance in software_instance_list: for instance in software_instance_list:
if instance.getSlapState() != "start_requested": # All partitions should be allocated
# There is something wrong.
return False
computer_partition = instance.getAggregateValue() computer_partition = instance.getAggregateValue()
if computer_partition is None: if computer_partition is None:
return False return False
if instance.getPortalType() == "Software Instance" and \ if instance.getPortalType() == "Software Instance":
if instance.getSlapState() == "start_requested" and \
instance.SoftwareInstance_hasReportedError(): instance.SoftwareInstance_hasReportedError():
return False return False
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment