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

fix sufficients error #345

Merged
merged 3 commits into from
Aug 23, 2023
Merged

fix sufficients error #345

merged 3 commits into from
Aug 23, 2023

Conversation

brenzi
Copy link
Member

@brenzi brenzi commented Aug 21, 2023

closes #333

  • added a unit test that reproduces the issue
  • error was: issue() didn't check for account creation to inc_sufficients

consequence:
current mainnet state is dirty. we have two options

  1. runtime state migration checking minimal balances on all accounts and recalculating sufficients and providers. Risk: overloading the block
  2. lazy dispatchable check_sufficients which does the above per account. combined with a script that calls this extrinsic for every account: Risk: none

Copy link
Member

@clangenb clangenb left a comment

Choose a reason for hiding this comment

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

Good catch. Yeah, this is indeed bad that the sufficients count is wrong on the main net.

I don't see a third option either, and would probably go for the lazy approach.

@brenzi brenzi merged commit 81fa3d2 into master Aug 23, 2023
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: reducing provider references when account is already dead.
2 participants