From b2e4f4a52daae2963b807e2927b52dcca3332377 Mon Sep 17 00:00:00 2001 From: Loris Nezan <11007033+loristns@users.noreply.github.com> Date: Thu, 31 Jul 2025 08:56:45 +0000 Subject: [PATCH 1/2] fix: CrontabSchedule day_of_week help text to say that sunday is 0, not 7 --- django_celery_beat/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/django_celery_beat/models.py b/django_celery_beat/models.py index ad53a288..8f58a555 100644 --- a/django_celery_beat/models.py +++ b/django_celery_beat/models.py @@ -295,7 +295,7 @@ class CrontabSchedule(models.Model): verbose_name=_('Day(s) Of The Week'), help_text=_( 'Cron Days Of The Week to Run. Use "*" for "all", Sunday ' - 'is 0 or 7, Monday is 1. (Example: "0,5")'), + 'is 0, Monday is 1. (Example: "0,5")'), validators=[validators.day_of_week_validator], ) From 995f8d26b47b5e8ee3d788beeb04028696196bdf Mon Sep 17 00:00:00 2001 From: Loris Nezan <11007033+loristns@users.noreply.github.com> Date: Thu, 31 Jul 2025 11:51:08 +0000 Subject: [PATCH 2/2] chore: add migration file --- .../0020_alter_crontabschedule_day_of_week.py | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 django_celery_beat/migrations/0020_alter_crontabschedule_day_of_week.py diff --git a/django_celery_beat/migrations/0020_alter_crontabschedule_day_of_week.py b/django_celery_beat/migrations/0020_alter_crontabschedule_day_of_week.py new file mode 100644 index 00000000..86343168 --- /dev/null +++ b/django_celery_beat/migrations/0020_alter_crontabschedule_day_of_week.py @@ -0,0 +1,25 @@ +# Generated by Django 5.2.4 on 2025-07-31 11:48 + +import django_celery_beat.validators +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ("django_celery_beat", "0019_alter_periodictasks_options"), + ] + + operations = [ + migrations.AlterField( + model_name="crontabschedule", + name="day_of_week", + field=models.CharField( + default="*", + help_text='Cron Days Of The Week to Run. Use "*" for "all", Sunday is 0, Monday is 1. (Example: "0,5")', + max_length=64, + validators=[django_celery_beat.validators.day_of_week_validator], + verbose_name="Day(s) Of The Week", + ), + ), + ]