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

Feat: cli: Remove verified data cap #8175

Merged
merged 10 commits into from
Feb 24, 2022

Conversation

geoff-vball
Copy link
Contributor

Related Issues

Closes Issue #7863

Proposed Changes

Added the following cli commands:
lotus filplus sign-remove-data-cap-proposal
lotus-shed verifreg remove-verified-client-data-cap

Additional Info

Tested on devnet. Works as expected.

Checklist

Before you mark the PR ready for review, please make sure that:

  • All commits have a clear commit message.
  • The PR title is in the form of of <PR type>: <area>: <change being made>
    • example: 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, test
    • area: api, chain, state, vm, data transfer, market, mempool, message, block production, multisig, networking, paychan, proving, sealing, wallet, deps
  • This PR has tests for new functionality or change in behaviour
  • If new user-facing features are introduced, clear usage guidelines and / or documentation updates should be included in https://lotus.filecoin.io or Discussion Tutorials.
  • CI is green

@geoff-vball geoff-vball requested a review from a team as a code owner February 23, 2022 04:03
@codecov
Copy link

codecov bot commented Feb 23, 2022

Codecov Report

Merging #8175 (e0382c5) into master (5d416de) will decrease coverage by 0.09%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #8175      +/-   ##
==========================================
- Coverage   39.91%   39.82%   -0.10%     
==========================================
  Files         666      666              
  Lines       72554    72733     +179     
==========================================
+ Hits        28963    28965       +2     
- Misses      38553    38717     +164     
- Partials     5038     5051      +13     
Impacted Files Coverage Δ
chain/actors/builtin/verifreg/util.go 13.15% <0.00%> (-9.57%) ⬇️
chain/actors/builtin/verifreg/v5.go 51.51% <0.00%> (-7.11%) ⬇️
chain/actors/builtin/verifreg/v6.go 21.21% <0.00%> (-2.93%) ⬇️
chain/actors/builtin/verifreg/v7.go 45.45% <0.00%> (-6.27%) ⬇️
chain/actors/builtin/verifreg/verifreg.go 56.16% <ø> (ø)
cli/filplus.go 0.00% <0.00%> (ø)
cmd/lotus-shed/verifreg.go 0.00% <0.00%> (ø)
markets/loggers/loggers.go 88.88% <0.00%> (-11.12%) ⬇️
cli/util.go 70.83% <0.00%> (-8.34%) ⬇️
chain/events/observer.go 71.64% <0.00%> (-6.72%) ⬇️
... and 18 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 5d416de...e0382c5. Read the comment docs.

Copy link
Contributor

@arajasek arajasek left a comment

Choose a reason for hiding this comment

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

Various nits

cli/filplus.go Outdated

var filplusSignRemoveDataCapProposal = &cli.Command{
Name: "sign-remove-data-cap-proposal",
Usage: "TODO",
Copy link
Contributor

Choose a reason for hiding this comment

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

fill in pls

chain/actors/builtin/verifreg/util.go Show resolved Hide resolved
cli/filplus.go Outdated Show resolved Hide resolved
cli/filplus.go Outdated
}
}

// TODO: This should be abstracted over actor versions
Copy link
Contributor

Choose a reason for hiding this comment

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

Drop this TODO

cli/filplus.go Show resolved Hide resolved
cli/filplus.go Outdated
},
Action: func(cctx *cli.Context) error {
if cctx.Args().Len() != 3 {
return fmt.Errorf("must specify three arguments: verifier address, client address, and allowance to remove")
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
return fmt.Errorf("must specify three arguments: verifier address, client address, and allowance to remove")
return fmt.Errorf("must specify three arguments: notary address, client address, and allowance to remove")

cmd/lotus-shed/verifreg.go Outdated Show resolved Hide resolved
cmd/lotus-shed/verifreg.go Outdated Show resolved Hide resolved
cmd/lotus-shed/verifreg.go Show resolved Hide resolved
cmd/lotus-shed/verifreg.go Show resolved Hide resolved
geoff-vball and others added 2 commits February 23, 2022 12:14
Co-authored-by: Aayush Rajasekaran <[email protected]>
Co-authored-by: Aayush Rajasekaran <[email protected]>
@arajasek
Copy link
Contributor

Needs make gen

return false, 0, xerrors.Errorf("loading verifreg: %w", err)
}
if vh == nil {
return false, 0, xerrors.Errorf("remove data cap proposal hamt not found. you are probably using an incompatible version of actors")
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
return false, 0, xerrors.Errorf("remove data cap proposal hamt not found. you are probably using an incompatible version of actors")
return false, 0, xerrors.Errorf("remove data cap proposal hamt not found (only exists from v7 and after)")

Co-authored-by: Aayush Rajasekaran <[email protected]>
@arajasek arajasek merged commit b8cd154 into master Feb 24, 2022
@arajasek arajasek deleted the gstuart/remove-verified-data-cap-cli branch February 24, 2022 18:33
@jennijuju jennijuju mentioned this pull request Feb 24, 2022
14 tasks
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