async def _query_dns(self, dns_address):
    try:
        if (self.default_port is None):
            self.log.error('Network id not supported in NETWORK_ID_DEFAULT_PORTS neither in config. Skipping DNS query.')
            return
        if (self.resolver is None):
            self.log.warn('Skipping DNS query: asyncresolver not initialized.')
            return
        for rdtype in ['A', 'AAAA']:
            peers: List[TimestampedPeerInfo] = []
            result = (await self.resolver.resolve(qname=dns_address, rdtype=rdtype, lifetime=30))
            for ip in result:
                peers.append(TimestampedPeerInfo(ip.to_text(), self.default_port, 0))
            self.log.info(f'Received {len(peers)} peers from DNS seeder, using rdtype = {rdtype}.')
            if (len(peers) > 0):
                (await self._respond_peers_common(full_node_protocol.RespondPeers(peers), None, False))
    except Exception as e:
        self.log.warn(f'querying DNS introducer failed: {e}')
async def _query_dns(self, dns_address):
    try:
        if (self.default_port is None):
            self.log.error('Network id not supported in NETWORK_ID_DEFAULT_PORTS neither in config. Skipping DNS query.')
            return
        if (self.resolver is None):
            self.log.warn('Skipping DNS query: asyncresolver not initialized.')
            return
        for rdtype in ['A', 'AAAA']:
            peers: List[TimestampedPeerInfo] = []
            result = (await self.resolver.resolve(qname=dns_address, rdtype=rdtype, lifetime=30))
            for ip in result:
                peers.append(TimestampedPeerInfo(ip.to_text(), self.default_port, 0))
            self.log.info(f'Received {len(peers)} peers from DNS seeder, using rdtype = {rdtype}.')
            if (len(peers) > 0):
                (await self._respond_peers_common(full_node_protocol.RespondPeers(peers), None, False))
    except Exception as e:
        self.log.warn(f'querying DNS introducer failed: {e}')