We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 02f8931 commit ac80548Copy full SHA for ac80548
1 file changed
asyncutils/queues.py
@@ -111,8 +111,9 @@ def __repr__(self): return f'<password-protected queue at {id(self):#x}>'
111
@property
112
def maxsize(self): return maxsize
113
def task_done(self):
114
+ nonlocal U
115
if U == 0: raise ValueError('task_done() called too many times')
- nonlocal U; U -= 1
116
+ U -= 1
117
if U == 0: E.set()
118
async def join(self):
119
if U > 0: await E.wait()
0 commit comments