-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Snap Deals full unseal #8478
Snap Deals full unseal #8478
Conversation
Codecov Report
@@ Coverage Diff @@
## master #8478 +/- ##
==========================================
- Coverage 40.86% 40.79% -0.07%
==========================================
Files 686 685 -1
Lines 75710 75646 -64
==========================================
- Hits 30939 30863 -76
- Misses 39445 39447 +2
- Partials 5326 5336 +10
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few things but this is close to ready
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM after a bit of out of band analysis
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generally looks good, just a few comments.
Looks like there is unintentional extern/filecoin-ffi
change committed.
Snapdeals test appears to be unhappy:
2022-04-15T14:58:54.849Z WARN stores stores/local.go:599 RemoveCopies: no primary copies of sector {1000 1} (sealed), not removing anything
2022-04-15T14:58:54.849Z WARN stores stores/remote.go:73 remote RemoveCopies: no primary copies of sector {1000 1} (sealed), not removing anything
2022-04-15T14:58:54.849Z WARN stores stores/local.go:599 RemoveCopies: no primary copies of sector {1000 1} (cache), not removing anything
2022-04-15T14:58:54.849Z WARN stores stores/remote.go:73 remote RemoveCopies: no primary copies of sector {1000 1} (cache), not removing anything
Release Sector Key
Unseal Replica
manager_test.go:323:
Error Trace: manager_test.go:323
Error: Received unexpected error:
worker UnsealPiece call:
github.com/filecoin-project/lotus/extern/sector-storage.(*Manager).SectorsUnsealPiece
/home/circleci/project/extern/sector-storage/manager.go:327
- storage call error 0: %!w(failed to acquire sector {1000 1} from remote(2): sector not found [Hostname: cba2a59638c7])
Test: TestSnapDeals
--- FAIL: TestSnapDeals (24.09s)
extern/sector-storage/manager.go
Outdated
if _, err := m.waitSimpleCall(ctx)(worker.Fetch(ctx, sector, storiface.FTSealed|storiface.FTCache, storiface.PathSealing, storiface.AcquireCopy)); err != nil { | ||
return xerrors.Errorf("copy sealed/cache sector data: %w", err) | ||
_, err := m.waitSimpleCall(ctx)(worker.Fetch(ctx, sector, storiface.FTSealed|storiface.FTCache, storiface.PathSealing, storiface.AcquireCopy)) | ||
if err != nil && !xerrors.Is(err, storiface.ErrSectorNotFound) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Those errors won't get propagated, would need filecoin-project/go-jsonrpc#36 (Maybe worth finally landing for this?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@magik6k I found the issue that was causing these errors to be returned as strings and it is fixed in the latest commit. Is there still a codepath where this might hit RPC? If so, could you show me where it is?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
worker.Fetch is an rpc call.
This will only work with the miner built-in worker, as that one doesn't go through rpc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@magik6k Talked this over with Zen and we decided that not checking the error type will still give us the desired result in all cases. If you agree, I think we can land this PR
@geoff-vball could you plz update the pr title format as suggested in the template? |
Blocked by filecoin-project/go-jsonrpc#36 |
79ce3c6
to
17c3eb0
Compare
Co-authored-by: Łukasz Magiera <[email protected]>
17c3eb0
to
94ceb03
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see anything obviously wrong here, and it's definitely better that the current state of things.
Related Issues
resolves #8230
Proposed Changes
Lotus can now recover unsealed data from a replica-update sector if the sector key has been deleted.
Checklist
Before you mark the PR ready for review, please make sure that:
<PR type>: <area>: <change being made>
fix: mempool: Introduce a cache for valid signatures
PR type
: fix, feat, INTERFACE BREAKING CHANGE, CONSENSUS BREAKING, build, chore, ci, docs,perf, refactor, revert, style, testarea
: api, chain, state, vm, data transfer, market, mempool, message, block production, multisig, networking, paychan, proving, sealing, wallet, deps