bot refactor

This commit is contained in:
2024-12-07 17:41:27 +09:00
parent 72cb7a4ef7
commit 626f378303
25 changed files with 1065 additions and 657 deletions

10
bot/utils/scheduler.py Normal file
View File

@@ -0,0 +1,10 @@
from apscheduler.schedulers.asyncio import AsyncIOScheduler
from bot.operations.notifications import schedule_notifications
def setup_scheduler():
"""Настройка планировщика уведомлений."""
print("Настройка планировщика...")
scheduler = AsyncIOScheduler()
scheduler.add_job(schedule_notifications, "cron", minute="*")
return scheduler