Skip to content

Renames max_retries to max_attempts in config#46

Merged
JessF298 merged 4 commits into
devfrom
fix/rename_retries
May 26, 2026
Merged

Renames max_retries to max_attempts in config#46
JessF298 merged 4 commits into
devfrom
fix/rename_retries

Conversation

@Sam-Sims

Copy link
Copy Markdown
Collaborator

Addresses #32

Previous behavior wanted a user to set a number of retries allowed. Internally this was always incremented by 1 to get the total number of attempts. This felt unintuitive as a user would have to set 0 if you only wanted one run.

New behavior is to allow the user to set explicitly the number of attempts for a pipeline - and validates at config parse time that this value is >=1.

This is a breaking to change to all configs - which will need to be updated once merged so we can hold off on this until ready.

Sam-Sims added 2 commits May 22, 2026 14:37
Internally max_retires was +1 to get max attempts anyway, this makes it
clearer to the end user how many times a pipeline will run
@Sam-Sims Sam-Sims requested a review from JessF298 May 22, 2026 13:44

@JessF298 JessF298 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

lgtm - installed and relevant tests pass.
Might consider nicer error handling, either custom errors or as suggestied use the add_note() method on the exception.

rather than rasing another ValueError

@JessF298 JessF298 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

nice thanks!

@Sam-Sims

Copy link
Copy Markdown
Collaborator Author

yeah good point - for polish we can look at custom exceptions at a later date, for now used the add_note func to add context

we can merge this whenever we are ready to update the configs

@JessF298 JessF298 merged commit f898d95 into dev May 26, 2026
2 checks passed
@Sam-Sims Sam-Sims deleted the fix/rename_retries branch May 26, 2026 11:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants