Update scheduler.py

This commit is contained in:
SpudGunMan
2025-10-22 21:08:55 -07:00
parent 1f48e9a4aa
commit c6e8feefd7

View File

@@ -62,14 +62,15 @@ async def setup_scheduler(
elif 'custom' in schedulerValue.lower():
# Import and setup custom schedules from custom_scheduler.py
try:
from modules.custom_scheduler import setup_custom_schedules
#
from modules.custom_scheduler import setup_custom_schedules # type: ignore # pylance
setup_custom_schedules(
send_message, tell_joke, welcome_message, handle_wxc, MOTD,
schedulerChannel, schedulerInterface)
logger.debug("System: Custom scheduler file imported and custom schedules set up.")
except Exception as e:
logger.debug(f"System: Failed to import custom scheduler. {e}")
logger.warning("Custom scheduler file not found or failed to import. cp ecp etc/custom_scheduler.py modules/custom_scheduler.py")
logger.warning("Custom scheduler file not found or failed to import. cp etc/custom_scheduler.py modules/custom_scheduler.py")
# Start the Broadcast Scheduler
await BroadcastScheduler()