Remove stale migrations post 9.16 release (#4848)

* Remove stale migrations post 9.16 release

* Remove more

* Bring back migration

* enact migration

* nit

* Fix warn

* Fix westend

* Fix build
This commit is contained in:
Kian Paimani
2022-02-14 10:16:28 +00:00
committed by GitHub
parent da78d0a4dc
commit 99728fd214
3 changed files with 4 additions and 1552 deletions
+1 -40
View File
@@ -1084,7 +1084,7 @@ pub type Executive = frame_executive::Executive<
frame_system::ChainContext<Runtime>,
Runtime,
AllPalletsWithSystem,
(SessionHistoricalPalletPrefixMigration, SchedulerMigrationV3, CrowdloanIndexMigration),
CrowdloanIndexMigration,
>;
/// The payload being signed in transactions.
pub type SignedPayload = generic::SignedPayload<Call, SignedExtra>;
@@ -1107,45 +1107,6 @@ impl OnRuntimeUpgrade for CrowdloanIndexMigration {
}
}
// Migration for scheduler pallet to move from a plain Call to a CallOrHash.
pub struct SchedulerMigrationV3;
impl OnRuntimeUpgrade for SchedulerMigrationV3 {
fn on_runtime_upgrade() -> frame_support::weights::Weight {
Scheduler::migrate_v2_to_v3()
}
#[cfg(feature = "try-runtime")]
fn pre_upgrade() -> Result<(), &'static str> {
Scheduler::pre_migrate_to_v3()
}
#[cfg(feature = "try-runtime")]
fn post_upgrade() -> Result<(), &'static str> {
Scheduler::post_migrate_to_v3()
}
}
/// Migrate session-historical from `Session` to the new pallet prefix `Historical`
pub struct SessionHistoricalPalletPrefixMigration;
impl OnRuntimeUpgrade for SessionHistoricalPalletPrefixMigration {
fn on_runtime_upgrade() -> frame_support::weights::Weight {
pallet_session::migrations::v1::migrate::<Runtime, Historical>()
}
#[cfg(feature = "try-runtime")]
fn pre_upgrade() -> Result<(), &'static str> {
pallet_session::migrations::v1::pre_migrate::<Runtime, Historical>();
Ok(())
}
#[cfg(feature = "try-runtime")]
fn post_upgrade() -> Result<(), &'static str> {
pallet_session::migrations::v1::post_migrate::<Runtime, Historical>();
Ok(())
}
}
#[cfg(feature = "runtime-benchmarks")]
#[macro_use]
extern crate frame_benchmarking;