Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR removes the
asyncio
andnull
entry points, and adjusts the tests accordingly. We're not removing theAsyncioEventLoop
or its uses in testing: we're only removing the ability to doexport ETS_TOOLKIT=asyncio
and pick up anAsyncioEventLoop
as a result. That functionality was questionable at best, is causing deprecation warnings in Python 3.10, and will become broken in future Python versions with the current code.Rationale:
asyncio.get_event_loop
function. It's possible to set a current event loop usingset_event_loop
, but that event loop isn't then picked up byasyncio.run
:asyncio.run
instead creates a brand new event loop. This means that the (relatively common) pattern of placing tasks on the event loop's task queue before starting the event loop becomes problematic with asyncio. See related discussion in https://bugs.python.org/issue39529The trigger for this PR was that our uses of
get_event_loop
are now causing warnings on Python 3.10, so we need to find a way to get rid of them. That change will happen in a separate PR from this one, but this one was necessary to enable getting rid ofget_event_loop
.Related: #491