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

Possibility of infinite retrying via :tries=>0 #20

Closed
wants to merge 2 commits into from
Closed

Possibility of infinite retrying via :tries=>0 #20

wants to merge 2 commits into from

Conversation

Nakilon
Copy link

@Nakilon Nakilon commented Mar 31, 2016

For infinite sequence of intervals had to use Enumerator.
Maybe get rid of Array at all? That would eliminate few ifs that check if tries is zero.

Note: !! sure makes sense in Ruby but not in if condition.

@kamui
Copy link
Owner

kamui commented Apr 21, 2016

I'm wondering if 0 makes sense as representing infinity. I think it might be confusing and unintuitive. Maybe Float::INFINITY?

@apurvis
Copy link
Contributor

apurvis commented Dec 14, 2016

Maybe Float::INFINITY?

+1 to that idea

@pchaganti
Copy link

👍

@apurvis
Copy link
Contributor

apurvis commented Feb 11, 2017

I feel like the issue of infinite retries is better solved with some simple input validation to make sure tries > 0 (or !intervals.empty?).

the idea of allowing an Enumerator is not a bad one but sort of deserves a separate PR.

@kamui
Copy link
Owner

kamui commented Jul 29, 2021

Closing this PR since using 0 tries not the approach we want.

@kamui kamui closed this Jul 29, 2021
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.

4 participants