Fork of a popular backoff library with a few fixed bugs
Project description
improved_backoff
Function decoration for backoff and retry
This is a fork of an excellent Python library backoff. The library was forked from version 2.2.1 (October 5, 2022) This version includes 2 PRs proposed in the original repo:
The updated behavior of max_time
is that a a function will be retried only if the elapsed time is less,
than max_time
. Also the remaining time should exceed the interval
(delay between retries).
In order to use this module import it under backoff
alias and use it
the same way as the original module
import improved_backoff as backoff
@backoff.on_exception(backoff.expo, requests.exceptions.RequestException)
def get_url(url):
return requests.get(url)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
improved_backoff-1.1.tar.gz
(11.6 kB
view hashes)
Built Distribution
Close
Hashes for improved_backoff-1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c46972fd695c0044580d09a48113bb635f079ae6394cf2ffb2ab77da91859dbf |
|
MD5 | 99e779b7a23cdc5146a99b747f6369d4 |
|
BLAKE2b-256 | 41bbefd498b219d0865343a08d11adc2d3788fec9634860f2db4305dc389c13d |