Skip to content

Commit

Permalink
give up on etherscan quicker. reset bot
Browse files Browse the repository at this point in the history
  • Loading branch information
funderbrker committed Apr 16, 2024
1 parent 1d1077a commit 87ea9ef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion data_access/etherscan.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ def get_gas_base_fee():
request_url = ETHERSCAN_API_URL.format(
module="gastracker", action="gasoracle", payload="", key=os.environ["ETHERSCAN_TOKEN"]
)
result = get_with_retries(request_url, timeout=15)
result = get_with_retries(request_url, max_tries=4, timeout=10)
if int(result["status"]) == 0:
raise Exception(f'Request rejected by etherscan:\n{result["result"]}')
return float(result["result"]["suggestBaseFee"])
Expand Down

0 comments on commit 87ea9ef

Please sign in to comment.