-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
move Un/DelegateCoins to x/staking #4056
Comments
The staking keeper when then need access to the auth's account keeper...just for this sole purpose. The staking keeper already needed the bank keeper, hence we decided to implement on such. Otherwise, the staking keeper would need to get the account, do the arithmetic, and set the coins. Sounds like a banking operation to me. |
@alexanderbez I don't think @fedekunze meant to call into question the design rationale, which is very clear indeed. However in his use case of develping a |
Sure, so just don't simply use those features 😉. That or update the staking module to do accounting. |
Yeah I think it could make sense to include these accounting features within the staking module - the ultimate home of delegation logic is in fact staking. Ideally we could somehow abstract out accounting patterns within bank so that any duplicate accounting patterns required for use within staking for the delegation logic can simply come directly from bank. This said, I think that the fact that the initial build of the delegation logic has been added to bank is totally acceptable as the MVP. This issue simply describes the next evolution |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Summary
Discuss whether
DelegateCoins
andUndelegateCoins
should live within the bank or staking module.Problem Definition
Currently the
bank
keeper handles the delegation and delegation of coins. The thing with this is that as an SDK dev I don't want to use thestaking
module (say by implementing an own PoA or PoW module). Then this 2 functions are useless:cosmos-sdk/x/bank/keeper.go
Lines 14 to 26 in 055d219
cc: @rigelrozanski @cwgoes @alessio @jackzampolin
For Admin Use
The text was updated successfully, but these errors were encountered: