Skip to content
This repository has been archived by the owner on Sep 10, 2023. It is now read-only.

cron_prev 29-feb infinite loop #32

Closed
JJM1987 opened this issue Dec 7, 2020 · 6 comments
Closed

cron_prev 29-feb infinite loop #32

JJM1987 opened this issue Dec 7, 2020 · 6 comments

Comments

@JJM1987
Copy link

JJM1987 commented Dec 7, 2020

cron_prev function infinite loop on 29 February. Issue occurs in non leap years.

Example infinite loop:
Expression: "* * * 29 2 *"
Current time: 2021-12-7 12:00:00

Example correct result:
Expression: "* * * 29 2 *"
Current time: 2020-12-7 12:00:00

@staticlibs
Copy link
Owner

Thanks for the report! This is a nasty bug, will try to fix it.

@alenloncaric
Copy link

Hi,

was this bug ever fixed?

Thank you!

BR

@ghseb
Copy link

ghseb commented Sep 14, 2021

@alenloncaric Just tried adding check_next("* * * 29 2 *", "2021-12-07_12:00:00", "2024-02-29_00:00:00"); to the tests and it seems to work as expected (at lease on my toolchain with minor local changes).

Probably it makes sense to check it yourself.

@exander77
Copy link

@ghseb He complains about cron_prev and not cron_next.

exander77 added a commit to exander77/supertinycron that referenced this issue Sep 7, 2023
@exander77
Copy link

This is the same bug as: #35

@staticlibs
Copy link
Owner

This project is no longer maintained, see its updated and extended fork in exander77/supertinycron repo, closing the issue to archive the repo.

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

No branches or pull requests

5 participants