Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error with run weekly feature #242

Open
josylad opened this issue Oct 15, 2023 · 3 comments
Open

Error with run weekly feature #242

josylad opened this issue Oct 15, 2023 · 3 comments

Comments

@josylad
Copy link

josylad commented Oct 15, 2023

Hello,
I am setting up a cronjob that is supposed to run on some weekdays using the example below.

class MyCronJob(CronJobBase):
    RUN_WEEKLY_ON_DAYS = [0, 6]
    RUN_AT_TIMES = ['6:30']
    schedule = Schedule(run_weekly_on_days=RUN_WEEKLY_ON_DAYS, run_at_times=RUN_AT_TIMES)

but I get this error "unexpected keyword argument 'run_weekly_on_days" when I try to run the cronjobs.

any help?

@josylad
Copy link
Author

josylad commented Oct 15, 2023

any help @JedrzejMaluszczak

@vaibhavhrt
Copy link

Screenshot 2024-06-03 at 11 02 54 PM

It's run_on_days not run_weekly_on_days.

@mostthingsweb
Copy link

It's run_on_days not run_weekly_on_days.

Maybe it used to be, but not anymore. It's run_weekly_on_days: https://github.com/Tivix/django-cron/blob/master/django_cron/core.py#L22

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants