Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

build: release: v1.17.0-rc2 #8910

Closed
wants to merge 153 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
153 commits
Select commit Hold shift + click to select a range
c8b41a5
simplify the release testing flow as minerx is now our default testin…
jennijuju Nov 30, 2021
73203f6
Update README.md
blademasterzhang Apr 8, 2022
3cdd92c
build: deps: add uninstall make target
nicobao Jun 6, 2022
faa3b18
fix: ux: client deal addrs is on-chain check
rjan90 Jun 9, 2022
41e325e
chore: refactor: rename var name for syncing mainnet v15 using FVM
jennijuju Jun 9, 2022
ed091b6
update butterfly artifects
jennijuju Jun 14, 2022
9aa5659
sealing pipeline: Drop TipSetToken, use TipSetKey directly
magik6k Jun 16, 2022
9fad80c
sealing pipeline: Drop unused miner-info related methods
magik6k Jun 16, 2022
cd4514b
sealing pipeline: Drop StateMinerActiveSectors
magik6k Jun 16, 2022
048bfe6
sealing pipeline: Use non-special msg wait APIs
magik6k Jun 16, 2022
a084445
sealing pipeline: Use non-special ChainHead
magik6k Jun 16, 2022
2dc1df8
api: Move StateComputeDataCID to full-node
magik6k Jun 16, 2022
db84222
sealing pipeline: Drop StateMarketStorageDealProposal
magik6k Jun 16, 2022
06b3e55
sealing pipeline: Drop ChainBaseFee, don't wrap StateSectorPartition
magik6k Jun 16, 2022
9c4d10e
api: handle no-precommit in StateSectorPreCommitInfo gracefully
magik6k Jun 16, 2022
59a4fe1
sealing pipeline: Don't adapt MpoolPushMessage
magik6k Jun 16, 2022
d562416
sealing pipeline: Remove adapter code!
magik6k Jun 16, 2022
3465f3a
Merge pull request #8837 from filecoin-project/jen/refactor
jennijuju Jun 16, 2022
51b6b07
Merge branch 'release/v1.16.0' into jen/master16
jennijuju Jun 16, 2022
ae37db7
update bundles for v16# Please enter the commit message for your cha…
jennijuju Jun 16, 2022
34b04cc
bump version
rjan90 Jun 16, 2022
1ad1c12
Merge pull request #8872 from filecoin-project/jen/master16
geoff-vball Jun 16, 2022
8375cc9
make gen
jennijuju Jun 16, 2022
8815fc1
Merge pull request #8875 from filecoin-project/phi/update-version
jennijuju Jun 16, 2022
4df19f9
address feedbacks + nit
jennijuju Jun 16, 2022
9e1794f
Merge pull request #8857 from filecoin-project/jen/butterflyreset
jennijuju Jun 16, 2022
7330ac5
Merge pull request #7715 from filecoin-project/jen/simplythings
jennijuju Jun 17, 2022
4a4d64f
sealing pipeline: Rename 'tok' to 'tsk'
magik6k Jun 17, 2022
7de400b
Merge remote-tracking branch 'origin/master' into chore/drop-pipeline…
magik6k Jun 17, 2022
58416d0
storage: Don't depend on specs-storage, move to storiface
magik6k Jun 17, 2022
db676ac
storage: Cleanup interfaces a bit
magik6k Jun 17, 2022
12f9b2c
Merge pull request #8879 from filecoin-project/chore/drop-specsstorage
geoff-vball Jun 17, 2022
5c884b5
Merge pull request #8830 from filecoin-project/fix/error-client-deal
geoff-vball Jun 17, 2022
3fe16cc
Merge pull request #8814 from nicobao/feat/uninstall/8812
geoff-vball Jun 17, 2022
ae17b76
storage: Address review, no tok
magik6k Jun 17, 2022
2c3dbb2
Merge pull request #8871 from filecoin-project/chore/drop-pipeline-ad…
magik6k Jun 17, 2022
1ccd905
update butterfly artifects
jennijuju Jun 14, 2022
17b5fc8
Merge pull request #8881 from filecoin-project/phi/fix-butterfly
rjan90 Jun 20, 2022
b1fddec
Update to go-state-types v0.1.10
arajasek Jun 20, 2022
b7ee05e
Update to go-state-types v0.1.10
arajasek Jun 20, 2022
f44ad26
Merge pull request #8882 from filecoin-project/asr/label-json
arajasek Jun 20, 2022
0e186ce
Merge pull request #8883 from filecoin-project/asr/label-json-master
arajasek Jun 20, 2022
7554991
Add a reentrant multisig test
arajasek Jun 6, 2022
d6e00bc
Merge pull request #8816 from filecoin-project/asr/reentrant-test
arajasek Jun 20, 2022
b2956ad
docs: update ./documentation/en/README.md
lidel Jun 21, 2022
866693f
fix: fvm: make exectraces match legacyVM some more
arajasek Jun 22, 2022
a80da7f
Merge pull request #8889 from filecoin-project/asr/exec-trace
arajasek Jun 22, 2022
e860a05
fix: fvm: make exectraces match legacyVM some more
arajasek Jun 22, 2022
1ced322
feat: support overriding actor versions per-network
Stebalien Jun 22, 2022
a7a3073
Update FFI
arajasek Jun 22, 2022
a0aa9ad
Merge pull request #8894 from filecoin-project/asr/update-ffi
arajasek Jun 22, 2022
eb9c342
Merge pull request #8892 from filecoin-project/feat/bundle-pack-multi…
arajasek Jun 22, 2022
a43231b
Merge pull request #8893 from filecoin-project/asr/exec-trace-v16
arajasek Jun 22, 2022
e122d11
chore: deps: update to actors v8.0.0-rc.2, except for calibnet
arajasek Jun 22, 2022
550d388
Merge pull request #8895 from filecoin-project/asr/update-actors
arajasek Jun 22, 2022
820013a
add mainnet upgrade epoch for nv16
jennijuju Jun 21, 2022
ea82355
bump version to v1.16.0-rc2
jennijuju Jun 21, 2022
781f924
add mainnet upgrade epoch
jennijuju Jun 21, 2022
7f864d0
Update go-fil-markets v1.20.1-v16-2
arajasek Jun 21, 2022
4815c73
tidy lotus-soup go.mod
arajasek Jun 22, 2022
17cd280
fvm liftoff
jennijuju Jun 22, 2022
cd6c0c2
feat: move banner, embed, and run at v8 upgrade only
Stebalien Jun 22, 2022
5d0a01a
update ffi
jennijuju Jun 22, 2022
eabb2d1
Merge pull request #8897 from filecoin-project/jen/art
jennijuju Jun 22, 2022
5d55e3d
Merge pull request #8898 from filecoin-project/jen/ffi2
arajasek Jun 22, 2022
6a6d671
update changelog
jennijuju Jun 22, 2022
6638ed4
Merge pull request #8884 from filecoin-project/jen/1602
jennijuju Jun 22, 2022
dc4ba81
Make cli deal command get Block Delay specific to build
geoff-vball Jun 22, 2022
69b7594
fix the the upgrade epoch in changelog
jennijuju Jun 23, 2022
824da5e
Merge pull request #8901 from filecoin-project/fixchangelog
jennijuju Jun 23, 2022
b368d08
Merge pull request #8896 from filecoin-project/gstuart/make-deal-devnet
magik6k Jun 23, 2022
f010aa9
feat: upgrade go-fil-markets to v1.22.0
dirkmc Jun 23, 2022
e684248
Added api call to get actors cids
geoff-vball Jun 23, 2022
73ea687
chore: deps: update FFI to use FVM 1.0.0
arajasek Jun 23, 2022
83d7db8
review fixes
geoff-vball Jun 23, 2022
42a1654
Update actors to v8.0.0
arajasek Jun 23, 2022
a002703
Merge pull request #8908 from filecoin-project/asr/bump-fvm
arajasek Jun 23, 2022
23bd1b2
Merge pull request #8909 from filecoin-project/asr/update-actors
jennijuju Jun 23, 2022
b3890d5
Merge pull request #8907 from filecoin-project/gstuart/api-actors-cids
arajasek Jun 23, 2022
fd5981b
feat: shed: print out actor code CIDs in manifest cid checker
arajasek Jun 23, 2022
2f27602
Merge pull request #8911 from filecoin-project/asr/manifest-cid-check
arajasek Jun 23, 2022
c10c898
Break out of retrieval if provider cancels
geoff-vball Jun 23, 2022
8b96396
Merge pull request #8912 from filecoin-project/gstuart/retrieval-no-hang
geoff-vball Jun 23, 2022
83d796f
bump the version to v1.16.0
jennijuju Jun 23, 2022
3b9783d
add changelog
jennijuju Jun 24, 2022
ed735a3
Merge pull request #8914 from filecoin-project/jen/v16
jennijuju Jun 24, 2022
01254ab
Merge pull request #8915 from filecoin-project/v16
jennijuju Jun 24, 2022
eba8219
Merge pull request #8905 from filecoin-project/feat/go-fil-marketsv1.…
jennijuju Jun 27, 2022
3e55995
Merge pull request #8887 from lidel/patch-1
magik6k Jun 27, 2022
f0c12a0
readme: link to installation instructions directly
magik6k Jun 27, 2022
cd1b439
Merge pull request #8460 from blademasterzhang/master
magik6k Jun 27, 2022
c3f3eb0
Merge branch 'releases' into jen/masterbp
jennijuju Jun 27, 2022
b7c9155
resolve conflict
jennijuju Jun 27, 2022
1583fe0
Merge pull request #8929 from filecoin-project/jen/masterbp
jennijuju Jun 27, 2022
f052caf
test appimage build
Jun 27, 2022
de81eaf
temporary remove filter
Jun 27, 2022
d4665d8
indent
Jun 27, 2022
3817571
increase timeout
Jun 27, 2022
83d0709
install patchelf
Jun 27, 2022
7365ae8
no update information
Jun 28, 2022
4e28dfa
remove sign lines
Jun 28, 2022
29b509f
restore original circleci config
Jun 28, 2022
cafb110
Merge pull request #8931 from filecoin-project/appimage-broken-build
Jun 28, 2022
3ad2fc5
feat: FVM Debug Dual Execution
vyzo Jun 10, 2022
a52d584
an attempt at cleanup
arajasek Jun 28, 2022
f9cf25f
address review
arajasek Jun 29, 2022
906463b
more review
arajasek Jun 29, 2022
709fe5c
Merge pull request #8841 from filecoin-project/feat/debug-execution
arajasek Jun 29, 2022
35dd30c
Upgrade index-provider and all related dependencies
masih Jun 22, 2022
6f686ca
Upgrade to go-blockstore `1.2.0` and go-cid `0.2.0`
masih Jun 28, 2022
535129a
Upgrade to go-fil-markets `v1.22.2`
masih Jun 28, 2022
57ed804
Update `ffi` submodule to the backport of `go-blockstore` dep. update
masih Jun 29, 2022
39a710e
Address lint issues as a result of libp2p deprecations and tidy go mod
masih Jun 29, 2022
e8c44ba
Remove dependency to archived quic and regenerate CLI docs
masih Jun 29, 2022
0c34699
unbreak itests
arajasek Jun 29, 2022
ed65b4c
Api call to get actor cids works for versions < 16
geoff-vball Jun 28, 2022
4268b42
review fixes
geoff-vball Jun 29, 2022
56c7e7a
Remove old functions for getting actors cids
geoff-vball Jun 29, 2022
68fc567
Merge pull request #8945 from filecoin-project/asr/upgrade-idxprov
arajasek Jun 29, 2022
4bebce0
Remove StateActorManifestCID
geoff-vball Jun 29, 2022
3bb7e9d
Merge pull request #8941 from filecoin-project/gstuart/actors-cids-ol…
geoff-vball Jun 29, 2022
8f087c7
chore: state: clarify state tree versioning in comment
arajasek Jun 29, 2022
f46cfb4
Merge pull request #8947 from filecoin-project/arajasek-patch-2
jennijuju Jun 30, 2022
9bfb370
ux: print absolute time for proving period start in proving cli
magik6k Jul 1, 2022
d1e325a
Update deps
ZenGround0 Jul 1, 2022
ef5bbde
net disconnect
ZenGround0 Jul 1, 2022
a686809
disconnect just takes pid
ZenGround0 Jul 1, 2022
db72f24
go mod tidy
ZenGround0 Jul 1, 2022
27604ac
Proper pid parsing
ZenGround0 Jul 1, 2022
0ace229
Actually proper pid decode
ZenGround0 Jul 1, 2022
0277ff4
wdpost: move fault/recover code to a separate file
magik6k Jul 1, 2022
84881f6
sealer: Config for disabling builtin PoSt
magik6k Jul 1, 2022
59f3161
wdpost: Config for disabling sector prechecks
magik6k Jul 1, 2022
1607f92
Update deps
ZenGround0 Jul 1, 2022
1d2cbd3
go mod tidy
ZenGround0 Jul 1, 2022
d5100f8
cfgdoc-gen: Handle empty lines in comments
magik6k Jul 1, 2022
2daefe5
Merge pull request #8955 from filecoin-project/feat/disconnect-cmd
magik6k Jul 1, 2022
a1675a8
ux: cli: add compute description
rjan90 Jul 3, 2022
7e7dc91
Merge pull request #8963 from filecoin-project/ux/proving-description
magik6k Jul 4, 2022
d5206aa
Merge pull request #8954 from filecoin-project/feat/prov-info-time
magik6k Jul 4, 2022
9ad7276
feat: cli: Hide sector nums in 'proving deadline' by default
magik6k Jul 1, 2022
2e7a2b1
Merge pull request #8952 from filecoin-project/feat/prov-dl-info-nums
magik6k Jul 4, 2022
9a97d83
wdpost: itests for new config fields
magik6k Jul 4, 2022
b35a325
Fixup typos
arajasek Jul 4, 2022
75d78de
Merge pull request #8959 from filecoin-project/feat/post-check-config
arajasek Jul 4, 2022
c379936
bump version
rjan90 Jun 16, 2022
0208a14
update changelog
rjan90 Jun 16, 2022
9141086
make gen
jennijuju Jun 16, 2022
2065149
Update CHANGELOG.md
rjan90 Jun 16, 2022
01a3e52
bump version to v1.17.0-rc2
rjan90 Jun 23, 2022
bda4b5a
Updated CHANGELOG
rjan90 Jun 29, 2022
6bcb37f
Update CHANGELOG
rjan90 Jun 30, 2022
58402b9
Add sub-info in Changelog
rjan90 Jul 1, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
sealing pipeline: Use non-special msg wait APIs
  • Loading branch information
