From ae38c903b17a6c597045b36c07d65bad271ee29c Mon Sep 17 00:00:00 2001 From: teknium1 <127238744+teknium1@users.noreply.github.com> Date: Sat, 12 Sep 2026 20:09:55 -0700 Subject: [PATCH] test(cron): unreachable-retry ladder test uses an interval schedule, not a wall-clock cron "0 3 * * *" fires at a fixed UTC minute; when CI runs in the half hour before it (observed 02:30:56Z), the 30-minute rung lands after the natural occurrence and plan_retry correctly yields to the schedule, clearing the state the test asserts on. "every 24h" always has its natural fire a full day out, so every rung is strictly earlier regardless of when the test runs. --- tests/cron/test_unreachable_retry.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/cron/test_unreachable_retry.py b/tests/cron/test_unreachable_retry.py index bce50f4c0d..d0a71f9504 100644 --- a/tests/cron/test_unreachable_retry.py +++ b/tests/cron/test_unreachable_retry.py @@ -29,7 +29,10 @@ def _iso(dt: datetime) -> str: def test_unreachable_failure_pulls_next_run_earlier_then_ladder_exhausts(tmp_cron_home): """Failed-unreachable runs re-fire on the 5/15/30-minute ladder instead of waiting a full period, and the ladder stops after its last rung (falls back to the schedule).""" - job = create_job("nightly report", "0 3 * * *") # daily — natural gap is hours + # Interval, not a cron expression: the natural next fire is always a full day out. A + # fixed clock time ("0 3 * * *") makes the 30-minute rung land past the natural fire + # in the half hour before it, and plan_retry rightly yields to the schedule (CI red). + job = create_job("nightly report", "every 24h") job_id = job["id"] now = datetime.now(timezone.utc)