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

API for registering inactive funds #12813

Merged
merged 7 commits into from
Dec 3, 2022
Merged

API for registering inactive funds #12813

merged 7 commits into from
Dec 3, 2022

Conversation

gavofyork
Copy link
Member

@gavofyork gavofyork commented Nov 30, 2022

Introduces ActiveIssuanceOf which is the total issuance not including the treasury funds and any other funds marked as inactive with deactivate. This should generally be used rather than TotalIssuance.

Balances pallet provides a migration which can be used to mark accounts with inactive funds (which, after the upgrade, we assume will be kept up to date with deactivate and reactivate). For chains with XCM, this should be used to mark the Checking Account when upgraded.

@gavofyork gavofyork added the A0-please_review Pull request needs code review. label Nov 30, 2022
frame/treasury/src/lib.rs Outdated Show resolved Hide resolved
frame/treasury/src/lib.rs Outdated Show resolved Hide resolved
frame/balances/src/lib.rs Outdated Show resolved Hide resolved
frame/treasury/src/lib.rs Outdated Show resolved Hide resolved
@gavofyork gavofyork added B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. D3-trivial 🧸 PR contains trivial changes in a runtime directory that do not require an audit labels Dec 1, 2022
@gavofyork
Copy link
Member Author

@muharem a final review/approve, so we can merge?

frame/treasury/src/lib.rs Outdated Show resolved Hide resolved
@gavofyork
Copy link
Member Author

@muharem issues addressed.

@Gesge

This comment was marked as spam.

@paritytech-cicd-pr
Copy link

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: test-linux-stable
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2110983

@gavofyork gavofyork merged commit 9812205 into master Dec 3, 2022
@gavofyork gavofyork deleted the gav-crowdloan-total branch December 3, 2022 08:14
@kianenigma
Copy link
Contributor

As a follow-up, all funds locked in nomination pools also have to be marked as deactivated now.

The migration will be O(pool_count). Each pool would look at its bonded account ledger.total and mark that as deactivated.

ltfschoen pushed a commit to ltfschoen/substrate that referenced this pull request Feb 22, 2023
* API for registering inactive funds

* Build fixes.

* Update frame/treasury/src/lib.rs

* Fix

* Fixes

* Fixes
ark0f pushed a commit to gear-tech/substrate that referenced this pull request Feb 27, 2023
* API for registering inactive funds

* Build fixes.

* Update frame/treasury/src/lib.rs

* Fix

* Fixes

* Fixes
@simonsso simonsso mentioned this pull request Dec 1, 2023
10 tasks
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A0-please_review Pull request needs code review. B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. D3-trivial 🧸 PR contains trivial changes in a runtime directory that do not require an audit
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

8 participants