From da6768c94d62f88ab707444181e9544d4fb85754 Mon Sep 17 00:00:00 2001 From: waynewyang Date: Tue, 26 May 2020 11:43:17 +0800 Subject: [PATCH] Set largest gaslimit for wdpost --- storage/wdpost_run.go | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/storage/wdpost_run.go b/storage/wdpost_run.go index e9e22e183..eb0f1c135 100644 --- a/storage/wdpost_run.go +++ b/storage/wdpost_run.go @@ -15,6 +15,7 @@ import ( "go.opencensus.io/trace" "golang.org/x/xerrors" + "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/actors" "github.com/filecoin-project/lotus/chain/types" ) @@ -336,12 +337,13 @@ func (s *WindowPoStScheduler) submitPost(ctx context.Context, proof *miner.Submi } msg := &types.Message{ - To: s.actor, - From: s.worker, - Method: builtin.MethodsMiner.SubmitWindowedPoSt, - Params: enc, - Value: types.NewInt(1000), // currently hard-coded late fee in actor, returned if not late - GasLimit: 10000000, // i dont know help + To: s.actor, + From: s.worker, + Method: builtin.MethodsMiner.SubmitWindowedPoSt, + Params: enc, + Value: types.NewInt(1000), // currently hard-coded late fee in actor, returned if not late + // TODO: Gaslimit needs to be calculated accurately. Before that, use the largest Gaslimit + GasLimit: build.BlockGasLimit, GasPrice: types.NewInt(1), }