-
-
Notifications
You must be signed in to change notification settings - Fork 30.8k
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
bpo-33792: Add selector and proactor windows policies #7487
Conversation
There's no adequate documentation on asyncio policies that lists all of them. I'll try to work on that in a separate PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
The new classes should be documented around https://docs.python.org/dev/library/asyncio-eventloops.html#event-loop-policies-and-the-default-policy
But it can be done later, right now event DefaultEventLoopPolicy is not properly documented... It's just mentionned one.
Please backport the change to 3.7 :-)
Oh wow, AppVeyor failed with a weird error!?
|
Ok, works for me. |
Not sure if it's related; restarted the CI. |
@ned-deily @vstinner The CI crash on Windows buildbots is real and I have no idea what's going on. It seems to be completely unrelated to asyncio. Here's a screenshot from my Win VM: If we comment out class WindowsProactorEventLoopPolicy(events.BaseDefaultEventLoopPolicy):
_loop_factory = ProactorEventLoop then everything works fine. The problem is that |
Would it help to pull in some of the Windows experts? (I’ll be off line for the next few hours.) |
Victor was also able to reproduce the bug. But the CI is green now... The crash is specific to 32bit builds and seems to be originating from class Handle:
"""Object returned by callback registration methods."""
__slots__ = ('_callback', '_args', '_cancelled', '_loop',
'_source_traceback', '_repr', '__weakref__',
'_context')
def __init__(self, callback, args, loop, context=None):
if context is None:
context = contextvars.copy_current() # << this line If we add a simple
|
The crash is https://bugs.python.org/issue33803 and it's unrelated to this change. It's just that the change made the bug more likely. |
Thanks @1st1 for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7. |
(cherry picked from commit 8f40429) Co-authored-by: Yury Selivanov <yury@magic.io>
GH-7508 is a backport of this pull request to the 3.7 branch. |
https://bugs.python.org/issue33792