Skip to content

Commit

Permalink
Update deps to polkadot-v0.9.19 (#567)
Browse files Browse the repository at this point in the history
* Update deps to polkadot-v0.9.19

* Fix
  • Loading branch information
ark930 authored May 10, 2022
1 parent 0a7a917 commit 9b4bcb0
Show file tree
Hide file tree
Showing 40 changed files with 1,227 additions and 1,182 deletions.
1,335 changes: 668 additions & 667 deletions Cargo.lock

Large diffs are not rendered by default.

24 changes: 12 additions & 12 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -95,15 +95,15 @@ yamux = { opt-level = 3 }
zeroize = { opt-level = 3 }

[patch.crates-io]
zenlink-protocol = { git = "https://github.com/zenlinkpro/Zenlink-DEX-Module", rev = "30486888d4ae2621b87ab025fc16e47aad800f67" }
zenlink-protocol-rpc = { git = "https://github.com/zenlinkpro/Zenlink-DEX-Module", rev = "30486888d4ae2621b87ab025fc16e47aad800f67" }
zenlink-protocol-runtime-api = { git = "https://github.com/zenlinkpro/Zenlink-DEX-Module", rev = "30486888d4ae2621b87ab025fc16e47aad800f67" }
merkle-distributor = { git = "https://github.com/zenlinkpro/merkle-distributor", rev = "72b1b16ae98b33bfaf14489f089302049d167130" }
orml-traits = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "2b5d4ce1d08fb54c0007c2055653892d2c93a92e" }
orml-currencies = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "2b5d4ce1d08fb54c0007c2055653892d2c93a92e" }
orml-tokens = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "2b5d4ce1d08fb54c0007c2055653892d2c93a92e" }
orml-xtokens = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "2b5d4ce1d08fb54c0007c2055653892d2c93a92e" }
orml-unknown-tokens = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "2b5d4ce1d08fb54c0007c2055653892d2c93a92e" }
orml-xcm = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "2b5d4ce1d08fb54c0007c2055653892d2c93a92e" }
orml-xcm-support = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "2b5d4ce1d08fb54c0007c2055653892d2c93a92e" }
parachain-staking = { git = "https://github.com/bifrost-finance/parachain-staking", rev = "5b3a16a456703d1fd18dc931d46f18c602df3cf3" }
zenlink-protocol = { git = "https://github.com/zenlinkpro/Zenlink-DEX-Module", rev = "3003ef14e367c6f69cb6ce7bdfe9327a286160e9" }
zenlink-protocol-rpc = { git = "https://github.com/zenlinkpro/Zenlink-DEX-Module", rev = "3003ef14e367c6f69cb6ce7bdfe9327a286160e9" }
zenlink-protocol-runtime-api = { git = "https://github.com/zenlinkpro/Zenlink-DEX-Module", rev = "3003ef14e367c6f69cb6ce7bdfe9327a286160e9" }
merkle-distributor = { git = "https://github.com/zenlinkpro/merkle-distributor", rev = "cf30bc0d4c01a8afd2a5d979f4ab327c68999584" }
orml-traits = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "238828ac2bafe498a2a071317639e9404d6f6994" }
orml-currencies = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "238828ac2bafe498a2a071317639e9404d6f6994" }
orml-tokens = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "238828ac2bafe498a2a071317639e9404d6f6994" }
orml-xtokens = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "238828ac2bafe498a2a071317639e9404d6f6994" }
orml-unknown-tokens = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "238828ac2bafe498a2a071317639e9404d6f6994" }
orml-xcm = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "238828ac2bafe498a2a071317639e9404d6f6994" }
orml-xcm-support = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "238828ac2bafe498a2a071317639e9404d6f6994" }
parachain-staking = { git = "https://github.com/bifrost-finance/parachain-staking", rev = "a260296833405403c2b532180592c4fcec01ca56" }
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ cd -
```bash
git clone -n https://github.com/paritytech/polkadot.git /tmp/polkadot
cd /tmp/polkadot
git checkout release-v0.9.17
git checkout release-v0.9.19
cargo build --release
cd -
```
Expand Down Expand Up @@ -122,7 +122,7 @@ cd ./output
docker-compose up -d --build
```

## Run full node with docker
## Run full node

### Create `bifrost-fullnode` directory, generate `node-key` and get `bifrost.json`

Expand All @@ -131,7 +131,7 @@ mkdir -p ~/node-key
subkey generate-node-key --file ~/node-key/bifrost.key
```

### Start the node with docker
### Start full node

