-
Notifications
You must be signed in to change notification settings - Fork 243
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
Support shared hold id to have constant number of hold id #3013
Conversation
Previously, we need to use withdraw_and_hold and then Currency::release Signed-off-by: linning <linningde25@gmail.com>
Signed-off-by: linning <linningde25@gmail.com>
Signed-off-by: linning <linningde25@gmail.com>
NOTE: we still need to keep track of the domain instantiation deposit in the state in case the DomainInstantiationDeposit change in the future Signed-off-by: linning <linningde25@gmail.com>
NOTE: we still need to keep track of the channel reserve fee in the state in case the ChannelReserveFee change in the future Signed-off-by: linning <linningde25@gmail.com>
Signed-off-by: linning <linningde25@gmail.com>
7a5bdff
to
338cf7b
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.
Looks good! I don’t have enough context to fully review, but here are some small things I wasn’t sure about.
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.
also, lgtm and not 100% familiar with the code to approve
@dariolina perhaps also @nazar-pc please take a look, thanks! |
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.
Makes sense to me overall as well, but I don't have the invariants in my head either, just like everyone else 🤷
Signed-off-by: linning <linningde25@gmail.com>
Had to stop CI due to |
close #2674
This PR supports shared hold id that is used in staking, domain instantiation, and XDM channel, such that we can have a constant number of hold id variants and extrinsic that require creating hold won't fail due to the fixed hold id limit.
Because we also support the nomination of multiple different operators, opening multiple channel, and instantiating multiple domains so we have to add storage keep tracking of the hold balance.
Code contributor checklist: