Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

nomination-pools: Consider allowing partial unbonding #10902

Closed
emostov opened this issue Feb 22, 2022 · 1 comment
Closed

nomination-pools: Consider allowing partial unbonding #10902

emostov opened this issue Feb 22, 2022 · 1 comment
Assignees
Labels
J0-enhancement An additional feature request. Z2-medium Can be fixed by a coder with good Rust knowledge but little knowledge of the codebase.

Comments

@emostov
Copy link
Contributor

emostov commented Feb 22, 2022

In the current design a delegator cannot unbond a sub portion of their stake; instead they must unbond all their stake at once. This was chosen for implementation simplicity. Instead we shoud allow a delagator to only unbond sub portion of their funds, thus giving users more flexibility. We could use a bounded btreeset to track the eras they are unbonding in and make sure to destroy the delegator when they withdraw unbonded and the btreeset is empty.

It will probably keep things simpler if the pool's creator still had to unbond all funds at once. This is ok because they can only unbond once the pool is in a destroying state and no other delegators remain.

We should still maintain the invariant that a delegator can only be a member of one pool at a time.

Should wait until #10694 is merged to start working on this.

@emostov emostov added J0-enhancement An additional feature request. Z2-medium Can be fixed by a coder with good Rust knowledge but little knowledge of the codebase. labels Feb 22, 2022
@emostov emostov mentioned this issue Feb 22, 2022
4 tasks
@emostov
Copy link
Contributor Author

emostov commented Apr 21, 2022

Closed by #11212

@emostov emostov closed this as completed Apr 21, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
J0-enhancement An additional feature request. Z2-medium Can be fixed by a coder with good Rust knowledge but little knowledge of the codebase.
Projects
Status: Done
Development

No branches or pull requests

2 participants