adhjustments to work with statediffing geth v1.10-alpha.2

This commit is contained in:
Ian Norden
2020-03-11 13:41:59 -05:00
parent be875c0100
commit e5c5422edc
26 changed files with 547 additions and 294 deletions
+4 -4
View File
@@ -139,12 +139,12 @@ func streamEthSubscription() {
continue
}
fmt.Printf("Account for key %s, and root %s, with balance %s\n",
stateNode.StateTrieKey.Hex(), acct.Root.Hex(), acct.Balance.String())
stateNode.StateLeafKey.Hex(), acct.Root.Hex(), acct.Balance.String())
fmt.Printf("state account: %+v\n", acct)
}
for _, storageNode := range ethData.StorageNodes {
fmt.Printf("Storage for state key %s ", storageNode.StateTrieKey.Hex())
fmt.Printf("with storage key %s\n", storageNode.StorageTrieKey.Hex())
fmt.Printf("Storage for state key %s ", storageNode.StateLeafKey.Hex())
fmt.Printf("with storage key %s\n", storageNode.StorageLeafKey.Hex())
var i []interface{}
err := rlp.DecodeBytes(storageNode.IPLD.Data, &i)
if err != nil {
@@ -158,7 +158,7 @@ func streamEthSubscription() {
continue
}
fmt.Printf("Storage leaf key: %s, and value hash: %s\n",
storageNode.StorageTrieKey.Hex(), common.BytesToHash(valueBytes).Hex())
storageNode.StorageLeafKey.Hex(), common.BytesToHash(valueBytes).Hex())
}
}
case err = <-sub.Err():