saghul/aiodns

Error when running aiodns

DemGiran opened this issue · 1 comments

future: <Future finished exception=DNSError(1, 'DNS server returned answer with no data')>
aiodns.error.DNSError: (1, 'DNS server returned answer with no data')
Future exception was never retrieved

Code is as follows:

import asyncio
import aiodns
from tqdm import tqdm
import time

from src.utils.load import load

loop = asyncio.get_event_loop()
resolver = aiodns.DNSResolver(loop=loop, nameservers=['8.8.8.8'])

bucket = [....]
f = []
for i in tqdm(bucket):
    f = resolver.query(i+'.com','NS')



result = loop.run_until_complete(f)
print(result)

What domain is this failing for? The code looks ok.