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

Commit 5ab15fb

Browse files
committed
Keep old migrations around
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
1 parent d76a744 commit 5ab15fb

File tree

4 files changed

+14
-7
lines changed

4 files changed

+14
-7
lines changed

runtime/kusama/src/lib.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1475,14 +1475,16 @@ impl Get<Perbill> for NominationPoolsMigrationV4OldPallet {
14751475

14761476
/// All migrations that will run on the next runtime upgrade.
14771477
///
1478-
/// Should be cleared after every release.
1478+
/// This contains the combined migrations of the last 10 releases. It allows to skip runtime
1479+
/// upgrades in case governance decides to do so.
14791480
#[allow(deprecated)]
14801481
pub type Migrations = (
1482+
// 0.9.40
14811483
pallet_nomination_pools::migration::v4::MigrateToV4<
14821484
Runtime,
14831485
NominationPoolsMigrationV4OldPallet,
14841486
>,
1485-
// NOTE: If we don't propose 0.9.40 on chain; these two can be replaced with `MigrateV3ToV5`.
1487+
// Unreleased - add new migrations here:
14861488
pallet_nomination_pools::migration::v5::MigrateToV5<Runtime>,
14871489
parachains_configuration::migration::v5::MigrateToV5<Runtime>,
14881490
);

runtime/polkadot/src/lib.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1412,14 +1412,15 @@ impl Get<Perbill> for NominationPoolsMigrationV4OldPallet {
14121412

14131413
/// All migrations that will run on the next runtime upgrade.
14141414
///
1415-
/// Should be cleared after every release.
1415+
/// This contains the combined migrations of the last 10 releases. It allows to skip runtime upgrades in case governance decides to do so.
14161416
#[allow(deprecated)]
14171417
pub type Migrations = (
1418+
// 0.9.40
14181419
pallet_nomination_pools::migration::v4::MigrateToV4<
14191420
Runtime,
14201421
NominationPoolsMigrationV4OldPallet,
14211422
>,
1422-
// NOTE: If we don't propose 0.9.40 on chain; these two can be replaced with `MigrateV3ToV5`.
1423+
// Unreleased - add new migrations here:
14231424
pallet_nomination_pools::migration::v5::MigrateToV5<Runtime>,
14241425
parachains_configuration::migration::v5::MigrateToV5<Runtime>,
14251426
);

runtime/rococo/src/lib.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1493,8 +1493,9 @@ pub type UncheckedExtrinsic =
14931493

14941494
/// All migrations that will run on the next runtime upgrade.
14951495
///
1496-
/// Should be cleared after every release.
1497-
pub type Migrations = parachains_configuration::migration::v5::MigrateToV5<Runtime>;
1496+
/// This contains the combined migrations of the last 10 releases. It allows to skip runtime
1497+
/// upgrades in case governance decides to do so.
1498+
pub type Migrations = (parachains_configuration::migration::v5::MigrateToV5<Runtime>);
14981499

14991500
/// Executive: handles dispatch to the various modules.
15001501
pub type Executive = frame_executive::Executive<

runtime/westend/src/lib.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1207,14 +1207,17 @@ impl Get<Perbill> for NominationPoolsMigrationV4OldPallet {
12071207

12081208
/// All migrations that will run on the next runtime upgrade.
12091209
///
1210-
/// Should be cleared after every release.
1210+
/// This contains the combined migrations of the last 10 releases. It allows to skip runtime
1211+
/// upgrades in case governance decides to do so.
12111212
#[allow(deprecated)]
12121213
pub type Migrations = (
1214+
// 0.9.40
12131215
clean_state_migration::CleanMigrate,
12141216
pallet_nomination_pools::migration::v4::MigrateToV4<
12151217
Runtime,
12161218
NominationPoolsMigrationV4OldPallet,
12171219
>,
1220+
// Unreleased - add new migrations here:
12181221
pallet_nomination_pools::migration::v5::MigrateToV5<Runtime>,
12191222
parachains_configuration::migration::v5::MigrateToV5<Runtime>,
12201223
);

0 commit comments

Comments
 (0)