ask/django-celery — Issue #101: DatabaseScheduler only supports crontab and schedule schedule types, contrary to documentation.
Author: crass
Created: 2012-01-13 00:29:32+00:00
State: open

As noticed by [zvikico](https://github.com/ask/django-celery/issues/45#issuecomment-962591), the celery documentation shows the schedule parameter for a task defined in CELERYBEAT_SCHEDULE being a datetime.timedelta. Django-celery 2.4.2 does not support this.

The root problem is at https://github.com/ask/django-celery/blob/master/djcelery/schedulers.py#L76, which only allows instances of type schedule or crontab. Perhaps celery.schedules.maybe_schedule should be used to convert int and timedelta instance schedule instance.

I've created a pull request that implements this: https://github.com/ask/django-celery/pull/100