Skip to content

Commit

Permalink
Backport Substrate #13829 and #13941 (#279)
Browse files Browse the repository at this point in the history
* Backport paritytech/substrate#13829 and paritytech/substrate#13941

* Bump node version to v0.1.24-2
  • Loading branch information
jasl authored Apr 24, 2023
1 parent fe996ed commit 3c5032b
Show file tree
Hide file tree
Showing 21 changed files with 8,730 additions and 185 deletions.
367 changes: 183 additions & 184 deletions Cargo.lock

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ exclude = [
"vendor/ring",
"polkadot/node/service",
"cumulus/client/consensus/common",
"substrate/client/network/sync",
]

members = [
Expand Down Expand Up @@ -59,3 +60,7 @@ polkadot-service = { path = "polkadot/node/service" }
# TODO: Remove after upgrade to Polkdaot v0.9.42
[patch."https://github.com/paritytech/cumulus"]
cumulus-client-consensus-common = { path = "cumulus/client/consensus/common" }

# TODO: Remove after upgrade to Polkdaot v0.9.42
[patch."https://github.com/paritytech/substrate"]
sc-network-sync = { path = "substrate/client/network/sync" }
2 changes: 1 addition & 1 deletion node/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "khala-node"
version = "0.1.24-1"
version = "0.1.24-2"
license = "Apache-2.0"
homepage = "https://phala.network/"
repository = "https:/Phala-Network/khala-parachain"
Expand Down
52 changes: 52 additions & 0 deletions substrate/client/network/sync/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
[package]
description = "Substrate sync network protocol"
name = "sc-network-sync"
version = "0.10.0-dev"
license = "GPL-3.0-or-later WITH Classpath-exception-2.0"
authors = ["Parity Technologies <[email protected]>"]
edition = "2021"
homepage = "https://substrate.io"
repository = "https:/paritytech/substrate/"
documentation = "https://docs.rs/sc-network-sync"

[package.metadata.docs.rs]
targets = ["x86_64-unknown-linux-gnu"]

[build-dependencies]
prost-build = "0.11"

[dependencies]
array-bytes = "4.1"
async-trait = "0.1.58"
codec = { package = "parity-scale-codec", version = "3.2.2", features = ["derive"] }
futures = "0.3.21"
futures-timer = "3.0.2"
libp2p = "0.50.0"
log = "0.4.17"
lru = "0.8.1"
mockall = "0.11.3"
prost = "0.11"
smallvec = "1.8.0"
thiserror = "1.0"
fork-tree = { version = "3.0.0", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
prometheus-endpoint = { package = "substrate-prometheus-endpoint", version = "0.10.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sc-client-api = { version = "4.0.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sc-consensus = { version = "0.10.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sc-network = { version = "0.10.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sc-network-common = { version = "0.10.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sc-peerset = { version = "4.0.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sc-utils = { version = "4.0.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sp-arithmetic = { version = "6.0.0", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sp-blockchain = { version = "4.0.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sp-consensus = { version = "0.10.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sp-core = { version = "7.0.0", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sp-consensus-grandpa = { version = "4.0.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sp-runtime = { version = "7.0.0", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }

[dev-dependencies]
tokio = { version = "1.22.0", features = ["macros"] }
quickcheck = { version = "1.0.3", default-features = false }
sc-block-builder = { version = "0.10.0-dev", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sp-test-primitives = { version = "2.0.0", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
sp-tracing = { version = "6.0.0", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
substrate-test-runtime-client = { version = "2.0.0", git = "https:/paritytech/substrate", branch = "polkadot-v0.9.41" }
5 changes: 5 additions & 0 deletions substrate/client/network/sync/build.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
const PROTOS: &[&str] = &["src/schema/api.v1.proto"];

fn main() {
prost_build::compile_protos(PROTOS, &["src/schema"]).unwrap();
}
Loading

0 comments on commit 3c5032b

Please sign in to comment.