tenacity icon indicating copy to clipboard operation
tenacity copied to clipboard

Respects `min` argument for `wait_random_exponential`

Open yxtay opened this issue 2 years ago • 0 comments

Summary

Respects min argument for wait_random_exponential

  • currently, min argument only affects computing the high range of the uniform sampling
  • min does not affect the low range of the uniform sampling, hence the sampled wait may be lower than min specified
  • This PR fixes the issue, which I believe is unexpected

Tests

pytest tests/test_tenacity.py::TestWaitConditions::test_wait_random_exponential

yxtay avatar Dec 18 '23 02:12 yxtay