diff options
author | Determinant <[email protected]> | 2020-09-17 02:16:30 -0400 |
---|---|---|
committer | Determinant <[email protected]> | 2020-09-17 02:16:30 -0400 |
commit | 8a12d92f6460bc6caa1217cbfadb7799670c3b1c (patch) | |
tree | 7d11b93d4d067ca470e056b469b46fdb662a4273 /plugin/evm/block.go | |
parent | 3b7ebac681f551a9f9931e9d68de402d4cff8c0d (diff) | |
parent | 92fdc0a4b6208387424029182a131b25a2f92dac (diff) |
Merge remote-tracking branch 'origin/dev' into geth-tavum
Diffstat (limited to 'plugin/evm/block.go')
-rw-r--r-- | plugin/evm/block.go | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/plugin/evm/block.go b/plugin/evm/block.go index 98280f0..ff1f6ae 100644 --- a/plugin/evm/block.go +++ b/plugin/evm/block.go @@ -8,6 +8,7 @@ import ( "fmt" "github.com/ava-labs/coreth/core/types" + "github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/rlp" "github.com/ava-labs/avalanchego/ids" @@ -30,7 +31,7 @@ func (b *Block) ID() ids.ID { return b.id } func (b *Block) Accept() error { vm := b.vm - vm.ctx.Log.Verbo("Block %s is accepted", b.id) + log.Trace(fmt.Sprintf("Block %s is accepted", b.ID())) vm.updateStatus(b.id, choices.Accepted) if err := vm.acceptedDB.Put(b.ethBlock.Number().Bytes(), b.id.Bytes()); err != nil { return err @@ -50,7 +51,7 @@ func (b *Block) Accept() error { // Reject implements the snowman.Block interface func (b *Block) Reject() error { - b.vm.ctx.Log.Verbo("Block %s is rejected", b.ID()) + log.Trace(fmt.Sprintf("Block %s is rejected", b.ID())) b.vm.updateStatus(b.ID(), choices.Rejected) return nil } @@ -68,10 +69,8 @@ func (b *Block) Status() choices.Status { func (b *Block) Parent() snowman.Block { parentID := ids.NewID(b.ethBlock.ParentHash()) if block := b.vm.getBlock(parentID); block != nil { - b.vm.ctx.Log.Verbo("Parent(%s) has status: %s", parentID, block.Status()) return block } - b.vm.ctx.Log.Verbo("Parent(%s) has status: %s", parentID, choices.Unknown) return &missing.Block{BlkID: parentID} } |