This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author asvetlov
Recipients asvetlov, hyzyla, yselivanov
Date 2021-12-06.16:57:06
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1638809826.96.0.955832539408.issue45997@roundup.psfhosted.org>
In-reply-to
Content
Or, maybe, there is a way to do everything without changing public API.

The idea is: _wake_up_next can create a future which is set by *waked up task* on its acquiring. acquire method should wait for this future first before entering in `while self._value < 0:` loop.

If the future is cancelled, `_wake_up_next` should be called again and waiting for the next future acquiring to be performed.

If there is no *acquire waiting* future exists -- do everything as usual.

All other lock objects should be modified also.
History
Date User Action Args
2021-12-06 16:57:06asvetlovsetrecipients: + asvetlov, yselivanov, hyzyla
2021-12-06 16:57:06asvetlovsetmessageid: <1638809826.96.0.955832539408.issue45997@roundup.psfhosted.org>
2021-12-06 16:57:06asvetlovlinkissue45997 messages
2021-12-06 16:57:06asvetlovcreate