Skip to content

bpo-30064: Refactor sock_* asyncio API - #10419

Merged
asvetlov merged 11 commits into
python:masterfrom
asvetlov:issue-30064
Nov 12, 2018
Merged

asvetlov merged 11 commits into
python:masterfrom
asvetlov:issue-30064

Conversation

@asvetlov

@asvetlov asvetlov commented Nov 8, 2018 •

Copy link
Copy Markdown
Contributor

Use add_done_callback() to unsubscribe reader/writer early on calcellation.

https://bugs.python.org/issue30064

@asvetlov asvetlov changed the title [WIP] bpo-30064: Refactor sock_* asyncio API Nov 8, 2018
@asvetlov

asvetlov commented Nov 8, 2018

Copy link
Copy Markdown
Contributor Author

@1st1 please review

@1st1 1st1 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.

This is a nice step forward but we also need to start using socket._io_refs to prevent sockets from being removed during IO.

@asvetlov

Copy link
Copy Markdown
Contributor Author

I'll do it in the following PR.
Wanted to fix one issue at once.

@asvetlov
asvetlov merged commit 7438792 into python:master Nov 12, 2018
@bedevere-bot

Copy link
Copy Markdown

@asvetlov: Please replace # with GH- in the commit message next time. Thanks!

@asvetlov
asvetlov deleted the issue-30064 branch November 12, 2018 17:00
fantix added a commit to fantix/uvloop that referenced this pull request Feb 8, 2021
CPython fixed the same issue in python/cpython#10419. Seems like under
pressure, more write callbacks may happen before _remove_writer() is
called, so we should check for done().

Fixes MagicStack#378
fantix added a commit to fantix/uvloop that referenced this pull request Feb 9, 2021
CPython fixed the same issue in python/cpython#10419. Seems like under
pressure, more write callbacks may happen before _remove_writer() is
called, so we should check for done().

Fixes MagicStack#378
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

4 participants