Skip to content

Commit 32d2c71

Browse files
committed
match devnet-ready
1 parent 17b8674 commit 32d2c71

File tree

1 file changed

+18
-20
lines changed

1 file changed

+18
-20
lines changed

runtime/src/lib.rs

Lines changed: 18 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -19,20 +19,20 @@ use codec::{Compact, Decode, Encode};
1919
use frame_support::dispatch::DispatchResult;
2020
use frame_support::traits::{Imbalance, InsideBoth};
2121
use frame_support::{
22-
PalletId,
2322
dispatch::DispatchResultWithPostInfo,
2423
genesis_builder_helper::{build_state, get_preset},
2524
pallet_prelude::Get,
2625
traits::{
27-
Contains, LinearStoragePrice, OnUnbalanced,
2826
fungible::{
2927
DecreaseIssuance, HoldConsideration, Imbalance as FungibleImbalance, IncreaseIssuance,
3028
},
29+
Contains, LinearStoragePrice, OnUnbalanced,
3130
},
31+
PalletId,
3232
};
3333
use frame_system::{EnsureNever, EnsureRoot, EnsureRootWithSuccess, RawOrigin};
3434
use pallet_commitments::{CanCommit, OnMetadataCommitment};
35-
use pallet_grandpa::{AuthorityId as GrandpaId, fg_primitives};
35+
use pallet_grandpa::{fg_primitives, AuthorityId as GrandpaId};
3636
use pallet_registry::CanRegisterIdentity;
3737
use pallet_subtensor::rpc_info::{
3838
delegate_info::DelegateInfo,
@@ -49,41 +49,44 @@ use sp_consensus_aura::sr25519::AuthorityId as AuraId;
4949
use sp_consensus_babe::BabeConfiguration;
5050
use sp_consensus_babe::BabeEpochConfiguration;
5151
use sp_core::{
52-
H160, H256, OpaqueMetadata, U256,
5352
crypto::{ByteArray, KeyTypeId},
53+
OpaqueMetadata, H160, H256, U256,
5454
};
55-
use sp_runtime::Cow;
5655
use sp_runtime::generic::Era;
56+
use sp_runtime::traits::NumberFor;
57+
use sp_runtime::Cow;
5758
use sp_runtime::{
58-
AccountId32, ApplyExtrinsicResult, ConsensusEngineId, generic, impl_opaque_keys,
59+
generic, impl_opaque_keys,
5960
traits::{
6061
AccountIdLookup, BlakeTwo256, Block as BlockT, DispatchInfoOf, Dispatchable, One,
6162
PostDispatchInfoOf, UniqueSaturatedInto, Verify,
6263
},
6364
transaction_validity::{TransactionSource, TransactionValidity, TransactionValidityError},
65+
AccountId32, ApplyExtrinsicResult, ConsensusEngineId,
6466
};
6567
use sp_std::cmp::Ordering;
6668
use sp_std::prelude::*;
6769
#[cfg(feature = "std")]
6870
use sp_version::NativeVersion;
6971
use sp_version::RuntimeVersion;
7072
use subtensor_precompiles::Precompiles;
71-
use subtensor_runtime_common::{AlphaCurrency, time::*, *};
73+
use subtensor_runtime_common::{time::*, AlphaCurrency, *};
7274

7375
// A few exports that help ease life for downstream crates.
7476
pub use frame_support::{
75-
StorageValue, construct_runtime, parameter_types,
77+
construct_runtime, parameter_types,
7678
traits::{
77-
ConstBool, ConstU8, ConstU32, ConstU64, ConstU128, FindAuthor, InstanceFilter,
79+
ConstBool, ConstU128, ConstU32, ConstU64, ConstU8, FindAuthor, InstanceFilter,
7880
KeyOwnerProofSystem, OnFinalize, OnTimestampSet, PrivilegeCmp, Randomness, StorageInfo,
7981
},
8082
weights::{
81-
IdentityFee, Weight, WeightToFeeCoefficient, WeightToFeeCoefficients,
82-
WeightToFeePolynomial,
8383
constants::{
8484
BlockExecutionWeight, ExtrinsicBaseWeight, RocksDbWeight, WEIGHT_REF_TIME_PER_SECOND,
8585
},
86+
IdentityFee, Weight, WeightToFeeCoefficient, WeightToFeeCoefficients,
87+
WeightToFeePolynomial,
8688
},
89+
StorageValue,
8790
};
8891
pub use frame_system::Call as SystemCall;
8992
pub use pallet_balances::Call as BalancesCall;
@@ -1908,18 +1911,13 @@ impl_runtime_apis! {
19081911
}
19091912

19101913
fn submit_report_equivocation_unsigned_extrinsic(
1911-
equivocation_proof: fg_primitives::EquivocationProof<
1914+
_equivocation_proof: fg_primitives::EquivocationProof<
19121915
<Block as BlockT>::Hash,
1913-
sp_runtime::traits::NumberFor<Block>,
1916+
NumberFor<Block>,
19141917
>,
1915-
key_owner_proof: fg_primitives::OpaqueKeyOwnershipProof,
1918+
_key_owner_proof: fg_primitives::OpaqueKeyOwnershipProof,
19161919
) -> Option<()> {
1917-
let key_owner_proof = key_owner_proof.decode()?;
1918-
1919-
Grandpa::submit_unsigned_equivocation_report(
1920-
equivocation_proof,
1921-
key_owner_proof,
1922-
)
1920+
None
19231921
}
19241922

19251923
fn generate_key_ownership_proof(

0 commit comments

Comments
 (0)