Replace your-fullnode-name
```sh
Expand Down
132 changes: 66 additions & 66 deletions integration-tests/Cargo.toml

Large diffs are not rendered by default.

34 changes: 17 additions & 17 deletions node/cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,37 +22,37 @@ codec = { package = "parity-scale-codec", version = "3.0.0" }
log = "0.4.16"

# primitives
sp-core = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sp-core = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }

# client dependencies
sc-service = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", optional = true }
sc-telemetry = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sc-tracing = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sc-service = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", optional = true }
sc-telemetry = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sc-tracing = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }

# node-specific dependencies
node-service = { path = "../service", default-features = false }
node-primitives = { path = "../primitives" }

# CLI-specific dependencies
sc-cli = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", optional = true }
try-runtime-cli = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", optional = true }
frame-try-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", optional = true }
frame-benchmarking-cli = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", optional = true }
node-inspect = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", optional = true }
sc-cli = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", optional = true }
try-runtime-cli = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", optional = true }
frame-try-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", optional = true }
frame-benchmarking-cli = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", optional = true }
node-inspect = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", optional = true }

# Cumulus dependencies
cumulus-client-cli = { git = "https://github.com/paritytech/cumulus", branch = "polkadot-v0.9.18" }
cumulus-client-service = { git = "https://github.com/paritytech/cumulus", branch = "polkadot-v0.9.18" }
cumulus-primitives-core = { git = "https://github.com/paritytech/cumulus", branch = "polkadot-v0.9.18" }
cumulus-client-cli = { git = "https://github.com/paritytech/cumulus", branch = "polkadot-v0.9.19" }
cumulus-client-service = { git = "https://github.com/paritytech/cumulus", branch = "polkadot-v0.9.19" }
cumulus-primitives-core = { git = "https://github.com/paritytech/cumulus", branch = "polkadot-v0.9.19" }

# Polkadot dependencies
polkadot-primitives = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.18" }
polkadot-cli = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.18" }
polkadot-parachain = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.18" }
polkadot-primitives = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.19" }
polkadot-cli = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.19" }
polkadot-parachain = { git = "https://github.com/paritytech/polkadot", branch = "release-v0.9.19" }

[build-dependencies]
substrate-build-script-utils = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", optional = true }
substrate-build-script-utils = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", optional = true }

[features]
default = ["wasmtime", "cli"]
Expand Down
5 changes: 3 additions & 2 deletions node/cli/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,9 @@ pub enum Subcommand {
)]
Inspect(node_inspect::cli::InspectCmd),

/// The custom benchmark subcommmand benchmarking runtime pallets.
#[clap(name = "benchmark", about = "Benchmark runtime pallets.")]
/// Sub-commands concerned with benchmarking.
/// The pallet benchmarking moved to the `pallet` sub-command.
#[clap(subcommand)]
Benchmark(frame_benchmarking_cli::BenchmarkCmd),

/// Try some experimental command on the runtime. This includes migration and runtime-upgrade
Expand Down
64 changes: 48 additions & 16 deletions node/cli/src/command.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ use std::{io::Write, net::SocketAddr};
use codec::Encode;
use cumulus_client_service::genesis::generate_genesis_block;
use cumulus_primitives_core::ParaId;
use frame_benchmarking_cli::BenchmarkCmd;
use log::info;
use node_service::{self as service, IdentifyVariant};
use polkadot_parachain::primitives::AccountIdConversion;
Expand Down Expand Up @@ -255,6 +256,10 @@ macro_rules! with_runtime_or_err {
#[cfg(any(feature = "with-bifrost-kusama-runtime",feature = "with-bifrost-runtime"))]
#[allow(unused_imports)]
use service::collator_kusama::new_chain_ops;
#[cfg(any(feature = "with-bifrost-kusama-runtime", feature = "with-bifrost-runtime"))]
#[allow(unused_imports)]
use service::collator_kusama::new_partial;

#[cfg(any(feature = "with-bifrost-kusama-runtime",feature = "with-bifrost-runtime"))]
$( $code )*

Expand All @@ -273,6 +278,9 @@ macro_rules! with_runtime_or_err {
#[cfg(any(feature = "with-bifrost-polkadot-runtime", feature = "with-bifrost-runtime"))]
#[allow(unused_imports)]
use service::collator_polkadot::new_chain_ops;
#[cfg(any(feature = "with-bifrost-polkadot-runtime", feature = "with-bifrost-runtime"))]
#[allow(unused_imports)]
use service::collator_polkadot::new_partial;

#[cfg(any(feature = "with-bifrost-polkadot-runtime", feature = "with-bifrost-runtime"))]
$( $code )*
Expand Down Expand Up @@ -323,7 +331,7 @@ pub fn run() -> Result<()> {
let id = ParaId::from(para_id);

let parachain_account =
AccountIdConversion::<polkadot_primitives::v0::AccountId>::into_account(&id);
AccountIdConversion::<polkadot_primitives::v2::AccountId>::into_account(&id);

let state_version =
RelayChainCli::native_runtime_version(&config.chain_spec).state_version();
Expand Down Expand Up @@ -364,20 +372,44 @@ pub fn run() -> Result<()> {
return runner.sync_run(|config| cmd.run::<Block, RuntimeApi, Executor>(config));
})
},
Some(Subcommand::Benchmark(cmd)) =>
if cfg!(feature = "runtime-benchmarks") {
let runner = cli.create_runner(cmd)?;
let chain_spec = &runner.config().chain_spec;
set_default_ss58_version(chain_spec);

with_runtime_or_err!(chain_spec, {
return runner.sync_run(|config| cmd.run::<Block, Executor>(config));
})
} else {
Err("Benchmarking wasn't enabled when building the node. \
You can enable it with `--features runtime-benchmarks`."
.into())
},
Some(Subcommand::Benchmark(cmd)) => {
let runner = cli.create_runner(cmd)?;
let chain_spec = &runner.config().chain_spec;
set_default_ss58_version(chain_spec);

// Switch on the concrete benchmark sub-command-
match cmd {
BenchmarkCmd::Pallet(cmd) =>
if cfg!(feature = "runtime-benchmarks") {
with_runtime_or_err!(chain_spec, {
return runner.sync_run(|config| cmd.run::<Block, Executor>(config));
})
} else {
Err("Benchmarking wasn't enabled when building the node. \
You can enable it with `--features runtime-benchmarks`."
.into())
},
BenchmarkCmd::Block(cmd) => runner.sync_run(|config| {
with_runtime_or_err!(config.chain_spec, {
{
let partials = new_partial::<RuntimeApi>(&config, false)?;
cmd.run(partials.client)
}
})
}),
BenchmarkCmd::Storage(cmd) => runner.sync_run(|config| {
with_runtime_or_err!(config.chain_spec, {
{
let partials = new_partial::<RuntimeApi>(&config, false)?;
let db = partials.backend.expose_db();
let storage = partials.backend.expose_storage();
cmd.run(config, partials.client.clone(), db, storage)
}
})
}),
BenchmarkCmd::Overhead(_) => Err("Unsupported benchmarking command".into()),
}
},
Some(Subcommand::Key(cmd)) => cmd.run(&cli),
Some(Subcommand::Sign(cmd)) => cmd.run(),
Some(Subcommand::Verify(cmd)) => cmd.run(),
Expand Down Expand Up @@ -467,7 +499,7 @@ pub fn run() -> Result<()> {
with_runtime_or_err!(chain_spec, {
return runner.async_run(|mut config| {
let (client, backend, _, task_manager) = new_chain_ops(&mut config)?;
Ok((cmd.run(client, backend), task_manager))
Ok((cmd.run(client, backend, None), task_manager))
});
})
},
Expand Down
14 changes: 7 additions & 7 deletions node/inspect/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ edition = "2021"
[dependencies]
codec = { package = "parity-scale-codec", version = "3.0.0" }
derive_more = "0.99"
sc-cli = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sc-client-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sc-executor = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sc-service = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", default-features = false }
sp-blockchain = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sp-core = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sc-cli = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sc-client-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sc-executor = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sc-service = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", default-features = false }
sp-blockchain = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sp-core = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
structopt = "0.3.8"
10 changes: 5 additions & 5 deletions node/primitives/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ bstringify = "0.1.2"
codec = { package = "parity-scale-codec", version = "3.0.0", default-features = false, features = ["derive"] }
scale-info = { version = "2.1.1", default-features = false, features = ["derive"] }
serde = { version = "1.0.123", optional = true, features = ["derive"] }
frame-system = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", default-features = false }
frame-support = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", default-features = false }
sp-core = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", default-features = false }
sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", default-features = false }
sp-std = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18", default-features = false }
frame-system = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", default-features = false }
frame-support = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", default-features = false }
sp-core = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", default-features = false }
sp-runtime = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", default-features = false }
sp-std = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19", default-features = false }
zenlink-protocol = { version = "*", default-features = false }

[features]
Expand Down
18 changes: 9 additions & 9 deletions node/rpc/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ targets = ["x86_64-unknown-linux-gnu"]
[dependencies]
jsonrpc-core = "18.0.0"
node-primitives = { path = "../primitives" }
sc-client-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sc-rpc-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sc-rpc = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sc-transaction-pool-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sp-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sp-block-builder = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sp-blockchain = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
pallet-transaction-payment-rpc = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
substrate-frame-rpc-system = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.18" }
sc-client-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sc-rpc-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sc-rpc = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sc-transaction-pool-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sp-api = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sp-block-builder = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
sp-blockchain = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
pallet-transaction-payment-rpc = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
substrate-frame-rpc-system = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.19" }
bifrost-flexible-fee-rpc = { path = "../../pallets/flexible-fee/rpc" }
bifrost-flexible-fee-rpc-runtime-api = { path = "../../pallets/flexible-fee/rpc/runtime-api" }
bifrost-salp-rpc-api = { path = "../../pallets/salp/rpc" }
Expand Down
Loading

0 comments on commit 9b4bcb0

Please sign in to comment.