{"id":17592406,"url":"https://github.com/bobthebuidler/eth_retry","last_synced_at":"2026-01-25T05:01:17.743Z","repository":{"id":38344999,"uuid":"486375143","full_name":"BobTheBuidler/eth_retry","owner":"BobTheBuidler","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.","archived":false,"fork":false,"pushed_at":"2026-01-21T08:19:35.000Z","size":2635,"stargazers_count":11,"open_issues_count":7,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2026-01-21T17:32:05.321Z","etag":null,"topics":["eth-brownie","ethereum","evm","python","python3","web3","web3py"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/BobTheBuidler.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2022-04-27T22:56:20.000Z","updated_at":"2026-01-21T08:19:38.000Z","dependencies_parsed_at":"2025-08-10T00:10:45.606Z","dependency_job_id":"ca080800-ce49-4d4c-a9da-48acacd954fc","html_url":"https://github.com/BobTheBuidler/eth_retry","commit_stats":null,"previous_names":[],"tags_count":35,"template":false,"template_full_name":null,"purl":"pkg:github/BobTheBuidler/eth_retry","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BobTheBuidler%2Feth_retry","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BobTheBuidler%2Feth_retry/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BobTheBuidler%2Feth_retry/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BobTheBuidler%2Feth_retry/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BobTheBuidler","download_url":"https://codeload.github.com/BobTheBuidler/eth_retry/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BobTheBuidler%2Feth_retry/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28744419,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-25T02:46:29.005Z","status":"ssl_error","status_checked_at":"2026-01-25T02:44:29.968Z","response_time":113,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["eth-brownie","ethereum","evm","python","python3","web3","web3py"],"created_at":"2024-10-22T05:22:39.823Z","updated_at":"2026-01-25T05:01:17.722Z","avatar_url":"https://github.com/BobTheBuidler.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# eth_retry\n\u003e Stop transient errors from wasting your time!\n\n`eth_retry` is a Python library that provides one decorator, `eth_retry.auto_retry`.\n\n`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.\n\nSupports both synchronous and asynchronous functions.\n\n------------\n\nCovers many common transient errors in the EVM ecosystem, including:\n- RPC timeouts\n- Block explorer API rate-limiting\n- Generic exceptions:\n  - ConnectionError\n  - HTTPError\n  - ReadTimeout\n  - TimeoutError\n- eth-brownie specific errors:\n  - sqlite3.OperationalError: database is locked\n\n## Installation:\n`pip install eth_retry`\nor\n`pip install git+https://github.com/BobTheBuidler/eth_retry.git`\n\n## Usage:\n```\nimport eth_retry\n\n@eth_retry.auto_retry\ndef some_function_that_errors_sometimes():\n    i = 0\n    am = 1\n    doing = 2\n    stuff = 3\n    return stuff\n\nerror_free_result = some_function_that_errors_sometimes()\n```\n\nBetween 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.\n\nOn the `n`th retry, the sleep period is multiplied by `n` so that the target endpoint can cool off in case of rate-limiting.\n\nAfter `os.environ['MAX_RETRIES']` failures, eth_retry will raise the exception.\n\n## Environment:\n```\n# Minimum sleep time in seconds. Integer. Defaults to 10.\nMIN_SLEEP_TIME=10\n\n# Maximum sleep time in seconds. Integer. Defaults to 20.\nMAX_SLEEP_TIME=20\n\n# Maximum number of times to retry. Integer. Defaults to 10.\nMAX_RETRIES=10\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbobthebuidler%2Feth_retry","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbobthebuidler%2Feth_retry","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbobthebuidler%2Feth_retry/lists"}