Upgrade evm-template to polkadot-stable2503 (#417)

* init 2503 upgrade for evm template need to upgrade frontier forks

* start upgrading frontier

* wip upgrading tanssi deps and synchronizing deps therein

* update tanssi wip

* fix dep tree for evm template and move onto resolving errors

* resolve 17 of 29 compilation errors 12 remaining most related to updating weight files

* resolve weight related compilation errors and evm abstraction and proc macro require updates

* impl DecodeWithMemTracking for custom origins 5 errors left requiring changes to astractions

* update evm abstraction runtime compiles

* node in progress frontier txpool requires more changes

* update txpool for node and node release compiles

* remove unused code commented out

* fix tanssi registrar benchmarking compilation

* fix pallet registrar benchmarks and unit tests

* update tanssi runtime apis to have benchmark features

* clean and fix some errors tests are recently requiring benchmark hidden impls oddly

* combine ci steps for running test and checking benchmark compilation to see if output changes

* update xcm core buyer 2412 dep to 2503 release ty @KitHat

* rm conditional compilation for runtime benchmarks inside a few declarative macro definitions

* apply clippy fix

* move runtime benchmarks declarations for referenda conviction voting and assets common into the runtime not sure why only those require explicit feature declaration

* break build but apply suggestions from @KitHat

* fix build

* fix toml sort

* fix tanssi build
This commit is contained in:
Amar Singh
2025-08-01 10:28:26 -04:00
committed by GitHub
parent 93d31c3ed5
commit 2bfcbf94d5
28 changed files with 3076 additions and 2978 deletions
@@ -86,6 +86,7 @@ pub fn para_ext(para_id: u32) -> sp_io::TestExternalities {
(PARA_ALICE.into(), INITIAL_BALANCE),
(parent_account_id(), INITIAL_BALANCE),
],
..Default::default()
}
.assimilate_storage(&mut t)
.unwrap();
@@ -110,6 +111,7 @@ pub fn relay_ext() -> sp_io::TestExternalities {
(child_account_id(1), INITIAL_BALANCE),
(child_account_id(2), INITIAL_BALANCE),
],
..Default::default()
}
.assimilate_storage(&mut t)
.unwrap();
@@ -4,7 +4,7 @@ use core::marker::PhantomData;
use evm_runtime_template::configs::xcm_config::SignedToAccountId20;
use frame_support::{
construct_runtime, derive_impl, parameter_types,
traits::{ConstU128, ContainsPair, Everything, Nothing},
traits::{ConstU128, ContainsPair, Disabled, Everything, Nothing},
weights::{constants::WEIGHT_REF_TIME_PER_SECOND, Weight},
};
use frame_system::EnsureRoot;
@@ -68,6 +68,8 @@ pub type TrustedLockers = TrustedLockerCase<RelayTokenForRelay>;
impl pallet_xcm::Config for Runtime {
type AdminOrigin = EnsureRoot<AccountId>;
type AdvertisedXcmVersion = pallet_xcm::CurrentXcmVersion;
// Aliasing is disabled: xcm_executor::Config::Aliasers is set to `Nothing`.
type AuthorizedAliasConsideration = Disabled;
type Currency = Balances;
type CurrencyMatcher = ();
type ExecuteXcmOrigin = EnsureXcmOrigin<RuntimeOrigin, LocalOriginToLocation>;
@@ -42,6 +42,7 @@ impl xcm_executor::Config for XcmConfig {
type UniversalAliases = Nothing;
type UniversalLocation = constants::UniversalLocation;
type Weigher = weigher::Weigher;
type XcmEventEmitter = PolkadotXcm;
type XcmRecorder = PolkadotXcm;
type XcmSender = XcmRouter;
}
@@ -1,7 +1,7 @@
mod xcm_config;
use frame_support::{
construct_runtime, derive_impl, parameter_types,
traits::{ConstU128, Everything, Nothing, ProcessMessage, ProcessMessageError},
traits::{ConstU128, Disabled, Everything, Nothing, ProcessMessage, ProcessMessageError},
weights::{Weight, WeightMeter},
};
use frame_system::EnsureRoot;
@@ -53,6 +53,8 @@ pub type LocalOriginToLocation =
impl pallet_xcm::Config for Runtime {
type AdminOrigin = EnsureRoot<AccountId>;
type AdvertisedXcmVersion = pallet_xcm::CurrentXcmVersion;
// Aliasing is disabled: xcm_executor::Config::Aliasers is set to `Nothing`.
type AuthorizedAliasConsideration = Disabled;
type Currency = Balances;
type CurrencyMatcher = IsConcrete<constants::TokenLocation>;
// Anyone can execute XCM messages locally...
@@ -43,6 +43,7 @@ impl Config for XcmConfig {
type UniversalAliases = Nothing;
type UniversalLocation = constants::UniversalLocation;
type Weigher = weigher::Weigher;
type XcmEventEmitter = XcmPallet;
type XcmRecorder = XcmPallet;
type XcmSender = XcmRouter;
}