Development of an internal social media platform with personalised dashboards for students
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

tasks.py 368B

1234567
  1. from celery.task.schedules import crontab
  2. from celery.decorators import periodic_task
  3. from .email_service import send_emails
  4. # this will run every minute, see http://celeryproject.org/docs/reference/celery.task.schedules.html#celery.task.schedules.crontab
  5. @periodic_task(run_every=crontab(hour="*", minute="*", day_of_week="*"))
  6. def trigger_emails():
  7. send_emails()