Fix event loop (#32)
* Fix main by ensuring a new event loop is created * fix Dockerfile workspace error
This commit was merged in pull request #32.
This commit is contained in:
committed by
GitHub
parent
c96617a039
commit
d85d6ed1eb
@@ -24,7 +24,9 @@ if __name__ == "__main__":
|
||||
except AssertionError as e:
|
||||
try:
|
||||
logging.warning(f"Telegram bot could not be started: {e}")
|
||||
asyncio.get_event_loop().run_forever()
|
||||
loop = asyncio.new_event_loop()
|
||||
asyncio.set_event_loop(loop)
|
||||
loop.run_forever()
|
||||
except KeyboardInterrupt:
|
||||
logging.info("Shutting down due to KeyboardInterrupt")
|
||||
finally:
|
||||
|
||||
Reference in New Issue
Block a user