MCPcopy
hub / github.com/celery/celery / __init__

Method __init__

celery/schedules.py:401–414  ·  view source on GitHub ↗
(self, minute: Cronspec = '*', hour: Cronspec = '*', day_of_week: Cronspec = '*',
                 day_of_month: Cronspec = '*', month_of_year: Cronspec = '*', **kwargs: Any)

Source from the content-addressed store, hash-verified

399 """
400
401 def __init__(self, minute: Cronspec = '*', hour: Cronspec = '*', day_of_week: Cronspec = '*',
402 day_of_month: Cronspec = '*', month_of_year: Cronspec = '*', **kwargs: Any) -> None:
403 self._orig_minute = cronfield(minute)
404 self._orig_hour = cronfield(hour)
405 self._orig_day_of_week = cronfield(day_of_week)
406 self._orig_day_of_month = cronfield(day_of_month)
407 self._orig_month_of_year = cronfield(month_of_year)
408 self._orig_kwargs = kwargs
409 self.hour = self._expand_cronspec(hour, 24)
410 self.minute = self._expand_cronspec(minute, 60)
411 self.day_of_week = self._expand_cronspec(day_of_week, 7)
412 self.day_of_month = self._expand_cronspec(day_of_month, 31, 1)
413 self.month_of_year = self._expand_cronspec(month_of_year, 12, 1)
414 super().__init__(**kwargs)
415
416 @classmethod
417 def from_string(cls, crontab: str) -> crontab:

Callers

nothing calls this directly

Calls 3

_expand_cronspecMethod · 0.95
cronfieldFunction · 0.85
__init__Method · 0.45

Tested by

no test coverage detected