Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

deprecate the asyncio child watchers system #94597

Closed
Assignees
gvanrossumkumaraditya303
Labels
3.12only security fixesstdlibPython modules in the Lib dirtopic-asyncio
@graingert

Description

@graingert

Deprecate the child watchers system and the policy system in favour of
asyncio.Runner(loop_factory=asyncio.ProactorEventLoop/asyncio.SelectorEventLoop/uvloop.new_event_loop)
that would be deprecating:

asyncio.get_event_loop() # already deprecated unless the loop is running asyncio.set_event_loop()  # asyncio.set_event_loop(None) should probably be exemptasyncio.get_event_loop_policy()asyncio.set_event_loop_policy()  # asyncio.set_event_loop_policy(None) should probably be exemptasyncio.set_child_watcher()asyncio.get_child_watcher()  # `_make_subprocess_transport` will instead attempt to use os.open_pidfd and fallback to starting a thread

I'd also like to introduce a new API:asyncio.EventLoop implemented as:

if sys.platform == "win32":    EventLoop = ProactorEventLoopelse:    EventLoop = SelectorEventLoop

asyncio.new_event_loop() will issue a DeprecationWarning if the current policy is not the default policy, and then in 3 releases become an alias ofasyncio.EventLoop

Originally posted by@graingert in#93896 (comment)

Metadata

Metadata

Labels

3.12only security fixesstdlibPython modules in the Lib dirtopic-asyncio

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions


    [8]ページ先頭

    ©2009-2025 Movatter.jp