Skip to content

Commit

Permalink
Run single block migrations in executive to make it compatible with t…
Browse files Browse the repository at this point in the history
…he try-runtime-cli (#60)
  • Loading branch information
clangenb authored Jun 4, 2024
1 parent 7098e2f commit 0b005a5
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion runtime/bajun/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,7 @@ pub type Executive = frame_executive::Executive<
frame_system::ChainContext<Runtime>,
Runtime,
AllPalletsWithSystem,
SingleBlockMigrations,
>;

/// Handles converting a weight scalar to a fee value, based on the scale and granularity of the
Expand Down Expand Up @@ -374,7 +375,12 @@ impl frame_system::Config for Runtime {
/// The Block provider type
type Block = Block;
type RuntimeTask = RuntimeTask;
type SingleBlockMigrations = SingleBlockMigrations;
// Note: Single block migrations are currently run in the classical way in the `Executive`
// because try-runtime doesn't support the pallet-migrations yet.
//
// Once it is supported, we want to switch to the pallet-migrations, but we **must** ensure
// that we remove the migrations from the `Executive` to prevent running the migrations twice.
type SingleBlockMigrations = ();
type MultiBlockMigrator = pallet_migrations::Pallet<Runtime>;
type PreInherents = ();
type PostInherents = ();
Expand Down

0 comments on commit 0b005a5

Please sign in to comment.