Use timedelta to avoid ValueError

This commit is contained in:
tcely 2025-06-07 19:28:18 -04:00 committed by GitHub
parent 4dc7243972
commit af4f242b05
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -404,7 +404,7 @@ class Source(db.models.Model):
)
elif Val(IndexSchedule.EVERY_7_DAYS) > self.index_schedule:
self.target_schedule = advance_hour(
when.replace(hour=1+when.hour),
when + timezone.timedelta(hours=1),
self.target_schedule.hour,
)