Skip to content

Add simple exponential backoff to approve transfer wait #115

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

Closed

Conversation

jrwdunham
Copy link
Contributor

@jrwdunham jrwdunham commented Jun 4, 2018

Fixes #114

This should allow us to wait 17.5 hours for the approve transfer select to appear, where before we only had 8.3 minutes:

>>> s = 1
>>> m = 64
>>> for x in range(990):
...   t += s
...   s = 2 * s
...   if s > m:
...     s = m
>>> (t / 60.0) / 60.0
17.510833333333334

Testing required to confirm fix.

@jrwdunham jrwdunham requested a review from jhsimpson June 4, 2018 23:05
@jrwdunham jrwdunham self-assigned this Jun 4, 2018
@jrwdunham jrwdunham added the Type: bug A flaw in the code that causes the software to produce an incorrect or unexpected result. label Jun 4, 2018
@jrwdunham
Copy link
Contributor Author

Closing in favour of #119

@jrwdunham jrwdunham closed this Jun 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: bug A flaw in the code that causes the software to produce an incorrect or unexpected result.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Problem: tests fail with recursion error on very large transfers
1 participant