difftreelog
feat common construct_runtime, rmrk feature
in: master
9 files changed
runtime/common/Cargo.tomldiffbeforeafterboth33 'frame-system/runtime-benchmarks',33 'frame-system/runtime-benchmarks',34]34]3535unique-runtime = []36opal-runtime = []36quartz-runtime = []37quartz-runtime = []38unique-runtime = []373938refungible = []40refungible = []3941runtime/common/src/lib.rsdiffbeforeafterboth23pub mod sponsoring;23pub mod sponsoring;24pub mod types;24pub mod types;25pub mod weights;25pub mod weights;26pub mod construct_runtime;2627runtime/common/src/runtime_apis.rsdiffbeforeafterboth154 }154 }155 }155 }156157 impl rmrk_rpc::RmrkApi<158 Block,159 AccountId,160 RmrkCollectionInfo<AccountId>,161 RmrkInstanceInfo<AccountId>,162 RmrkResourceInfo,163 RmrkPropertyInfo,164 RmrkBaseInfo<AccountId>,165 RmrkPartType,166 RmrkTheme167 > for Runtime {168 fn last_collection_idx() -> Result<RmrkCollectionId, DispatchError> {169 #[cfg(feature = "rmrk")]170 return pallet_proxy_rmrk_core::rpc::last_collection_idx::<Runtime>();171172 #[cfg(not(feature = "rmrk"))]173 return Ok(Default::default());174 }175176 fn collection_by_id(177 #[allow(unused_variables)]178 collection_id: RmrkCollectionId179 ) -> Result<Option<RmrkCollectionInfo<AccountId>>, DispatchError> {180 #[cfg(feature = "rmrk")]181 return pallet_proxy_rmrk_core::rpc::collection_by_id::<Runtime>(collection_id);182183 #[cfg(not(feature = "rmrk"))]184 return Ok(Default::default())185 }186187 fn nft_by_id(188 #[allow(unused_variables)]189 collection_id: RmrkCollectionId,190191 #[allow(unused_variables)]192 nft_by_id: RmrkNftId193 ) -> Result<Option<RmrkInstanceInfo<AccountId>>, DispatchError> {194 #[cfg(feature = "rmrk")]195 return pallet_proxy_rmrk_core::rpc::nft_by_id::<Runtime>(collection_id, nft_by_id);196197 #[cfg(not(feature = "rmrk"))]198 return Ok(Default::default())199 }200201 fn account_tokens(202 #[allow(unused_variables)]203 account_id: AccountId,204205 #[allow(unused_variables)]206 collection_id: RmrkCollectionId207 ) -> Result<Vec<RmrkNftId>, DispatchError> {208 #[cfg(feature = "rmrk")]209 return pallet_proxy_rmrk_core::rpc::account_tokens::<Runtime>(account_id, collection_id);210211 #[cfg(not(feature = "rmrk"))]212 return Ok(Default::default())213 }214215 fn nft_children(216 #[allow(unused_variables)]217 collection_id: RmrkCollectionId,218219 #[allow(unused_variables)]220 nft_id: RmrkNftId221 ) -> Result<Vec<RmrkNftChild>, DispatchError> {222 #[cfg(feature = "rmrk")]223 return pallet_proxy_rmrk_core::rpc::nft_children::<Runtime>(collection_id, nft_id);224225 #[cfg(not(feature = "rmrk"))]226 return Ok(Default::default())227 }228229 fn collection_properties(230 #[allow(unused_variables)]231 collection_id: RmrkCollectionId,232233 #[allow(unused_variables)]234 filter_keys: Option<Vec<RmrkPropertyKey>>235 ) -> Result<Vec<RmrkPropertyInfo>, DispatchError> {236 #[cfg(feature = "rmrk")]237 return pallet_proxy_rmrk_core::rpc::collection_properties::<Runtime>(collection_id, filter_keys);238239 #[cfg(not(feature = "rmrk"))]240 return Ok(Default::default())241 }242243 fn nft_properties(244 #[allow(unused_variables)]245 collection_id: RmrkCollectionId,246247 #[allow(unused_variables)]248 nft_id: RmrkNftId,249250 #[allow(unused_variables)]251 filter_keys: Option<Vec<RmrkPropertyKey>>252 ) -> Result<Vec<RmrkPropertyInfo>, DispatchError> {253 #[cfg(feature = "rmrk")]254 return pallet_proxy_rmrk_core::rpc::nft_properties::<Runtime>(collection_id, nft_id, filter_keys);255256 #[cfg(not(feature = "rmrk"))]257 return Ok(Default::default())258 }259260 fn nft_resources(261 #[allow(unused_variables)]262 collection_id: RmrkCollectionId,263264 #[allow(unused_variables)]265 nft_id: RmrkNftId266 ) -> Result<Vec<RmrkResourceInfo>, DispatchError> {267 #[cfg(feature = "rmrk")]268 return pallet_proxy_rmrk_core::rpc::nft_resources::<Runtime>(collection_id, nft_id);269270 #[cfg(not(feature = "rmrk"))]271 return Ok(Default::default())272 }273274 fn nft_resource_priority(275 #[allow(unused_variables)]276 collection_id: RmrkCollectionId,277278 #[allow(unused_variables)]279 nft_id: RmrkNftId,280281 #[allow(unused_variables)]282 resource_id: RmrkResourceId283 ) -> Result<Option<u32>, DispatchError> {284 #[cfg(feature = "rmrk")]285 return pallet_proxy_rmrk_core::rpc::nft_resource_priority::<Runtime>(collection_id, nft_id, resource_id);286287 #[cfg(not(feature = "rmrk"))]288 return Ok(Default::default())289 }290291 fn base(292 #[allow(unused_variables)]293 base_id: RmrkBaseId294 ) -> Result<Option<RmrkBaseInfo<AccountId>>, DispatchError> {295 #[cfg(feature = "rmrk")]296 return pallet_proxy_rmrk_equip::rpc::base::<Runtime>(base_id);297298 #[cfg(not(feature = "rmrk"))]299 return Ok(Default::default())300 }301302 fn base_parts(303 #[allow(unused_variables)]304 base_id: RmrkBaseId305 ) -> Result<Vec<RmrkPartType>, DispatchError> {306 #[cfg(feature = "rmrk")]307 return pallet_proxy_rmrk_equip::rpc::base_parts::<Runtime>(base_id);308309 #[cfg(not(feature = "rmrk"))]310 return Ok(Default::default())311 }312313 fn theme_names(314 #[allow(unused_variables)]315 base_id: RmrkBaseId316 ) -> Result<Vec<RmrkThemeName>, DispatchError> {317 #[cfg(feature = "rmrk")]318 return pallet_proxy_rmrk_equip::rpc::theme_names::<Runtime>(base_id);319320 #[cfg(not(feature = "rmrk"))]321 Ok(Default::default())322 }323324 fn theme(325 #[allow(unused_variables)]326 base_id: RmrkBaseId,327328 #[allow(unused_variables)]329 theme_name: RmrkThemeName,330331 #[allow(unused_variables)]332 filter_keys: Option<Vec<RmrkPropertyKey>>333 ) -> Result<Option<RmrkTheme>, DispatchError> {334 #[cfg(feature = "rmrk")]335 return pallet_proxy_rmrk_equip::rpc::theme::<Runtime>(base_id, theme_name, filter_keys);336337 #[cfg(not(feature = "rmrk"))]338 return Ok(Default::default())339 }340 }156341157 impl sp_api::Core<Block> for Runtime {342 impl sp_api::Core<Block> for Runtime {158 fn version() -> RuntimeVersion {343 fn version() -> RuntimeVersion {runtime/opal/Cargo.tomldiffbeforeafterboth16targets = ['x86_64-unknown-linux-gnu']16targets = ['x86_64-unknown-linux-gnu']171718[features]18[features]19default = ['std', 'new-functionality']19default = ['std', 'opal-runtime']20runtime-benchmarks = [20runtime-benchmarks = [21 'hex-literal',21 'hex-literal',22 'frame-benchmarking',22 'frame-benchmarking',119 "orml-vesting/std",119 "orml-vesting/std",120]120]121limit-testing = ['pallet-unique/limit-testing', 'up-data-structs/limit-testing']121limit-testing = ['pallet-unique/limit-testing', 'up-data-structs/limit-testing']122new-functionality = [122opal-runtime = ['rmrk']123 'unique-runtime-common/refungible',123124]124rmrk = []125125126################################################################################126################################################################################127# Substrate Dependencies127# Substrate Dependencies399399400[dependencies]400[dependencies]401log = { version = "0.4.16", default-features = false }401log = { version = "0.4.16", default-features = false }402unique-runtime-common = { path = "../common", default-features = false }402unique-runtime-common = { path = "../common", default-features = false, features = ['refungible'] }403scale-info = { version = "2.0.1", default-features = false, features = [403scale-info = { version = "2.0.1", default-features = false, features = [404 "derive",404 "derive",405] }405] }runtime/opal/src/lib.rsdiffbeforeafterboth54 OnMethodCall, Account as EVMAccount, FeeCalculator, GasWeightMapping,54 OnMethodCall, Account as EVMAccount, FeeCalculator, GasWeightMapping,55};55};56pub use frame_support::{56pub use frame_support::{57 construct_runtime, match_types,57 match_types,58 dispatch::DispatchResult,58 dispatch::DispatchResult,59 PalletId, parameter_types, StorageValue, ConsensusEngineId,59 PalletId, parameter_types, StorageValue, ConsensusEngineId,60 traits::{60 traits::{130//use xcm_executor::traits::MatchesFungible;130//use xcm_executor::traits::MatchesFungible;131131132use unique_runtime_common::{132use unique_runtime_common::{133 construct_runtime,133 impl_common_runtime_apis,134 impl_common_runtime_apis,134 types::*,135 types::*,135 constants::*,136 constants::*,910 type WeightInfo = pallet_nonfungible::weights::SubstrateWeight<Self>;911 type WeightInfo = pallet_nonfungible::weights::SubstrateWeight<Self>;911}912}912913914#[cfg(feature = "rmrk")]913impl pallet_proxy_rmrk_core::Config for Runtime {915impl pallet_proxy_rmrk_core::Config for Runtime {914 type WeightInfo = pallet_proxy_rmrk_core::weights::SubstrateWeight<Self>;916 type WeightInfo = pallet_proxy_rmrk_core::weights::SubstrateWeight<Self>;915 type Event = Event;917 type Event = Event;916}918}917919920#[cfg(feature = "rmrk")]918impl pallet_proxy_rmrk_equip::Config for Runtime {921impl pallet_proxy_rmrk_equip::Config for Runtime {919 type WeightInfo = pallet_proxy_rmrk_equip::weights::SubstrateWeight<Self>;922 type WeightInfo = pallet_proxy_rmrk_equip::weights::SubstrateWeight<Self>;920 type Event = Event;923 type Event = Event;1121}1124}112211251123construct_runtime!(1126construct_runtime!();1124 pub enum Runtime where1125 Block = Block,1126 NodeBlock = opaque::Block,1127 UncheckedExtrinsic = UncheckedExtrinsic1128 {1129 ParachainSystem: cumulus_pallet_parachain_system::{Pallet, Call, Config, Storage, Inherent, Event<T>, ValidateUnsigned} = 20,1130 ParachainInfo: parachain_info::{Pallet, Storage, Config} = 21,11311132 Aura: pallet_aura::{Pallet, Config<T>} = 22,1133 AuraExt: cumulus_pallet_aura_ext::{Pallet, Config} = 23,11341135 Balances: pallet_balances::{Pallet, Call, Storage, Config<T>, Event<T>} = 30,1136 RandomnessCollectiveFlip: pallet_randomness_collective_flip::{Pallet, Storage} = 31,1137 Timestamp: pallet_timestamp::{Pallet, Call, Storage, Inherent} = 32,1138 TransactionPayment: pallet_transaction_payment::{Pallet, Storage} = 33,1139 Treasury: pallet_treasury::{Pallet, Call, Storage, Config, Event<T>} = 34,1140 Sudo: pallet_sudo::{Pallet, Call, Storage, Config<T>, Event<T>} = 35,1141 System: frame_system::{Pallet, Call, Storage, Config, Event<T>} = 36,1142 Vesting: orml_vesting::{Pallet, Storage, Call, Event<T>, Config<T>} = 37,1143 // Vesting: pallet_vesting::{Pallet, Call, Config<T>, Storage, Event<T>} = 37,1144 // Contracts: pallet_contracts::{Pallet, Call, Storage, Event<T>} = 38,11451146 // XCM helpers.1147 XcmpQueue: cumulus_pallet_xcmp_queue::{Pallet, Call, Storage, Event<T>} = 50,1148 PolkadotXcm: pallet_xcm::{Pallet, Call, Event<T>, Origin} = 51,1149 CumulusXcm: cumulus_pallet_xcm::{Pallet, Call, Event<T>, Origin} = 52,1150 DmpQueue: cumulus_pallet_dmp_queue::{Pallet, Call, Storage, Event<T>} = 53,11511152 // Unique Pallets1153 Inflation: pallet_inflation::{Pallet, Call, Storage} = 60,1154 Unique: pallet_unique::{Pallet, Call, Storage, Event<T>} = 61,1155 Scheduler: pallet_unique_scheduler::{Pallet, Call, Storage, Event<T>} = 62,1156 // free = 631157 Charging: pallet_charge_transaction::{Pallet, Call, Storage } = 64,1158 // ContractHelpers: pallet_contract_helpers::{Pallet, Call, Storage} = 65,1159 Common: pallet_common::{Pallet, Storage, Event<T>} = 66,1160 Fungible: pallet_fungible::{Pallet, Storage} = 67,1161 Refungible: pallet_refungible::{Pallet, Storage} = 68,1162 Nonfungible: pallet_nonfungible::{Pallet, Storage} = 69,1163 Structure: pallet_structure::{Pallet, Call, Storage, Event<T>} = 70,1164 RmrkCore: pallet_proxy_rmrk_core::{Pallet, Call, Storage, Event<T>} = 71,1165 RmrkEquip: pallet_proxy_rmrk_equip::{Pallet, Call, Storage, Event<T>} = 72,11661167 // Frontier1168 EVM: pallet_evm::{Pallet, Config, Call, Storage, Event<T>} = 100,1169 Ethereum: pallet_ethereum::{Pallet, Config, Call, Storage, Event, Origin} = 101,11701171 EvmCoderSubstrate: pallet_evm_coder_substrate::{Pallet, Storage} = 150,1172 EvmContractHelpers: pallet_evm_contract_helpers::{Pallet, Storage} = 151,1173 EvmTransactionPayment: pallet_evm_transaction_payment::{Pallet} = 152,1174 EvmMigration: pallet_evm_migration::{Pallet, Call, Storage} = 153,1175 }1176);117711271178pub struct TransactionConverter;1128pub struct TransactionConverter;1309 }};1259 }};1310}1260}131112611312impl_common_runtime_apis! {1262impl_common_runtime_apis!();1313 #![custom_apis]13141315 impl rmrk_rpc::RmrkApi<1316 Block,1317 AccountId,1318 RmrkCollectionInfo<AccountId>,1319 RmrkInstanceInfo<AccountId>,1320 RmrkResourceInfo,1321 RmrkPropertyInfo,1322 RmrkBaseInfo<AccountId>,1323 RmrkPartType,1324 RmrkTheme1325 > for Runtime {1326 fn last_collection_idx() -> Result<RmrkCollectionId, DispatchError> {1327 pallet_proxy_rmrk_core::rpc::last_collection_idx::<Runtime>()1328 }13291330 fn collection_by_id(collection_id: RmrkCollectionId) -> Result<Option<RmrkCollectionInfo<AccountId>>, DispatchError> {1331 pallet_proxy_rmrk_core::rpc::collection_by_id::<Runtime>(collection_id)1332 }13331334 fn nft_by_id(collection_id: RmrkCollectionId, nft_by_id: RmrkNftId) -> Result<Option<RmrkInstanceInfo<AccountId>>, DispatchError> {1335 pallet_proxy_rmrk_core::rpc::nft_by_id::<Runtime>(collection_id, nft_by_id)1336 }13371338 fn account_tokens(account_id: AccountId, collection_id: RmrkCollectionId) -> Result<Vec<RmrkNftId>, DispatchError> {1339 pallet_proxy_rmrk_core::rpc::account_tokens::<Runtime>(account_id, collection_id)1340 }13411342 fn nft_children(collection_id: RmrkCollectionId, nft_id: RmrkNftId) -> Result<Vec<RmrkNftChild>, DispatchError> {1343 pallet_proxy_rmrk_core::rpc::nft_children::<Runtime>(collection_id, nft_id)1344 }13451346 fn collection_properties(collection_id: RmrkCollectionId, filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Vec<RmrkPropertyInfo>, DispatchError> {1347 pallet_proxy_rmrk_core::rpc::collection_properties::<Runtime>(collection_id, filter_keys)1348 }13491350 fn nft_properties(collection_id: RmrkCollectionId, nft_id: RmrkNftId, filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Vec<RmrkPropertyInfo>, DispatchError> {1351 pallet_proxy_rmrk_core::rpc::nft_properties::<Runtime>(collection_id, nft_id, filter_keys)1352 }13531354 fn nft_resources(collection_id: RmrkCollectionId, nft_id: RmrkNftId) -> Result<Vec<RmrkResourceInfo>, DispatchError> {1355 pallet_proxy_rmrk_core::rpc::nft_resources::<Runtime>(collection_id, nft_id)1356 }13571358 fn nft_resource_priority(collection_id: RmrkCollectionId, nft_id: RmrkNftId, resource_id: RmrkResourceId) -> Result<Option<u32>, DispatchError> {1359 pallet_proxy_rmrk_core::rpc::nft_resource_priority::<Runtime>(collection_id, nft_id, resource_id)1360 }13611362 fn base(base_id: RmrkBaseId) -> Result<Option<RmrkBaseInfo<AccountId>>, DispatchError> {1363 pallet_proxy_rmrk_equip::rpc::base::<Runtime>(base_id)1364 }13651366 fn base_parts(base_id: RmrkBaseId) -> Result<Vec<RmrkPartType>, DispatchError> {1367 pallet_proxy_rmrk_equip::rpc::base_parts::<Runtime>(base_id)1368 }13691370 fn theme_names(base_id: RmrkBaseId) -> Result<Vec<RmrkThemeName>, DispatchError> {1371 pallet_proxy_rmrk_equip::rpc::theme_names::<Runtime>(base_id)1372 }13731374 fn theme(base_id: RmrkBaseId, theme_name: RmrkThemeName, filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Option<RmrkTheme>, DispatchError> {1375 pallet_proxy_rmrk_equip::rpc::theme::<Runtime>(base_id, theme_name, filter_keys)1376 }1377 }1378}137912631380struct CheckInherents;1264struct CheckInherents;13811265runtime/quartz/Cargo.tomldiffbeforeafterboth16targets = ['x86_64-unknown-linux-gnu']16targets = ['x86_64-unknown-linux-gnu']171718[features]18[features]19default = ['std', 'new-functionality']19default = ['std', 'quartz-runtime']20runtime-benchmarks = [20runtime-benchmarks = [21 'hex-literal',21 'hex-literal',22 'frame-benchmarking',22 'frame-benchmarking',118 "orml-vesting/std",118 "orml-vesting/std",119]119]120limit-testing = ['pallet-unique/limit-testing', 'up-data-structs/limit-testing']120limit-testing = ['pallet-unique/limit-testing', 'up-data-structs/limit-testing']121new-functionality = []121quartz-runtime = []122123rmrk = []122124123################################################################################125################################################################################124# Substrate Dependencies126# Substrate Dependenciesruntime/quartz/src/lib.rsdiffbeforeafterboth54 OnMethodCall, Account as EVMAccount, FeeCalculator, GasWeightMapping,54 OnMethodCall, Account as EVMAccount, FeeCalculator, GasWeightMapping,55};55};56pub use frame_support::{56pub use frame_support::{57 construct_runtime, match_types,57 match_types,58 dispatch::DispatchResult,58 dispatch::DispatchResult,59 PalletId, parameter_types, StorageValue, ConsensusEngineId,59 PalletId, parameter_types, StorageValue, ConsensusEngineId,60 traits::{60 traits::{128use xcm_executor::traits::{MatchesFungible, WeightTrader};128use xcm_executor::traits::{MatchesFungible, WeightTrader};129129130use unique_runtime_common::{130use unique_runtime_common::{131 construct_runtime,131 impl_common_runtime_apis,132 impl_common_runtime_apis,132 types::*,133 types::*,133 constants::*,134 constants::*,909 type WeightInfo = pallet_nonfungible::weights::SubstrateWeight<Self>;910 type WeightInfo = pallet_nonfungible::weights::SubstrateWeight<Self>;910}911}911912912// impl pallet_proxy_rmrk_core::Config for Runtime {913#[cfg(feature = "rmrk")]913// type WeightInfo = pallet_proxy_rmrk_core::weights::SubstrateWeight<Self>;914impl pallet_proxy_rmrk_core::Config for Runtime {914// type Event = Event;915 type WeightInfo = pallet_proxy_rmrk_core::weights::SubstrateWeight<Self>;915// }916 type Event = Event;916917}917// impl pallet_proxy_rmrk_equip::Config for Runtime {918918// type WeightInfo = pallet_proxy_rmrk_equip::weights::SubstrateWeight<Self>;919#[cfg(feature = "rmrk")]919// type Event = Event;920impl pallet_proxy_rmrk_equip::Config for Runtime {920// }921 type WeightInfo = pallet_proxy_rmrk_equip::weights::SubstrateWeight<Self>;922 type Event = Event;923}921924922impl pallet_unique::Config for Runtime {925impl pallet_unique::Config for Runtime {923 type Event = Event;926 type Event = Event;1119}1122}112011231121construct_runtime!(1124construct_runtime!();1122 pub enum Runtime where1123 Block = Block,1124 NodeBlock = opaque::Block,1125 UncheckedExtrinsic = UncheckedExtrinsic1126 {1127 ParachainSystem: cumulus_pallet_parachain_system::{Pallet, Call, Config, Storage, Inherent, Event<T>, ValidateUnsigned} = 20,1128 ParachainInfo: parachain_info::{Pallet, Storage, Config} = 21,11291130 Aura: pallet_aura::{Pallet, Config<T>} = 22,1131 AuraExt: cumulus_pallet_aura_ext::{Pallet, Config} = 23,11321133 Balances: pallet_balances::{Pallet, Call, Storage, Config<T>, Event<T>} = 30,1134 RandomnessCollectiveFlip: pallet_randomness_collective_flip::{Pallet, Storage} = 31,1135 Timestamp: pallet_timestamp::{Pallet, Call, Storage, Inherent} = 32,1136 TransactionPayment: pallet_transaction_payment::{Pallet, Storage} = 33,1137 Treasury: pallet_treasury::{Pallet, Call, Storage, Config, Event<T>} = 34,1138 Sudo: pallet_sudo::{Pallet, Call, Storage, Config<T>, Event<T>} = 35,1139 System: frame_system::{Pallet, Call, Storage, Config, Event<T>} = 36,1140 Vesting: orml_vesting::{Pallet, Storage, Call, Event<T>, Config<T>} = 37,1141 // Vesting: pallet_vesting::{Pallet, Call, Config<T>, Storage, Event<T>} = 37,1142 // Contracts: pallet_contracts::{Pallet, Call, Storage, Event<T>} = 38,11431144 // XCM helpers.1145 XcmpQueue: cumulus_pallet_xcmp_queue::{Pallet, Call, Storage, Event<T>} = 50,1146 PolkadotXcm: pallet_xcm::{Pallet, Call, Event<T>, Origin} = 51,1147 CumulusXcm: cumulus_pallet_xcm::{Pallet, Call, Event<T>, Origin} = 52,1148 DmpQueue: cumulus_pallet_dmp_queue::{Pallet, Call, Storage, Event<T>} = 53,11491150 // Unique Pallets1151 Inflation: pallet_inflation::{Pallet, Call, Storage} = 60,1152 Unique: pallet_unique::{Pallet, Call, Storage, Event<T>} = 61,1153 // Scheduler: pallet_unique_scheduler::{Pallet, Call, Storage, Event<T>} = 62,1154 // free = 631155 Charging: pallet_charge_transaction::{Pallet, Call, Storage } = 64,1156 // ContractHelpers: pallet_contract_helpers::{Pallet, Call, Storage} = 65,1157 Common: pallet_common::{Pallet, Storage, Event<T>} = 66,1158 Fungible: pallet_fungible::{Pallet, Storage} = 67,1159 // Refungible: pallet_refungible::{Pallet, Storage} = 68,1160 Nonfungible: pallet_nonfungible::{Pallet, Storage} = 69,1161 Structure: pallet_structure::{Pallet, Call, Storage, Event<T>} = 70,1162 // RmrkCore: pallet_proxy_rmrk_core::{Pallet, Call, Storage, Event<T>} = 71,1163 // RmrkEquip: pallet_proxy_rmrk_equip::{Pallet, Call, Storage, Event<T>} = 72,11641165 // Frontier1166 EVM: pallet_evm::{Pallet, Config, Call, Storage, Event<T>} = 100,1167 Ethereum: pallet_ethereum::{Pallet, Config, Call, Storage, Event, Origin} = 101,11681169 EvmCoderSubstrate: pallet_evm_coder_substrate::{Pallet, Storage} = 150,1170 EvmContractHelpers: pallet_evm_contract_helpers::{Pallet, Storage} = 151,1171 EvmTransactionPayment: pallet_evm_transaction_payment::{Pallet} = 152,1172 EvmMigration: pallet_evm_migration::{Pallet, Call, Storage} = 153,1173 }1174);117511251176pub struct TransactionConverter;1126pub struct TransactionConverter;1309 }};1259 }};1310}1260}131112611312impl_common_runtime_apis! {1262impl_common_runtime_apis!();1313 #![custom_apis]13141315 impl rmrk_rpc::RmrkApi<1316 Block,1317 AccountId,1318 RmrkCollectionInfo<AccountId>,1319 RmrkInstanceInfo<AccountId>,1320 RmrkResourceInfo,1321 RmrkPropertyInfo,1322 RmrkBaseInfo<AccountId>,1323 RmrkPartType,1324 RmrkTheme1325 > for Runtime {1326 1327 // fn last_collection_idx() -> Result<RmrkCollectionId, DispatchError> {1328 // pallet_proxy_rmrk_core::rpc::last_collection_idx::<Runtime>()1329 // }13301331 // fn collection_by_id(collection_id: RmrkCollectionId) -> Result<Option<RmrkCollectionInfo<AccountId>>, DispatchError> {1332 // pallet_proxy_rmrk_core::rpc::collection_by_id::<Runtime>(collection_id)1333 // }13341335 // fn nft_by_id(collection_id: RmrkCollectionId, nft_by_id: RmrkNftId) -> Result<Option<RmrkInstanceInfo<AccountId>>, DispatchError> {1336 // pallet_proxy_rmrk_core::rpc::nft_by_id::<Runtime>(collection_id, nft_by_id)1337 // }13381339 // fn account_tokens(account_id: AccountId, collection_id: RmrkCollectionId) -> Result<Vec<RmrkNftId>, DispatchError> {1340 // pallet_proxy_rmrk_core::rpc::account_tokens::<Runtime>(account_id, collection_id)1341 // }13421343 // fn nft_children(collection_id: RmrkCollectionId, nft_id: RmrkNftId) -> Result<Vec<RmrkNftChild>, DispatchError> {1344 // pallet_proxy_rmrk_core::rpc::nft_children::<Runtime>(collection_id, nft_id)1345 // }13461347 // fn collection_properties(collection_id: RmrkCollectionId, filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Vec<RmrkPropertyInfo>, DispatchError> {1348 // pallet_proxy_rmrk_core::rpc::collection_properties::<Runtime>(collection_id, filter_keys)1349 // }13501351 // fn nft_properties(collection_id: RmrkCollectionId, nft_id: RmrkNftId, filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Vec<RmrkPropertyInfo>, DispatchError> {1352 // pallet_proxy_rmrk_core::rpc::nft_properties::<Runtime>(collection_id, nft_id, filter_keys)1353 // }13541355 // fn nft_resources(collection_id: RmrkCollectionId, nft_id: RmrkNftId) -> Result<Vec<RmrkResourceInfo>, DispatchError> {1356 // pallet_proxy_rmrk_core::rpc::nft_resources::<Runtime>(collection_id, nft_id)1357 // }13581359 // fn nft_resource_priority(collection_id: RmrkCollectionId, nft_id: RmrkNftId, resource_id: RmrkResourceId) -> Result<Option<u32>, DispatchError> {1360 // pallet_proxy_rmrk_core::rpc::nft_resource_priority::<Runtime>(collection_id, nft_id, resource_id)1361 // }13621363 // fn base(base_id: RmrkBaseId) -> Result<Option<RmrkBaseInfo<AccountId>>, DispatchError> {1364 // pallet_proxy_rmrk_equip::rpc::base::<Runtime>(base_id)1365 // }13661367 // fn base_parts(base_id: RmrkBaseId) -> Result<Vec<RmrkPartType>, DispatchError> {1368 // pallet_proxy_rmrk_equip::rpc::base_parts::<Runtime>(base_id)1369 // }13701371 // fn theme_names(base_id: RmrkBaseId) -> Result<Vec<RmrkThemeName>, DispatchError> {1372 // pallet_proxy_rmrk_equip::rpc::theme_names::<Runtime>(base_id)1373 // }13741375 // fn theme(base_id: RmrkBaseId, theme_name: RmrkThemeName, filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Option<RmrkTheme>, DispatchError> {1376 // pallet_proxy_rmrk_equip::rpc::theme::<Runtime>(base_id, theme_name, filter_keys)1377 // }1378 1379 fn last_collection_idx() -> Result<RmrkCollectionId, DispatchError> {1380 Ok(Default::default())1381 }13821383 fn collection_by_id(_collection_id: RmrkCollectionId) -> Result<Option<RmrkCollectionInfo<AccountId>>, DispatchError> {1384 Ok(Default::default())1385 }13861387 fn nft_by_id(_collection_id: RmrkCollectionId, _nft_by_id: RmrkNftId) -> Result<Option<RmrkInstanceInfo<AccountId>>, DispatchError> {1388 Ok(Default::default())1389 }13901391 fn account_tokens(_account_id: AccountId, _collection_id: RmrkCollectionId) -> Result<Vec<RmrkNftId>, DispatchError> {1392 Ok(Default::default())1393 }13941395 fn nft_children(_collection_id: RmrkCollectionId, _nft_id: RmrkNftId) -> Result<Vec<RmrkNftChild>, DispatchError> {1396 Ok(Default::default())1397 }13981399 fn collection_properties(_collection_id: RmrkCollectionId, _filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Vec<RmrkPropertyInfo>, DispatchError> {1400 Ok(Default::default())1401 }14021403 fn nft_properties(_collection_id: RmrkCollectionId, _nft_id: RmrkNftId, _filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Vec<RmrkPropertyInfo>, DispatchError> {1404 Ok(Default::default())1405 }14061407 fn nft_resources(_collection_id: RmrkCollectionId, _nft_id: RmrkNftId) -> Result<Vec<RmrkResourceInfo>, DispatchError> {1408 Ok(Default::default())1409 }14101411 fn nft_resource_priority(_collection_id: RmrkCollectionId, _nft_id: RmrkNftId, _resource_id: RmrkResourceId) -> Result<Option<u32>, DispatchError> {1412 Ok(Default::default())1413 }14141415 fn base(_base_id: RmrkBaseId) -> Result<Option<RmrkBaseInfo<AccountId>>, DispatchError> {1416 Ok(Default::default())1417 }14181419 fn base_parts(_base_id: RmrkBaseId) -> Result<Vec<RmrkPartType>, DispatchError> {1420 Ok(Default::default())1421 }14221423 fn theme_names(_base_id: RmrkBaseId) -> Result<Vec<RmrkThemeName>, DispatchError> {1424 Ok(Default::default())1425 }14261427 fn theme(_base_id: RmrkBaseId, _theme_name: RmrkThemeName, _filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Option<RmrkTheme>, DispatchError> {1428 Ok(Default::default())1429 }1430 1431 1432 }1433}143412631435struct CheckInherents;1264struct CheckInherents;14361265runtime/unique/Cargo.tomldiffbeforeafterboth16targets = ['x86_64-unknown-linux-gnu']16targets = ['x86_64-unknown-linux-gnu']171718[features]18[features]19default = ['std', 'new-functionality']19default = ['std', 'unique-runtime']20runtime-benchmarks = [20runtime-benchmarks = [21 'hex-literal',21 'hex-literal',22 'frame-benchmarking',22 'frame-benchmarking',119 "orml-vesting/std",119 "orml-vesting/std",120]120]121limit-testing = ['pallet-unique/limit-testing', 'up-data-structs/limit-testing']121limit-testing = ['pallet-unique/limit-testing', 'up-data-structs/limit-testing']122new-functionality = []122unique-runtime = []123123124################################################################################124################################################################################125# Substrate Dependencies125# Substrate Dependenciesruntime/unique/src/lib.rsdiffbeforeafterboth54 OnMethodCall, Account as EVMAccount, FeeCalculator, GasWeightMapping,54 OnMethodCall, Account as EVMAccount, FeeCalculator, GasWeightMapping,55};55};56pub use frame_support::{56pub use frame_support::{57 construct_runtime, match_types,57 match_types,58 dispatch::DispatchResult,58 dispatch::DispatchResult,59 PalletId, parameter_types, StorageValue, ConsensusEngineId,59 PalletId, parameter_types, StorageValue, ConsensusEngineId,60 traits::{60 traits::{128use xcm_executor::traits::{MatchesFungible, WeightTrader};128use xcm_executor::traits::{MatchesFungible, WeightTrader};129129130use unique_runtime_common::{130use unique_runtime_common::{131 construct_runtime,131 impl_common_runtime_apis,132 impl_common_runtime_apis,132 types::*,133 types::*,133 constants::*,134 constants::*,910 type WeightInfo = pallet_nonfungible::weights::SubstrateWeight<Self>;911 type WeightInfo = pallet_nonfungible::weights::SubstrateWeight<Self>;911}912}913914#[cfg(feature = "rmrk")]915impl pallet_proxy_rmrk_core::Config for Runtime {916 type WeightInfo = pallet_proxy_rmrk_core::weights::SubstrateWeight<Self>;917 type Event = Event;918}919920#[cfg(feature = "rmrk")]921impl pallet_proxy_rmrk_equip::Config for Runtime {922 type WeightInfo = pallet_proxy_rmrk_equip::weights::SubstrateWeight<Self>;923 type Event = Event;924}912925913impl pallet_unique::Config for Runtime {926impl pallet_unique::Config for Runtime {914 type Event = Event;927 type Event = Event;1110}1123}111111241112construct_runtime!(1125construct_runtime!();1113 pub enum Runtime where1114 Block = Block,1115 NodeBlock = opaque::Block,1116 UncheckedExtrinsic = UncheckedExtrinsic1117 {1118 ParachainSystem: cumulus_pallet_parachain_system::{Pallet, Call, Config, Storage, Inherent, Event<T>, ValidateUnsigned} = 20,1119 ParachainInfo: parachain_info::{Pallet, Storage, Config} = 21,11201121 Aura: pallet_aura::{Pallet, Config<T>} = 22,1122 AuraExt: cumulus_pallet_aura_ext::{Pallet, Config} = 23,11231124 Balances: pallet_balances::{Pallet, Call, Storage, Config<T>, Event<T>} = 30,1125 RandomnessCollectiveFlip: pallet_randomness_collective_flip::{Pallet, Storage} = 31,1126 Timestamp: pallet_timestamp::{Pallet, Call, Storage, Inherent} = 32,1127 TransactionPayment: pallet_transaction_payment::{Pallet, Storage} = 33,1128 Treasury: pallet_treasury::{Pallet, Call, Storage, Config, Event<T>} = 34,1129 Sudo: pallet_sudo::{Pallet, Call, Storage, Config<T>, Event<T>} = 35,1130 System: frame_system::{Pallet, Call, Storage, Config, Event<T>} = 36,1131 Vesting: orml_vesting::{Pallet, Storage, Call, Event<T>, Config<T>} = 37,1132 // Vesting: pallet_vesting::{Pallet, Call, Config<T>, Storage, Event<T>} = 37,1133 // Contracts: pallet_contracts::{Pallet, Call, Storage, Event<T>} = 38,11341135 // XCM helpers.1136 XcmpQueue: cumulus_pallet_xcmp_queue::{Pallet, Call, Storage, Event<T>} = 50,1137 PolkadotXcm: pallet_xcm::{Pallet, Call, Event<T>, Origin} = 51,1138 CumulusXcm: cumulus_pallet_xcm::{Pallet, Call, Event<T>, Origin} = 52,1139 DmpQueue: cumulus_pallet_dmp_queue::{Pallet, Call, Storage, Event<T>} = 53,11401141 // Unique Pallets1142 Inflation: pallet_inflation::{Pallet, Call, Storage} = 60,1143 Unique: pallet_unique::{Pallet, Call, Storage, Event<T>} = 61,1144 // Scheduler: pallet_unique_scheduler::{Pallet, Call, Storage, Event<T>} = 62,1145 // free = 631146 Charging: pallet_charge_transaction::{Pallet, Call, Storage } = 64,1147 // ContractHelpers: pallet_contract_helpers::{Pallet, Call, Storage} = 65,1148 Common: pallet_common::{Pallet, Storage, Event<T>} = 66,1149 Fungible: pallet_fungible::{Pallet, Storage} = 67,1150 // Refungible: pallet_refungible::{Pallet, Storage} = 68,1151 Nonfungible: pallet_nonfungible::{Pallet, Storage} = 69,1152 Structure: pallet_structure::{Pallet, Call, Storage, Event<T>} = 70,11531154 // Frontier1155 EVM: pallet_evm::{Pallet, Config, Call, Storage, Event<T>} = 100,1156 Ethereum: pallet_ethereum::{Pallet, Config, Call, Storage, Event, Origin} = 101,11571158 EvmCoderSubstrate: pallet_evm_coder_substrate::{Pallet, Storage} = 150,1159 EvmContractHelpers: pallet_evm_contract_helpers::{Pallet, Storage} = 151,1160 EvmTransactionPayment: pallet_evm_transaction_payment::{Pallet} = 152,1161 EvmMigration: pallet_evm_migration::{Pallet, Call, Storage} = 153,1162 }1163);116411261165pub struct TransactionConverter;1127pub struct TransactionConverter;1297 }};1259 }};1298}1260}129912611300impl_common_runtime_apis! {1262impl_common_runtime_apis!();1301 #![custom_apis]13021303 impl rmrk_rpc::RmrkApi<1304 Block,1305 AccountId,1306 RmrkCollectionInfo<AccountId>,1307 RmrkInstanceInfo<AccountId>,1308 RmrkResourceInfo,1309 RmrkPropertyInfo,1310 RmrkBaseInfo<AccountId>,1311 RmrkPartType,1312 RmrkTheme1313 > for Runtime {1314 fn last_collection_idx() -> Result<RmrkCollectionId, DispatchError> {1315 Ok(Default::default())1316 }13171318 fn collection_by_id(_collection_id: RmrkCollectionId) -> Result<Option<RmrkCollectionInfo<AccountId>>, DispatchError> {1319 Ok(Default::default())1320 }13211322 fn nft_by_id(_collection_id: RmrkCollectionId, _nft_by_id: RmrkNftId) -> Result<Option<RmrkInstanceInfo<AccountId>>, DispatchError> {1323 Ok(Default::default())1324 }13251326 fn account_tokens(_account_id: AccountId, _collection_id: RmrkCollectionId) -> Result<Vec<RmrkNftId>, DispatchError> {1327 Ok(Default::default())1328 }13291330 fn nft_children(_collection_id: RmrkCollectionId, _nft_id: RmrkNftId) -> Result<Vec<RmrkNftChild>, DispatchError> {1331 Ok(Default::default())1332 }13331334 fn collection_properties(_collection_id: RmrkCollectionId, _filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Vec<RmrkPropertyInfo>, DispatchError> {1335 Ok(Default::default())1336 }13371338 fn nft_properties(_collection_id: RmrkCollectionId, _nft_id: RmrkNftId, _filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Vec<RmrkPropertyInfo>, DispatchError> {1339 Ok(Default::default())1340 }13411342 fn nft_resources(_collection_id: RmrkCollectionId, _nft_id: RmrkNftId) -> Result<Vec<RmrkResourceInfo>, DispatchError> {1343 Ok(Default::default())1344 }13451346 fn nft_resource_priority(_collection_id: RmrkCollectionId, _nft_id: RmrkNftId, _resource_id: RmrkResourceId) -> Result<Option<u32>, DispatchError> {1347 Ok(Default::default())1348 }13491350 fn base(_base_id: RmrkBaseId) -> Result<Option<RmrkBaseInfo<AccountId>>, DispatchError> {1351 Ok(Default::default())1352 }13531354 fn base_parts(_base_id: RmrkBaseId) -> Result<Vec<RmrkPartType>, DispatchError> {1355 Ok(Default::default())1356 }13571358 fn theme_names(_base_id: RmrkBaseId) -> Result<Vec<RmrkThemeName>, DispatchError> {1359 Ok(Default::default())1360 }13611362 fn theme(_base_id: RmrkBaseId, _theme_name: RmrkThemeName, _filter_keys: Option<Vec<RmrkPropertyKey>>) -> Result<Option<RmrkTheme>, DispatchError> {1363 Ok(Default::default())1364 }1365 }1366}136712631368struct CheckInherents;1264struct CheckInherents;13691265