Skip to content

Commit

Permalink
Use authority set of parent hash to determine block author (#386)
Browse files Browse the repository at this point in the history
  • Loading branch information
arjanz authored Apr 11, 2024
1 parent 84485c1 commit 1cd8dd9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion substrateinterface/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -2355,7 +2355,8 @@ def decode_block(block_data, block_data_hash=None):

engine = bytes(log_digest[1][0])
# Retrieve validator set
validator_set = self.query("Session", "Validators", block_hash=block_hash)
parent_hash = block_data['header']['parentHash']
validator_set = self.query("Session", "Validators", block_hash=parent_hash)

if engine == b'BABE':
babe_predigest = self.runtime_config.create_scale_object(
Expand Down

0 comments on commit 1cd8dd9

Please sign in to comment.