add docstrings to the scheduler module
This commit is contained in:
@@ -11,7 +11,8 @@ class Schedule:
|
|||||||
mqtt = None
|
mqtt = None
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def start(cls):
|
def start(cls) -> None:
|
||||||
|
'''Start the scheduler and schedule the tasks (cron jobs)'''
|
||||||
logging.info("Scheduler init")
|
logging.info("Scheduler init")
|
||||||
cls.mqtt = Mqtt(None)
|
cls.mqtt = Mqtt(None)
|
||||||
|
|
||||||
@@ -19,7 +20,8 @@ class Schedule:
|
|||||||
# crontab('*/5 * * * *', func=cls.atmidnight, start=True)
|
# crontab('*/5 * * * *', func=cls.atmidnight, start=True)
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
async def atmidnight(cls):
|
async def atmidnight(cls) -> None:
|
||||||
|
'''Clear daily counters at midnight'''
|
||||||
logging.info("Clear daily counters at midnight")
|
logging.info("Clear daily counters at midnight")
|
||||||
|
|
||||||
for key, data in ClrAtMidnight.elm():
|
for key, data in ClrAtMidnight.elm():
|
||||||
|
|||||||
Reference in New Issue
Block a user