Skip to content

Instantly share code, notes, and snippets.



Created Feb 10, 2011
What would you like to do?
diff --git a/djcelery/ b/djcelery/
index cf17f3b..eaa5525 100644
--- a/djcelery/
+++ b/djcelery/
@@ -51,6 +51,13 @@ class ModelEntry(ScheduleEntry):
self.model.no_changes = True
return self.__class__(self.model)
+ def is_due(self):
+ """See :meth:`celery.task.base.PeriodicTask.is_due`."""
+ due = self.schedule.is_due(self.last_run_at)
+ if self.model.enabled:
+ return due
+ return False, due
def save(self):
# Object may not be synchronized, so only
# change the fields we care about.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment