You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The block hash from web3 RPC is different from the one generated by using the block header information returned by web3 RPC on the Rinkeby network
#23512
The block hash from web3 RPC is same as the one generated by using the block header information returned by web3 RPC
Actual behaviour
The block hash from web3 RPC is different from the one generated by using the block header information returned by web3 RPC
Steps to reproduce the behaviour
e.g., in a block with a block number 9204314, the block hash from web3 rpc is 0xb339bd0b82a47e8d072c11aace1119099c137ad819b47ee342ef001577a91539,
but the one generated by types.block.Hash() is 0xa30d74603c598be4f2cdebb68cca2aab4ec3efa50169993e3ee5a32bc2c82a61
The golang example is below:
block.Hash() call the header.Hash() to generate the block hash at the first time.
The log is below: block number: 9204314, block hash: 0xa30d74603c598be4f2cdebb68cca2aab4ec3efa50169993e3ee5a32bc2c82a61, parent hash: 0x636455431c7f50ca5867a5bd63a0a8f12aa731c235ae963d8d5f5169f4cd47b3
If the requested block height is 9204315, then the outpu is below: block number: 9204315, block hash: 0x412dd0cfde7eff5b2944b130158cffcd0e81c7e2b8c0b09007bfe736bcb18fbf, parent hash: 0xb339bd0b82a47e8d072c11aace1119099c137ad819b47ee342ef001577a91539
The parent hash in the block number 9204315 is same as the block hash from web3 rpc and Etherscan in the block number 9204314, but is different from the one generated by types.block.Hash() in the block number 9204314.
web3 RPC response is below with the block number 9204314:
System information
Geth version:
geth v1.10.8
OS & Version: Windows/Linux
Network: rinkeby
Node: infura
Expected behaviour
The block hash from web3 RPC is same as the one generated by using the block header information returned by web3 RPC
Actual behaviour
The block hash from web3 RPC is different from the one generated by using the block header information returned by web3 RPC
Steps to reproduce the behaviour
e.g., in a block with a block number 9204314, the block hash from web3 rpc is
0xb339bd0b82a47e8d072c11aace1119099c137ad819b47ee342ef001577a91539
,but the one generated by types.block.Hash() is
0xa30d74603c598be4f2cdebb68cca2aab4ec3efa50169993e3ee5a32bc2c82a61
The golang example is below:
block.Hash() call the header.Hash() to generate the block hash at the first time.
The log is below:
block number: 9204314, block hash: 0xa30d74603c598be4f2cdebb68cca2aab4ec3efa50169993e3ee5a32bc2c82a61, parent hash: 0x636455431c7f50ca5867a5bd63a0a8f12aa731c235ae963d8d5f5169f4cd47b3
If the requested block height is 9204315, then the outpu is below:
block number: 9204315, block hash: 0x412dd0cfde7eff5b2944b130158cffcd0e81c7e2b8c0b09007bfe736bcb18fbf, parent hash: 0xb339bd0b82a47e8d072c11aace1119099c137ad819b47ee342ef001577a91539
The parent hash in the block number 9204315 is same as the block hash from web3 rpc and Etherscan in the block number 9204314, but is different from the one generated by types.block.Hash() in the block number 9204314.
web3 RPC response is below with the block number 9204314:
note: this exception only appears in rinkeby
The text was updated successfully, but these errors were encountered: