We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 75c1b7c + 4f28d9f commit 6802cb4Copy full SHA for 6802cb4
v3/primitives/queue.py
@@ -33,8 +33,8 @@ def _get(self):
33
async def get(self): # Usage: item = await queue.get()
34
if self.empty():
35
# Queue is empty, put the calling Task on the waiting queue
36
- await self._evput.wait()
37
self._evput.clear()
+ await self._evput.wait()
38
return self._get()
39
40
def get_nowait(self): # Remove and return an item from the queue.
@@ -50,8 +50,8 @@ def _put(self, val):
50
async def put(self, val): # Usage: await queue.put(item)
51
if self.qsize() >= self.maxsize and self.maxsize:
52
# Queue full
53
- await self._evget.wait()
54
self._evget.clear()
+ await self._evget.wait()
55
# Task(s) waiting to get from queue, schedule first Task
56
self._put(val)
57
0 commit comments