magik6k committed Jun 16, 2022
commit 048bfe6d5b8fb101129aa047407a8ca749d1c046
38 changes: 4 additions & 34 deletions storage/adapter_storage_miner.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ import (

"github.com/filecoin-project/lotus/api"
"github.com/filecoin-project/lotus/blockstore"
"github.com/filecoin-project/lotus/build"
"github.com/filecoin-project/lotus/chain/actors"
"github.com/filecoin-project/lotus/chain/actors/builtin/market"
"github.com/filecoin-project/lotus/chain/actors/builtin/miner"
Expand Down Expand Up @@ -103,42 +102,13 @@ func (s SealingAPIAdapter) ChainReadObj(ctx context.Context, ocid cid.Cid) ([]by
return s.delegate.ChainReadObj(ctx, ocid)
}

func (s SealingAPIAdapter) StateWaitMsg(ctx context.Context, mcid cid.Cid) (pipeline.MsgLookup, error) {
wmsg, err := s.delegate.StateWaitMsg(ctx, mcid, build.MessageConfidence, api.LookbackNoLimit, true)
if err != nil {
return pipeline.MsgLookup{}, err
}
func (s SealingAPIAdapter) StateWaitMsg(ctx context.Context, cid cid.Cid, confidence uint64, limit abi.ChainEpoch, allowReplaced bool) (*api.MsgLookup, error) {
return s.delegate.StateWaitMsg(ctx, cid, confidence, limit, allowReplaced)

return pipeline.MsgLookup{
Receipt: pipeline.MessageReceipt{
ExitCode: wmsg.Receipt.ExitCode,
Return: wmsg.Receipt.Return,
GasUsed: wmsg.Receipt.GasUsed,
},
TipSetTok: wmsg.TipSet,
Height: wmsg.Height,
}, nil
}

func (s SealingAPIAdapter) StateSearchMsg(ctx context.Context, c cid.Cid) (*pipeline.MsgLookup, error) {
wmsg, err := s.delegate.StateSearchMsg(ctx, types.EmptyTSK, c, api.LookbackNoLimit, true)
if err != nil {
return nil, err
}

if wmsg == nil {
return nil, nil
}

return &pipeline.MsgLookup{
Receipt: pipeline.MessageReceipt{
ExitCode: wmsg.Receipt.ExitCode,
Return: wmsg.Receipt.Return,
GasUsed: wmsg.Receipt.GasUsed,
},
TipSetTok: wmsg.TipSet,
Height: wmsg.Height,
}, nil
func (s SealingAPIAdapter) StateSearchMsg(ctx context.Context, from types.TipSetKey, msg cid.Cid, limit abi.ChainEpoch, allowReplaced bool) (*api.MsgLookup, error) {
return s.delegate.StateSearchMsg(ctx, from, msg, limit, allowReplaced)
}

func (s SealingAPIAdapter) StateComputeDataCommitment(ctx context.Context, maddr address.Address, sectorType abi.RegisteredSealProof, deals []abi.DealID, tsk types.TipSetKey) (cid.Cid, error) {
Expand Down
58 changes: 5 additions & 53 deletions storage/pipeline/currentdealinfo.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import (
"bytes"
"context"
"fmt"

"github.com/ipfs/go-cid"
"golang.org/x/xerrors"

Expand All @@ -23,7 +22,7 @@ type CurrentDealInfoAPI interface {
ChainGetMessage(context.Context, cid.Cid) (*types.Message, error)
StateLookupID(context.Context, address.Address, types.TipSetKey) (address.Address, error)
StateMarketStorageDeal(context.Context, abi.DealID, types.TipSetKey) (*api.MarketDeal, error)
StateSearchMsg(context.Context, cid.Cid) (*MsgLookup, error)
StateSearchMsg(ctx context.Context, from types.TipSetKey, msg cid.Cid, limit abi.ChainEpoch, allowReplaced bool) (*api.MsgLookup, error)
StateNetworkVersion(ctx context.Context, tok types.TipSetKey) (network.Version, error)
}

Expand Down Expand Up @@ -69,7 +68,7 @@ func (mgr *CurrentDealInfoManager) dealIDFromPublishDealsMsg(ctx context.Context
dealID := abi.DealID(0)

// Get the return value of the publish deals message
lookup, err := mgr.CDAPI.StateSearchMsg(ctx, publishCid)
lookup, err := mgr.CDAPI.StateSearchMsg(ctx, tok, publishCid, api.LookbackNoLimit, true)
if err != nil {
return dealID, types.EmptyTSK, xerrors.Errorf("looking for publish deal message %s: search msg failed: %w", publishCid, err)
}
Expand All @@ -82,7 +81,7 @@ func (mgr *CurrentDealInfoManager) dealIDFromPublishDealsMsg(ctx context.Context
return dealID, types.EmptyTSK, xerrors.Errorf("looking for publish deal message %s: non-ok exit code: %s", publishCid, lookup.Receipt.ExitCode)
}

nv, err := mgr.CDAPI.StateNetworkVersion(ctx, lookup.TipSetTok)
nv, err := mgr.CDAPI.StateNetworkVersion(ctx, lookup.TipSet)
if err != nil {
return dealID, types.EmptyTSK, xerrors.Errorf("getting network version: %w", err)
}
Expand Down Expand Up @@ -113,7 +112,7 @@ func (mgr *CurrentDealInfoManager) dealIDFromPublishDealsMsg(ctx context.Context
// There is a single deal in this publish message and no deal proposal
// was supplied, so we have nothing to compare against. Just assume
// the deal ID is correct and that it was valid
return dealIDs[0], lookup.TipSetTok, nil
return dealIDs[0], lookup.TipSet, nil
}

// Get the parameters to the publish deals message
Expand Down Expand Up @@ -166,7 +165,7 @@ func (mgr *CurrentDealInfoManager) dealIDFromPublishDealsMsg(ctx context.Context
if outIdx >= len(dealIDs) {
return dealID, types.EmptyTSK, xerrors.Errorf("invalid publish storage deals ret marking %d as valid while only returning %d valid deals in publish deal message %s", outIdx, len(dealIDs), publishCid)
}
return dealIDs[outIdx], lookup.TipSetTok, nil
return dealIDs[outIdx], lookup.TipSet, nil
}

func (mgr *CurrentDealInfoManager) CheckDealEquality(ctx context.Context, tok types.TipSetKey, p1, p2 market.DealProposal) (bool, error) {
Expand All @@ -190,50 +189,3 @@ func (mgr *CurrentDealInfoManager) CheckDealEquality(ctx context.Context, tok ty
p1.Provider == p2.Provider &&
p1ClientID == p2ClientID, nil
}

type CurrentDealInfoTskAPI interface {
ChainGetMessage(ctx context.Context, mc cid.Cid) (*types.Message, error)
StateLookupID(context.Context, address.Address, types.TipSetKey) (address.Address, error)
StateMarketStorageDeal(context.Context, abi.DealID, types.TipSetKey) (*api.MarketDeal, error)
StateSearchMsg(ctx context.Context, from types.TipSetKey, msg cid.Cid, limit abi.ChainEpoch, allowReplaced bool) (*api.MsgLookup, error)
StateNetworkVersion(context.Context, types.TipSetKey) (network.Version, error)
}

type CurrentDealInfoAPIAdapter struct {
CurrentDealInfoTskAPI
}

func (c *CurrentDealInfoAPIAdapter) StateLookupID(ctx context.Context, a address.Address, tsk types.TipSetKey) (address.Address, error) {
return c.CurrentDealInfoTskAPI.StateLookupID(ctx, a, tsk)
}

func (c *CurrentDealInfoAPIAdapter) StateMarketStorageDeal(ctx context.Context, dealID abi.DealID, tsk types.TipSetKey) (*api.MarketDeal, error) {
return c.CurrentDealInfoTskAPI.StateMarketStorageDeal(ctx, dealID, tsk)
}

func (c *CurrentDealInfoAPIAdapter) StateSearchMsg(ctx context.Context, k cid.Cid) (*MsgLookup, error) {
wmsg, err := c.CurrentDealInfoTskAPI.StateSearchMsg(ctx, types.EmptyTSK, k, api.LookbackNoLimit, true)
if err != nil {
return nil, err
}

if wmsg == nil {
return nil, nil
}

return &MsgLookup{
Receipt: MessageReceipt{
ExitCode: wmsg.Receipt.ExitCode,
Return: wmsg.Receipt.Return,
GasUsed: wmsg.Receipt.GasUsed,
},
TipSetTok: wmsg.TipSet,
Height: wmsg.Height,
}, nil
}

func (c *CurrentDealInfoAPIAdapter) StateNetworkVersion(ctx context.Context, tsk types.TipSetKey) (network.Version, error) {
return c.CurrentDealInfoTskAPI.StateNetworkVersion(ctx, tsk)
}

var _ CurrentDealInfoAPI = (*CurrentDealInfoAPIAdapter)(nil)
46 changes: 23 additions & 23 deletions storage/pipeline/currentdealinfo_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ func TestGetCurrentDealInfo(t *testing.T) {
}

type testCaseData struct {
searchMessageLookup *MsgLookup
searchMessageLookup *api.MsgLookup
searchMessageErr error
marketDeals map[abi.DealID]*api.MarketDeal
publishCid cid.Cid
Expand All @@ -114,8 +114,8 @@ func TestGetCurrentDealInfo(t *testing.T) {
testCases := map[string]testCaseData{
"deal lookup succeeds": {
publishCid: dummyCid,
searchMessageLookup: &MsgLookup{
Receipt: MessageReceipt{
searchMessageLookup: &api.MsgLookup{
Receipt: types.MessageReceipt{
ExitCode: exitcode.Ok,
Return: makePublishDealsReturnBytesOldVersion(t, []abi.DealID{successDealID}),
},
Expand All @@ -129,8 +129,8 @@ func TestGetCurrentDealInfo(t *testing.T) {
},
"deal lookup succeeds two return values": {
publishCid: dummyCid,
searchMessageLookup: &MsgLookup{
Receipt: MessageReceipt{
searchMessageLookup: &api.MsgLookup{
Receipt: types.MessageReceipt{
ExitCode: exitcode.Ok,
Return: makePublishDealsReturnBytesOldVersion(t, []abi.DealID{earlierDealID, successDealID}),
},
Expand All @@ -145,8 +145,8 @@ func TestGetCurrentDealInfo(t *testing.T) {
},
"deal lookup fails proposal mis-match": {
publishCid: dummyCid,
searchMessageLookup: &MsgLookup{
Receipt: MessageReceipt{
searchMessageLookup: &api.MsgLookup{
Receipt: types.MessageReceipt{
ExitCode: exitcode.Ok,
Return: makePublishDealsReturnBytesOldVersion(t, []abi.DealID{earlierDealID}),
},
Expand All @@ -160,8 +160,8 @@ func TestGetCurrentDealInfo(t *testing.T) {
},
"deal lookup handles invalid actor output with mismatched count of deals and return values": {
publishCid: dummyCid,
searchMessageLookup: &MsgLookup{
Receipt: MessageReceipt{
searchMessageLookup: &api.MsgLookup{
Receipt: types.MessageReceipt{
ExitCode: exitcode.Ok,
Return: makePublishDealsReturnBytesOldVersion(t, []abi.DealID{earlierDealID}),
},
Expand All @@ -177,8 +177,8 @@ func TestGetCurrentDealInfo(t *testing.T) {

"deal lookup fails when deal was not valid and index exceeds output array": {
publishCid: dummyCid,
searchMessageLookup: &MsgLookup{
Receipt: MessageReceipt{
searchMessageLookup: &api.MsgLookup{
Receipt: types.MessageReceipt{
ExitCode: exitcode.Ok,
Return: makePublishDealsReturn(t, []abi.DealID{earlierDealID}, []uint64{0}),
},
Expand All @@ -195,8 +195,8 @@ func TestGetCurrentDealInfo(t *testing.T) {

"deal lookup succeeds when theres a separate deal failure": {
publishCid: dummyCid,
searchMessageLookup: &MsgLookup{
Receipt: MessageReceipt{
searchMessageLookup: &api.MsgLookup{
Receipt: types.MessageReceipt{
ExitCode: exitcode.Ok,
Return: makePublishDealsReturn(t, []abi.DealID{anotherDealID, successDealID}, []uint64{0, 2}),
},
Expand All @@ -214,8 +214,8 @@ func TestGetCurrentDealInfo(t *testing.T) {

"deal lookup succeeds, target proposal nil, single deal in message": {
publishCid: dummyCid,
searchMessageLookup: &MsgLookup{
Receipt: MessageReceipt{
searchMessageLookup: &api.MsgLookup{
Receipt: types.MessageReceipt{
ExitCode: exitcode.Ok,
Return: makePublishDealsReturnBytesOldVersion(t, []abi.DealID{successDealID}),
},
Expand All @@ -229,8 +229,8 @@ func TestGetCurrentDealInfo(t *testing.T) {
},
"deal lookup fails, multiple deals in return value but target proposal nil": {
publishCid: dummyCid,
searchMessageLookup: &MsgLookup{
Receipt: MessageReceipt{
searchMessageLookup: &api.MsgLookup{
Receipt: types.MessageReceipt{
ExitCode: exitcode.Ok,
Return: makePublishDealsReturnBytesOldVersion(t, []abi.DealID{earlierDealID, successDealID}),
},
Expand Down Expand Up @@ -258,8 +258,8 @@ func TestGetCurrentDealInfo(t *testing.T) {
},
"return code not ok": {
publishCid: dummyCid,
searchMessageLookup: &MsgLookup{
Receipt: MessageReceipt{
searchMessageLookup: &api.MsgLookup{
Receipt: types.MessageReceipt{
ExitCode: exitcode.ErrIllegalState,
},
},
Expand All @@ -269,8 +269,8 @@ func TestGetCurrentDealInfo(t *testing.T) {
},
"unable to unmarshal params": {
publishCid: dummyCid,
searchMessageLookup: &MsgLookup{
Receipt: MessageReceipt{
searchMessageLookup: &api.MsgLookup{
Receipt: types.MessageReceipt{
ExitCode: exitcode.Ok,
Return: []byte("applesauce"),
},
Expand Down Expand Up @@ -319,7 +319,7 @@ type marketDealKey struct {
}

type CurrentDealInfoMockAPI struct {
SearchMessageLookup *MsgLookup
SearchMessageLookup *api.MsgLookup
SearchMessageErr error

MarketDeals map[marketDealKey]*api.MarketDeal
Expand Down Expand Up @@ -371,7 +371,7 @@ func (mapi *CurrentDealInfoMockAPI) StateMarketStorageDeal(ctx context.Context,
return deal, nil
}

func (mapi *CurrentDealInfoMockAPI) StateSearchMsg(ctx context.Context, c cid.Cid) (*MsgLookup, error) {
func (mapi *CurrentDealInfoMockAPI) StateSearchMsg(ctx context.Context, from types.TipSetKey, msg cid.Cid, limit abi.ChainEpoch, allowReplaced bool) (*api.MsgLookup, error) {
if mapi.SearchMessageLookup == nil {
return mapi.SearchMessageLookup, mapi.SearchMessageErr
}
Expand Down
20 changes: 10 additions & 10 deletions storage/pipeline/mocks/api.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions storage/pipeline/sealing.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ var ErrSectorAllocated = errors.New("sectorNumber is allocated, but PreCommit in
//go:generate go run github.com/golang/mock/mockgen -destination=mocks/api.go -package=mocks . SealingAPI

type SealingAPI interface {
StateWaitMsg(context.Context, cid.Cid) (MsgLookup, error)
StateSearchMsg(context.Context, cid.Cid) (*MsgLookup, error)
StateWaitMsg(ctx context.Context, cid cid.Cid, confidence uint64, limit abi.ChainEpoch, allowReplaced bool) (*api.MsgLookup, error)
StateSearchMsg(ctx context.Context, from types.TipSetKey, msg cid.Cid, limit abi.ChainEpoch, allowReplaced bool) (*api.MsgLookup, error)
StateComputeDataCommitment(ctx context.Context, maddr address.Address, sectorType abi.RegisteredSealProof, deals []abi.DealID, tok types.TipSetKey) (cid.Cid, error)

// Can return ErrSectorAllocated in case precommit info wasn't found, but the sector number is marked as allocated
Expand Down
7 changes: 4 additions & 3 deletions storage/pipeline/states_failed.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package sealing

import (
"context"
"github.com/filecoin-project/lotus/api"
"time"

"github.com/hashicorp/go-multierror"
Expand Down Expand Up @@ -80,7 +81,7 @@ func (m *Sealing) handlePreCommitFailed(ctx statemachine.Context, sector SectorI
}

if sector.PreCommitMessage != nil {
mw, err := m.Api.StateSearchMsg(ctx.Context(), *sector.PreCommitMessage)
mw, err := m.Api.StateSearchMsg(ctx.Context(), tok, *sector.PreCommitMessage, api.LookbackNoLimit, true)
if err != nil {
// API error
if err := failedCooldown(ctx, sector); err != nil {
Expand Down Expand Up @@ -189,7 +190,7 @@ func (m *Sealing) handleSubmitReplicaUpdateFailed(ctx statemachine.Context, sect
}

if sector.ReplicaUpdateMessage != nil {
mw, err := m.Api.StateSearchMsg(ctx.Context(), *sector.ReplicaUpdateMessage)
mw, err := m.Api.StateSearchMsg(ctx.Context(), types.EmptyTSK, *sector.ReplicaUpdateMessage, api.LookbackNoLimit, true)
if err != nil {
// API error
return ctx.Send(SectorRetrySubmitReplicaUpdateWait{})
Expand Down Expand Up @@ -269,7 +270,7 @@ func (m *Sealing) handleCommitFailed(ctx statemachine.Context, sector SectorInfo
}

if sector.CommitMessage != nil {
mw, err := m.Api.StateSearchMsg(ctx.Context(), *sector.CommitMessage)
mw, err := m.Api.StateSearchMsg(ctx.Context(), tok, *sector.CommitMessage, api.LookbackNoLimit, true)
if err != nil {
// API error
if err := failedCooldown(ctx, sector); err != nil {
Expand Down
Loading