Skip to content

Commit

Permalink
Merge pull request #141 from InvArch/gabriel-new_derivation
Browse files Browse the repository at this point in the history
New account derivation + INV4/Staking in InvArch
  • Loading branch information
arrudagates authored Jan 29, 2024
2 parents c5c57ba + c9820d9 commit 2c1cc6c
Show file tree
Hide file tree
Showing 25 changed files with 1,934 additions and 75 deletions.
221 changes: 219 additions & 2 deletions invarch/Cargo.lock

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

1 change: 1 addition & 0 deletions invarch/node/src/chain_spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -328,5 +328,6 @@ fn testnet_genesis(
// Assign network admin rights.
key: Some(root_key),
},
core_assets: Default::default(),
}
}
27 changes: 21 additions & 6 deletions invarch/runtime/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,12 @@ log = { version = "0.4.17", default-features = false }
scale-info = { version = "2.3.1", default-features = false, features = ["derive"] }
smallvec = "1.10.0"

modified-construct-runtime = { path = "../../modified-construct-runtime", default-features = false }

# InvArch
pallet-inv4 = { git = "https://github.com/InvArch/InvArch-Frames", rev = "ce1c1421550019472c622b7896e3fbd7f03d2ec5", default-features = false }
pallet-ocif-staking = { git = "https://github.com/InvArch/InvArch-Frames", rev = "ce1c1421550019472c622b7896e3fbd7f03d2ec5", default-features = false }
pallet-checked-inflation = { git = "https://github.com/InvArch/InvArch-Frames", rev = "ce1c1421550019472c622b7896e3fbd7f03d2ec5", default-features = false }

# Substrate
frame-benchmarking = { git = "https://github.com/paritytech/substrate", default-features = false, optional = true, branch = "polkadot-v0.9.43" }
Expand Down Expand Up @@ -58,6 +64,8 @@ pallet-tx-pause = { path = "../pallet-tx-pause", default-features = false }
# ORML
orml-xcm = { git = "https://github.com/open-web3-stack/open-runtime-module-library", default-features = false, branch = "polkadot-v0.9.43" }
orml-vesting = { git = "https://github.com/open-web3-stack/open-runtime-module-library", default-features = false, branch = "polkadot-v0.9.43" }
orml-traits = { git = "https://github.com/open-web3-stack/open-runtime-module-library", default-features = false, branch = "polkadot-v0.9.43" }
orml-tokens = { git = "https://github.com/open-web3-stack/open-runtime-module-library", default-features = false, branch = "polkadot-v0.9.43" }

# Polkadot
pallet-xcm = { git = "https://github.com/paritytech/polkadot", default-features = false, branch = "release-v0.9.43" }
Expand Down Expand Up @@ -100,21 +108,22 @@ std = [
"frame-support/std",
"frame-system-rpc-runtime-api/std",
"frame-system/std",
"orml-vesting/std",
"orml-xcm/std",
"orml-tokens/std",
"orml-vesting/std",
"orml-xcm/std",
"pallet-aura/std",
"pallet-authorship/std",
"pallet-balances/std",
"pallet-collator-selection/std",
"pallet-identity/std",
"pallet-identity/std",
"pallet-session/std",
"pallet-sudo/std",
"pallet-timestamp/std",
"pallet-transaction-payment-rpc-runtime-api/std",
"pallet-transaction-payment/std",
"pallet-treasury/std",
"pallet-tx-pause/std",
"pallet-utility/std",
"pallet-treasury/std",
"pallet-tx-pause/std",
"pallet-utility/std",
"pallet-xcm/std",
"parachain-info/std",
"polkadot-parachain/std",
Expand All @@ -133,6 +142,12 @@ std = [
"xcm-builder/std",
"xcm-executor/std",
"xcm/std",

"modified-construct-runtime/std",

"pallet-inv4/std",
"pallet-checked-inflation/std",
"pallet-ocif-staking/std"
]

runtime-benchmarks = [
Expand Down
8 changes: 8 additions & 0 deletions invarch/runtime/src/assets.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
use crate::common_types::AssetId;
use frame_support::parameter_types;

pub const VARCH_ASSET_ID: AssetId = 0;

parameter_types! {
pub const NativeAssetId: AssetId = VARCH_ASSET_ID;
}
2 changes: 1 addition & 1 deletion invarch/runtime/src/balances.rs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ impl WeightToFeePolynomial for WeightToFee {
}
}

type NegativeImbalance = <Balances as Currency<AccountId>>::NegativeImbalance;
pub type NegativeImbalance = <Balances as Currency<AccountId>>::NegativeImbalance;

pub struct ToCollatorPot;
impl OnUnbalanced<NegativeImbalance> for ToCollatorPot {
Expand Down
3 changes: 3 additions & 0 deletions invarch/runtime/src/common_types.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
pub type CommonId = u32;

pub type AssetId = u32;
Loading

0 comments on commit 2c1cc6c

Please sign in to comment.