Fix amt bug
This commit is contained in:
parent
c544c2b5c5
commit
d5027bfbb2
@ -29,7 +29,7 @@ type StateTree struct {
|
||||
|
||||
func NewStateTree(cst cbor.IpldStore) (*StateTree, error) {
|
||||
return &StateTree{
|
||||
root: hamt.NewNode(cst),
|
||||
root: hamt.NewNode(cst, hamt.UseTreeBitWidth(5)),
|
||||
Store: cst,
|
||||
actorcache: make(map[address.Address]*types.Actor),
|
||||
}, nil
|
||||
|
@ -4,6 +4,7 @@ import (
|
||||
"encoding/hex"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"github.com/filecoin-project/specs-actors/actors/abi/big"
|
||||
"io/ioutil"
|
||||
"os"
|
||||
"path/filepath"
|
||||
@ -313,6 +314,9 @@ func mergeGenMiners(a, b genesis.Miner) genesis.Miner {
|
||||
return genesis.Miner{
|
||||
Owner: a.Owner,
|
||||
Worker: a.Worker,
|
||||
PeerId: "",
|
||||
MarketBalance: big.Zero(),
|
||||
PowerBalance: big.Zero(),
|
||||
SectorSize: a.SectorSize,
|
||||
Sectors: append(a.Sectors, b.Sectors...),
|
||||
}
|
||||
|
@ -109,9 +109,10 @@ func PreSeal(maddr address.Address, ssize abi.SectorSize, offset abi.SectorNumbe
|
||||
miner := &genesis.Miner{
|
||||
Owner: minerAddr.Address,
|
||||
Worker: minerAddr.Address,
|
||||
|
||||
PeerId: "",
|
||||
MarketBalance: big.Zero(),
|
||||
PowerBalance: big.Zero(),
|
||||
SectorSize: ssize,
|
||||
|
||||
Sectors: sealedSectors,
|
||||
}
|
||||
|
||||
|
2
go.mod
2
go.mod
@ -23,7 +23,7 @@ require (
|
||||
github.com/filecoin-project/go-paramfetch v0.0.1
|
||||
github.com/filecoin-project/go-sectorbuilder v0.0.2-0.20200210220012-eb75ec747d6b
|
||||
github.com/filecoin-project/go-statestore v0.1.0
|
||||
github.com/filecoin-project/specs-actors v0.0.0-20200212234534-e2abd13ec4b1
|
||||
github.com/filecoin-project/specs-actors v0.0.0-20200214164743-74b45ccaaff9
|
||||
github.com/gbrlsnchs/jwt/v3 v3.0.0-beta.1
|
||||
github.com/go-ole/go-ole v1.2.4 // indirect
|
||||
github.com/gorilla/mux v1.7.3
|
||||
|
2
go.sum
2
go.sum
@ -128,6 +128,8 @@ github.com/filecoin-project/specs-actors v0.0.0-20200211202147-e5d0a86dd8fb h1:6
|
||||
github.com/filecoin-project/specs-actors v0.0.0-20200211202147-e5d0a86dd8fb/go.mod h1:xtDZUB6pe4Pksa/bAJbJ693OilaC5Wbot9jMhLm3cZA=
|
||||
github.com/filecoin-project/specs-actors v0.0.0-20200212234534-e2abd13ec4b1 h1:jU0PeLjpsrvDBhVyzVgupcwicSioVvXWreN0NMhuMN0=
|
||||
github.com/filecoin-project/specs-actors v0.0.0-20200212234534-e2abd13ec4b1/go.mod h1:xtDZUB6pe4Pksa/bAJbJ693OilaC5Wbot9jMhLm3cZA=
|
||||
github.com/filecoin-project/specs-actors v0.0.0-20200214164743-74b45ccaaff9 h1:i6hLXvnse+C7DE2/1anKrlKahBFbusa066LG0K/v8KM=
|
||||
github.com/filecoin-project/specs-actors v0.0.0-20200214164743-74b45ccaaff9/go.mod h1:xtDZUB6pe4Pksa/bAJbJ693OilaC5Wbot9jMhLm3cZA=
|
||||
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/gbrlsnchs/jwt/v3 v3.0.0-beta.1 h1:EzDjxMg43q1tA2c0MV3tNbaontnHLplHyFF6M5KiVP0=
|
||||
|
Loading…
Reference in New Issue
Block a user