- if peers list is empty, try to fetch from /instances
logger.debug("Marking domain='%s' as successfully handled ...")
instances.set_success(domain)
- else:
- logger.warning("JSON response does not contain 'federated_instances', domain='%s' - trying /instances ...", domain)
+
+ if len(peers) == 0:
+ logger.warning("Fetching instances for domain='%s' from /instances ...", domain)
peers = fetch_instances(domain, origin)
except network.exceptions as exception: