def __members_ips(self) -> Iterator[Union[IPv4Network, IPv6Network]]:
        """Resolve each Patroni node ``restapi.connect_address`` to IP networks.

        .. note::
            Only yields object if ``restapi.allowlist_include_members`` setting is enabled.

        :yields: each node ``restapi.connect_address`` resolved to an IP network.
        """
        cluster = self.patroni.dcs.cluster
        if self.__allowlist_include_members and cluster:
            for cluster in [cluster] + list(cluster.workers.values()):
                for member in cluster.members:
                    if member.api_url:
                        try:
                            r = urlparse(member.api_url)
                            if r.hostname:
                                port = r.port or (443 if r.scheme == 'https' else 80)
                                for ip in self.__resolve_ips(r.hostname, port):
                                    yield ip
                        except Exception as e:
                            logger.debug('Failed to parse url %s: %r', member.api_url, e)
Resolve each Patroni node ``restapi.connect_address`` to IP networks.

        .. note::
            Only yields object if ``restapi.allowlist_include_members`` setting is enabled.

        :yields: each node ``restapi.connect_address`` resolved to an IP network.
        
patroni/api.py