http_retry_request_with_sleep_middleware
Documentation for eth_defi.middleware.http_retry_request_with_sleep_middleware function.
- http_retry_request_with_sleep_middleware(make_request, web3)[source]
A HTTP retry middleware with sleep and backoff.
If you want to customise timeouts, supported exceptions and such you can directly create your own middleware using
exception_retry_middleware()
.Usage:
web3.middleware_onion.clear() web3.middleware_onion.inject(http_retry_request_with_sleep_middleware, layer=0)