This repository was archived by the owner on Nov 15, 2023. It is now read-only.
Self-sufficient account ref-counting#8221
Merged
Conversation
Member
Author
|
CC @xlc |
4 tasks
jacogr
reviewed
Feb 27, 2021
Co-authored-by: Jaco Greeff <jacogr@gmail.com>
bkchr
reviewed
Feb 27, 2021
| migrations::migrate_to_dual_ref_count::<T>() | ||
| if !UpgradedToTripleRefCount::<T>::get() { | ||
| UpgradedToTripleRefCount::<T>::put(true); | ||
| migrations::migrate_to_triple_ref_count::<T>() |
Member
There was a problem hiding this comment.
Can we not call the migration explicitly in the particular runtimes?
Member
Author
There was a problem hiding this comment.
sure - i'm just concerned about it being forgotten.
Contributor
|
I think I understand the purpose of this but still think the whole account ref system is under utilized & under documented. Will be helpful to have some guides to explain how it should be used along with examples. #5255 |
gui1117
reviewed
Mar 1, 2021
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com>
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com>
Co-authored-by: Guillaume Thiolliere <gui.thiolliere@gmail.com>
kianenigma
reviewed
Mar 3, 2021
kianenigma
reviewed
Mar 3, 2021
gui1117
approved these changes
Mar 3, 2021
Co-authored-by: Kian Paimani <5588131+kianenigma@users.noreply.github.com>
arjanz
added a commit
to JAMdotTech/py-scale-codec
that referenced
this pull request
Mar 5, 2021
5 tasks
25 tasks
icodezjb
added a commit
to chainx-org/ChainX
that referenced
this pull request
Feb 8, 2022
gguoss
pushed a commit
to chainx-org/ChainX
that referenced
this pull request
Feb 25, 2022
* Remove VestingAccount * Fix chain specs * Update rust-toolchain * Update make test and benchmark * Update CI * Run `make format` and `make clippy` * Update CI * Quick fix * Support try-runtime * Remove pallet-randomness-collective-flip * Migrate elections-phragmen (paritytech/substrate#7040) * Migrate PalletVersion to StorageVersion (paritytech/substrate#9165) * Migrate pallet-babe epoch config (paritytech/substrate#8072) * Migrate frame-system AccountInfo to AccountInfoWithTripleRefCount (paritytech/substrate#8221) * Migrate prefix `GrandpaFinality` -> `Grandpa` * Migrate prefix `Instance1Collective` -> `Council` * Migrate prefix `Instance2Collective` -> `TechnicalCommittee` * Migrate prefix `Instance1Membership` -> `TechnicalMembership` * Migrate pallet-tips prefix from `Treasury` -> `Tips` * Migrate pallet-bounties prefix from `Treasury` -> `Bounties` * Migrate prefix from `PhragmenElection` -> `Elections` * Revert `dev` spec_name * Confirm migrations order * Use ChainX substrate patch for system migration * Run `make format` * Reset spec_name `dev` -> `chainx` * Add migrations.rs for mainnet and testnet * Bump ChainX version to `4.0.0` * Bump ChainX version to `4.0.0` * Update governance parameters for dev and malan * Update malan chainspec * Quick fix * Quick fix * Update generate_keys.sh * Adjust malan parameters * Update malan chainspec * Update malan chainspec * Update malan chainspec * Rename malan testnet name * Add bootnodes url * Run `make format` * Regenerate weights * Disable pre_release.yml CI * Regenerate benchmark weights * Run `make clippy` * Run `make format` Co-authored-by: icodezjb <icodezjb@users.noreply.github.com>
gguoss
pushed a commit
to chainx-org/ChainX
that referenced
this pull request
Feb 25, 2022
* Remove VestingAccount * Fix chain specs * Update rust-toolchain * Update make test and benchmark * Update CI * Run `make format` and `make clippy` * Update CI * Quick fix * Support try-runtime * Remove pallet-randomness-collective-flip * Migrate elections-phragmen (paritytech/substrate#7040) * Migrate PalletVersion to StorageVersion (paritytech/substrate#9165) * Migrate pallet-babe epoch config (paritytech/substrate#8072) * Migrate frame-system AccountInfo to AccountInfoWithTripleRefCount (paritytech/substrate#8221) * Migrate prefix `GrandpaFinality` -> `Grandpa` * Migrate prefix `Instance1Collective` -> `Council` * Migrate prefix `Instance2Collective` -> `TechnicalCommittee` * Migrate prefix `Instance1Membership` -> `TechnicalMembership` * Migrate pallet-tips prefix from `Treasury` -> `Tips` * Migrate pallet-bounties prefix from `Treasury` -> `Bounties` * Migrate prefix from `PhragmenElection` -> `Elections` * Revert `dev` spec_name * Confirm migrations order * Use ChainX substrate patch for system migration * Run `make format` * Reset spec_name `dev` -> `chainx` * Add migrations.rs for mainnet and testnet * Bump ChainX version to `4.0.0` * Bump ChainX version to `4.0.0` * Update governance parameters for dev and malan * Update malan chainspec * Quick fix * Quick fix * Update generate_keys.sh * Adjust malan parameters * Update malan chainspec * Update malan chainspec * Update malan chainspec * Rename malan testnet name * Add bootnodes url * Run `make format` * Regenerate weights * Disable pre_release.yml CI * Regenerate benchmark weights * Run `make clippy` * Run `make format` Co-authored-by: icodezjb <icodezjb@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Introduces a new ref-counted account type next to providers and consumers, called self-sufficient references. These allow an account to exist, but do not in themselves allow consumers to exist (for that there must be at least one provider reference on the account).
This is useful for times where you know that an aspect of an account is enough to pay for its basic existence, but where you want to guarantee that the reference can be yanked (probably by someone other than the account holder) without concern of there being consumers which depend on it.
Depended on by #8220
Requires audit.
Includes migration!