Skip to content

Commit

Permalink
fix: python 3.7
Browse files Browse the repository at this point in the history
  • Loading branch information
Anton committed May 22, 2023
1 parent a786589 commit cc1ac3b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions taskiq/semaphore.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ async def acquire(self, first: bool = False) -> Literal[True]: # noqa: C901
Acquire a semaphore.
:param first: acquire ASAP
:raises asyncio.exceptions.CancelledError: task cancelled
:raises asyncio.CancelledError: task cancelled
:returns: true
"""
if not self.locked():
Expand All @@ -78,7 +78,7 @@ async def acquire(self, first: bool = False) -> Literal[True]: # noqa: C901
else:
self._waiters.remove(fut)

except asyncio.exceptions.CancelledError:
except asyncio.CancelledError:
if not fut.cancelled():
self._value += 1
self._wakeup_next()
Expand Down

0 comments on commit cc1ac3b

Please sign in to comment.