Skip to content

Commit

Permalink
Review fix
Browse files Browse the repository at this point in the history
  • Loading branch information
cyc60 committed Jul 20, 2023
1 parent ec27893 commit a40f490
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions sw_utils/execution.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,10 @@ def lock_endpoint(self, endpoint_uri: URI | str):
if not uri_providers:
raise ValueError(f'Invalid uri provider for execution client: {uri_providers}')
self._locker_provider = uri_providers[0]
yield
self._locker_provider = None
try:
yield
finally:
self._locker_provider = None


def get_execution_client(endpoints: list[str], is_poa=False, timeout=60) -> AsyncWeb3:
Expand Down

0 comments on commit a40f490

Please sign in to comment.