Fixed ExponentialBackoff not working when integral
This commit is contained in:
parent
8acf3d01ce
commit
f490afa5dc
@ -61,7 +61,7 @@ class ExponentialBackoff:
|
|||||||
rand = random.Random()
|
rand = random.Random()
|
||||||
rand.seed()
|
rand.seed()
|
||||||
|
|
||||||
self._randfunc = rand.rand_range if integral else rand.uniform
|
self._randfunc = rand.randrange if integral else rand.uniform
|
||||||
|
|
||||||
def delay(self):
|
def delay(self):
|
||||||
"""Compute the next delay
|
"""Compute the next delay
|
||||||
|
Loading…
x
Reference in New Issue
Block a user