mirror of
https://github.com/aiogram/aiogram.git
synced 2025-12-11 09:55:21 +00:00
Fix executor.
This commit is contained in:
parent
2587c63d0e
commit
6ee44d4e04
1 changed files with 1 additions and 1 deletions
|
|
@ -49,9 +49,9 @@ def start_pooling(dispatcher, *, loop=None, skip_updates=False, on_startup=None,
|
||||||
|
|
||||||
loop.set_task_factory(context.task_factory)
|
loop.set_task_factory(context.task_factory)
|
||||||
|
|
||||||
loop.create_task(dispatcher.start_pooling())
|
|
||||||
try:
|
try:
|
||||||
loop.run_until_complete(_startup(dispatcher, skip_updates=skip_updates, callback=on_startup))
|
loop.run_until_complete(_startup(dispatcher, skip_updates=skip_updates, callback=on_startup))
|
||||||
|
loop.create_task(dispatcher.start_pooling())
|
||||||
loop.run_forever()
|
loop.run_forever()
|
||||||
except (KeyboardInterrupt, SystemExit):
|
except (KeyboardInterrupt, SystemExit):
|
||||||
pass
|
pass
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue