Ensure all StorageVersions on Polkadot/Kusama are correct (#7199)

* Yeah

* Fix all the migrations for Kusama & Polkadot

---------

Co-authored-by: Liam Aharon <liam.aharon@hotmail.com>
This commit is contained in:
Bastian Köcher
2023-05-17 16:53:01 +02:00
committed by GitHub
parent 750579aab0
commit 676bb648d2
9 changed files with 75 additions and 18 deletions
+3 -1
View File
@@ -162,8 +162,10 @@ pub mod pallet {
pub const CurrentXcmVersion: u32 = XCM_VERSION;
}
const STORAGE_VERSION: StorageVersion = StorageVersion::new(1);
#[pallet::pallet]
#[pallet::storage_version(migration::STORAGE_VERSION)]
#[pallet::storage_version(STORAGE_VERSION)]
#[pallet::without_storage_info]
pub struct Pallet<T>(_);
+1 -3
View File
@@ -21,8 +21,6 @@ use frame_support::{
weights::Weight,
};
pub const STORAGE_VERSION: StorageVersion = StorageVersion::new(1);
const DEFAULT_PROOF_SIZE: u64 = 64 * 1024;
pub mod v1 {
@@ -51,7 +49,7 @@ pub mod v1 {
VersionNotifyTargets::<T>::translate_values(translate);
log::info!("v1 applied successfully");
STORAGE_VERSION.put::<Pallet<T>>();
StorageVersion::new(1).put::<Pallet<T>>();
weight.saturating_add(T::DbWeight::get().writes(1))
} else {