Skip to content

Commit

Permalink
fix: curve registry zero address on base (#501)
Browse files Browse the repository at this point in the history
  • Loading branch information
BobTheBuidler authored Jan 23, 2024
1 parent c937d96 commit 894d144
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions y/prices/stable_swap/curve.py
Original file line number Diff line number Diff line change
Expand Up @@ -552,8 +552,8 @@ async def _load_all(self) -> None:
await self.address_provider
logger.debug("curve address provider events loaded, now loading factories and pools")
# NOTE: Gnosis chain's address provider fails to provide registry via events. Maybe other chains as well.
if not self.identifiers[Ids.Main_Registry]:
self.identifiers[Ids.Main_Registry] = [await self.address_provider.get_registry()]
if not self.identifiers[Ids.Main_Registry] and (registry := await self.address_provider.get_registry()) != ZERO_ADDRESS:
self.identifiers[Ids.Main_Registry] = [registry]
while True:
# Check if any registries were updated, then ensure all old and new are loaded
await asyncio.gather(*[
Expand Down

0 comments on commit 894d144

Please sign in to comment.