Skip to content

Commit

Permalink
Merge branch 'dev' into p-865-solana-token-holding-amount
Browse files Browse the repository at this point in the history
  • Loading branch information
0xverin authored Jul 19, 2024
2 parents 70726a0 + 64c3357 commit fe5d09a
Show file tree
Hide file tree
Showing 18 changed files with 1,287 additions and 11 deletions.
23 changes: 23 additions & 0 deletions Cargo.lock

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

3 changes: 3 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ members = [
'pallets/group',
'pallets/identity-management',
'pallets/parachain-staking',
'pallets/score-staking',
'pallets/teebag',
'pallets/vc-management',
'pallets/xcm-asset-manager',
Expand Down Expand Up @@ -77,6 +78,7 @@ tokio = { version = "1.38.0", features = ["macros", "sync"] }
strum = { version = "0.26", default-features = false }
strum_macros = { version = "0.26", default-features = false }
num_enum = { version = "0.7.2", default-features = false }
num-integer = { version = "0.1", default-features = false }
rustc-hex = { version = "2.0.1", default-features = false }
x509-cert = { version = "0.1.0", default-features = false, features = ["alloc"] }
ring = { version = "0.16.20", default-features = false, features = ["alloc"] }
Expand Down Expand Up @@ -252,6 +254,7 @@ pallet-extrinsic-filter = { path = "pallets/extrinsic-filter", default-features
pallet-group = { path = "pallets/group", default-features = false }
pallet-identity-management = { path = "pallets/identity-management", default-features = false }
pallet-parachain-staking = { path = "pallets/parachain-staking", default-features = false }
pallet-score-staking = { path = "pallets/score-staking", default-features = false }
pallet-teebag = { path = "pallets/teebag", default-features = false }
pallet-vc-management = { path = "pallets/vc-management", default-features = false }
precompile-utils = { path = "precompiles/utils", default-features = false }
Expand Down
1 change: 1 addition & 0 deletions node/src/chain_specs/rococo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -256,5 +256,6 @@ fn generate_genesis(
mode: TeebagOperationalMode::Development,
},
bitacross: BitacrossConfig { admin: Some(root_key) },
score_staking: Default::default(),
}
}
4 changes: 2 additions & 2 deletions pallets/parachain-staking/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@ pub mod pallet {
#[pallet::storage]
#[pallet::getter(fn delegator_state)]
/// Get delegator state associated with an account if account is delegating else None
pub(crate) type DelegatorState<T: Config> = StorageMap<
pub type DelegatorState<T: Config> = StorageMap<
_,
Twox64Concat,
T::AccountId,
Expand Down Expand Up @@ -587,7 +587,7 @@ pub mod pallet {
#[pallet::storage]
#[pallet::getter(fn total)]
/// Total capital locked by this staking pallet
pub(crate) type Total<T: Config> = StorageValue<_, BalanceOf<T>, ValueQuery>;
pub type Total<T: Config> = StorageValue<_, BalanceOf<T>, ValueQuery>;

#[pallet::storage]
#[pallet::getter(fn candidate_pool)]
Expand Down
58 changes: 58 additions & 0 deletions pallets/score-staking/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
[package]
name = "pallet-score-staking"
description = 'pallet to stake based on the oracle score'
version = "0.1.0"
edition = "2021"

[dependencies]
num-integer = { workspace = true }
parity-scale-codec = { workspace = true }
scale-info = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true, features = ["alloc"] }

frame-benchmarking = { workspace = true, optional = true }
frame-support = { workspace = true }
frame-system = { workspace = true }
sp-core = { workspace = true }
sp-runtime = { workspace = true }
sp-std = { workspace = true }

core-primitives = { workspace = true }
pallet-parachain-staking = { workspace = true }

[dev-dependencies]
sp-io = { workspace = true }
pallet-balances = { workspace = true }
sp-keyring = { workspace = true }

[features]
default = ["std"]
std = [
"parity-scale-codec/std",
"serde/std",
"serde_json/std",
"num-integer/std",
"frame-benchmarking?/std",
"frame-support/std",
"frame-system/std",
"scale-info/std",
"sp-core/std",
"sp-io/std",
"sp-runtime/std",
"sp-std/std",
"pallet-balances/std",
"core-primitives/std",
"pallet-parachain-staking/std",
]
runtime-benchmarks = [
"frame-benchmarking/runtime-benchmarks",
"frame-support/runtime-benchmarks",
"frame-system/runtime-benchmarks",
"sp-runtime/runtime-benchmarks",
]
try-runtime = [
"frame-support/try-runtime",
"frame-system/try-runtime",
"sp-runtime/try-runtime",
]
Loading

0 comments on commit fe5d09a

Please sign in to comment.