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

Add --unproven flag to the sectors list command #7263

Merged

Conversation

magik6k
Copy link
Contributor

@magik6k magik6k commented Sep 2, 2021

Depends on #7261

This PR adds an --unproven flag to lotus-miner sectors list, which makes it print only sectors which are being sealed. It also is a lot faster than printing all sectors.

@magik6k magik6k requested a review from a team as a code owner September 2, 2021 20:09
@codecov
Copy link

codecov bot commented Sep 2, 2021

Codecov Report

Merging #7263 (271cbf9) into feat/sectors-list-sealing-deals (3451964) will increase coverage by 0.02%.
The diff coverage is 18.75%.

Impacted file tree graph

@@                         Coverage Diff                         @@
##           feat/sectors-list-sealing-deals    #7263      +/-   ##
===================================================================
+ Coverage                            39.07%   39.09%   +0.02%     
===================================================================
  Files                                  614      614              
  Lines                                64912    64920       +8     
===================================================================
+ Hits                                 25366    25383      +17     
+ Misses                               35140    35139       -1     
+ Partials                              4406     4398       -8     
Impacted Files Coverage Δ
cmd/lotus-miner/sectors.go 11.13% <18.75%> (-0.09%) ⬇️
chain/actors/builtin/miner/diff.go 48.52% <0.00%> (-10.30%) ⬇️
chain/stmgr/call.go 67.87% <0.00%> (-3.64%) ⬇️
extern/sector-storage/sched.go 83.05% <0.00%> (-1.66%) ⬇️
extern/storage-sealing/fsm.go 57.42% <0.00%> (-1.61%) ⬇️
chain/vm/vm.go 59.47% <0.00%> (-1.12%) ⬇️
chain/messagepool/selection.go 80.12% <0.00%> (-0.41%) ⬇️
node/impl/storminer.go 22.46% <0.00%> (-0.40%) ⬇️
chain/sync.go 64.94% <0.00%> (-0.34%) ⬇️
chain/messagepool/messagepool.go 57.00% <0.00%> (-0.13%) ⬇️
... and 15 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3451964...271cbf9. Read the comment docs.


if cctx.Bool("unproven") {
for state := range sealing.ExistSectorStateList {
if state == sealing.Proving {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One minor point of confusion that I think is possible with this code and terminology is that there is a brief window where the sector is marked in onchain data as "unproven" but the sealing FSM sees the sector as "Proving". If I understand the FSM correctly the sector transitions to FinalizeSector and then Proving after successful ProveCommit message without waiting for any window posts but miner state keeps the sector in "unproven" state until first post.

If there is another name you could give this flag (unfinalized, uncommitted, unporeped?) it would prevent confusion with the on chain concept.

@magik6k magik6k merged commit 03e2016 into feat/sectors-list-sealing-deals Sep 3, 2021
@magik6k magik6k deleted the feat/sectors-list-unproven branch September 3, 2021 15:52
@magik6k magik6k restored the feat/sectors-list-unproven branch September 9, 2021 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants