Changed the algorithm of the start method
This commit is contained in:
@@ -21,10 +21,11 @@ class MyApp(ConfigManager):
|
||||
|
||||
async def main():
|
||||
app = MyApp("config.yaml")
|
||||
app.start()
|
||||
await app.start()
|
||||
logger.info("App started")
|
||||
await asyncio.sleep(20)
|
||||
await app.stop()
|
||||
|
||||
while True:
|
||||
await asyncio.sleep(1)
|
||||
|
||||
if __name__ == "__main__":
|
||||
asyncio.run(main())
|
||||
|
||||
Reference in New Issue
Block a user