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

Companion for Substrate#9165 #3526

Merged
3 commits merged into from
Jul 27, 2021
Merged

Companion for Substrate#9165 #3526

3 commits merged into from
Jul 27, 2021

Conversation

bkchr
Copy link
Member

@bkchr bkchr commented Jul 27, 2021

@bkchr bkchr added 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. labels Jul 27, 2021
@bkchr bkchr requested a review from kianenigma July 27, 2021 12:11
@bkchr bkchr requested a review from gui1117 July 27, 2021 13:31

impl OnRuntimeUpgrade for MigratePalletVersionToStorageVersion {
fn on_runtime_upgrade() -> frame_support::weights::Weight {
frame_support::migrations::migrate_from_pallet_version_to_storage_version::<AllPalletsWithSystem>(
Copy link
Contributor

Choose a reason for hiding this comment

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

this will write the new version to the storage before executing the pallet specific hooks,
If some hooks rely on the stored version, this upgrade can break them.
I'll double check now, but I guess we should double check before the next releases as well.

Copy link
Contributor

@gui1117 gui1117 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, about https://github.com/paritytech/polkadot/pull/3526/files#r677620613 the only runtime upgrade that looks into the stored version is pallet-contract but we don't use it here.

@ghost
Copy link

ghost commented Jul 27, 2021

Waiting for commit status.

@ghost ghost merged commit d28fc8d into master Jul 27, 2021
@ghost ghost deleted the bkchr-substrate-companion-9165 branch July 27, 2021 21:59
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. 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
None yet
Development

Successfully merging this pull request may close these issues.

2 participants