diff --git a/chain/actors/actor_cron.go b/chain/actors/actor_cron.go deleted file mode 100644 index 39190e42d..000000000 --- a/chain/actors/actor_cron.go +++ /dev/null @@ -1,9 +0,0 @@ -package actors - -import ( - "github.com/filecoin-project/specs-actors/actors/builtin/cron" -) - -type CronActor = cron.Actor - -type CronActorState = cron.State diff --git a/chain/actors/actor_init.go b/chain/actors/actor_init.go deleted file mode 100644 index baa2ceac5..000000000 --- a/chain/actors/actor_init.go +++ /dev/null @@ -1,12 +0,0 @@ -package actors - -import ( - init_ "github.com/filecoin-project/specs-actors/actors/builtin/init" - logging "github.com/ipfs/go-log/v2" -) - -var log = logging.Logger("actors") - -type InitActor = init_.Actor - -type InitActorState = init_.State diff --git a/chain/actors/actor_miner.go b/chain/actors/actor_miner.go deleted file mode 100644 index 28a60d99f..000000000 --- a/chain/actors/actor_miner.go +++ /dev/null @@ -1,9 +0,0 @@ -package actors - -import ( - "github.com/filecoin-project/specs-actors/actors/builtin/miner" -) - -type StorageMinerActor = miner.Actor - -type StorageMinerActorState = miner.State diff --git a/chain/actors/actor_paych.go b/chain/actors/actor_paych.go deleted file mode 100644 index 17fc787f2..000000000 --- a/chain/actors/actor_paych.go +++ /dev/null @@ -1,9 +0,0 @@ -package actors - -import ( - "github.com/filecoin-project/specs-actors/actors/builtin/paych" -) - -type PaymentChannelActor = paych.Actor - -type PaymentChannelActorState = paych.State diff --git a/chain/actors/actor_storagemarket.go b/chain/actors/actor_storagemarket.go deleted file mode 100644 index cb5af7b23..000000000 --- a/chain/actors/actor_storagemarket.go +++ /dev/null @@ -1,45 +0,0 @@ -package actors - -import ( - "github.com/filecoin-project/specs-actors/actors/builtin/market" -) - -type StorageMarketState = market.State - -// TODO: Drop in favour of car storage -type SerializationMode = uint64 - -const ( - SerializationUnixFSv0 = iota - // IPLD / car -) - -type StorageDealProposal = market.DealProposal - -type WithdrawBalanceParams = market.WithdrawBalanceParams - -type PublishStorageDealsParams = market.PublishStorageDealsParams - -type PublishStorageDealResponse = market.PublishStorageDealsReturn - -type ActivateStorageDealsParams = market.VerifyDealsOnSectorProveCommitParams - -type ComputeDataCommitmentParams = market.ComputeDataCommitmentParams - -/* -func (sma StorageMarketActor) HandleCronAction(act *types.Actor, vmctx types.VMContext, params *struct{}) ([]byte, ActorError) { - -} - -func (sma StorageMarketActor) SettleExpiredDeals(act *types.Actor, vmctx types.VMContext, params *struct{}) ([]byte, ActorError) { - -} - -func (sma StorageMarketActor) SlashStorageDealCollateral(act *types.Actor, vmctx types.VMContext, params *struct{}) ([]byte, ActorError) { - -} - -func (sma StorageMarketActor) GetLastExpirationFromDealIDs(act *types.Actor, vmctx types.VMContext, params *struct{}) ([]byte, ActorError) { - -} -*/ diff --git a/chain/actors/actor_storagepower.go b/chain/actors/actor_storagepower.go deleted file mode 100644 index 4fd7c0604..000000000 --- a/chain/actors/actor_storagepower.go +++ /dev/null @@ -1,12 +0,0 @@ -package actors - -import ( - "github.com/filecoin-project/specs-actors/actors/builtin" - "github.com/filecoin-project/specs-actors/actors/builtin/power" -) - -type StoragePowerActor = power.Actor - -var SPAMethods = builtin.MethodsPower - -type StoragePowerState = power.State diff --git a/chain/actors/forks.go b/chain/actors/forks.go index 60be370ef..0e79521df 100644 --- a/chain/actors/forks.go +++ b/chain/actors/forks.go @@ -4,10 +4,14 @@ import ( "reflect" "sort" + logging "github.com/ipfs/go-log/v2" + "github.com/filecoin-project/lotus/chain/actors/aerrors" "github.com/filecoin-project/lotus/chain/types" ) +var log = logging.Logger("actors") + type update struct { start uint64 method interface{} diff --git a/chain/gen/genesis/miners.go b/chain/gen/genesis/miners.go index 45a0f20ce..e24846617 100644 --- a/chain/gen/genesis/miners.go +++ b/chain/gen/genesis/miners.go @@ -69,7 +69,7 @@ func SetupStorageMiners(ctx context.Context, cs *store.ChainStore, sroot cid.Cid } params := mustEnc(constructorParams) - rval, err := doExecValue(ctx, vm, actors.StoragePowerAddress, m.Owner, m.PowerBalance, actors.SPAMethods.CreateMiner, params) + rval, err := doExecValue(ctx, vm, actors.StoragePowerAddress, m.Owner, m.PowerBalance, builtin.MethodsPower.CreateMiner, params) if err != nil { return cid.Undef, xerrors.Errorf("failed to create genesis miner: %w", err) } diff --git a/chain/gen/genesis/t01_init.go b/chain/gen/genesis/t01_init.go index 46f66548c..7797eae6f 100644 --- a/chain/gen/genesis/t01_init.go +++ b/chain/gen/genesis/t01_init.go @@ -5,6 +5,7 @@ import ( "encoding/json" "fmt" + init_ "github.com/filecoin-project/specs-actors/actors/builtin/init" "github.com/ipfs/go-hamt-ipld" bstore "github.com/ipfs/go-ipfs-blockstore" cbor "github.com/ipfs/go-ipld-cbor" @@ -20,7 +21,7 @@ func SetupInitActor(bs bstore.Blockstore, netname string, initialActors []genesi return nil, xerrors.New("too many initial actors") } - var ias actors.InitActorState + var ias init_.State ias.NextID = MinerStart ias.NetworkName = netname diff --git a/chain/gen/genesis/t03_cron.go b/chain/gen/genesis/t03_cron.go index bc2a8cde3..432927e09 100644 --- a/chain/gen/genesis/t03_cron.go +++ b/chain/gen/genesis/t03_cron.go @@ -14,7 +14,7 @@ import ( func SetupCronActor(bs bstore.Blockstore) (*types.Actor, error) { cst := cbor.NewCborStore(bs) - cas := &actors.CronActorState{Entries: []cron.Entry{{ + cas := &cron.State{Entries: []cron.Entry{{ Receiver: builtin.StoragePowerActorAddr, MethodNum: builtin.MethodsPower.OnEpochTickEnd, }, diff --git a/chain/state/statetree.go b/chain/state/statetree.go index a2815c35c..3b12f3576 100644 --- a/chain/state/statetree.go +++ b/chain/state/statetree.go @@ -79,7 +79,7 @@ func (st *StateTree) LookupID(addr address.Address) (address.Address, error) { return address.Undef, xerrors.Errorf("getting init actor: %w", err) } - var ias actors.InitActorState + var ias init_.State if err := st.Store.Get(context.TODO(), act.Head, &ias); err != nil { return address.Undef, xerrors.Errorf("loading init actor state: %w", err) } @@ -158,7 +158,7 @@ func (st *StateTree) Snapshot(ctx context.Context) error { func (st *StateTree) RegisterNewAddress(addr address.Address, act *types.Actor) (address.Address, error) { var out address.Address err := st.MutateActor(actors.InitAddress, func(initact *types.Actor) error { - var ias actors.InitActorState + var ias init_.State if err := st.Store.Get(context.TODO(), initact.Head, &ias); err != nil { return err } diff --git a/chain/stmgr/stmgr.go b/chain/stmgr/stmgr.go index 98235f53a..8e7fb8b68 100644 --- a/chain/stmgr/stmgr.go +++ b/chain/stmgr/stmgr.go @@ -16,6 +16,7 @@ import ( "github.com/filecoin-project/specs-actors/actors/abi" "github.com/filecoin-project/specs-actors/actors/abi/big" "github.com/filecoin-project/specs-actors/actors/builtin" + "github.com/filecoin-project/specs-actors/actors/builtin/market" "github.com/filecoin-project/specs-actors/actors/runtime" "github.com/filecoin-project/specs-actors/actors/util/adt" cbg "github.com/whyrusleeping/cbor-gen" @@ -627,7 +628,7 @@ func (sm *StateManager) ListAllActors(ctx context.Context, ts *types.TipSet) ([] } func (sm *StateManager) MarketBalance(ctx context.Context, addr address.Address, ts *types.TipSet) (api.MarketBalance, error) { - var state actors.StorageMarketState + var state market.State _, err := sm.LoadActorState(ctx, actors.StorageMarketAddress, &state, ts) if err != nil { return api.MarketBalance{}, err diff --git a/chain/stmgr/utils.go b/chain/stmgr/utils.go index cd70e84f6..b2c98da84 100644 --- a/chain/stmgr/utils.go +++ b/chain/stmgr/utils.go @@ -103,7 +103,7 @@ func GetMinerWorker(ctx context.Context, sm *StateManager, ts *types.TipSet, mad } func GetMinerPostState(ctx context.Context, sm *StateManager, ts *types.TipSet, maddr address.Address) (*miner.PoStState, error) { - var mas actors.StorageMinerActorState + var mas miner.State _, err := sm.LoadActorState(ctx, maddr, &mas, ts) if err != nil { return nil, xerrors.Errorf("(get eps) failed to load miner actor state: %w", err) @@ -113,7 +113,7 @@ func GetMinerPostState(ctx context.Context, sm *StateManager, ts *types.TipSet, } func SectorSetSizes(ctx context.Context, sm *StateManager, maddr address.Address, ts *types.TipSet) (api.MinerSectors, error) { - var mas actors.StorageMinerActorState + var mas miner.State _, err := sm.LoadActorState(ctx, maddr, &mas, ts) if err != nil { return api.MinerSectors{}, xerrors.Errorf("(get sset) failed to load miner actor state: %w", err) @@ -137,7 +137,7 @@ func SectorSetSizes(ctx context.Context, sm *StateManager, maddr address.Address } func GetMinerProvingSet(ctx context.Context, sm *StateManager, ts *types.TipSet, maddr address.Address) ([]*api.ChainSectorInfo, error) { - var mas actors.StorageMinerActorState + var mas miner.State _, err := sm.LoadActorState(ctx, maddr, &mas, ts) if err != nil { return nil, xerrors.Errorf("(get pset) failed to load miner actor state: %w", err) @@ -147,7 +147,7 @@ func GetMinerProvingSet(ctx context.Context, sm *StateManager, ts *types.TipSet, } func GetMinerSectorSet(ctx context.Context, sm *StateManager, ts *types.TipSet, maddr address.Address) ([]*api.ChainSectorInfo, error) { - var mas actors.StorageMinerActorState + var mas miner.State _, err := sm.LoadActorState(ctx, maddr, &mas, ts) if err != nil { return nil, xerrors.Errorf("(get sset) failed to load miner actor state: %w", err) @@ -181,7 +181,7 @@ func GetSectorsForElectionPost(ctx context.Context, sm *StateManager, ts *types. } func GetMinerSectorSize(ctx context.Context, sm *StateManager, ts *types.TipSet, maddr address.Address) (abi.SectorSize, error) { - var mas actors.StorageMinerActorState + var mas miner.State _, err := sm.LoadActorState(ctx, maddr, &mas, ts) if err != nil { return 0, xerrors.Errorf("(get ssize) failed to load miner actor state: %w", err) @@ -196,7 +196,7 @@ func GetMinerSlashed(ctx context.Context, sm *StateManager, ts *types.TipSet, ma } func GetMinerFaults(ctx context.Context, sm *StateManager, ts *types.TipSet, maddr address.Address) ([]abi.SectorNumber, error) { - var mas actors.StorageMinerActorState + var mas miner.State _, err := sm.LoadActorState(ctx, maddr, &mas, ts) if err != nil { return nil, xerrors.Errorf("(get ssize) failed to load miner actor state: %w", err) @@ -249,7 +249,7 @@ func GetStorageDeal(ctx context.Context, sm *StateManager, dealId abi.DealID, ts } func ListMinerActors(ctx context.Context, sm *StateManager, ts *types.TipSet) ([]address.Address, error) { - var state actors.StoragePowerState + var state power.State if _, err := sm.LoadActorState(ctx, actors.StoragePowerAddress, &state, ts); err != nil { return nil, err } diff --git a/chain/vm/invoker.go b/chain/vm/invoker.go index f3661bb2d..64b98489d 100644 --- a/chain/vm/invoker.go +++ b/chain/vm/invoker.go @@ -13,9 +13,13 @@ import ( "github.com/filecoin-project/specs-actors/actors/abi" "github.com/filecoin-project/specs-actors/actors/builtin" + "github.com/filecoin-project/specs-actors/actors/builtin/cron" + init_ "github.com/filecoin-project/specs-actors/actors/builtin/init" "github.com/filecoin-project/specs-actors/actors/builtin/market" "github.com/filecoin-project/specs-actors/actors/builtin/miner" "github.com/filecoin-project/specs-actors/actors/builtin/multisig" + "github.com/filecoin-project/specs-actors/actors/builtin/paych" + "github.com/filecoin-project/specs-actors/actors/builtin/power" "github.com/filecoin-project/specs-actors/actors/builtin/system" vmr "github.com/filecoin-project/specs-actors/actors/runtime" "github.com/filecoin-project/specs-actors/actors/util/adt" @@ -41,13 +45,13 @@ func NewInvoker() *invoker { // add builtInCode using: register(cid, singleton) inv.Register(builtin.SystemActorCodeID, system.Actor{}, adt.EmptyValue{}) - inv.Register(actors.InitCodeCid, actors.InitActor{}, actors.InitActorState{}) - inv.Register(actors.CronCodeCid, actors.CronActor{}, actors.CronActorState{}) - inv.Register(actors.StoragePowerCodeCid, actors.StoragePowerActor{}, actors.StoragePowerState{}) + inv.Register(actors.InitCodeCid, init_.Actor{}, init_.State{}) + inv.Register(actors.CronCodeCid, cron.Actor{}, cron.State{}) + inv.Register(actors.StoragePowerCodeCid, power.Actor{}, power.State{}) inv.Register(actors.StorageMarketCodeCid, market.Actor{}, market.State{}) inv.Register(actors.StorageMinerCodeCid, miner.Actor{}, miner.State{}) inv.Register(actors.MultisigCodeCid, multisig.Actor{}, multisig.State{}) - inv.Register(actors.PaymentChannelCodeCid, actors.PaymentChannelActor{}, actors.PaymentChannelActorState{}) + inv.Register(actors.PaymentChannelCodeCid, paych.Actor{}, paych.State{}) return inv } diff --git a/cli/state.go b/cli/state.go index 25fd4759a..e585a5e94 100644 --- a/cli/state.go +++ b/cli/state.go @@ -5,7 +5,6 @@ import ( "context" "encoding/json" "fmt" - miner2 "github.com/filecoin-project/specs-actors/actors/builtin/miner" "reflect" "strconv" "strings" @@ -13,7 +12,10 @@ import ( "github.com/filecoin-project/go-address" "github.com/filecoin-project/specs-actors/actors/abi" "github.com/filecoin-project/specs-actors/actors/builtin/market" + miner2 "github.com/filecoin-project/specs-actors/actors/builtin/miner" samsig "github.com/filecoin-project/specs-actors/actors/builtin/multisig" + "github.com/filecoin-project/specs-actors/actors/builtin/paych" + "github.com/filecoin-project/specs-actors/actors/builtin/power" "github.com/libp2p/go-libp2p-core/peer" "golang.org/x/xerrors" @@ -974,13 +976,13 @@ func parseParamsForMethod(act cid.Cid, method uint64, args []string) ([]byte, er case actors.StorageMarketCodeCid: f = market.Actor{}.Exports()[method] case actors.StorageMinerCodeCid: - f = actors.StorageMinerActor{}.Exports()[method] + f = miner2.Actor{}.Exports()[method] case actors.StoragePowerCodeCid: - f = actors.StoragePowerActor{}.Exports()[method] + f = power.Actor{}.Exports()[method] case actors.MultisigCodeCid: f = samsig.Actor{}.Exports()[method] case actors.PaymentChannelCodeCid: - f = actors.PaymentChannelActor{}.Exports()[method] + f = paych.Actor{}.Exports()[method] default: return nil, fmt.Errorf("the lazy devs didnt add support for that actor to this call yet") } diff --git a/cmd/lotus-storage-miner/init.go b/cmd/lotus-storage-miner/init.go index e7e1d64b3..76cf9192e 100644 --- a/cmd/lotus-storage-miner/init.go +++ b/cmd/lotus-storage-miner/init.go @@ -6,6 +6,7 @@ import ( "encoding/json" "fmt" "github.com/filecoin-project/specs-actors/actors/builtin" + "github.com/filecoin-project/specs-actors/actors/builtin/market" miner2 "github.com/filecoin-project/specs-actors/actors/builtin/miner" "github.com/filecoin-project/specs-actors/actors/builtin/power" crypto2 "github.com/filecoin-project/specs-actors/actors/crypto" @@ -308,7 +309,7 @@ func migratePreSealMeta(ctx context.Context, api lapi.FullNode, metadata string, return nil } -func findMarketDealID(ctx context.Context, api lapi.FullNode, deal actors.StorageDealProposal) (abi.DealID, error) { +func findMarketDealID(ctx context.Context, api lapi.FullNode, deal market.DealProposal) (abi.DealID, error) { // TODO: find a better way // (this is only used by genesis miners) diff --git a/markets/storageadapter/client.go b/markets/storageadapter/client.go index f2e65bf09..3c57c6e39 100644 --- a/markets/storageadapter/client.go +++ b/markets/storageadapter/client.go @@ -186,7 +186,7 @@ func (c *ClientNodeAdapter) ValidatePublishedDeal(ctx context.Context, deal stor return 0, xerrors.Errorf("deal publish message called incorrect method (method=%s)", pubmsg.Method) } - var params actors.PublishStorageDealsParams + var params samarket.PublishStorageDealsParams if err := params.UnmarshalCBOR(bytes.NewReader(pubmsg.Params)); err != nil { return 0, err } @@ -218,7 +218,7 @@ func (c *ClientNodeAdapter) ValidatePublishedDeal(ctx context.Context, deal stor return 0, xerrors.Errorf("deal publish failed: exit=%d", ret.ExitCode) } - var res actors.PublishStorageDealResponse + var res samarket.PublishStorageDealsReturn if err := res.UnmarshalCBOR(bytes.NewReader(ret.Return)); err != nil { return 0, err } diff --git a/markets/storageadapter/provider.go b/markets/storageadapter/provider.go index 258ee39ff..b8ace84c5 100644 --- a/markets/storageadapter/provider.go +++ b/markets/storageadapter/provider.go @@ -58,7 +58,7 @@ func (n *ProviderNodeAdapter) PublishDeals(ctx context.Context, deal storagemark return 0, cid.Undef, err } - params, err := actors.SerializeParams(&actors.PublishStorageDealsParams{ + params, err := actors.SerializeParams(&market.PublishStorageDealsParams{ Deals: []market.ClientDealProposal{deal.ClientDealProposal}, }) @@ -86,7 +86,7 @@ func (n *ProviderNodeAdapter) PublishDeals(ctx context.Context, deal storagemark if r.Receipt.ExitCode != 0 { return 0, cid.Undef, xerrors.Errorf("publishing deal failed: exit %d", r.Receipt.ExitCode) } - var resp actors.PublishStorageDealResponse + var resp market.PublishStorageDealsReturn if err := resp.UnmarshalCBOR(bytes.NewReader(r.Receipt.Return)); err != nil { return 0, cid.Undef, err } diff --git a/node/impl/full/state.go b/node/impl/full/state.go index 4d1dcceff..a8dfbbc87 100644 --- a/node/impl/full/state.go +++ b/node/impl/full/state.go @@ -328,7 +328,7 @@ func (a *StateAPI) StateMarketBalance(ctx context.Context, addr address.Address, func (a *StateAPI) StateMarketParticipants(ctx context.Context, tsk types.TipSetKey) (map[string]api.MarketBalance, error) { out := map[string]api.MarketBalance{} - var state actors.StorageMarketState + var state market.State ts, err := a.Chain.GetTipSetFromKey(tsk) if err != nil { return nil, xerrors.Errorf("loading tipset %s: %w", tsk, err) @@ -377,7 +377,7 @@ func (a *StateAPI) StateMarketParticipants(ctx context.Context, tsk types.TipSet func (a *StateAPI) StateMarketDeals(ctx context.Context, tsk types.TipSetKey) (map[string]api.MarketDeal, error) { out := map[string]api.MarketDeal{} - var state actors.StorageMarketState + var state market.State ts, err := a.Chain.GetTipSetFromKey(tsk) if err != nil { return nil, xerrors.Errorf("loading tipset %s: %w", tsk, err) diff --git a/paychmgr/paych.go b/paychmgr/paych.go index 8cd625647..f497217f6 100644 --- a/paychmgr/paych.go +++ b/paychmgr/paych.go @@ -53,7 +53,7 @@ func NewManager(sm *stmgr.StateManager, pchstore *Store, api ManagerApi) *Manage } } -func maxLaneFromState(st *actors.PaymentChannelActorState) (uint64, error) { +func maxLaneFromState(st *paych.State) (uint64, error) { maxLane := uint64(math.MaxInt64) for _, state := range st.LaneStates { if (state.ID)+1 > maxLane+1 { diff --git a/paychmgr/state.go b/paychmgr/state.go index 9f3b80261..6aff6bd9e 100644 --- a/paychmgr/state.go +++ b/paychmgr/state.go @@ -7,12 +7,11 @@ import ( "github.com/filecoin-project/specs-actors/actors/builtin/paych" xerrors "golang.org/x/xerrors" - "github.com/filecoin-project/lotus/chain/actors" "github.com/filecoin-project/lotus/chain/types" ) -func (pm *Manager) loadPaychState(ctx context.Context, ch address.Address) (*types.Actor, *actors.PaymentChannelActorState, error) { - var pcast actors.PaymentChannelActorState +func (pm *Manager) loadPaychState(ctx context.Context, ch address.Address) (*types.Actor, *paych.State, error) { + var pcast paych.State act, err := pm.sm.LoadActorState(ctx, ch, &pcast, nil) if err != nil { return nil, nil, err diff --git a/storage/sbmock/preseal.go b/storage/sbmock/preseal.go index 62efc699b..22326482a 100644 --- a/storage/sbmock/preseal.go +++ b/storage/sbmock/preseal.go @@ -5,9 +5,9 @@ import ( commcid "github.com/filecoin-project/go-fil-commcid" "github.com/filecoin-project/specs-actors/actors/abi" "github.com/filecoin-project/specs-actors/actors/abi/big" + "github.com/filecoin-project/specs-actors/actors/builtin/market" "github.com/filecoin-project/specs-actors/actors/crypto" - "github.com/filecoin-project/lotus/chain/actors" "github.com/filecoin-project/lotus/chain/types" "github.com/filecoin-project/lotus/chain/wallet" "github.com/filecoin-project/lotus/genesis" @@ -35,7 +35,7 @@ func PreSeal(ssize abi.SectorSize, maddr address.Address, sectors int) (*genesis preseal.CommD = commD(sdata) preseal.CommR = commDR(preseal.CommD[:]) preseal.SectorID = abi.SectorNumber(i + 1) - preseal.Deal = actors.StorageDealProposal{ + preseal.Deal = market.DealProposal{ PieceCID: commcid.PieceCommitmentV1ToCID(preseal.CommD[:]), PieceSize: abi.PaddedPieceSize(ssize), Client: maddr, diff --git a/storage/sealing/checks.go b/storage/sealing/checks.go index 8770dd1af..35b37daab 100644 --- a/storage/sealing/checks.go +++ b/storage/sealing/checks.go @@ -3,20 +3,21 @@ package sealing import ( "bytes" "context" - commcid "github.com/filecoin-project/go-fil-commcid" - "github.com/filecoin-project/lotus/lib/zerocomm" - "github.com/ipfs/go-cid" - cbg "github.com/whyrusleeping/cbor-gen" - "github.com/filecoin-project/specs-actors/actors/builtin" + "github.com/ipfs/go-cid" "github.com/multiformats/go-multihash" + cbg "github.com/whyrusleeping/cbor-gen" "golang.org/x/xerrors" "github.com/filecoin-project/go-address" + commcid "github.com/filecoin-project/go-fil-commcid" + "github.com/filecoin-project/specs-actors/actors/builtin" + "github.com/filecoin-project/specs-actors/actors/builtin/market" "github.com/filecoin-project/lotus/build" "github.com/filecoin-project/lotus/chain/actors" "github.com/filecoin-project/lotus/chain/types" + "github.com/filecoin-project/lotus/lib/zerocomm" ) // TODO: For now we handle this by halting state execution, when we get jsonrpc reconnecting @@ -88,7 +89,7 @@ func checkSeal(ctx context.Context, maddr address.Address, si SectorInfo, api se return &ErrApi{err} } - ccparams, err := actors.SerializeParams(&actors.ComputeDataCommitmentParams{ + ccparams, err := actors.SerializeParams(&market.ComputeDataCommitmentParams{ DealIDs: si.deals(), SectorSize: ssize, }) diff --git a/storage/sealing/states_failed.go b/storage/sealing/states_failed.go index f6ccc5057..aaffe8b43 100644 --- a/storage/sealing/states_failed.go +++ b/storage/sealing/states_failed.go @@ -11,7 +11,6 @@ import ( "github.com/filecoin-project/lotus/api" "github.com/filecoin-project/lotus/api/apibstore" - "github.com/filecoin-project/lotus/chain/actors" "github.com/filecoin-project/lotus/chain/store" "github.com/filecoin-project/lotus/chain/types" "github.com/filecoin-project/lotus/lib/statemachine" @@ -46,7 +45,7 @@ func (m *Sealing) checkPreCommitted(ctx statemachine.Context, sector SectorInfo) return nil, true } - var state actors.StorageMinerActorState + var state miner.State if err := state.UnmarshalCBOR(bytes.NewReader(st)); err != nil { log.Errorf("handleSealFailed(%d): temp error: unmarshaling miner state: %+v", sector.SectorID, err) return nil, true