Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[4.4] Fix next exec calculation for task scheduler #44061

Open
wants to merge 6 commits into
base: 4.4-dev
Choose a base branch
from

Conversation

rdeutz
Copy link
Contributor

@rdeutz rdeutz commented Sep 12, 2024

Pull Request for Issue #42459 partly .

Summary of Changes

The calculation of the next execution is not working as expected. This fix is for the intervals:

  • interval-minutes
  • interval-hours
  • interval-days
  • interval-months

I haven't looked into the cron-execution but will do in the furture (seems to me working right).

Testing Instructions

Create a task (e.g. Sleep) and chose Interval Days and set "Interval in Days" to 1 and the "Execution Time (UTC)" to 11:11 and save it.

Actual result BEFORE applying this Pull Request

You will see that the day is the next day but the time is the current time.

Expected result AFTER applying this Pull Request

The day is the next day and the time is 11:11

Apply the patch and try again, now it should be as expected. Play around with the other options and settings.

For the calculation of the next execution I have used the current time, then I am adding the interval and finally set time and day if needed.

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

@rdeutz rdeutz added the bug label Sep 14, 2024
@TLWebdesign
Copy link

I have tested this item ✅ successfully on 52f7cb7


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44061.

1 similar comment
@dautrich
Copy link

I have tested this item ✅ successfully on 52f7cb7


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44061.

@Quy
Copy link
Contributor

Quy commented Sep 18, 2024

Not sure to mark RTC per comment.

@rdeutz
Copy link
Contributor Author

rdeutz commented Sep 18, 2024

@Quy I would set RTC because it is a good step in the right direction and we only have a few days before the last 4.4.x Version before securtiy only fixes will be released. It would be a shame to have it so broken as it is now. I am going to make a 2nd PR and will work on the other issues in the comment.

@Quy Quy removed the bug label Sep 18, 2024
@Quy
Copy link
Contributor

Quy commented Sep 18, 2024

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/44061.

@joomla-cms-bot joomla-cms-bot added the RTC This Pull Request is Ready To Commit label Sep 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR-4.4-dev RTC This Pull Request is Ready To Commit
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants