import logging

from edx_ace.message import MessageType

from openedx.core.djangoapps.schedules.config import DEBUG_MESSAGE_WAFFLE_FLAG


class ScheduleMessageType(MessageType):
    def __init__(self, *args, **kwargs):
        super(ScheduleMessageType, self).__init__(*args, **kwargs)
        self.log_level = logging.DEBUG if DEBUG_MESSAGE_WAFFLE_FLAG.is_enabled() else None


class RecurringNudge(ScheduleMessageType):
    def __init__(self, day, *args, **kwargs):
        super(RecurringNudge, self).__init__(*args, **kwargs)
        self.name = "recurringnudge_day{}".format(day)


class UpgradeReminder(ScheduleMessageType):
    pass


class CourseUpdate(ScheduleMessageType):
    pass
