Skip to content

fix: Schedule task on weekends or workweek (#99)#656

Open
princ0301 wants to merge 1 commit into
dbader:masterfrom
princ0301:agent/fix-99-schedule-task-on-weekends-or-workweek
Open

fix: Schedule task on weekends or workweek (#99)#656
princ0301 wants to merge 1 commit into
dbader:masterfrom
princ0301:agent/fix-99-schedule-task-on-weekends-or-workweek

Conversation

@princ0301
Copy link
Copy Markdown

@princ0301 princ0301 commented May 24, 2026

Fixes #99

What changed

Adds workday and weekend properties to the Job class to allow scheduling tasks on weekdays (Monday-Friday) or weekends (Saturday-Sunday). This is achieved by introducing a weekday_constraints attribute to the Job and updating _schedule_next_run to skip days that do not match the constraint.

Test results

All tests passing after 1 attempt(s).

configfile: pyproject.toml
collected 81 items

test_schedule.py ss.ssss.................sss.ss...................ssssss [ 67%]
ssssssssssssssssssssssss..                                               [100%]

======================== 40 passed, 41 skipped in 0.63s ========================

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

Successfully merging this pull request may close these issues.

Schedule task on weekends or workweek

1 participant