-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Flow with_options
fixes - retries, retry_delay_seconds, flow_run_name
#12020
Conversation
👷 Deploy request for prefect-docs-preview pending review.Visit the deploys page to approve it
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR @NodeJSmith! Could you please add one or two regression tests covering these changes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@NodeJSmith thank you for the pull request! The code here looks right to me, and I love that you fixed the type hint as well. I have one ask, could you add these options to this existing test? https://github.com/PrefectHQ/prefect/blob/main/tests/test_flows.py#L272
@bunchesofdonald Thanks for pointing out where to add these, I had meant to do that before creating the PR, I think it slipped my mind. Two tests added, one for each of the attributes. I double checked on the logic, since the Let me know if you have any other concerns or if I need to add anything else. |
@bunchesofdonald I just realized while working on something that |
I don't believe that was by design, so if you want to make this PR include that as well that seems fine to me. Also don't worry about these test failures, |
with_options
with_options
fixes - retries, retry_delay_seconds, flow_run_name
@bunchesofdonald Ready for review again, fixed the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great, thank you @NodeJSmith!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Closes #11468
Correct logic in
Flow.with_options
to allow settingretries
andretry_delay_seconds
to 0.Checklist
<link to issue>
"maintenance
,fix
,feature
,enhancement
,docs
.For documentation changes:
netlify.toml
for files that are removed or renamed.For new functions or classes in the Python SDK:
mkdocs.yml
navigation.