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

Update task engine to increment run_count when entering RUNNING state #15436

Merged
merged 3 commits into from
Sep 19, 2024

Conversation

desertaxle
Copy link
Member

Walks back some changes in #15424 to update run_count when a task run enters RUNNING instead of when the user code is run.

Checklist

  • This pull request references any related issue by including "closes <link to issue>"
    • If no issue exists and your change is not a small fix, please create an issue first.
  • If this pull request adds new functionality, it includes unit tests that cover the changes
  • If this pull request removes docs files, it includes redirect settings in mint.json.
  • If this pull request adds functions or classes, it includes helpful docstrings.

self.set_state(
Retrying() if self.state.name == "AwaitingRetry" else Running(),
new_state,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Jw: would it be simpler to have an if new_state.is_running() then increment run count statement in set_state or will that have edge cases?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup, that does appear to work. Updated in 3fb2d68

Copy link

codspeed-hq bot commented Sep 19, 2024

CodSpeed Performance Report

Merging #15436 will not alter performance

Comparing fix-15424 (3fb2d68) with main (e248442)

Summary

✅ 3 untouched benchmarks

@desertaxle desertaxle merged commit ab6c49d into main Sep 19, 2024
31 checks passed
@desertaxle desertaxle deleted the fix-15424 branch September 19, 2024 19:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix A fix for a bug in an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants