From 8dc07ee117016ce214de6798e6d9157cb5e43350 Mon Sep 17 00:00:00 2001 From: Wondertan Date: Mon, 31 May 2021 03:39:23 +0300 Subject: [PATCH] fix(consensus): increase timeout for PutBlock --- consensus/state.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/consensus/state.go b/consensus/state.go index 4bf977696c..a9b8481ad8 100644 --- a/consensus/state.go +++ b/consensus/state.go @@ -1122,7 +1122,7 @@ func (cs *State) defaultDecideProposal(height int64, round int32) { // TODO(evan): don't hard code context and timeout // // longer timeouts result in block proposers failing to propose blocks in time. - ctx, cancel := context.WithTimeout(context.Background(), time.Millisecond*1500) + ctx, cancel := context.WithTimeout(context.Background(), time.Second*120) defer cancel() cs.Logger.Info("Putting Block to ipfs", "height", block.Height) err = ipld.PutBlock(ctx, cs.dag, block, cs.croute)