Skip to content

Commit

Permalink
Merge pull request #664 from galacticcouncil/whitelist
Browse files Browse the repository at this point in the history
fix: Update TechComm origins
  • Loading branch information
mrq1911 authored Jun 13, 2024
2 parents d3b62ef + a43fbd3 commit 01c712c
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion 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 runtime/basilisk/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "basilisk-runtime"
version = "116.0.0"
version = "117.0.0"
authors = ["GalacticCouncil"]
edition = "2021"
homepage = "https://github.com/galacticcouncil/Basilisk-node"
Expand Down
5 changes: 4 additions & 1 deletion runtime/basilisk/src/governance/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ use frame_support::{
PalletId,
};
use frame_system::{EnsureRoot, EnsureRootWithSuccess};
use pallet_collective::EnsureProportionAtLeast;
use primitives::constants::{currency::DOLLARS, time::DAYS};
use sp_arithmetic::Perbill;
use sp_runtime::{traits::IdentityLookup, DispatchError};
Expand All @@ -38,6 +39,8 @@ mod tracks;
// Old governance configurations.
pub mod old;

pub type TechCommitteeMajority = EnsureProportionAtLeast<AccountId, TechnicalCollective, 1, 2>;

parameter_types! {
pub const TechnicalMotionDuration: BlockNumber = 5 * DAYS;
pub const TechnicalMaxProposals: u32 = 20;
Expand Down Expand Up @@ -84,7 +87,7 @@ impl pallet_whitelist::Config for Runtime {
type WeightInfo = weights::pallet_whitelist::WeightInfo<Self>;
type RuntimeCall = RuntimeCall;
type RuntimeEvent = RuntimeEvent;
type WhitelistOrigin = EnsureRoot<Self::AccountId>;
type WhitelistOrigin = EitherOf<EnsureRoot<Self::AccountId>, TechCommitteeMajority>;
type DispatchWhitelistedOrigin = EitherOf<EnsureRoot<Self::AccountId>, WhitelistedCaller>;
type Preimages = Preimage;
}
Expand Down
2 changes: 1 addition & 1 deletion runtime/basilisk/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion {
spec_name: create_runtime_str!("basilisk"),
impl_name: create_runtime_str!("basilisk"),
authoring_version: 1,
spec_version: 116,
spec_version: 117,
impl_version: 0,
apis: RUNTIME_API_VERSIONS,
transaction_version: 1,
Expand Down
4 changes: 2 additions & 2 deletions runtime/basilisk/src/system.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
// limitations under the License.

use super::*;
use crate::governance::{old::MajorityTechCommitteeOrRoot, origins::GeneralAdmin, TreasuryAccount};
use crate::governance::{origins::GeneralAdmin, TechCommitteeMajority, TreasuryAccount};

use pallet_transaction_multi_payment::{DepositAll, TransferFees};
use pallet_transaction_payment::{Multiplier, TargetedFeeAdjustment};
Expand Down Expand Up @@ -488,7 +488,7 @@ impl pallet_relaychain_info::Config for Runtime {

impl pallet_transaction_pause::Config for Runtime {
type RuntimeEvent = RuntimeEvent;
type UpdateOrigin = MajorityTechCommitteeOrRoot;
type UpdateOrigin = EitherOf<EnsureRoot<Self::AccountId>, TechCommitteeMajority>;
type WeightInfo = weights::pallet_transaction_pause::BasiliskWeight<Runtime>;
}

Expand Down

0 comments on commit 01c712c

Please sign in to comment.