FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

fix Future exception never retrieved in create_connection by jensbjorgensen · Pull Request #590 · MagicStack/uvloop · GitHub

fix Future exception never retrieved in create_connection - #590

Open
jensbjorgensen wants to merge 1 commit into
MagicStack:masterfrom
jensbjorgensen:getaddrinfo_future_unretrieved
Open

fix Future exception never retrieved in create_connection#590
jensbjorgensen wants to merge 1 commit into
MagicStack:masterfrom
jensbjorgensen:getaddrinfo_future_unretrieved

Conversation

jensbjorgensen commented Jan 17, 2024
edited by fantix
Loading

Copy link
Copy Markdown
Contributor

I also have observed that when I use asyncio.wait_for(...) around loop.create_connection in the timeout case I end up getting this logged to stdout(err?):

Future exception was never retrieved
future: <Future finished exception=gaierror(-2, 'Name or service not known')>
socket.gaierror: [Errno -2] Name or service not known

The code in this commit fixes this.

fantix left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

This makes sense! Though a unit test is preferred.

Comment thread uvloop/loop.pyx
except asyncio.CancelledError as exc:
for fut in fs:
fut.cancel()
raise exc from None

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

Why dropping the original context here, instead of just raise?

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants


Back | FazBrowse Home | New Git URL