From a60aff559c61922ea8cddb639ca424209cc9fa27 Mon Sep 17 00:00:00 2001 From: Jernej Kos Date: Wed, 2 Sep 2020 18:27:55 +0200 Subject: [PATCH] go/consensus/tendermint: Bump Tendermint Core to v0.34-rc4-oasis2 --- .changelog/3229.breaking.md | 6 ++ go/consensus/api/base.go | 7 +- go/consensus/api/grpc.go | 60 +++------------ go/consensus/api/light.go | 24 ++---- go/consensus/tendermint/api/genesis.go | 1 - .../tendermint/apps/staking/staking.go | 3 +- go/consensus/tendermint/full/light.go | 36 +++------ go/consensus/tendermint/full/statesync.go | 56 +++++++------- go/consensus/tendermint/light/client.go | 77 +++++-------------- go/consensus/tendermint/light/light.go | 7 +- go/consensus/tests/tester.go | 13 +--- go/extra/stats/cmd/stats.go | 19 ++--- go/go.mod | 9 +-- go/go.sum | 51 +++++++----- 14 files changed, 137 insertions(+), 232 deletions(-) create mode 100644 .changelog/3229.breaking.md diff --git a/.changelog/3229.breaking.md b/.changelog/3229.breaking.md new file mode 100644 index 00000000000..6843ab72d6f --- /dev/null +++ b/.changelog/3229.breaking.md @@ -0,0 +1,6 @@ +go/consensus: Simplify light client API + +Methods `GetSignedHeader` and `GetValidatorSet` have been replaced with +`GetLightBlock` which provides both the signed header and the validator set. +This makes sense as the two are commonly used together so this saves a +round-trip. diff --git a/go/consensus/api/base.go b/go/consensus/api/base.go index 4a1eb14f40e..698ad0a9b7e 100644 --- a/go/consensus/api/base.go +++ b/go/consensus/api/base.go @@ -185,12 +185,7 @@ func (b *BaseBackend) GetSignerNonce(ctx context.Context, req *GetSignerNonceReq } // Implements Backend. -func (b *BaseBackend) GetSignedHeader(ctx context.Context, height int64) (*SignedHeader, error) { - panic(ErrUnsupported) -} - -// Implements Backend. -func (b *BaseBackend) GetValidatorSet(ctx context.Context, height int64) (*ValidatorSet, error) { +func (b *BaseBackend) GetLightBlock(ctx context.Context, height int64) (*LightBlock, error) { panic(ErrUnsupported) } diff --git a/go/consensus/api/grpc.go b/go/consensus/api/grpc.go index 933ac0b6c58..49c3854abc9 100644 --- a/go/consensus/api/grpc.go +++ b/go/consensus/api/grpc.go @@ -47,10 +47,8 @@ var ( // methodWatchBlocks is the WatchBlocks method. methodWatchBlocks = serviceName.NewMethod("WatchBlocks", nil) - // methodGetSignedHeader is the GetSignedHeader method. - methodGetSignedHeader = lightServiceName.NewMethod("GetSignedHeader", int64(0)) - // methodGetValidatorSet is the GetValidatorSet method. - methodGetValidatorSet = lightServiceName.NewMethod("GetValidatorSet", int64(0)) + // methodGetLightBlock is the GetLightBlock method. + methodGetLightBlock = lightServiceName.NewMethod("GetLightBlock", int64(0)) // methodGetParameters is the GetParameters method. methodGetParameters = lightServiceName.NewMethod("GetParameters", int64(0)) // methodStateSyncGet is the StateSyncGet method. @@ -133,12 +131,8 @@ var ( HandlerType: (*LightClientBackend)(nil), Methods: []grpc.MethodDesc{ { - MethodName: methodGetSignedHeader.ShortName(), - Handler: handlerGetSignedHeader, - }, - { - MethodName: methodGetValidatorSet.ShortName(), - Handler: handlerGetValidatorSet, + MethodName: methodGetLightBlock.ShortName(), + Handler: handlerGetLightBlock, }, { MethodName: methodGetParameters.ShortName(), @@ -460,7 +454,7 @@ func handlerWatchBlocks(srv interface{}, stream grpc.ServerStream) error { } } -func handlerGetSignedHeader( // nolint: golint +func handlerGetLightBlock( // nolint: golint srv interface{}, ctx context.Context, dec func(interface{}) error, @@ -471,37 +465,14 @@ func handlerGetSignedHeader( // nolint: golint return nil, err } if interceptor == nil { - return srv.(LightClientBackend).GetSignedHeader(ctx, height) + return srv.(LightClientBackend).GetLightBlock(ctx, height) } info := &grpc.UnaryServerInfo{ Server: srv, - FullMethod: methodGetSignedHeader.FullName(), + FullMethod: methodGetLightBlock.FullName(), } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(LightClientBackend).GetSignedHeader(ctx, req.(int64)) - } - return interceptor(ctx, height, info, handler) -} - -func handlerGetValidatorSet( // nolint: golint - srv interface{}, - ctx context.Context, - dec func(interface{}) error, - interceptor grpc.UnaryServerInterceptor, -) (interface{}, error) { - var height int64 - if err := dec(&height); err != nil { - return nil, err - } - if interceptor == nil { - return srv.(LightClientBackend).GetValidatorSet(ctx, height) - } - info := &grpc.UnaryServerInfo{ - Server: srv, - FullMethod: methodGetValidatorSet.FullName(), - } - handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(LightClientBackend).GetValidatorSet(ctx, req.(int64)) + return srv.(LightClientBackend).GetLightBlock(ctx, req.(int64)) } return interceptor(ctx, height, info, handler) } @@ -660,18 +631,9 @@ type consensusLightClient struct { } // Implements LightClientBackend. -func (c *consensusLightClient) GetSignedHeader(ctx context.Context, height int64) (*SignedHeader, error) { - var rsp SignedHeader - if err := c.conn.Invoke(ctx, methodGetSignedHeader.FullName(), height, &rsp); err != nil { - return nil, err - } - return &rsp, nil -} - -// Implements LightClientBackend. -func (c *consensusLightClient) GetValidatorSet(ctx context.Context, height int64) (*ValidatorSet, error) { - var rsp ValidatorSet - if err := c.conn.Invoke(ctx, methodGetValidatorSet.FullName(), height, &rsp); err != nil { +func (c *consensusLightClient) GetLightBlock(ctx context.Context, height int64) (*LightBlock, error) { + var rsp LightBlock + if err := c.conn.Invoke(ctx, methodGetLightBlock.FullName(), height, &rsp); err != nil { return nil, err } return &rsp, nil diff --git a/go/consensus/api/light.go b/go/consensus/api/light.go index 52aa1ec7409..02388fd1312 100644 --- a/go/consensus/api/light.go +++ b/go/consensus/api/light.go @@ -9,11 +9,9 @@ import ( // LightClientBackend is the limited consensus interface used by light clients. type LightClientBackend interface { - // GetSignedHeader returns the signed header for a specific height. - GetSignedHeader(ctx context.Context, height int64) (*SignedHeader, error) - - // GetValidatorSet returns the validator set for a specific height. - GetValidatorSet(ctx context.Context, height int64) (*ValidatorSet, error) + // GetLightBlock returns a light version of the consensus layer block that can be used for light + // client verification. + GetLightBlock(ctx context.Context, height int64) (*LightBlock, error) // GetParameters returns the consensus parameters for a specific height. GetParameters(ctx context.Context, height int64) (*Parameters, error) @@ -30,19 +28,11 @@ type LightClientBackend interface { SubmitEvidence(ctx context.Context, evidence *Evidence) error } -// SignedHeader is a signed consensus block header. -type SignedHeader struct { - // Height contains the block height this header is for. - Height int64 `json:"height"` - // Meta contains the consensus backend specific signed header. - Meta []byte `json:"meta"` -} - -// ValidatorSet contains the validator set information. -type ValidatorSet struct { - // Height contains the block height this validator set is for. +// LightBlock is a light consensus block suitable for syncing light clients. +type LightBlock struct { + // Height contains the block height. Height int64 `json:"height"` - // Meta contains the consensus backend specific validator set. + // Meta contains the consensus backend specific light block. Meta []byte `json:"meta"` } diff --git a/go/consensus/tendermint/api/genesis.go b/go/consensus/tendermint/api/genesis.go index 4435d3ab61e..f58b813fdf6 100644 --- a/go/consensus/tendermint/api/genesis.go +++ b/go/consensus/tendermint/api/genesis.go @@ -95,7 +95,6 @@ func genesisToTendermint(d *genesis.Document) (*tmtypes.GenesisDoc, error) { evCfg.MaxNum = d.Consensus.Parameters.MaxEvidenceNum evCfg.MaxAgeNumBlocks = debondingInterval * epochInterval evCfg.MaxAgeDuration = time.Duration(evCfg.MaxAgeNumBlocks) * (d.Consensus.Parameters.TimeoutCommit + 1*time.Second) - evCfg.ProofTrialPeriod = evCfg.MaxAgeNumBlocks / 2 doc := tmtypes.GenesisDoc{ ChainID: d.ChainContext()[:tmtypes.MaxChainIDLen], diff --git a/go/consensus/tendermint/apps/staking/staking.go b/go/consensus/tendermint/apps/staking/staking.go index 3498eadaa68..f8383ea3195 100644 --- a/go/consensus/tendermint/apps/staking/staking.go +++ b/go/consensus/tendermint/apps/staking/staking.go @@ -5,7 +5,6 @@ import ( "fmt" "github.com/tendermint/tendermint/abci/types" - tmtypes "github.com/tendermint/tendermint/types" "github.com/oasisprotocol/oasis-core/go/common/cbor" "github.com/oasisprotocol/oasis-core/go/common/quantity" @@ -85,7 +84,7 @@ func (app *stakingApplication) BeginBlock(ctx *api.Context, request types.Reques // the actual evidence has already been verified by Tendermint to be valid. for _, evidence := range request.ByzantineValidators { switch evidence.Type { - case tmtypes.ABCIEvidenceTypeDuplicateVote: + case types.EvidenceType_DUPLICATE_VOTE: if err := onEvidenceDoubleSign(ctx, evidence.Validator.Address, evidence.Height, evidence.Time, evidence.Validator.Power); err != nil { return err } diff --git a/go/consensus/tendermint/full/light.go b/go/consensus/tendermint/full/light.go index 6261545a9b5..d095cd4724b 100644 --- a/go/consensus/tendermint/full/light.go +++ b/go/consensus/tendermint/full/light.go @@ -5,6 +5,7 @@ import ( "fmt" tmstate "github.com/tendermint/tendermint/state" + tmtypes "github.com/tendermint/tendermint/types" "github.com/oasisprotocol/oasis-core/go/common/cbor" consensusAPI "github.com/oasisprotocol/oasis-core/go/consensus/api" @@ -13,7 +14,7 @@ import ( ) // Implements LightClientBackend. -func (t *fullService) GetSignedHeader(ctx context.Context, height int64) (*consensusAPI.SignedHeader, error) { +func (t *fullService) GetLightBlock(ctx context.Context, height int64) (*consensusAPI.LightBlock, error) { if err := t.ensureStarted(ctx); err != nil { return nil, err } @@ -27,40 +28,27 @@ func (t *fullService) GetSignedHeader(ctx context.Context, height int64) (*conse return nil, fmt.Errorf("tendermint: header is nil") } - meta, err := commit.SignedHeader.ToProto().Marshal() - if err != nil { - return nil, fmt.Errorf("tendermint: failed to marshal signed header: %w", err) - } - - return &consensusAPI.SignedHeader{ - Height: commit.Header.Height, - Meta: meta, - }, nil -} - -// Implements LightClientBackend. -func (t *fullService) GetValidatorSet(ctx context.Context, height int64) (*consensusAPI.ValidatorSet, error) { - if err := t.ensureStarted(ctx); err != nil { - return nil, err - } - // Don't use the client as that imposes stupid pagination. Access the state database directly. vals, err := tmstate.LoadValidators(t.stateDb, height) if err != nil { return nil, consensusAPI.ErrVersionNotFound } - protoVals, err := vals.ToProto() + lb := tmtypes.LightBlock{ + SignedHeader: &commit.SignedHeader, + ValidatorSet: vals, + } + protoLb, err := lb.ToProto() if err != nil { - return nil, fmt.Errorf("tendermint: failed to convert validators: %w", err) + return nil, fmt.Errorf("tendermint: failed to convert light block: %w", err) } - meta, err := protoVals.Marshal() + meta, err := protoLb.Marshal() if err != nil { - return nil, fmt.Errorf("tendermint: failed to marshal validators: %w", err) + return nil, fmt.Errorf("tendermint: failed to marshal light block: %w", err) } - return &consensusAPI.ValidatorSet{ - Height: height, + return &consensusAPI.LightBlock{ + Height: commit.Header.Height, Meta: meta, }, nil } diff --git a/go/consensus/tendermint/full/statesync.go b/go/consensus/tendermint/full/statesync.go index 7d5507330f6..c680541a5c5 100644 --- a/go/consensus/tendermint/full/statesync.go +++ b/go/consensus/tendermint/full/statesync.go @@ -30,11 +30,11 @@ func (sp *stateProvider) AppHash(height uint64) ([]byte, error) { defer sp.Unlock() // We have to fetch the next height, which contains the app hash for the previous height. - header, err := sp.lc.GetVerifiedSignedHeader(sp.ctx, int64(height+1)) + lb, err := sp.lc.GetVerifiedLightBlock(sp.ctx, int64(height+1)) if err != nil { return nil, err } - return header.AppHash, nil + return lb.AppHash, nil } // Implements tmstatesync.StateProvider. @@ -42,11 +42,11 @@ func (sp *stateProvider) Commit(height uint64) (*tmtypes.Commit, error) { sp.Lock() defer sp.Unlock() - header, err := sp.lc.GetVerifiedSignedHeader(sp.ctx, int64(height)) + lb, err := sp.lc.GetVerifiedLightBlock(sp.ctx, int64(height)) if err != nil { return nil, err } - return header.Commit, nil + return lb.Commit, nil } // Implements tmstatesync.StateProvider. @@ -62,45 +62,41 @@ func (sp *stateProvider) State(height uint64) (tmstate.State, error) { // XXX: This will fail in case an upgrade happened in-between. state.Version.Consensus.App = version.ConsensusProtocol.ToU64() - // We need to verify up until h+2, to get the validator set. This also prefetches the headers - // for h and h+1 in the typical case where the trusted header is after the snapshot height. - _, err := sp.lc.GetVerifiedSignedHeader(sp.ctx, int64(height+2)) + // The snapshot height maps onto the state heights as follows: + // + // height: last block, i.e. the snapshotted height + // height+1: current block, i.e. the first block we'll process after the snapshot + // height+2: next block, i.e. the second block after the snapshot + // + // We need to fetch the NextValidators from height+2 because if the application changed + // the validator set at the snapshot height then this only takes effect at height+2. + lastLightBlock, err := sp.lc.GetVerifiedLightBlock(sp.ctx, int64(height)) if err != nil { return tmstate.State{}, err } - header, err := sp.lc.GetVerifiedSignedHeader(sp.ctx, int64(height)) + curLightBlock, err := sp.lc.GetVerifiedLightBlock(sp.ctx, int64(height)+1) if err != nil { return tmstate.State{}, err } - nextHeader, err := sp.lc.GetVerifiedSignedHeader(sp.ctx, int64(height+1)) + nextLightBlock, err := sp.lc.GetVerifiedLightBlock(sp.ctx, int64(height)+2) if err != nil { return tmstate.State{}, err } - state.LastBlockHeight = header.Height - state.LastBlockTime = header.Time - state.LastBlockID = header.Commit.BlockID - state.AppHash = nextHeader.AppHash - state.LastResultsHash = nextHeader.LastResultsHash - - state.LastValidators, _, err = sp.lc.GetVerifiedValidatorSet(sp.ctx, int64(height)) - if err != nil { - return tmstate.State{}, err - } - state.Validators, _, err = sp.lc.GetVerifiedValidatorSet(sp.ctx, int64(height+1)) - if err != nil { - return tmstate.State{}, err - } - state.NextValidators, _, err = sp.lc.GetVerifiedValidatorSet(sp.ctx, int64(height+2)) - if err != nil { - return tmstate.State{}, err - } - state.LastHeightValidatorsChanged = int64(height) + state.LastBlockHeight = lastLightBlock.Height + state.LastBlockTime = lastLightBlock.Time + state.LastBlockID = lastLightBlock.Commit.BlockID + state.AppHash = curLightBlock.AppHash + state.LastResultsHash = curLightBlock.LastResultsHash + state.LastValidators = lastLightBlock.ValidatorSet + state.Validators = curLightBlock.ValidatorSet + state.NextValidators = nextLightBlock.ValidatorSet + state.LastHeightValidatorsChanged = nextLightBlock.Height // Fetch consensus parameters with light client verification. - params, err := sp.lc.GetVerifiedParameters(sp.ctx, nextHeader.Height) + params, err := sp.lc.GetVerifiedParameters(sp.ctx, nextLightBlock.Height) if err != nil { return tmstate.State{}, fmt.Errorf("failed to fetch consensus parameters for height %d: %w", - nextHeader.Height, + nextLightBlock.Height, err, ) } diff --git a/go/consensus/tendermint/light/client.go b/go/consensus/tendermint/light/client.go index c4b9e4f254f..994ff97c345 100644 --- a/go/consensus/tendermint/light/client.go +++ b/go/consensus/tendermint/light/client.go @@ -56,58 +56,30 @@ func (lp *lightClientProvider) ChainID() string { } // Implements tmlightprovider.Provider. -func (lp *lightClientProvider) SignedHeader(height int64) (*tmtypes.SignedHeader, error) { - shdr, err := lp.client.GetSignedHeader(lp.ctx, height) +func (lp *lightClientProvider) LightBlock(height int64) (*tmtypes.LightBlock, error) { + lb, err := lp.client.GetLightBlock(lp.ctx, height) switch { case err == nil: case errors.Is(err, consensus.ErrVersionNotFound): - return nil, tmlightprovider.ErrSignedHeaderNotFound + return nil, tmlightprovider.ErrLightBlockNotFound default: - return nil, fmt.Errorf("failed to fetch signed header: %w", err) + return nil, tmlightprovider.ErrNoResponse } - // Decode Tendermint-specific signed header. - var protoSigHdr tmproto.SignedHeader - if err = protoSigHdr.Unmarshal(shdr.Meta); err != nil { - return nil, fmt.Errorf("received malformed header: %w", err) + // Decode Tendermint-specific light block. + var protoLb tmproto.LightBlock + if err = protoLb.Unmarshal(lb.Meta); err != nil { + return nil, tmlightprovider.ErrBadLightBlock{Reason: err} } - sh, err := tmtypes.SignedHeaderFromProto(&protoSigHdr) + tlb, err := tmtypes.LightBlockFromProto(&protoLb) if err != nil { - return nil, fmt.Errorf("received malformed header: %w", err) + return nil, tmlightprovider.ErrBadLightBlock{Reason: err} } - - if lp.chainID != sh.ChainID { - return nil, fmt.Errorf("incorrect chain ID (expected: %s got: %s)", - lp.chainID, - sh.ChainID, - ) - } - - return sh, nil -} - -// Implements tmlightprovider.Provider. -func (lp *lightClientProvider) ValidatorSet(height int64) (*tmtypes.ValidatorSet, error) { - vs, err := lp.client.GetValidatorSet(lp.ctx, height) - switch { - case err == nil: - case errors.Is(err, consensus.ErrVersionNotFound): - return nil, tmlightprovider.ErrValidatorSetNotFound - default: - return nil, fmt.Errorf("failed to fetch validator set: %w", err) - } - - // Decode Tendermint-specific validator set. - var protoVals tmproto.ValidatorSet - if err = protoVals.Unmarshal(vs.Meta); err != nil { - return nil, fmt.Errorf("received malformed validator set: %w", err) - } - vals, err := tmtypes.ValidatorSetFromProto(&protoVals) - if err != nil { - return nil, fmt.Errorf("received malformed validator set: %w", err) + if err = tlb.ValidateBasic(lp.chainID); err != nil { + return nil, tmlightprovider.ErrBadLightBlock{Reason: err} } - return vals, nil + return tlb, nil } // Implements tmlightprovider.Provider. @@ -162,13 +134,8 @@ type lightClient struct { } // Implements consensus.LightClientBackend. -func (lc *lightClient) GetSignedHeader(ctx context.Context, height int64) (*consensus.SignedHeader, error) { - return lc.getPrimary().GetSignedHeader(ctx, height) -} - -// Implements consensus.LightClientBackend. -func (lc *lightClient) GetValidatorSet(ctx context.Context, height int64) (*consensus.ValidatorSet, error) { - return lc.getPrimary().GetValidatorSet(ctx, height) +func (lc *lightClient) GetLightBlock(ctx context.Context, height int64) (*consensus.LightBlock, error) { + return lc.getPrimary().GetLightBlock(ctx, height) } // Implements consensus.LightClientBackend. @@ -192,12 +159,8 @@ func (lc *lightClient) SubmitEvidence(ctx context.Context, evidence *consensus.E } // Implements Client. -func (lc *lightClient) GetVerifiedSignedHeader(ctx context.Context, height int64) (*tmtypes.SignedHeader, error) { - return lc.tmc.VerifyHeaderAtHeight(height, time.Now()) -} - -func (lc *lightClient) GetVerifiedValidatorSet(ctx context.Context, height int64) (*tmtypes.ValidatorSet, int64, error) { - return lc.tmc.TrustedValidatorSet(height) +func (lc *lightClient) GetVerifiedLightBlock(ctx context.Context, height int64) (*tmtypes.LightBlock, error) { + return lc.tmc.VerifyLightBlockAtHeight(height, time.Now()) } // Implements Client. @@ -220,15 +183,15 @@ func (lc *lightClient) GetVerifiedParameters(ctx context.Context, height int64) } // Fetch the header from the light client. - h, err := lc.tmc.VerifyHeaderAtHeight(p.Height, time.Now()) + l, err := lc.tmc.VerifyLightBlockAtHeight(p.Height, time.Now()) if err != nil { return nil, fmt.Errorf("failed to fetch header %d from light client: %w", p.Height, err) } // Verify hash. - if localHash := tmtypes.HashConsensusParams(params); !bytes.Equal(localHash, h.ConsensusHash) { + if localHash := tmtypes.HashConsensusParams(params); !bytes.Equal(localHash, l.ConsensusHash) { return nil, fmt.Errorf("mismatched parameters hash (expected: %X got: %X)", - h.ConsensusHash, + l.ConsensusHash, localHash, ) } diff --git a/go/consensus/tendermint/light/light.go b/go/consensus/tendermint/light/light.go index f31f381b2d7..2bf4f17334b 100644 --- a/go/consensus/tendermint/light/light.go +++ b/go/consensus/tendermint/light/light.go @@ -15,11 +15,8 @@ import ( type Client interface { consensus.LightClientBackend - // GetVerifiedSignedHeader returns a verified signed header. - GetVerifiedSignedHeader(ctx context.Context, height int64) (*tmtypes.SignedHeader, error) - - // GetVerifiedValidatorSet returns a verified validator set. - GetVerifiedValidatorSet(ctx context.Context, height int64) (*tmtypes.ValidatorSet, int64, error) + // GetVerifiedLightBlock returns a verified light block. + GetVerifiedLightBlock(ctx context.Context, height int64) (*tmtypes.LightBlock, error) // GetVerifiedParameters returns verified consensus parameters. GetVerifiedParameters(ctx context.Context, height int64) (*tmproto.ConsensusParams, error) diff --git a/go/consensus/tests/tester.go b/go/consensus/tests/tester.go index f56070377c0..03e760840e8 100644 --- a/go/consensus/tests/tester.go +++ b/go/consensus/tests/tester.go @@ -108,15 +108,10 @@ func ConsensusImplementationTests(t *testing.T, backend consensus.ClientBackend) require.Equal(uint64(0), nonce, "Nonce should be zero") // Light client API. - shdr, err := backend.GetSignedHeader(ctx, blk.Height) - require.NoError(err, "GetSignedHeader") - require.Equal(shdr.Height, blk.Height, "returned header height should be correct") - require.NotNil(shdr.Meta, "returned header should contain metadata") - - vals, err := backend.GetValidatorSet(ctx, blk.Height) - require.NoError(err, "GetValidatorSet") - require.Equal(vals.Height, blk.Height, "returned validator set height should be correct") - require.NotNil(vals.Meta, "returned validator set should contain metadata") + shdr, err := backend.GetLightBlock(ctx, blk.Height) + require.NoError(err, "GetLightBlock") + require.Equal(shdr.Height, blk.Height, "returned light block height should be correct") + require.NotNil(shdr.Meta, "returned light block should contain metadata") params, err := backend.GetParameters(ctx, blk.Height) require.NoError(err, "GetParameters") diff --git a/go/extra/stats/cmd/stats.go b/go/extra/stats/cmd/stats.go index 1e1d0248741..a659f97874d 100644 --- a/go/extra/stats/cmd/stats.go +++ b/go/extra/stats/cmd/stats.go @@ -294,27 +294,27 @@ func getStats(ctx context.Context, consensus consensusAPI.ClientBackend, registr // Get validators. // Hypothesis: this gets the validator set with priorities after they're incremented to get the round 0 // proposer. - vs, err := consensus.GetValidatorSet(ctx, lastCommitHeight) + lb, err := consensus.GetLightBlock(ctx, lastCommitHeight) if err != nil { - logger.Error("failed to query validators", + logger.Error("failed to query light block", "err", err, "height", lastCommitHeight, ) os.Exit(1) } - var protoVals tmproto.ValidatorSet - if err = protoVals.Unmarshal(vs.Meta); err != nil { - logger.Error("unmarshal validator set error", - "meta", vs.Meta, + var protoLb tmproto.LightBlock + if err = protoLb.Unmarshal(lb.Meta); err != nil { + logger.Error("unmarshal light block error", + "meta", lb.Meta, "err", err, "height", lastCommitHeight, ) os.Exit(1) } - vals, err := tmtypes.ValidatorSetFromProto(&protoVals) + tlb, err := tmtypes.LightBlockFromProto(&protoLb) if err != nil { - logger.Error("unmarshal validator set error", - "meta", vs.Meta, + logger.Error("unmarshal light block error", + "meta", lb.Meta, "err", err, "height", lastCommitHeight, ) @@ -322,6 +322,7 @@ func getStats(ctx context.Context, consensus consensusAPI.ClientBackend, registr } // Go over all validators. + vals := tlb.ValidatorSet for _, val := range vals.Validators { stats.nodeStatsOrExit(ctx, registry, lastCommitHeight, val.Address.String()).elections++ } diff --git a/go/go.mod b/go/go.mod index 951ce1fc3ae..6955860f8c2 100644 --- a/go/go.mod +++ b/go/go.mod @@ -7,7 +7,7 @@ replace ( // https://github.com/spf13/cobra/issues/1091 github.com/gorilla/websocket => github.com/gorilla/websocket v1.4.2 - github.com/tendermint/tendermint => github.com/oasisprotocol/tendermint v0.34.0-rc4-oasis1 + github.com/tendermint/tendermint => github.com/oasisprotocol/tendermint v0.34.0-rc4-oasis2 golang.org/x/crypto/curve25519 => github.com/oasisprotocol/ed25519/extra/x25519 v0.0.0-20200819094954-65138ca6ec7c golang.org/x/crypto/ed25519 => github.com/oasisprotocol/ed25519 v0.0.0-20200819094954-65138ca6ec7c ) @@ -48,17 +48,16 @@ require ( github.com/spf13/viper v1.7.1 github.com/stretchr/testify v1.6.1 github.com/tendermint/tendermint v0.33.6 - github.com/tendermint/tm-db v0.6.0 + github.com/tendermint/tm-db v0.6.2 github.com/thepudds/fzgo v0.2.2 github.com/uber/jaeger-client-go v2.25.0+incompatible github.com/uber/jaeger-lib v2.2.0+incompatible // indirect github.com/whyrusleeping/go-logging v0.0.1 gitlab.com/yawning/dynlib.git v0.0.0-20200603163025-35fe007b0761 golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899 - golang.org/x/net v0.0.0-20200602114024-627f9648deb9 - golang.org/x/sys v0.0.0-20200722175500-76b94024e4b6 // indirect + golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a - google.golang.org/grpc v1.31.0 + google.golang.org/grpc v1.31.1 google.golang.org/grpc/examples v0.0.0-20200625174016-7a808837ae92 // indirect google.golang.org/grpc/security/advancedtls v0.0.0-20200504170109-c8482678eb49 google.golang.org/protobuf v1.23.0 diff --git a/go/go.sum b/go/go.sum index 5b8778ca1fa..98dccc0bd31 100644 --- a/go/go.sum +++ b/go/go.sum @@ -142,6 +142,7 @@ github.com/davidlazar/go-crypto v0.0.0-20170701192655-dcfb0a7ac018 h1:6xT9KW8zLC github.com/davidlazar/go-crypto v0.0.0-20170701192655-dcfb0a7ac018/go.mod h1:rQYf4tfk5sSwFsnDg3qYaBxSjsD9S8+59vW0dKUgme4= github.com/dgraph-io/badger v1.6.1 h1:w9pSFNSdq/JPM1N12Fz/F/bzo993Is1W+Q7HjPzi7yg= github.com/dgraph-io/badger v1.6.1/go.mod h1:FRmFw3uxvcpa8zG3Rxs0th+hCLIuaQg8HlNV5bjgnuU= +github.com/dgraph-io/badger/v2 v2.2007.1/go.mod h1:26P/7fbL4kUZVEVKLAKXkBXKOydDmM2p1e+NhhnBCAE= github.com/dgraph-io/badger/v2 v2.2007.2 h1:EjjK0KqwaFMlPin1ajhP943VPENHJdEz1KLIegjaI3k= github.com/dgraph-io/badger/v2 v2.2007.2/go.mod h1:26P/7fbL4kUZVEVKLAKXkBXKOydDmM2p1e+NhhnBCAE= github.com/dgraph-io/ristretto v0.0.2 h1:a5WaUrDa0qm0YrAAS1tUykT5El3kt62KNZZeMxQn3po= @@ -182,6 +183,8 @@ github.com/franela/goblin v0.0.0-20200105215937-c9ffbefa60db/go.mod h1:7dvUGVsVB github.com/franela/goreq v0.0.0-20171204163338-bcd34c9993f8/go.mod h1:ZhphrRTfi2rbfLwlschooIH4+wKKDR4Pdxhh+TRoA20= github.com/fsnotify/fsnotify v1.4.7 h1:IXs+QLmnXW2CcXuY+8Mzv/fWEsPGWxqefPtCP5CnV9I= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= +github.com/fsnotify/fsnotify v1.4.9 h1:hsms1Qyu0jgnwNXIxa+/V/PDsU6CfLf6CNO8H7IWoS4= +github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fxamacker/cbor/v2 v2.2.1-0.20200820021930-bafca87fa6db h1:JCjUE9xYakEXU8BtIZ2T6z10RJBgYZCC3q9lZhAaTms= github.com/fxamacker/cbor/v2 v2.2.1-0.20200820021930-bafca87fa6db/go.mod h1:TA1xS00nchWmaBnEIxPSE5oHLuJBAVvqrtAnWBwBCVo= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= @@ -634,14 +637,16 @@ github.com/nats-io/nats.go v1.9.1/go.mod h1:ZjDU1L/7fJ09jvUSRVBR2e7+RnLiiIQyqyzE github.com/nats-io/nkeys v0.1.0/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= github.com/nats-io/nkeys v0.1.3/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= github.com/nats-io/nuid v1.0.1/go.mod h1:19wcPz3Ph3q0Jbyiqsd0kePYG7A95tJPxeL+1OSON2c= +github.com/nxadm/tail v1.4.4 h1:DQuhQpB1tVlglWS2hLQ5OV6B5r8aGxSrPc5Qo6uTN78= +github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/oasisprotocol/deoxysii v0.0.0-20200527154044-851aec403956 h1:etZXZf8f2xLJFivW4tTg87nSV3KLszQ7oYot3UNcmF0= github.com/oasisprotocol/deoxysii v0.0.0-20200527154044-851aec403956/go.mod h1:cE5EgXTIhq5oAVdZ7LZd1FjTRLALPEzv93CWzBtDkyI= github.com/oasisprotocol/ed25519 v0.0.0-20200528083105-55566edd6df0 h1:qmiMZ6ZhkeQZkV/Huajj+QBAu1jX0HTGsOwi+eXTGY8= github.com/oasisprotocol/ed25519 v0.0.0-20200528083105-55566edd6df0/go.mod h1:IZbb50w3AB72BVobEF6qG93NNSrTw/V2QlboxqSu3Xw= github.com/oasisprotocol/safeopen v0.0.0-20200528085122-e01cfdfc7661 h1:MB73kGMtuMGS+6VDoU/mitzff7Cu+aZo9ta5wabuxVA= github.com/oasisprotocol/safeopen v0.0.0-20200528085122-e01cfdfc7661/go.mod h1:SwBxaVibf6Sr2IZ6M3WnUue0yp8dPLAo1riQRNQ60+g= -github.com/oasisprotocol/tendermint v0.34.0-rc4-oasis1 h1:9y1VeFaaE/Q4JEjgGVnBAYqky2XPnSSp/AS6iKFqdPM= -github.com/oasisprotocol/tendermint v0.34.0-rc4-oasis1/go.mod h1:pgZ5jfG7ZZ6p/9YLuJEG/k1OHIHfxPg7w4PU3VUbGiQ= +github.com/oasisprotocol/tendermint v0.34.0-rc4-oasis2 h1:XulmWXzRa4+PdjxflrBdNLhE5iz083uCcKLk7gs1Szk= +github.com/oasisprotocol/tendermint v0.34.0-rc4-oasis2/go.mod h1:WHUWHLnMu2AjW40QBlV2W3w2fi14gomdJDU7y+xqJPw= github.com/oklog/oklog v0.3.2/go.mod h1:FCV+B7mhrz4o+ueLpx+KqkyXRGMWOYEvfiXtdGtbWGs= github.com/oklog/run v1.0.0 h1:Ru7dDtJNOyC66gQ5dQmaCa0qIsAUFY3sFpK1Xk8igrw= github.com/oklog/run v1.0.0/go.mod h1:dlhp/R75TPv97u0XWUtDeV/lRKWPKSdTuV0TZvrmrQA= @@ -651,10 +656,15 @@ github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+W github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.0 h1:Iw5WCbBcaAAd0fpRb1c9r5YCylv4XDoCSigm1zLevwU= github.com/onsi/ginkgo v1.12.0/go.mod h1:oUhWkIvk5aDxtKvDDuw8gItl8pKl42LzjC9KZE0HfGg= +github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= +github.com/onsi/ginkgo v1.14.0 h1:2mOpI4JVVPBN+WQRa0WKH2eXR+Ey+uK4n7Zj0aYpIQA= +github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.9.0 h1:R1uwffexN6Pr340GtYRIdZmAiN4J+iw6WG4wog1DUXg= github.com/onsi/gomega v1.9.0/go.mod h1:Ho0h+IUsWyvy1OpqCwxlQ/21gkhVunqlU8fDGcoTdcA= +github.com/onsi/gomega v1.10.1 h1:o0+MgICZLuZ7xjH7Vx6zS/zcu93/BEp1VwkIW1mEXCE= +github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= github.com/opentracing-contrib/go-observer v0.0.0-20170622124052-a52f23424492/go.mod h1:Ngi6UdF0k5OKD5t5wlmGhe/EDKPoUM3BXZSSfIuJbis= github.com/opentracing/basictracer-go v1.0.0/go.mod h1:QfBfYuafItcjQuMwinw9GhYKwFXS9KnPs5lxoYwgW74= @@ -799,12 +809,12 @@ github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/ github.com/subosito/gotenv v1.2.0 h1:Slr1R9HxAlEKefgq5jn9U+DnETlIUa6HfgEzj0g5d7s= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= github.com/syndtr/goleveldb v1.0.0/go.mod h1:ZVVdQEZoIme9iO1Ch2Jdy24qqXrMMOU6lpPAyBWyWuQ= -github.com/syndtr/goleveldb v1.0.1-0.20190923125748-758128399b1d h1:gZZadD8H+fF+n9CmNhYL1Y0dJB+kLOmKd7FbPJLeGHs= -github.com/syndtr/goleveldb v1.0.1-0.20190923125748-758128399b1d/go.mod h1:9OrXJhf154huy1nPWmuSrkgjPUtUNhA+Zmy+6AESzuA= +github.com/syndtr/goleveldb v1.0.1-0.20200815110645-5c35d600f0ca h1:Ld/zXl5t4+D69SiV4JoN7kkfvJdOWlPpfxrzxpLMoUk= +github.com/syndtr/goleveldb v1.0.1-0.20200815110645-5c35d600f0ca/go.mod h1:u2MKkTVTVJWe5D1rCvame8WqhBd88EuIwODJZ1VHCPM= github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c h1:g+WoO5jjkqGAzHWCjJB1zZfXPIAaDpzXIEJ0eS6B5Ok= github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c/go.mod h1:ahpPrc7HpcfEWDQRZEmnXMzHY03mLDYMCxeDzy46i+8= -github.com/tendermint/tm-db v0.6.0 h1:Us30k7H1UDcdqoSPhmP8ztAW/SWV6c6OfsfeCiboTC4= -github.com/tendermint/tm-db v0.6.0/go.mod h1:xj3AWJ08kBDlCHKijnhJ7mTcDMOikT1r8Poxy2pJn7Q= +github.com/tendermint/tm-db v0.6.2 h1:DOn8jwCdjJblrCFJbtonEIPD1IuJWpbRUUdR8GWE4RM= +github.com/tendermint/tm-db v0.6.2/go.mod h1:GYtQ67SUvATOcoY8/+x6ylk8Qo02BQyLrAs+yAcLvGI= github.com/thepudds/fzgo v0.2.2 h1:bGofmgAGfTLpVgETkL9jvhg6azylvCF/kW6JPy5fkzQ= github.com/thepudds/fzgo v0.2.2/go.mod h1:ZgigL1toyKrar3rWdXz7Fuv7bUpKZ4BAYN49TpEFMCI= github.com/tinylib/msgp v1.1.0 h1:9fQd+ICuRIu/ue4vxJZu6/LzxN0HwMds2nq/0cFvxHU= @@ -897,8 +907,7 @@ golang.org/x/crypto v0.0.0-20191119213627-4f8c1d86b1ba/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20191206172530-e9b2fee46413 h1:ULYEB3JvPRE/IfO+9uO7vKV/xzVTO7XPAwm8xbf4w2g= golang.org/x/crypto v0.0.0-20191206172530-e9b2fee46413/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200115085410-6d4e4cb37c7d/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20200406173513-056763e48d71 h1:DOmugCavvUtnUD114C1Wh+UgTgQZ4pMLzXxi1pSt+/Y= -golang.org/x/crypto v0.0.0-20200406173513-056763e48d71/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899 h1:DZhuSZLsGlFL4CmhA8BcRA0mnthyA/nZ00AqCUo7vHg= golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= @@ -945,10 +954,9 @@ golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLL golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7 h1:fHDIZ2oxGnUZRN6WgWFCbYBjH9uqVPRCUVUDhs0wnbA= golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190923162816-aa69164e4478/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e h1:3G+cUijn7XD+S4eJFddp53Pv7+slrESplyjG25HgL+k= -golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= -golang.org/x/net v0.0.0-20200602114024-627f9648deb9 h1:pNX+40auqi2JqRfOP1akLGtYcn15TUbkhwuCO3foqqM= -golang.org/x/net v0.0.0-20200602114024-627f9648deb9/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= +golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= +golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc h1:zK/HqS5bZxDptfPJNq8v7vJfXtkU7r9TLIoSr1bXaP4= +golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -990,7 +998,9 @@ golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190804053845-51ab0e2deafa/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190924154521-2837fb4f24fe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191008105621-543471e840be/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191220142924-d4481acd189f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -998,14 +1008,17 @@ golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd h1:xhmwyvizuTgC2qz7ZlMluP20uW+C3Rm0FD/WLDX8884= golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1 h1:ogLJMz+qpzav7lGMh10LMvAkM/fAoGlaiiHYiFYdm80= golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200722175500-76b94024e4b6 h1:X9xIZ1YU8bLZA3l6gqDUHSFiD0GFI9S548h6C8nDtOY= -golang.org/x/sys v0.0.0-20200722175500-76b94024e4b6/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200814200057-3d37ad5750ed h1:J22ig1FUekjjkmZUM7pTKixYm8DvrYsvrBZdunYeIuQ= +golang.org/x/sys v0.0.0-20200814200057-3d37ad5750ed/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2 h1:tW2bmiBqwgJj/UpqtC8EpXEZVYOwU0yG4iWbprSVAcs= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= +golang.org/x/text v0.3.3 h1:cokOdA+Jmi5PJGXLlLllQSgYigAEfHXJAERHVMaCc2k= +golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/time v0.0.0-20180412165947-fbb02b2291d2/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= @@ -1043,6 +1056,8 @@ golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IV golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 h1:go1bK/D/BFZV2I8cIQd1NKEZ+0owSTG1fDTci4IqFcE= +golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= google.golang.org/api v0.3.1/go.mod h1:6wY9I6uQWHQ8EM57III9mq/AjF+i8G65rmVagqKMtkk= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= @@ -1084,10 +1099,8 @@ google.golang.org/grpc v1.27.0 h1:rRYRFMVgRv6E0D70Skyfsr28tDXIuuPZyWGMPdMcnXg= google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= google.golang.org/grpc v1.30.0-dev.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= -google.golang.org/grpc v1.30.0 h1:M5a8xTlYTxwMn5ZFkwhRabsygDY5G8TYLyQDBxJNAxE= -google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= -google.golang.org/grpc v1.31.0 h1:T7P4R73V3SSDPhH7WW7ATbfViLtmamH0DKrP3f9AuDI= -google.golang.org/grpc v1.31.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= +google.golang.org/grpc v1.31.1 h1:SfXqXS5hkufcdZ/mHtYCh53P2b+92WQq/DZcKLgsFRs= +google.golang.org/grpc v1.31.1/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= google.golang.org/grpc/examples v0.0.0-20200625174016-7a808837ae92 h1:zJsIxBOIY4bVTZS2uOJ35AcnayXX3alhJEsejLWezh0= google.golang.org/grpc/examples v0.0.0-20200625174016-7a808837ae92/go.mod h1:wwLo5XaKQhinfnT+PqwJ17u2NXm7cllRQ4fKKyB22+w= google.golang.org/grpc/security/advancedtls v0.0.0-20200504170109-c8482678eb49 h1:0JUa0KgbivB+hPBKMrS/PEPhlzyH2gya70HZFd3Bi6E= @@ -1127,6 +1140,8 @@ gopkg.in/yaml.v2 v2.2.4 h1:/eiJrUcujPVeJ3xlSWaiNi3uSVmDGBK1pDHUHAnao1I= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.5 h1:ymVxjfMaHvXD8RqPRmzHHsB3VvucivSkIAvJFDI5O3c= gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= +gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c h1:dUUwHk2QECo/6vqA44rthZ8ie2QXMNeKRTHCNY2nXvo= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=