{"repo":"BobTheBuidler/eth_retry","free":true,"listed":false,"github":"https://github.com/BobTheBuidler/eth_retry","clone":"git clone https://github.com/BobTheBuidler/eth_retry.git","description":"Stop transient errors from wasting your time! Provides a decorator to automatically retry calls that fail due to specific transient errors seen in the web3 ecosystem.","language":"Python","stars":11,"topics":["eth-brownie","ethereum","evm","python","python3","web3","web3py"],"license":"MIT","category":"blockchain-web3","readme_excerpt":"eth retry Stop transient errors from wasting your time! eth retry is a Python library that provides one decorator, eth retry.auto retry . auto retry will automatically catch known transient exceptions that are common in the Ethereum/EVM ecosystem and will reattempt to evaluate your decorated function up to os.environ['MAX RETRIES'] (default: 10) times. Supports both synchronous and asynchronous functions. ------------ Covers many common transient errors in the EVM ecosystem, including: - RPC timeouts - Block explorer API rate-limiting - Generic exceptions: - ConnectionError - HTTPError - ReadTimeout - TimeoutError - eth-brownie specific errors: - sqlite3.OperationalError: database is locked Installation: pip install eth retry or pip install git+https://github.com/BobTheBuidler/eth retry.git Usage: Between attempts, eth retry will time.sleep for a random period between os.environ['MIN SLEEP TIME'] (default: 10) and os.environ['MAX SLEEP TIME'] (default: 20) seconds. The period is randomized to help prevent repetitive rate-limiting issues with parallelism by staggering the retries. On the n th retry, the sleep period is multiplied by n so that the target endpoint can cool off in case of rate-limiting. After os.environ['MAX RETRIES'] failures, eth retry will raise the exception. Environment:","default_branch":null,"files":null,"tree":[],"storefront":"/r/BobTheBuidler","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/BobTheBuidler/eth_retry/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}