-
-
Notifications
You must be signed in to change notification settings - Fork 174
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
Fix recursion while waiting for redis connection #311
Fix recursion while waiting for redis connection #311
Conversation
Codecov Report
@@ Coverage Diff @@
## main #311 +/- ##
==========================================
+ Coverage 98.77% 98.87% +0.10%
==========================================
Files 11 11
Lines 980 981 +1
Branches 183 183
==========================================
+ Hits 968 970 +2
Misses 6 6
+ Partials 6 5 -1
Continue to review full report at Codecov.
|
`Arq` has ability to retry connections to redis in case of problems. That is a nice feature, but it crashes after hundreds of attempts reaching maximal recursion depth. This change modifies re-try algorithm from recursion to iteration avoiding the limit. In practice it would be nice to have ability to wait forever as issue with redis instance should not kill worker process, but that is a separate change that can be built on top. Fixes exception when retrying redis connection many times: RecursionError: maximum recursion depth exceeded while getting the str of an object
50bbdbf
to
f248aed
Compare
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.
Looks great!
Hi, all the failures in CI feels unrelated, should I do something more to get this PR merged? |
3.9 failure looks intermittent, might be worth rerunning. If you can fix the problem with click that would be great, otherwise I will. |
I have no means of re-running other then changing something and re-pushing. I guess it is related to some permissions.
|
Thanks so much. By the way, you can always re-run CI using |
Arq
has ability to retry connections to redis in case of problems.That is a nice feature, but it crashes after hundreds of attempts
reaching maximal recursion depth. This change modifies re-try algorithm
from recursion to iteration avoiding the limit.
In practice it would be nice to have ability to wait forever as issue
with redis instance should not kill worker process, but that is a
separate change that can be built on top.
Fixes exception when retrying redis connection many times:
RecursionError: maximum recursion depth exceeded while getting the str of an object