From 5154f525d3489ab54c0614da9707fc163dfdba5c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Magiera?= Date: Mon, 16 Dec 2019 12:46:52 +0100 Subject: [PATCH 1/2] config: don't comment sections be default --- node/config/load.go | 1 + 1 file changed, 1 insertion(+) diff --git a/node/config/load.go b/node/config/load.go index fd1aeb181..352d17197 100644 --- a/node/config/load.go +++ b/node/config/load.go @@ -44,6 +44,7 @@ func ConfigComment(t interface{}) ([]byte, error) { } b := buf.Bytes() b = bytes.ReplaceAll(b, []byte("\n"), []byte("\n#")) + b = bytes.ReplaceAll(b, []byte("#["), []byte("[")) return b, nil } From d6f543ce8712b81e7832aac68288b5958f0659e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Magiera?= Date: Mon, 16 Dec 2019 12:47:11 +0100 Subject: [PATCH 2/2] gofmt --- chain/validation/message.go | 16 ++++++++-------- chain/vm/validation_test.go | 2 +- cmd/lotus-chainwatch/storage.go | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/chain/validation/message.go b/chain/validation/message.go index a795a2a10..ed9f2c0b9 100644 --- a/chain/validation/message.go +++ b/chain/validation/message.go @@ -83,14 +83,14 @@ var methods = []uint64{ vchain.StorageMinerGetPeerID: actors.MAMethods.GetPeerID, vchain.StorageMinerGetSectorSize: actors.MAMethods.GetSectorSize, - vchain.MultiSigConstructor: actors.MultiSigMethods.MultiSigConstructor, - vchain.MultiSigPropose: actors.MultiSigMethods.Propose, - vchain.MultiSigApprove: actors.MultiSigMethods.Approve, - vchain.MultiSigCancel: actors.MultiSigMethods.Cancel, - vchain.MultiSigClearCompleted: actors.MultiSigMethods.ClearCompleted, - vchain.MultiSigAddSigner: actors.MultiSigMethods.AddSigner, - vchain.MultiSigRemoveSigner: actors.MultiSigMethods.RemoveSigner, - vchain.MultiSigSwapSigner: actors.MultiSigMethods.SwapSigner, + vchain.MultiSigConstructor: actors.MultiSigMethods.MultiSigConstructor, + vchain.MultiSigPropose: actors.MultiSigMethods.Propose, + vchain.MultiSigApprove: actors.MultiSigMethods.Approve, + vchain.MultiSigCancel: actors.MultiSigMethods.Cancel, + vchain.MultiSigClearCompleted: actors.MultiSigMethods.ClearCompleted, + vchain.MultiSigAddSigner: actors.MultiSigMethods.AddSigner, + vchain.MultiSigRemoveSigner: actors.MultiSigMethods.RemoveSigner, + vchain.MultiSigSwapSigner: actors.MultiSigMethods.SwapSigner, vchain.MultiSigChangeRequirement: actors.MultiSigMethods.ChangeRequirement, // More to follow... } diff --git a/chain/vm/validation_test.go b/chain/vm/validation_test.go index 6291e8486..5e5a46a63 100644 --- a/chain/vm/validation_test.go +++ b/chain/vm/validation_test.go @@ -32,4 +32,4 @@ func TestMultiSig(t *testing.T) { suites.MultiSigActorConstructor(t, factory) suites.MultiSigActorProposeApprove(t, factory) suites.MultiSigActorProposeCancel(t, factory) -} \ No newline at end of file +} diff --git a/cmd/lotus-chainwatch/storage.go b/cmd/lotus-chainwatch/storage.go index 3a737acdb..43be97d27 100644 --- a/cmd/lotus-chainwatch/storage.go +++ b/cmd/lotus-chainwatch/storage.go @@ -327,7 +327,7 @@ func (st *storage) storeHeaders(bhs map[cid.Cid]*types.BlockHeader, sync bool) e bh.EPostProof.Candidates[0].Partial, bh.EPostProof.Candidates[0].SectorID, bh.EPostProof.Candidates[0].ChallengeIndex, - ); err != nil { + ); err != nil { return err } }