Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Altair Release 1026 & Development Release 1019 #1302

Merged
merged 6 commits into from
Apr 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "centrifuge-chain"
version = "0.10.25"
version = "0.10.26"
authors = ["Centrifuge <[email protected]>"]
description = "Centrifuge chain implementation in Rust."
build = "build.rs"
Expand Down
2 changes: 1 addition & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@
};

# This is a hash of all the Cargo dependencies, for reproducibility.
cargoSha256 = "sha256-V+ST911USf0FCpVxpJEwRrbwXjvLDQ0aHtNoIokH1M4=";
cargoSha256 = "sha256-h4Vlu7ilGD8MtewSaNC6k5EsM2SS1UyzM6UxIYC5ECE=";

nativeBuildInputs = with pkgs; [ clang git-mock pkg-config ];
buildInputs = with pkgs; [ openssl ] ++ (
Expand Down
2 changes: 1 addition & 1 deletion runtime/altair/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "altair-runtime"
version = "0.10.25"
version = "0.10.26"
authors = ["Centrifuge <[email protected]>"]
edition = "2021"
build = "build.rs"
Expand Down
14 changes: 8 additions & 6 deletions runtime/altair/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
spec_name: create_runtime_str!("altair"),
impl_name: create_runtime_str!("altair"),
authoring_version: 1,
spec_version: 1025,
spec_version: 1026,
impl_version: 1,
#[cfg(not(feature = "disable-runtime-api"))]
apis: RUNTIME_API_VERSIONS,
Expand Down Expand Up @@ -1475,18 +1475,20 @@ pub type UncheckedExtrinsic =
/// Extrinsic type that has already been checked.
pub type CheckedExtrinsic = generic::CheckedExtrinsic<AccountId, RuntimeCall, SignedExtra>;

type UpgradeAltair1026 = (
pallet_interest_accrual::migrations::v2::Migration<Runtime>,
pallet_loans_ref::migrations::NukeMigration<Runtime>,
pallet_pool_system::migrations::v1::Migration<Runtime, MaxSizeMetadata>,
);

/// Executive: handles dispatch to the various modules.
pub type Executive = frame_executive::Executive<
Runtime,
Block,
frame_system::ChainContext<Runtime>,
Runtime,
AllPalletsWithSystem,
(
pallet_interest_accrual::migrations::v2::Migration<Runtime>,
pallet_loans_ref::migrations::NukeMigration<Runtime>,
pallet_pool_system::migrations::v1::Migration<Runtime, MaxSizeMetadata>,
),
UpgradeAltair1026,
>;

#[cfg(not(feature = "disable-runtime-api"))]
Expand Down
2 changes: 1 addition & 1 deletion runtime/development/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "development-runtime"
version = "0.10.17"
version = "0.10.19"
authors = ["Centrifuge <[email protected]>"]
edition = "2021"
build = "build.rs"
Expand Down
12 changes: 7 additions & 5 deletions runtime/development/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
spec_name: create_runtime_str!("centrifuge-devel"),
impl_name: create_runtime_str!("centrifuge-devel"),
authoring_version: 1,
spec_version: 1018,
spec_version: 1019,
impl_version: 1,
#[cfg(not(feature = "disable-runtime-api"))]
apis: RUNTIME_API_VERSIONS,
Expand Down Expand Up @@ -1814,14 +1814,16 @@ pub type Executive = frame_executive::Executive<
frame_system::ChainContext<Runtime>,
Runtime,
AllPalletsWithSystem,
SchedulerMigrationV3,
UpgradeDev1019,
>;

type UpgradeDev1019 = SchedulerMigrationV4;

// Migration for scheduler pallet to move from a plain Call to a CallOrHash.
pub struct SchedulerMigrationV3;
impl frame_support::traits::OnRuntimeUpgrade for SchedulerMigrationV3 {
pub struct SchedulerMigrationV4;
impl frame_support::traits::OnRuntimeUpgrade for SchedulerMigrationV4 {
fn on_runtime_upgrade() -> frame_support::weights::Weight {
Scheduler::migrate_v2_to_v4()
Scheduler::migrate_v3_to_v4()
Copy link
Contributor

@wischli wischli Apr 5, 2023

Choose a reason for hiding this comment

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

Develop on 1018 has Scheduler.PalletVersion(3). Thus, we need to migrate to V4.

Altair 1025 and Centrifuge 1017 are already up-to-date on V4.

}
}

Expand Down