Message48140
Logged In: YES
user_id=488897
This looks like a good idea to me. It will help to clean up
the "get" method in Queue.py, which now has:
while self._empty():
remaining = endtime - _time()
if remaining <= 0.0:
raise Empty
self.not_empty.wait(remaining)
Here, self.not_empty is an object of the class
threading.Condition. It seems odd that first we wait for
self.not_empty.wait to return, and then have to check
self._empty(), even though self.not_empty.wait could have
told us directly if it was notified or it timed out.
I'll write a message to python-dev in support of this patch
(I'm a mere patch reviewer, not an official Python developer). |
|
| Date |
User |
Action |
Args |
| 2007-08-23 15:42:34 | admin | link | issue1175933 messages |
| 2007-08-23 15:42:34 | admin | create | |
|