-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
custom DNS server with aiodns got err: ot Future <Future pending> attached to a different loop #3573
Comments
GitMate.io thinks the contributor most likely able to help you is @asvetlov. Possibly related issues are #2168 (server often throw "concurrent.futures._base.CancelledError"), and #3143 (Problems using custom DNS with aiohttp). |
I'm sorry. |
Thanks for your update. Before I submitting the bug, I checked aiodns with the code: import asyncio
import aiodns
loop = asyncio.new_event_loop()
loop.close
resolver = aiodns.DNSResolver(loop=loop, nameservers=['114.114.114.114'])
f = resolver.query('www.google.com', 'A')
result = loop.run_until_complete(f)
print(result) and it works. |
Looks like you have a memory corruption error. |
@asvetlov , |
I took a quick look. With a small change it works fine:
Loos like somehow loops gets mixed. In |
Aha, I see. It is a programming error and aiohttp misusage. @saghul thanks for investigation. |
Long story short
aiohttp doesn't work with custom DNS Server.
The DNS Resolver should works without error
With the error:
Steps to reproduce
Run the code:
Your environment
Here are the packages I'm using:
Package Version
aiohttp 3.5.4
aiodns 2.0.0b0
async-timeout 3.0.1
attrs 18.2.0
cffi 1.11.5
chardet 3.0.4
idna 2.8
multidict 4.5.2
pip 18.1
pycares 3.0.0b2
pycparser 2.19
setuptools 40.6.3
typing 3.6.6
wheel 0.32.3
yarl 1.3.0
The text was updated successfully, but these errors were encountered: