Skip to content

Commit

Permalink
0.1b minor update
Browse files Browse the repository at this point in the history
  • Loading branch information
larsyngvelundin committed Nov 22, 2023
1 parent 8a2dd7b commit 3ba38ef
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
5 changes: 5 additions & 0 deletions version_history.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
## 0.1b
Added `TimeoutError` to the exceptions to be handled.

## 0.1
Initial version
5 changes: 4 additions & 1 deletion web3_balancer/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,10 @@ def _call_w3_func(self, func):
val = eval(f"self.is_contract.{func}")
else:
val = eval(f"self._w3.{func}")
except (requests.exceptions.ConnectionError, requests.exceptions.ReadTimeout, requests.exceptions.HTTPError) as error:
except (requests.exceptions.ConnectionError,
requests.exceptions.ReadTimeout,
requests.exceptions.HTTPError,
TimeoutError) as error:
self.error_count += 1
if (self.error_count > 1):
raise Exception(
Expand Down

0 comments on commit 3ba38ef

Please sign in to comment.