mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-08 12:19:24 +00:00
Update patch-polkadot-sdk to remove scale_info
This commit is contained in:
859
Cargo.lock
generated
859
Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@@ -1,9 +1,6 @@
|
|||||||
[workspace]
|
[workspace]
|
||||||
resolver = "2"
|
resolver = "2"
|
||||||
members = [
|
members = [
|
||||||
# Version patches
|
|
||||||
"patches/parking_lot",
|
|
||||||
|
|
||||||
# Rewrites/redirects
|
# Rewrites/redirects
|
||||||
"patches/option-ext",
|
"patches/option-ext",
|
||||||
"patches/directories-next",
|
"patches/directories-next",
|
||||||
@@ -186,8 +183,6 @@ modular-frost = { path = "crypto/frost" }
|
|||||||
# https://github.com/rust-lang-nursery/lazy-static.rs/issues/201
|
# https://github.com/rust-lang-nursery/lazy-static.rs/issues/201
|
||||||
lazy_static = { git = "https://github.com/rust-lang-nursery/lazy-static.rs", rev = "5735630d46572f1e5377c8f2ba0f79d18f53b10c" }
|
lazy_static = { git = "https://github.com/rust-lang-nursery/lazy-static.rs", rev = "5735630d46572f1e5377c8f2ba0f79d18f53b10c" }
|
||||||
|
|
||||||
parking_lot = { path = "patches/parking_lot" }
|
|
||||||
|
|
||||||
# directories-next was created because directories was unmaintained
|
# directories-next was created because directories was unmaintained
|
||||||
# directories-next is now unmaintained while directories is maintained
|
# directories-next is now unmaintained while directories is maintained
|
||||||
# The directories author pulls in ridiculously pointless crates and prefers
|
# The directories author pulls in ridiculously pointless crates and prefers
|
||||||
|
|||||||
@@ -1,16 +0,0 @@
|
|||||||
[package]
|
|
||||||
name = "parking_lot"
|
|
||||||
version = "0.11.2"
|
|
||||||
description = "parking_lot which patches to the latest update"
|
|
||||||
license = "MIT"
|
|
||||||
repository = "https://github.com/serai-dex/serai/tree/develop/patches/parking_lot"
|
|
||||||
authors = ["Luke Parker <lukeparker5132@gmail.com>"]
|
|
||||||
keywords = []
|
|
||||||
edition = "2021"
|
|
||||||
|
|
||||||
[package.metadata.docs.rs]
|
|
||||||
all-features = true
|
|
||||||
rustdoc-args = ["--cfg", "docsrs"]
|
|
||||||
|
|
||||||
[dependencies]
|
|
||||||
parking_lot = "0.12"
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
pub use parking_lot::*;
|
|
||||||
@@ -22,13 +22,12 @@ workspace = true
|
|||||||
borsh = { version = "1", default-features = false, features = ["derive", "de_strict_order"] }
|
borsh = { version = "1", default-features = false, features = ["derive", "de_strict_order"] }
|
||||||
|
|
||||||
bitvec = { version = "1", default-features = false, features = ["alloc"] }
|
bitvec = { version = "1", default-features = false, features = ["alloc"] }
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
serde = { version = "1", default-features = false, features = ["derive"], optional = true }
|
serde = { version = "1", default-features = false, features = ["derive"], optional = true }
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"], optional = true }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"], optional = true }
|
||||||
scale-info = { version = "2", default-features = false, features = ["derive"], optional = true }
|
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false, features = ["serde"], optional = true }
|
||||||
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false, features = ["serde"], optional = true }
|
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false, optional = true }
|
||||||
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false, optional = true }
|
|
||||||
|
|
||||||
serai-primitives = { path = "../primitives", version = "0.1", default-features = false }
|
serai-primitives = { path = "../primitives", version = "0.1", default-features = false }
|
||||||
|
|
||||||
@@ -41,12 +40,11 @@ std = [
|
|||||||
|
|
||||||
"serde?/std",
|
"serde?/std",
|
||||||
"scale?/std",
|
"scale?/std",
|
||||||
"scale-info?/std",
|
|
||||||
"sp-runtime?/std",
|
"sp-runtime?/std",
|
||||||
"frame-support?/std",
|
"frame-support?/std",
|
||||||
|
|
||||||
"serai-primitives/std",
|
"serai-primitives/std",
|
||||||
]
|
]
|
||||||
substrate = ["serde", "scale", "scale-info", "sp-runtime", "frame-support", "serai-primitives/serde", "serai-primitives/non_canonical_scale_derivations"]
|
substrate = ["serde", "scale", "sp-runtime", "frame-support", "serai-primitives/serde", "serai-primitives/non_canonical_scale_derivations"]
|
||||||
try-runtime = ["sp-runtime/try-runtime"]
|
try-runtime = ["sp-runtime/try-runtime"]
|
||||||
default = ["std"]
|
default = ["std"]
|
||||||
|
|||||||
@@ -106,7 +106,6 @@ mod substrate {
|
|||||||
use core::fmt::Debug;
|
use core::fmt::Debug;
|
||||||
|
|
||||||
use scale::{Encode, Decode, DecodeWithMemTracking};
|
use scale::{Encode, Decode, DecodeWithMemTracking};
|
||||||
use scale_info::TypeInfo;
|
|
||||||
|
|
||||||
use sp_core::H256;
|
use sp_core::H256;
|
||||||
use sp_runtime::{
|
use sp_runtime::{
|
||||||
@@ -182,7 +181,6 @@ mod substrate {
|
|||||||
Encode,
|
Encode,
|
||||||
Decode,
|
Decode,
|
||||||
DecodeWithMemTracking,
|
DecodeWithMemTracking,
|
||||||
TypeInfo,
|
|
||||||
sp_runtime::Serialize,
|
sp_runtime::Serialize,
|
||||||
sp_runtime::Deserialize,
|
sp_runtime::Deserialize,
|
||||||
)]
|
)]
|
||||||
@@ -208,7 +206,6 @@ mod substrate {
|
|||||||
Encode,
|
Encode,
|
||||||
Decode,
|
Decode,
|
||||||
DecodeWithMemTracking,
|
DecodeWithMemTracking,
|
||||||
TypeInfo,
|
|
||||||
sp_runtime::Serialize,
|
sp_runtime::Serialize,
|
||||||
sp_runtime::Deserialize,
|
sp_runtime::Deserialize,
|
||||||
)]
|
)]
|
||||||
@@ -226,7 +223,6 @@ mod substrate {
|
|||||||
Encode,
|
Encode,
|
||||||
Decode,
|
Decode,
|
||||||
DecodeWithMemTracking,
|
DecodeWithMemTracking,
|
||||||
TypeInfo,
|
|
||||||
sp_runtime::Serialize,
|
sp_runtime::Serialize,
|
||||||
sp_runtime::Deserialize,
|
sp_runtime::Deserialize,
|
||||||
)]
|
)]
|
||||||
@@ -285,7 +281,7 @@ mod substrate {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// A block, as needed by Substrate.
|
/// A block, as needed by Substrate.
|
||||||
#[derive(Clone, Debug, PartialEq, Eq, Encode, Decode, DecodeWithMemTracking, TypeInfo)]
|
#[derive(Clone, Debug, PartialEq, Eq, Encode, Decode, DecodeWithMemTracking)]
|
||||||
pub struct SubstrateBlock {
|
pub struct SubstrateBlock {
|
||||||
header: SubstrateHeader,
|
header: SubstrateHeader,
|
||||||
transactions: Vec<Transaction>,
|
transactions: Vec<Transaction>,
|
||||||
|
|||||||
@@ -256,23 +256,10 @@ mod substrate {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Clean `Transaction` tracks its memory during decoding, as we do call
|
// Clean `Transaction` tracks its memory during decoding, as `read_scale_as_borsh` does call
|
||||||
// `Input::on_before_alloc_mem`
|
// `Input::on_before_alloc_mem`
|
||||||
impl scale::DecodeWithMemTracking for Transaction {}
|
impl scale::DecodeWithMemTracking for Transaction {}
|
||||||
|
|
||||||
// Shim `TypeInfo` for `Transaction`
|
|
||||||
impl scale_info::TypeInfo for Transaction {
|
|
||||||
type Identity = Self;
|
|
||||||
fn type_info() -> scale_info::Type {
|
|
||||||
scale_info::Type {
|
|
||||||
path: scale_info::Path { segments: vec!["serai_abi", "transaction", "Transaction"] },
|
|
||||||
type_params: vec![],
|
|
||||||
type_def: (scale_info::TypeDefComposite { fields: vec![] }).into(),
|
|
||||||
docs: vec![],
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/// The context which transactions are executed in.
|
/// The context which transactions are executed in.
|
||||||
pub trait TransactionContext: 'static + Send + Sync + Clone + PartialEq + Eq + Debug {
|
pub trait TransactionContext: 'static + Send + Sync + Clone + PartialEq + Eq + Debug {
|
||||||
/// The base weight for a signed transaction.
|
/// The base weight for a signed transaction.
|
||||||
|
|||||||
@@ -31,9 +31,9 @@ serde_json = { version = "1", optional = true }
|
|||||||
serai-abi = { path = "../abi", version = "0.1" }
|
serai-abi = { path = "../abi", version = "0.1" }
|
||||||
|
|
||||||
multiaddr = { version = "0.18", optional = true }
|
multiaddr = { version = "0.18", optional = true }
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", optional = true }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", optional = true }
|
||||||
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", optional = true }
|
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", optional = true }
|
||||||
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", optional = true }
|
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", optional = true }
|
||||||
|
|
||||||
async-lock = "3"
|
async-lock = "3"
|
||||||
|
|
||||||
|
|||||||
@@ -12,27 +12,23 @@ rust-version = "1.85"
|
|||||||
all-features = true
|
all-features = true
|
||||||
rustdoc-args = ["--cfg", "docsrs"]
|
rustdoc-args = ["--cfg", "docsrs"]
|
||||||
|
|
||||||
[package.metadata.cargo-machete]
|
|
||||||
ignored = ["scale", "scale-info"]
|
|
||||||
|
|
||||||
[lints]
|
[lints]
|
||||||
workspace = true
|
workspace = true
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
||||||
scale-info = { version = "2", default-features = false, features = ["derive"] }
|
|
||||||
|
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-std = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-std = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
serai-primitives = { path = "../primitives", default-features = false, features = ["serde", "non_canonical_scale_derivations"] }
|
serai-primitives = { path = "../primitives", default-features = false, features = ["serde", "non_canonical_scale_derivations"] }
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false, features = ["std"] }
|
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false, features = ["std"] }
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
std = [
|
std = [
|
||||||
|
|||||||
@@ -13,24 +13,23 @@ all-features = true
|
|||||||
rustdoc-args = ["--cfg", "docsrs"]
|
rustdoc-args = ["--cfg", "docsrs"]
|
||||||
|
|
||||||
[package.metadata.cargo-machete]
|
[package.metadata.cargo-machete]
|
||||||
ignored = ["scale", "scale-info"]
|
ignored = ["scale"]
|
||||||
|
|
||||||
[lints]
|
[lints]
|
||||||
workspace = true
|
workspace = true
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
scale = { package = "parity-scale-codec", version = "3.6.1", default-features = false }
|
scale = { package = "parity-scale-codec", version = "3.6.1", default-features = false }
|
||||||
scale-info = { version = "2.5.0", default-features = false, features = ["derive"] }
|
|
||||||
|
|
||||||
sp-std = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-std = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-benchmarking = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false, optional = true }
|
frame-benchmarking = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false, optional = true }
|
||||||
|
|
||||||
coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-features = false }
|
coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-features = false }
|
||||||
|
|
||||||
@@ -43,7 +42,6 @@ rand_core = { version = "0.6", default-features = false, features = ["getrandom"
|
|||||||
default = ["std"]
|
default = ["std"]
|
||||||
std = [
|
std = [
|
||||||
"scale/std",
|
"scale/std",
|
||||||
"scale-info/std",
|
|
||||||
|
|
||||||
"sp-std/std",
|
"sp-std/std",
|
||||||
"sp-io/std",
|
"sp-io/std",
|
||||||
|
|||||||
@@ -13,17 +13,16 @@ all-features = true
|
|||||||
rustdoc-args = ["--cfg", "docsrs"]
|
rustdoc-args = ["--cfg", "docsrs"]
|
||||||
|
|
||||||
[package.metadata.cargo-machete]
|
[package.metadata.cargo-machete]
|
||||||
ignored = ["scale", "scale-info"]
|
ignored = ["scale"]
|
||||||
|
|
||||||
[lints]
|
[lints]
|
||||||
workspace = true
|
workspace = true
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
||||||
scale-info = { version = "2", default-features = false, features = ["derive"] }
|
|
||||||
|
|
||||||
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
dex-pallet = { package = "serai-dex-pallet", path = "../dex", default-features = false }
|
dex-pallet = { package = "serai-dex-pallet", path = "../dex", default-features = false }
|
||||||
coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-features = false }
|
coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-features = false }
|
||||||
@@ -31,21 +30,20 @@ coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-feat
|
|||||||
serai-primitives = { path = "../primitives", default-features = false }
|
serai-primitives = { path = "../primitives", default-features = false }
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
pallet-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
pallet-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
pallet-grandpa = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
pallet-grandpa = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
pallet-timestamp = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
pallet-timestamp = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
validator-sets-pallet = { package = "serai-validator-sets-pallet", path = "../validator-sets", default-features = false }
|
validator-sets-pallet = { package = "serai-validator-sets-pallet", path = "../validator-sets", default-features = false }
|
||||||
|
|
||||||
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-consensus-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-consensus-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
std = [
|
std = [
|
||||||
"scale/std",
|
"scale/std",
|
||||||
"scale-info/std",
|
|
||||||
|
|
||||||
"frame-system/std",
|
"frame-system/std",
|
||||||
"frame-support/std",
|
"frame-support/std",
|
||||||
|
|||||||
@@ -13,20 +13,19 @@ all-features = true
|
|||||||
rustdoc-args = ["--cfg", "docsrs"]
|
rustdoc-args = ["--cfg", "docsrs"]
|
||||||
|
|
||||||
[package.metadata.cargo-machete]
|
[package.metadata.cargo-machete]
|
||||||
ignored = ["scale", "scale-info"]
|
ignored = ["scale"]
|
||||||
|
|
||||||
[lints]
|
[lints]
|
||||||
workspace = true
|
workspace = true
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
||||||
scale-info = { version = "2", default-features = false, features = ["derive"] }
|
|
||||||
|
|
||||||
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
sp-std = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-std = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-features = false }
|
coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-features = false }
|
||||||
validator-sets-pallet = { package = "serai-validator-sets-pallet", path = "../validator-sets", default-features = false }
|
validator-sets-pallet = { package = "serai-validator-sets-pallet", path = "../validator-sets", default-features = false }
|
||||||
@@ -40,7 +39,6 @@ serai-primitives = { path = "../primitives", default-features = false }
|
|||||||
[features]
|
[features]
|
||||||
std = [
|
std = [
|
||||||
"scale/std",
|
"scale/std",
|
||||||
"scale-info/std",
|
|
||||||
|
|
||||||
"frame-system/std",
|
"frame-system/std",
|
||||||
"frame-support/std",
|
"frame-support/std",
|
||||||
|
|||||||
@@ -13,21 +13,20 @@ all-features = true
|
|||||||
rustdoc-args = ["--cfg", "docsrs"]
|
rustdoc-args = ["--cfg", "docsrs"]
|
||||||
|
|
||||||
[package.metadata.cargo-machete]
|
[package.metadata.cargo-machete]
|
||||||
ignored = ["scale", "scale-info"]
|
ignored = ["scale"]
|
||||||
|
|
||||||
[lints]
|
[lints]
|
||||||
workspace = true
|
workspace = true
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
||||||
scale-info = { version = "2", default-features = false, features = ["derive"] }
|
|
||||||
|
|
||||||
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
sp-std = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-std = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-application-crypto = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-application-crypto = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
dex-pallet = { package = "serai-dex-pallet", path = "../dex", default-features = false }
|
dex-pallet = { package = "serai-dex-pallet", path = "../dex", default-features = false }
|
||||||
coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-features = false }
|
coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-features = false }
|
||||||
@@ -40,7 +39,6 @@ serai-primitives = { path = "../primitives", default-features = false }
|
|||||||
[features]
|
[features]
|
||||||
std = [
|
std = [
|
||||||
"scale/std",
|
"scale/std",
|
||||||
"scale-info/std",
|
|
||||||
|
|
||||||
"frame-system/std",
|
"frame-system/std",
|
||||||
"frame-support/std",
|
"frame-support/std",
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ all-features = true
|
|||||||
rustdoc-args = ["--cfg", "docsrs"]
|
rustdoc-args = ["--cfg", "docsrs"]
|
||||||
|
|
||||||
[package.metadata.cargo-machete]
|
[package.metadata.cargo-machete]
|
||||||
ignored = ["scale", "scale-info"]
|
ignored = ["scale"]
|
||||||
|
|
||||||
[lints]
|
[lints]
|
||||||
workspace = true
|
workspace = true
|
||||||
@@ -23,16 +23,15 @@ workspace = true
|
|||||||
bitvec = { version = "1", default-features = false, features = ["alloc"] }
|
bitvec = { version = "1", default-features = false, features = ["alloc"] }
|
||||||
|
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive", "max-encoded-len"] }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive", "max-encoded-len"] }
|
||||||
scale-info = { version = "2", default-features = false, features = ["derive"] }
|
|
||||||
|
|
||||||
sp-std = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-std = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-application-crypto = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-application-crypto = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
serai-primitives = { path = "../primitives", default-features = false }
|
serai-primitives = { path = "../primitives", default-features = false }
|
||||||
|
|
||||||
@@ -43,16 +42,15 @@ genesis-liquidity-pallet = { package = "serai-genesis-liquidity-pallet", path =
|
|||||||
emissions-pallet = { package = "serai-emissions-pallet", path = "../emissions", default-features = false }
|
emissions-pallet = { package = "serai-emissions-pallet", path = "../emissions", default-features = false }
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
pallet-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
pallet-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
pallet-grandpa = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
pallet-grandpa = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
pallet-timestamp = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
pallet-timestamp = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
economic-security-pallet = { package = "serai-economic-security-pallet", path = "../economic-security", default-features = false }
|
economic-security-pallet = { package = "serai-economic-security-pallet", path = "../economic-security", default-features = false }
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
std = [
|
std = [
|
||||||
"scale/std",
|
"scale/std",
|
||||||
"scale-info/std",
|
|
||||||
|
|
||||||
"sp-std/std",
|
"sp-std/std",
|
||||||
"sp-application-crypto/std",
|
"sp-application-crypto/std",
|
||||||
|
|||||||
@@ -34,16 +34,16 @@ secq256k1 = { path = "../../crypto/secq256k1" }
|
|||||||
|
|
||||||
libp2p = "0.54"
|
libp2p = "0.54"
|
||||||
|
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sp-keystore = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sp-keystore = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sp-timestamp = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sp-timestamp = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sp-blockchain = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sp-blockchain = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sp-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sp-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sp-block-builder = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sp-block-builder = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sp-consensus-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sp-consensus-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
|
|
||||||
frame-benchmarking = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
frame-benchmarking = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
|
|
||||||
serai-runtime = { path = "../runtime", features = ["std"] }
|
serai-runtime = { path = "../runtime", features = ["std"] }
|
||||||
|
|
||||||
@@ -55,25 +55,24 @@ jsonrpsee = { version = "0.24", features = ["server"] }
|
|||||||
|
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
||||||
|
|
||||||
sc-offchain = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-transaction-pool = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-transaction-pool = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-transaction-pool-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-transaction-pool-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-basic-authorship = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-basic-authorship = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-executor = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-executor = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-service = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-service = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-client-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-client-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-network-common = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-network-common = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-network = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false, features = [] }
|
||||||
sc-network = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false, features = [] }
|
|
||||||
|
|
||||||
sc-consensus = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-consensus = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-consensus-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-consensus-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-consensus-grandpa = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-consensus-grandpa = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-authority-discovery = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-authority-discovery = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
|
|
||||||
sc-telemetry = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-telemetry = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
sc-cli = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false, features = ["rocksdb"] }
|
sc-cli = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false, features = ["rocksdb"] }
|
||||||
|
|
||||||
sc-rpc-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
sc-rpc-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
|
|
||||||
serai-env = { path = "../../common/env" }
|
serai-env = { path = "../../common/env" }
|
||||||
|
|
||||||
|
|||||||
@@ -21,8 +21,7 @@ borsh = { version = "1", default-features = false, features = ["derive", "de_str
|
|||||||
|
|
||||||
bitvec = { version = "1", default-features = false, features = ["alloc"] }
|
bitvec = { version = "1", default-features = false, features = ["alloc"] }
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"], optional = true }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"], optional = true }
|
||||||
scale-info = { version = "2", default-features = false, features = ["derive"], optional = true }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
|
||||||
|
|
||||||
ciphersuite = { path = "../../crypto/ciphersuite", default-features = false, features = ["alloc"] }
|
ciphersuite = { path = "../../crypto/ciphersuite", default-features = false, features = ["alloc"] }
|
||||||
schnorr-signatures = { path = "../../crypto/schnorr", default-features = false }
|
schnorr-signatures = { path = "../../crypto/schnorr", default-features = false }
|
||||||
@@ -44,7 +43,6 @@ std = [
|
|||||||
"borsh/std",
|
"borsh/std",
|
||||||
"bitvec/std",
|
"bitvec/std",
|
||||||
"scale?/std",
|
"scale?/std",
|
||||||
"scale-info?/std",
|
|
||||||
"sp-core/std",
|
"sp-core/std",
|
||||||
"ciphersuite/std",
|
"ciphersuite/std",
|
||||||
"schnorr-signatures/std",
|
"schnorr-signatures/std",
|
||||||
@@ -56,5 +54,5 @@ std = [
|
|||||||
"bech32/std"
|
"bech32/std"
|
||||||
]
|
]
|
||||||
serde = []
|
serde = []
|
||||||
non_canonical_scale_derivations = ["scale", "scale-info"]
|
non_canonical_scale_derivations = ["scale"]
|
||||||
default = ["std"]
|
default = ["std"]
|
||||||
|
|||||||
@@ -24,10 +24,7 @@ const HUMAN_READABLE_PART: bech32::Hrp = bech32::Hrp::parse_unchecked("sri");
|
|||||||
|
|
||||||
/// The address for an account on Serai.
|
/// The address for an account on Serai.
|
||||||
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(feature = "non_canonical_scale_derivations", derive(scale::Encode, scale::Decode))]
|
||||||
feature = "non_canonical_scale_derivations",
|
|
||||||
derive(scale::Encode, scale::Decode, scale_info::TypeInfo)
|
|
||||||
)]
|
|
||||||
pub struct SeraiAddress(pub [u8; 32]);
|
pub struct SeraiAddress(pub [u8; 32]);
|
||||||
|
|
||||||
// These share encodings as 32-byte arrays
|
// These share encodings as 32-byte arrays
|
||||||
@@ -117,13 +114,7 @@ impl core::str::FromStr for SeraiAddress {
|
|||||||
#[derive(Clone, PartialEq, Eq, Debug, borsh::BorshSerialize, borsh::BorshDeserialize)]
|
#[derive(Clone, PartialEq, Eq, Debug, borsh::BorshSerialize, borsh::BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub struct ExternalAddress(
|
pub struct ExternalAddress(
|
||||||
#[borsh(
|
#[borsh(
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ pub type AmountRepr = u64;
|
|||||||
#[derive(Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking, scale_info::TypeInfo)
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
)]
|
)]
|
||||||
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
||||||
#[cfg_attr(feature = "serde", serde(crate = "sp_core::serde"))]
|
#[cfg_attr(feature = "serde", serde(crate = "sp_core::serde"))]
|
||||||
@@ -46,13 +46,7 @@ impl Mul for Amount {
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
||||||
#[cfg_attr(feature = "serde", serde(crate = "sp_core::serde"))]
|
#[cfg_attr(feature = "serde", serde(crate = "sp_core::serde"))]
|
||||||
@@ -88,13 +82,7 @@ impl Mul<Amount> for ExternalBalance {
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
||||||
#[cfg_attr(feature = "serde", serde(crate = "sp_core::serde"))]
|
#[cfg_attr(feature = "serde", serde(crate = "sp_core::serde"))]
|
||||||
|
|||||||
@@ -11,13 +11,7 @@ use crate::network_id::{ExternalNetworkId, NetworkId};
|
|||||||
#[borsh(use_discriminant = true)]
|
#[borsh(use_discriminant = true)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
||||||
#[cfg_attr(feature = "serde", serde(crate = "sp_core::serde"))]
|
#[cfg_attr(feature = "serde", serde(crate = "sp_core::serde"))]
|
||||||
@@ -45,13 +39,7 @@ impl ExternalCoin {
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
#[cfg_attr(feature = "non_canonical_scale_derivations", allow(clippy::cast_possible_truncation))]
|
#[cfg_attr(feature = "non_canonical_scale_derivations", allow(clippy::cast_possible_truncation))]
|
||||||
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
||||||
|
|||||||
@@ -17,13 +17,7 @@ use crate::network_id::ExternalNetworkId;
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub struct Public(pub [u8; 32]);
|
pub struct Public(pub [u8; 32]);
|
||||||
impl From<sp_core::sr25519::Public> for Public {
|
impl From<sp_core::sr25519::Public> for Public {
|
||||||
@@ -41,13 +35,7 @@ impl From<Public> for sp_core::sr25519::Public {
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub struct Signature(pub [u8; 64]);
|
pub struct Signature(pub [u8; 64]);
|
||||||
impl From<schnorrkel::Signature> for Signature {
|
impl From<schnorrkel::Signature> for Signature {
|
||||||
@@ -70,13 +58,7 @@ impl From<Signature> for sp_core::sr25519::Signature {
|
|||||||
#[derive(Clone, PartialEq, Eq, Debug, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, PartialEq, Eq, Debug, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub struct ExternalKey(
|
pub struct ExternalKey(
|
||||||
#[borsh(
|
#[borsh(
|
||||||
@@ -373,12 +355,6 @@ impl scale::DecodeWithMemTracking for SignedEmbeddedEllipticCurveKeys {}
|
|||||||
#[derive(Clone, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub struct KeyPair(pub Public, pub ExternalKey);
|
pub struct KeyPair(pub Public, pub ExternalKey);
|
||||||
|
|||||||
@@ -8,13 +8,7 @@ use crate::{address::ExternalAddress, balance::ExternalBalance};
|
|||||||
#[derive(Clone, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
#[cfg_attr(feature = "non_canonical_scale_derivations", allow(clippy::cast_possible_truncation))]
|
#[cfg_attr(feature = "non_canonical_scale_derivations", allow(clippy::cast_possible_truncation))]
|
||||||
pub enum OutInstruction {
|
pub enum OutInstruction {
|
||||||
@@ -26,13 +20,7 @@ pub enum OutInstruction {
|
|||||||
#[derive(Clone, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub struct OutInstructionWithBalance {
|
pub struct OutInstructionWithBalance {
|
||||||
/// The instruction on how to transfer coins out.
|
/// The instruction on how to transfer coins out.
|
||||||
|
|||||||
@@ -67,10 +67,7 @@ impl From<u64> for BlockNumber {
|
|||||||
hash it into a 32-byte hash or truncate it.
|
hash it into a 32-byte hash or truncate it.
|
||||||
*/
|
*/
|
||||||
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(feature = "non_canonical_scale_derivations", derive(scale::Encode, scale::Decode))]
|
||||||
feature = "non_canonical_scale_derivations",
|
|
||||||
derive(scale::Encode, scale::Decode, scale_info::TypeInfo)
|
|
||||||
)]
|
|
||||||
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
#[cfg_attr(feature = "serde", derive(sp_core::serde::Serialize, sp_core::serde::Deserialize))]
|
||||||
#[cfg_attr(feature = "serde", serde(crate = "sp_core::serde"))]
|
#[cfg_attr(feature = "serde", serde(crate = "sp_core::serde"))]
|
||||||
pub struct BlockHash(pub [u8; 32]);
|
pub struct BlockHash(pub [u8; 32]);
|
||||||
|
|||||||
@@ -76,7 +76,7 @@ impl UnbalancedMerkleTree {
|
|||||||
#[derive(Clone, PartialEq, Eq, Debug)]
|
#[derive(Clone, PartialEq, Eq, Debug)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(scale::Encode, scale::Decode, scale::DecodeWithMemTracking, scale_info::TypeInfo)
|
derive(scale::Encode, scale::Decode, scale::DecodeWithMemTracking)
|
||||||
)]
|
)]
|
||||||
pub struct IncrementalUnbalancedMerkleTree {
|
pub struct IncrementalUnbalancedMerkleTree {
|
||||||
/// (number of children under branch, branch hash)
|
/// (number of children under branch, branch hash)
|
||||||
|
|||||||
@@ -8,13 +8,7 @@ use crate::coin::{ExternalCoin, Coin};
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub enum EmbeddedEllipticCurve {
|
pub enum EmbeddedEllipticCurve {
|
||||||
/// The Embedwards25519 curve, defined over (embedded into) Ed25519's/Ristretto's scalar field.
|
/// The Embedwards25519 curve, defined over (embedded into) Ed25519's/Ristretto's scalar field.
|
||||||
@@ -30,13 +24,7 @@ pub enum EmbeddedEllipticCurve {
|
|||||||
#[borsh(use_discriminant = true)]
|
#[borsh(use_discriminant = true)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
#[non_exhaustive]
|
#[non_exhaustive]
|
||||||
pub enum ExternalNetworkId {
|
pub enum ExternalNetworkId {
|
||||||
@@ -88,13 +76,7 @@ impl ExternalNetworkId {
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
#[cfg_attr(feature = "non_canonical_scale_derivations", allow(clippy::cast_possible_truncation))]
|
#[cfg_attr(feature = "non_canonical_scale_derivations", allow(clippy::cast_possible_truncation))]
|
||||||
pub enum NetworkId {
|
pub enum NetworkId {
|
||||||
|
|||||||
@@ -19,13 +19,7 @@ pub use slashes::*;
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub struct Session(pub u32);
|
pub struct Session(pub u32);
|
||||||
|
|
||||||
@@ -33,13 +27,7 @@ pub struct Session(pub u32);
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub struct ExternalValidatorSet {
|
pub struct ExternalValidatorSet {
|
||||||
/// The network this set of validators are for.
|
/// The network this set of validators are for.
|
||||||
@@ -52,13 +40,7 @@ pub struct ExternalValidatorSet {
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Hash, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub struct ValidatorSet {
|
pub struct ValidatorSet {
|
||||||
/// The network this set of validators are for.
|
/// The network this set of validators are for.
|
||||||
|
|||||||
@@ -22,13 +22,7 @@ fn downtime_per_slash_point(validators: NonZero<u16>) -> Duration {
|
|||||||
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, Copy, PartialEq, Eq, Debug, Zeroize, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
#[cfg_attr(feature = "non_canonical_scale_derivations", allow(clippy::cast_possible_truncation))]
|
#[cfg_attr(feature = "non_canonical_scale_derivations", allow(clippy::cast_possible_truncation))]
|
||||||
pub enum Slash {
|
pub enum Slash {
|
||||||
@@ -211,13 +205,7 @@ impl Slash {
|
|||||||
#[derive(Clone, PartialEq, Eq, Debug, BorshSerialize, BorshDeserialize)]
|
#[derive(Clone, PartialEq, Eq, Debug, BorshSerialize, BorshDeserialize)]
|
||||||
#[cfg_attr(
|
#[cfg_attr(
|
||||||
feature = "non_canonical_scale_derivations",
|
feature = "non_canonical_scale_derivations",
|
||||||
derive(
|
derive(scale::Encode, scale::Decode, scale::MaxEncodedLen, scale::DecodeWithMemTracking)
|
||||||
scale::Encode,
|
|
||||||
scale::Decode,
|
|
||||||
scale::MaxEncodedLen,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo
|
|
||||||
)
|
|
||||||
)]
|
)]
|
||||||
pub struct SlashReport(
|
pub struct SlashReport(
|
||||||
#[borsh(
|
#[borsh(
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ all-features = true
|
|||||||
rustdoc-args = ["--cfg", "docsrs"]
|
rustdoc-args = ["--cfg", "docsrs"]
|
||||||
|
|
||||||
[package.metadata.cargo-machete]
|
[package.metadata.cargo-machete]
|
||||||
ignored = ["scale", "scale-info"]
|
ignored = ["scale"]
|
||||||
|
|
||||||
[lints]
|
[lints]
|
||||||
workspace = true
|
workspace = true
|
||||||
@@ -21,28 +21,26 @@ workspace = true
|
|||||||
borsh = { version = "1", default-features = false, features = ["derive", "de_strict_order"] }
|
borsh = { version = "1", default-features = false, features = ["derive", "de_strict_order"] }
|
||||||
|
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
||||||
scale-info = { version = "2", default-features = false, features = ["derive"] }
|
|
||||||
|
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-version = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-version = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
serai-abi = { path = "../abi", default-features = false, features = ["substrate"] }
|
serai-abi = { path = "../abi", default-features = false, features = ["substrate"] }
|
||||||
|
|
||||||
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-executive = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-executive = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
serai-coins-pallet = { path = "../coins", default-features = false }
|
serai-coins-pallet = { path = "../coins", default-features = false }
|
||||||
|
|
||||||
[build-dependencies]
|
[build-dependencies]
|
||||||
substrate-wasm-builder = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0" }
|
substrate-wasm-builder = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c" }
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
std = [
|
std = [
|
||||||
"scale/std",
|
"scale/std",
|
||||||
"scale-info/std",
|
|
||||||
|
|
||||||
"sp-core/std",
|
"sp-core/std",
|
||||||
"sp-version/std",
|
"sp-version/std",
|
||||||
|
|||||||
@@ -13,20 +13,19 @@ all-features = true
|
|||||||
rustdoc-args = ["--cfg", "docsrs"]
|
rustdoc-args = ["--cfg", "docsrs"]
|
||||||
|
|
||||||
[package.metadata.cargo-machete]
|
[package.metadata.cargo-machete]
|
||||||
ignored = ["scale", "scale-info"]
|
ignored = ["scale"]
|
||||||
|
|
||||||
[lints]
|
[lints]
|
||||||
workspace = true
|
workspace = true
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive"] }
|
||||||
scale-info = { version = "2", default-features = false, features = ["derive"] }
|
|
||||||
|
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
serai-primitives = { path = "../primitives", default-features = false }
|
serai-primitives = { path = "../primitives", default-features = false }
|
||||||
|
|
||||||
@@ -36,7 +35,6 @@ in-instructions-pallet = { package = "serai-in-instructions-pallet", path = "../
|
|||||||
[features]
|
[features]
|
||||||
std = [
|
std = [
|
||||||
"scale/std",
|
"scale/std",
|
||||||
"scale-info/std",
|
|
||||||
|
|
||||||
"sp-core/std",
|
"sp-core/std",
|
||||||
"sp-io/std",
|
"sp-io/std",
|
||||||
|
|||||||
@@ -9,8 +9,6 @@
|
|||||||
)] // TODO
|
)] // TODO
|
||||||
#[frame_support::pallet]
|
#[frame_support::pallet]
|
||||||
pub mod pallet {
|
pub mod pallet {
|
||||||
use scale_info::TypeInfo;
|
|
||||||
|
|
||||||
use sp_core::sr25519::Public;
|
use sp_core::sr25519::Public;
|
||||||
use sp_io::hashing::blake2_256;
|
use sp_io::hashing::blake2_256;
|
||||||
|
|
||||||
@@ -25,9 +23,7 @@ pub mod pallet {
|
|||||||
use in_instructions_pallet::{Config as IiConfig, Pallet as InInstructions};
|
use in_instructions_pallet::{Config as IiConfig, Pallet as InInstructions};
|
||||||
|
|
||||||
#[pallet::config]
|
#[pallet::config]
|
||||||
pub trait Config:
|
pub trait Config: frame_system::Config<AccountId = Public> + VsConfig + IiConfig {
|
||||||
frame_system::Config<AccountId = Public> + VsConfig + IiConfig + TypeInfo
|
|
||||||
{
|
|
||||||
type RuntimeEvent: IsType<<Self as frame_system::Config>::RuntimeEvent> + From<Event<Self>>;
|
type RuntimeEvent: IsType<<Self as frame_system::Config>::RuntimeEvent> + From<Event<Self>>;
|
||||||
|
|
||||||
type RetirementValidityDuration: Get<u32>;
|
type RetirementValidityDuration: Get<u32>;
|
||||||
@@ -56,7 +52,7 @@ pub mod pallet {
|
|||||||
#[pallet::pallet]
|
#[pallet::pallet]
|
||||||
pub struct Pallet<T>(PhantomData<T>);
|
pub struct Pallet<T>(PhantomData<T>);
|
||||||
|
|
||||||
#[derive(Clone, PartialEq, Eq, Debug, Encode, Decode, TypeInfo, MaxEncodedLen)]
|
#[derive(Clone, PartialEq, Eq, Debug, Encode, Decode, MaxEncodedLen)]
|
||||||
pub struct RegisteredRetirementSignal<T: Config> {
|
pub struct RegisteredRetirementSignal<T: Config> {
|
||||||
in_favor_of: [u8; 32],
|
in_favor_of: [u8; 32],
|
||||||
registrant: T::AccountId,
|
registrant: T::AccountId,
|
||||||
|
|||||||
@@ -19,24 +19,23 @@ workspace = true
|
|||||||
bitvec = { version = "1", default-features = false, features = ["alloc", "serde"] }
|
bitvec = { version = "1", default-features = false, features = ["alloc", "serde"] }
|
||||||
|
|
||||||
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive", "bit-vec"] }
|
scale = { package = "parity-scale-codec", version = "3", default-features = false, features = ["derive", "bit-vec"] }
|
||||||
scale-info = { version = "2", default-features = false, features = ["derive", "bit-vec"] }
|
|
||||||
|
|
||||||
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-core = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-io = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-runtime = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
sp-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
sp-api = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-system = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
frame-support = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
serai-primitives = { path = "../primitives", default-features = false, features = ["non_canonical_scale_derivations"] }
|
serai-primitives = { path = "../primitives", default-features = false, features = ["non_canonical_scale_derivations"] }
|
||||||
|
|
||||||
coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-features = false }
|
coins-pallet = { package = "serai-coins-pallet", path = "../coins", default-features = false }
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
#pallet-timestamp = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
#pallet-timestamp = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
#sp-consensus-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "9451a7e8d8ff28571bd9bc8cdea91dacd80e1ab0", default-features = false }
|
#sp-consensus-babe = { git = "https://github.com/serai-dex/patch-polkadot-sdk", rev = "749e7a1a664813ea3ae15e646f352a410e39653c", default-features = false }
|
||||||
|
|
||||||
#ciphersuite = { path = "../../../crypto/ciphersuite", default-features = false, features = ["std"] }
|
#ciphersuite = { path = "../../../crypto/ciphersuite", default-features = false, features = ["std"] }
|
||||||
#dalek-ff-group = { path = "../../../crypto/dalek-ff-group", default-features = false, features = ["std"] }
|
#dalek-ff-group = { path = "../../../crypto/dalek-ff-group", default-features = false, features = ["std"] }
|
||||||
@@ -54,7 +53,6 @@ std = [
|
|||||||
"bitvec/std",
|
"bitvec/std",
|
||||||
|
|
||||||
"scale/std",
|
"scale/std",
|
||||||
"scale-info/std",
|
|
||||||
|
|
||||||
"sp-core/std",
|
"sp-core/std",
|
||||||
"sp-io/std",
|
"sp-io/std",
|
||||||
|
|||||||
@@ -17,7 +17,6 @@ use sessions::{*, GenesisValidators as GenesisValidatorsContainer};
|
|||||||
use core::marker::PhantomData;
|
use core::marker::PhantomData;
|
||||||
|
|
||||||
use scale::{Encode, Decode};
|
use scale::{Encode, Decode};
|
||||||
use scale_info::TypeInfo;
|
|
||||||
|
|
||||||
use sp_std::{vec, vec::Vec};
|
use sp_std::{vec, vec::Vec};
|
||||||
use sp_core::sr25519::{Public, Signature};
|
use sp_core::sr25519::{Public, Signature};
|
||||||
@@ -49,7 +48,7 @@ use pallet_grandpa::{
|
|||||||
EquivocationOffence as GrandpaEquivocationOffence,
|
EquivocationOffence as GrandpaEquivocationOffence,
|
||||||
};
|
};
|
||||||
|
|
||||||
#[derive(Debug, Encode, Decode, TypeInfo, PartialEq, Eq, Clone)]
|
#[derive(Debug, Encode, Decode, PartialEq, Eq, Clone)]
|
||||||
pub struct MembershipProof<T: pallet::Config>(pub Public, pub PhantomData<T>);
|
pub struct MembershipProof<T: pallet::Config>(pub Public, pub PhantomData<T>);
|
||||||
impl<T: pallet::Config> GetSessionNumber for MembershipProof<T> {
|
impl<T: pallet::Config> GetSessionNumber for MembershipProof<T> {
|
||||||
fn session(&self) -> u32 {
|
fn session(&self) -> u32 {
|
||||||
|
|||||||
@@ -94,11 +94,7 @@ fn clear_selected_validators<Storage: StoragePrefixedMap<u64>>(set: ValidatorSet
|
|||||||
|
|
||||||
/// An error when allocating.
|
/// An error when allocating.
|
||||||
#[derive(
|
#[derive(
|
||||||
scale::Encode,
|
scale::Encode, scale::Decode, scale::DecodeWithMemTracking, frame_support::PalletError,
|
||||||
scale::Decode,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo,
|
|
||||||
frame_support::PalletError,
|
|
||||||
)]
|
)]
|
||||||
pub enum AllocationError {
|
pub enum AllocationError {
|
||||||
/// The validator set didn't define an allocation requirement for a key share.
|
/// The validator set didn't define an allocation requirement for a key share.
|
||||||
@@ -118,11 +114,7 @@ pub(crate) enum DeallocationTimeline {
|
|||||||
|
|
||||||
/// An error when deallocating.
|
/// An error when deallocating.
|
||||||
#[derive(
|
#[derive(
|
||||||
scale::Encode,
|
scale::Encode, scale::Decode, scale::DecodeWithMemTracking, frame_support::PalletError,
|
||||||
scale::Decode,
|
|
||||||
scale::DecodeWithMemTracking,
|
|
||||||
scale_info::TypeInfo,
|
|
||||||
frame_support::PalletError,
|
|
||||||
)]
|
)]
|
||||||
pub enum DeallocationError {
|
pub enum DeallocationError {
|
||||||
/// The validator set didn't define an allocation requirement for a key share.
|
/// The validator set didn't define an allocation requirement for a key share.
|
||||||
|
|||||||
Reference in New Issue
Block a user