Esempio n. 1
0
 async def getBlockByNumber(self, at_block: Union[str, int],
                            include_transactions: bool) -> RpcBlockResponse:
     block = await get_block_at_number(self.chain, at_block)
     return block_to_dict(block, self.chain, include_transactions)
Esempio n. 2
0
 def getBlockByNumber(self, at_block, include_transactions):
     block = get_block_at_number(self._chain, at_block)
     return block_to_dict(block, self._chain, include_transactions)
Esempio n. 3
0
 async def getBlockByHash(self, block_hash: Hash32,
                          include_transactions: bool) -> RpcBlockResponse:
     block = await self.chain.coro_get_block_by_hash(block_hash)
     return block_to_dict(block, self.chain, include_transactions)
Esempio n. 4
0
 def getBlockByHash(self, block_hash, include_transactions):
     block = self._chain.get_block_by_hash(block_hash)
     return block_to_dict(block, self._chain, include_transactions)
Esempio n. 5
0
 async def getBlockByNumber(
         self, at_block: Union[str, int],
         include_transactions: bool) -> Dict[str, Union[str, List[str]]]:
     block = await get_block_at_number(self._chain, at_block)
     return block_to_dict(block, self._chain, include_transactions)
Esempio n. 6
0
 async def getBlockByHash(
         self, block_hash: Hash32,
         include_transactions: bool) -> Dict[str, Union[str, List[str]]]:
     block = await self._chain.coro_get_block_by_hash(block_hash)
     return block_to_dict(block, self._chain, include_transactions)
Esempio n. 7
0
 def getBlockByNumber(self, at_block, include_transactions):
     block = get_block_at_number(self._chain, at_block)
     return block_to_dict(block, self._chain, include_transactions)
Esempio n. 8
0
 def getBlockByHash(self, block_hash, include_transactions):
     block = self._chain.get_block_by_hash(block_hash)
     return block_to_dict(block, self._chain, include_transactions)