Merge pull request #389 from filecoin-project/feat/tracing-4

Now! Thats what I call tracing! Vol 4
This commit is contained in:
Jakub Sztandera 2019-10-17 13:25:30 +09:00 committed by GitHub
commit 22b9f15e69
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View File

@ -7,11 +7,10 @@ import (
"fmt"
"sync"
"github.com/filecoin-project/go-lotus/chain/vm"
"github.com/filecoin-project/go-lotus/build"
"github.com/filecoin-project/go-lotus/chain/address"
"github.com/filecoin-project/go-lotus/chain/state"
"github.com/filecoin-project/go-lotus/chain/vm"
"go.opencensus.io/trace"
"go.uber.org/zap"

View File

@ -417,6 +417,9 @@ func (syncer *Syncer) minerIsValid(ctx context.Context, maddr address.Address, b
}
func (syncer *Syncer) validateTickets(ctx context.Context, mworker address.Address, tickets []*types.Ticket, base *types.TipSet) error {
ctx, span := trace.StartSpan(ctx, "validateTickets")
defer span.End()
if len(tickets) == 0 {
return xerrors.Errorf("block had no tickets")
}