Skip to content

Commit

Permalink
remove unneeded cancel logic
Browse files Browse the repository at this point in the history
  • Loading branch information
TheTechromancer committed Feb 9, 2024
1 parent 381f12a commit 9498117
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions bbot/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -351,12 +351,7 @@ async def akeyboard_listen():

keyboard_listen_task = asyncio.create_task(akeyboard_listen())

try:
await scanner.async_start_without_generator()
finally:
with suppress(Exception):
keyboard_listen_task.cancel()
await keyboard_listen_task
await scanner.async_start_without_generator()

except bbot.core.errors.ScanError as e:
log_to_stderr(str(e), level="ERROR")
Expand Down

0 comments on commit 9498117

Please sign in to comment.