Repository navigation
asyncio module state should be locked with mutexes in free-threaded builds #121621
Copy link
Copy link
Closed
Labels
Description
Activity
- addedtype-featureA feature request or enhancementA feature request or enhancement
on Jul 11, 2024 I think we also want to make
enter_task,leave_task, andswap_current_taskbehave atomically. For example,enter_taskmakes two dict API calls that individually lock the dictionary, but the combined operation isn't atomic.I can think of two strategies for this:
- Try to replace multiple API calls with a single call. For example, I think
enter_taskmay be able to usePyDict_SetDefaultRefandleave_taskmay be able to use_PyDict_DelItemIfwith some modifications. - Use a critical section to lock the dict and use the "lock held" variants.
- Try to replace multiple API calls with a single call. For example, I think
- added a commit that references this issue
on Jul 17, 2024 - added 4 commits that reference this issue
on Jul 19, 2024 Fixed.
Feature or enhancement
Proposal:
Please see issue title.
Has this already been discussed elsewhere?
No response given
Links to previous discussion of this feature:
No response
Linked PRs