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

Bounties Pallet to FrameV2 #9566

Merged
31 commits merged into from
Sep 21, 2021
Merged

Conversation

ferrell-code
Copy link
Contributor

@ferrell-code ferrell-code commented Aug 14, 2021

relates: #7882

Following the upgrade guidelines here: https://crates.parity.io/frame_support/attr.pallet.html#upgrade-guidelines.

⚠️ Breaking Change ⚠️

From https://crates.parity.io/frame_support/attr.pallet.html#checking-upgrade-guidelines

storages now use PalletInfo for module_prefix instead of the one given to decl_storage: Thus any use of this pallet in construct_runtime! should be careful to update name in order not to break storage or to upgrade storage (moreover for instantiable pallet). If pallet is published, make sure to warn about this breaking change.

So users of the Bounties pallet must be careful about the name they used in construct_runtime!. Hence the runtime-migration label, which might not be needed depending on the configuration of the Bounties pallet. Since the old version was using Treasury in storage, it is probably safe to say all users of Bounties pallet must migrate.

Polkadot and Kusama both use the name Bounties in construct_runtime. They must be both migrated from the current pallet prefix of Treasury. see companion PR

polkadot companion: paritytech/polkadot#3704

@ferrell-code ferrell-code changed the title Fer bounties framev2 Bounties Pallet to FrameV2 Aug 14, 2021
frame/bounties/src/lib.rs Outdated Show resolved Hide resolved
@thiolliere thiolliere added this to In progress in Runtime via automation Aug 16, 2021
@thiolliere thiolliere added A3-in_progress Pull request is in progress. No review needed at this stage. B3-apinoteworthy C1-low PR touches the given topic and has a low impact on builders. D5-nicetohaveaudit ⚠️ PR contains trivial changes to logic that should be properly reviewed. labels Aug 16, 2021
@thiolliere thiolliere added A0-please_review Pull request needs code review. and removed A3-in_progress Pull request is in progress. No review needed at this stage. labels Aug 21, 2021
@thiolliere thiolliere moved this from In progress to Please Review in Runtime Aug 21, 2021
@ferrell-code
Copy link
Contributor Author

ferrell-code commented Aug 24, 2021

Not exactly sure how to test if this does indeed migrate the storage correctly, may need a pointer on that

frame/bounties/src/migrations/v4.rs Show resolved Hide resolved
frame/bounties/src/migrations/v4.rs Outdated Show resolved Hide resolved
frame/bounties/src/migrations/v4.rs Outdated Show resolved Hide resolved
Copy link
Contributor

@thiolliere thiolliere left a comment

Choose a reason for hiding this comment

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

Looks good to me, I'll test the runtime migration on polkadot/kusama using try-runtime when reviewing the companion

Runtime automation moved this from Please Review to Needs Audit Sep 13, 2021
@thiolliere
Copy link
Contributor

bot merge

@ghost
Copy link

ghost commented Sep 21, 2021

Trying merge.

@ghost ghost merged commit 78ce061 into paritytech:master Sep 21, 2021
Runtime automation moved this from Needs Audit to Done Sep 21, 2021
@ferrell-code ferrell-code deleted the fer-bounties-framev2 branch September 21, 2021 18:22
@shawntabrizi shawntabrizi moved this from Done to Archive in Runtime Sep 30, 2021
This pull request was closed.
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. C1-low PR touches the given topic and has a low impact on builders. D5-nicetohaveaudit ⚠️ PR contains trivial changes to logic that should be properly reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants