coros: reenable sleep() in Channel.send() to give earlier senders/waiters a priority
This commit is contained in:
@@ -508,8 +508,8 @@ class Channel(object):
|
||||
if self._waiters:
|
||||
api.get_hub().schedule_call_global(0, self._do_switch)
|
||||
else:
|
||||
# if self._waiters and self._senders:
|
||||
# api.sleep(0)
|
||||
if self._waiters and self._senders:
|
||||
api.sleep(0)
|
||||
self.items.append((result, exc))
|
||||
# note that send() does not work well with timeouts. if your timeout fires
|
||||
# after this point, the item will remain in the queue
|
||||
|
Reference in New Issue
Block a user