|
|
|
@@ -44,7 +44,6 @@ type StateModuleAPI interface {
|
|
|
|
|
StateAccountKey(ctx context.Context, addr address.Address, tsk types.TipSetKey) (address.Address, error)
|
|
|
|
|
StateDealProviderCollateralBounds(ctx context.Context, size abi.PaddedPieceSize, verified bool, tsk types.TipSetKey) (api.DealCollateralBounds, error)
|
|
|
|
|
StateGetActor(ctx context.Context, actor address.Address, tsk types.TipSetKey) (*types.Actor, error)
|
|
|
|
|
StateGetReceipt(context.Context, cid.Cid, types.TipSetKey) (*types.MessageReceipt, error)
|
|
|
|
|
StateListMiners(ctx context.Context, tsk types.TipSetKey) ([]address.Address, error)
|
|
|
|
|
StateLookupID(ctx context.Context, addr address.Address, tsk types.TipSetKey) (address.Address, error)
|
|
|
|
|
StateMarketBalance(ctx context.Context, addr address.Address, tsk types.TipSetKey) (api.MarketBalance, error)
|
|
|
|
@@ -53,12 +52,14 @@ type StateModuleAPI interface {
|
|
|
|
|
StateMinerProvingDeadline(ctx context.Context, addr address.Address, tsk types.TipSetKey) (*dline.Info, error)
|
|
|
|
|
StateMinerPower(context.Context, address.Address, types.TipSetKey) (*api.MinerPower, error)
|
|
|
|
|
StateNetworkVersion(ctx context.Context, key types.TipSetKey) (network.Version, error)
|
|
|
|
|
StateSearchMsg(ctx context.Context, msg cid.Cid) (*api.MsgLookup, error)
|
|
|
|
|
StateSectorGetInfo(ctx context.Context, maddr address.Address, n abi.SectorNumber, tsk types.TipSetKey) (*miner.SectorOnChainInfo, error)
|
|
|
|
|
StateVerifiedClientStatus(ctx context.Context, addr address.Address, tsk types.TipSetKey) (*abi.StoragePower, error)
|
|
|
|
|
StateWaitMsg(ctx context.Context, msg cid.Cid, confidence uint64) (*api.MsgLookup, error)
|
|
|
|
|
StateSearchMsg(ctx context.Context, from types.TipSetKey, msg cid.Cid, limit abi.ChainEpoch, allowReplaced bool) (*api.MsgLookup, error)
|
|
|
|
|
StateWaitMsg(ctx context.Context, cid cid.Cid, confidence uint64, limit abi.ChainEpoch, allowReplaced bool) (*api.MsgLookup, error)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var _ StateModuleAPI = *new(api.FullNode)
|
|
|
|
|
|
|
|
|
|
// StateModule provides a default implementation of StateModuleAPI.
|
|
|
|
|
// It can be swapped out with another implementation through Dependency
|
|
|
|
|
// Injection (for example with a thin RPC client).
|
|
|
|
@@ -378,7 +379,7 @@ func (a *StateAPI) StateReplay(ctx context.Context, tsk types.TipSetKey, mc cid.
|
|
|
|
|
var ts *types.TipSet
|
|
|
|
|
var err error
|
|
|
|
|
if tsk == types.EmptyTSK {
|
|
|
|
|
mlkp, err := a.StateSearchMsg(ctx, mc)
|
|
|
|
|
mlkp, err := a.StateSearchMsg(ctx, types.EmptyTSK, mc, stmgr.LookbackNoLimit, true)
|
|
|
|
|
if err != nil {
|
|
|
|
|
return nil, xerrors.Errorf("searching for msg %s: %w", mc, err)
|
|
|
|
|
}
|
|
|
|
|