Skip to content

Commit

Permalink
Fix AttributeError: 'TzktDatasource' object has no attribute 'block' (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
arrijabba committed Sep 16, 2021
1 parent 0b0d878 commit f76b714
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/dipdup/datasources/tzkt/datasource.py
Original file line number Diff line number Diff line change
Expand Up @@ -705,12 +705,13 @@ async def _on_operation_message(self, message: List[Dict[str, Any]]) -> None:

async def _on_big_map_message(self, message: List[Dict[str, Any]]) -> None:
"""Parse and emit raw big map diffs from WS"""
async for _, data in self._extract_message_data('big_map', message):
async for level, data in self._extract_message_data('big_map', message):
block = await self._block_cache.get_block(level)
big_maps = []
for big_map_json in data:
big_map = self.convert_big_map(big_map_json)
big_maps.append(big_map)
self.emit_big_maps(big_maps, self.block)
self.emit_big_maps(big_maps, block)

async def _on_head_message(self, message: List[Dict[str, Any]]) -> None:
async for _, data in self._extract_message_data('head', message):
Expand Down

0 comments on commit f76b714

Please sign in to comment.