Skip to content
This repository has been archived by the owner on Jul 28, 2023. It is now read-only.

Bump to v0.9.10 #103

Merged
merged 24 commits into from
Oct 20, 2021
Merged
Show file tree
Hide file tree
Changes from 22 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3,341 changes: 1,851 additions & 1,490 deletions Cargo.lock

Large diffs are not rendered by default.

5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Use `--sealing` argument to select sealing mode:

Install [polkadot-launch](https://github.com/paritytech/polkadot-launch).

**Note:** you must have polkadot node `v0.9.8` compiled and built placed in `../polkadot/target/release/`.
**Note:** you must have polkadot node `v0.9.10` compiled and built placed in `../polkadot/target/release/`.
To use different localion you can modify `./launch-config.json`.

Build Pontem:
Expand Down Expand Up @@ -105,7 +105,8 @@ Build Polkadot:
```sh
git clone https://github.com/paritytech/polkadot.git
cd polkadot
git checkout v0.9.8
git fetch origin
git checkout release-v0.9.10
cargo build --release
```

Expand Down
2 changes: 1 addition & 1 deletion cargo-toolchain
Original file line number Diff line number Diff line change
@@ -1 +1 @@
nightly-2020-10-05
nightly-2021-06-28
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ services:
dockerfile: launch.Dockerfile
args:
PONTEM_VERSION: v0.4.1
POLKADOT_VERSION: v0.9.8
POLKADOT_VERSION: v0.9.10
NODE_VERSION: 16
ports:
- "9944:9944" # Alice relaychain
Expand Down
99 changes: 50 additions & 49 deletions node/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ path = 'src/main.rs'
targets = ['x86_64-unknown-linux-gnu']

[build-dependencies]
substrate-build-script-utils = { git = 'https://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
substrate-build-script-utils = { git = 'https://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
stdlib-fetch = { path = "../utils/stdlib-fetch" }

[dependencies]
Expand All @@ -32,61 +32,62 @@ log = "0.4"
serde = { version = "1.0", features = ["derive"]}

# Substrate dependencies
frame-benchmarking = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
frame-benchmarking-cli = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
pallet-transaction-payment-rpc = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
substrate-frame-rpc-system = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
substrate-prometheus-endpoint = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
frame-benchmarking = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
frame-benchmarking-cli = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
pallet-transaction-payment-rpc = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
substrate-frame-rpc-system = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
substrate-prometheus-endpoint = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }

# Substarte Client Dependencies
sc-basic-authorship = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-cli = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8', features = ['wasmtime'] }
sc-client-api = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-consensus = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-executor = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8', features = ['wasmtime'] }
sc-finality-grandpa = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-keystore = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-rpc = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-rpc-api = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-service = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8', features = ['wasmtime'] }
sc-telemetry = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-transaction-pool = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-tracing = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-chain-spec = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-network = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-consensus-manual-seal = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sc-basic-authorship = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-cli = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10', features = ['wasmtime'] }
sc-client-api = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-consensus = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-executor = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10', features = ['wasmtime'] }
sc-finality-grandpa = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-keystore = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-rpc = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-rpc-api = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-service = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10', features = ['wasmtime'] }
sc-telemetry = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-transaction-pool = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-tracing = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-chain-spec = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-network = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-transaction-pool-api = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sc-consensus-manual-seal = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }

# Substrate Primitive Dependencies
sp-api = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-block-builder = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-blockchain = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-consensus = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-core = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-finality-grandpa = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-inherents = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-runtime = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-transaction-pool = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-timestamp = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-session = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-offchain = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
sp-keystore = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.8' }
nimbus-primitives = { git = "https://github.com/purestake/cumulus", branch = "joshy-np098" }
sp-api = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-block-builder = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-blockchain = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-consensus = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-core = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-finality-grandpa = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-inherents = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-runtime = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-transaction-pool = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-timestamp = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-session = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-offchain = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
sp-keystore = { git = 'http://github.com/paritytech/substrate.git', branch = 'polkadot-v0.9.10' }
nimbus-primitives = { git = "https://github.com/purestake/cumulus", rev = "5053470650f19ab4f30e37b4a4f3cf292a8e8fe9" }

# Cumulus dependencies
cumulus-client-consensus-relay-chain = { git = "https://github.com/purestake/cumulus", branch = "joshy-np098" }
cumulus-client-consensus-common = { git = "https://github.com/purestake/cumulus", branch = 'joshy-np098' }
cumulus-client-network = { git = 'https://github.com/purestake/cumulus', branch = 'joshy-np098' }
cumulus-client-service = { git = 'https://github.com/purestake/cumulus', branch = 'joshy-np098' }
cumulus-client-cli = { git = 'https://github.com/purestake/cumulus', branch = 'joshy-np098' }
cumulus-primitives-core = { git = 'https://github.com/purestake/cumulus', branch = 'joshy-np098' }
cumulus-primitives-parachain-inherent = { git = 'https://github.com/purestake/cumulus', branch = 'joshy-np098' }
nimbus-consensus = { git = "https://github.com/purestake/cumulus", branch = "joshy-np098" }
cumulus-client-consensus-relay-chain = { git = "https://github.com/purestake/cumulus", rev = "5053470650f19ab4f30e37b4a4f3cf292a8e8fe9" }
cumulus-client-consensus-common = { git = "https://github.com/purestake/cumulus", rev = '5053470650f19ab4f30e37b4a4f3cf292a8e8fe9' }
cumulus-client-network = { git = 'https://github.com/purestake/cumulus', rev = '5053470650f19ab4f30e37b4a4f3cf292a8e8fe9' }
cumulus-client-service = { git = 'https://github.com/purestake/cumulus', rev = '5053470650f19ab4f30e37b4a4f3cf292a8e8fe9' }
cumulus-client-cli = { git = 'https://github.com/purestake/cumulus', rev = '5053470650f19ab4f30e37b4a4f3cf292a8e8fe9' }
cumulus-primitives-core = { git = 'https://github.com/purestake/cumulus', rev = '5053470650f19ab4f30e37b4a4f3cf292a8e8fe9' }
cumulus-primitives-parachain-inherent = { git = 'https://github.com/purestake/cumulus', rev = '5053470650f19ab4f30e37b4a4f3cf292a8e8fe9' }
nimbus-consensus = { git = "https://github.com/purestake/cumulus", rev = "5053470650f19ab4f30e37b4a4f3cf292a8e8fe9" }


# Polkadot dependencies
polkadot-primitives = { git = 'http://github.com/paritytech/polkadot.git', branch = 'release-v0.9.8' }
polkadot-service = { git = 'http://github.com/paritytech/polkadot.git', branch = 'release-v0.9.8' }
polkadot-parachain = { git = 'http://github.com/paritytech/polkadot.git', branch = 'release-v0.9.8' }
polkadot-primitives = { git = 'http://github.com/paritytech/polkadot.git', branch = 'release-v0.9.10' }
polkadot-service = { git = 'http://github.com/paritytech/polkadot.git', branch = 'release-v0.9.10' }
polkadot-parachain = { git = 'http://github.com/paritytech/polkadot.git', branch = 'release-v0.9.10' }

# Local dependencies
pontem-runtime = { path = '../runtime' }
Expand All @@ -101,12 +102,12 @@ sp-mvm-rpc-runtime = { path = '../pallets/sp-mvm/rpc/runtime' }
#
# ** Don't enable relay chains you don't need, as this is a **very** heavy build for no reason**
# More info: https://github.com/paritytech/polkadot/pull/3189
polkadot-cli = { git = 'http://github.com/paritytech/polkadot.git', branch = 'release-v0.9.8', features = ["rococo-native"] }
polkadot-cli = { git = 'http://github.com/paritytech/polkadot.git', branch = 'release-v0.9.10', features = ["rococo-native"] }

[dependencies.move-vm]
package = "mvm"
git = "https://github.com/pontem-network/sp-move-vm.git"
rev = "a6585179256bcb44c5e1db34201c3a5b6c8e3693"
rev = "52ccf19823c9516d448ac6dc360b42dab4ac97d2"
borispovod marked this conversation as resolved.
Show resolved Hide resolved
default-features = false
features = [ "move_stdlib" ]

Expand Down
2 changes: 1 addition & 1 deletion node/src/rpc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ use sp_api::ProvideRuntimeApi;
use sp_blockchain::HeaderBackend;
use sp_block_builder::BlockBuilder;
pub use sc_rpc_api::DenyUnsafe;
use sp_transaction_pool::TransactionPool;
use sc_transaction_pool_api::TransactionPool;
use sp_mvm_rpc_runtime::MVMApiRuntime;
use sp_mvm_rpc::{MVMApiRpc, MVMApi};

Expand Down
21 changes: 13 additions & 8 deletions node/src/service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,8 @@ use sp_keystore::SyncCryptoStorePtr;
use cumulus_client_consensus_common::ParachainConsensus;
use nimbus_primitives::NimbusId;
use nimbus_consensus::{build_nimbus_consensus, BuildNimbusConsensusParams};
use pontem_runtime::primitives::Block;

// Runtime type overrides
type BlockNumber = u32;
type Header = sp_runtime::generic::Header<BlockNumber, sp_runtime::traits::BlakeTwo256>;
pub type Block = sp_runtime::generic::Block<Header, sp_runtime::OpaqueExtrinsic>;
type FullBackend = TFullBackend<Block>;
type FullClient = TFullClient<Block, RuntimeApi, ParachainRuntimeExecutor>;
type MaybeSelectChain = Option<sc_consensus::LongestChain<FullBackend, Block>>;
Expand All @@ -50,7 +47,7 @@ pub fn new_partial(
FullClient,
TFullBackend<Block>,
MaybeSelectChain,
sp_consensus::DefaultImportQueue<Block, FullClient>,
sc_consensus::DefaultImportQueue<Block, FullClient>,
sc_transaction_pool::FullPool<Block, FullClient>,
(Option<Telemetry>, Option<TelemetryWorkerHandle>),
>,
Expand Down Expand Up @@ -168,6 +165,7 @@ async fn start_node_impl(
);

let is_validator = parachain_config.role.is_authority();
let force_authoring = parachain_config.force_authoring;
let prometheus_registry = parachain_config.prometheus_registry().cloned();
let transaction_pool = params.transaction_pool.clone();
let mut task_manager = params.task_manager;
Expand All @@ -180,6 +178,7 @@ async fn start_node_impl(
spawn_handle: task_manager.spawn_handle(),
import_queue: import_queue.clone(),
on_demand: None,
warp_sync: None,
block_announce_validator_builder: Some(Box::new(|_| block_announce_validator)),
})?;

Expand All @@ -194,7 +193,8 @@ async fn start_node_impl(
deny_unsafe,
};

crate::rpc::create_full(deps)
let io = crate::rpc::create_full(deps);
Ok(io)
})
};

Expand Down Expand Up @@ -228,6 +228,7 @@ async fn start_node_impl(
&relay_chain_full_node,
transaction_pool,
params.keystore_container.sync_keystore(),
force_authoring,
)?;
let spawner = task_manager.spawn_handle();
let params = StartCollatorParams {
Expand Down Expand Up @@ -269,6 +270,7 @@ fn build_consensus(
relay_chain_node: &polkadot_service::NewFull<polkadot_service::Client>,
transaction_pool: Arc<sc_transaction_pool::FullPool<Block, FullClient>>,
keystore: SyncCryptoStorePtr,
force_authoring: bool,
) -> Result<Box<dyn ParachainConsensus<Block>>, sc_service::Error> {
let proposer_factory = sc_basic_authorship::ProposerFactory::with_proof_recording(
task_manager.spawn_handle(),
Expand Down Expand Up @@ -313,6 +315,7 @@ fn build_consensus(
relay_chain_backend: relay_chain_node.backend.clone(),
parachain_client: client.clone(),
keystore,
skip_prediction: force_authoring,
create_inherent_data_providers,
}))
}
Expand Down Expand Up @@ -352,6 +355,7 @@ pub fn new_dev(
spawn_handle: task_manager.spawn_handle(),
import_queue,
on_demand: None,
warp_sync: None,
block_announce_validator_builder: None,
})?;

Expand Down Expand Up @@ -415,7 +419,7 @@ pub fn new_dev(
block_import: client.clone(),
env,
client: client.clone(),
pool: transaction_pool.pool().clone(),
pool: transaction_pool.clone(),
commands_stream,
select_chain,
consensus_data_provider: None,
Expand Down Expand Up @@ -456,7 +460,8 @@ pub fn new_dev(
deny_unsafe,
};

crate::rpc::create_full(deps)
let io = crate::rpc::create_full(deps);
Ok(io)
})
};

Expand Down
18 changes: 9 additions & 9 deletions pallets/author-mapping/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,20 +7,20 @@ description = "Maps AuthorIds to AccountIds Useful for associating consensus aut

[dependencies]
log = { version="0.4", default-features=false }
nimbus-primitives = { git="https://github.com/purestake/cumulus", branch="joshy-np098", default-features=false }
frame-support = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.8", default-features=false }
frame-system = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.8", default-features=false }
nimbus-primitives = { git="https://github.com/purestake/cumulus", rev="5053470650f19ab4f30e37b4a4f3cf292a8e8fe9", default-features=false }
frame-support = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.10", default-features=false }
frame-system = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.10", default-features=false }
# TODO: update parity-scale-codec to 2.2.0
parity-scale-codec = { version="2.0.0", default-features=false, features=["derive"] }
serde = { version="1.0.101", optional=true }
sp-std = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.8", default-features=false }
sp-runtime = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.8", default-features=false }
frame-benchmarking = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.8", default-features = false, optional = true }
sp-std = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.10", default-features=false }
sp-runtime = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.10", default-features=false }
frame-benchmarking = { git = "https://github.com/paritytech/substrate", branch = "polkadot-v0.9.10", default-features = false, optional = true }

[dev-dependencies]
sp-io = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.8" }
sp-core = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.8" }
pallet-balances = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.8" }
sp-io = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.10" }
sp-core = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.10" }
pallet-balances = { git="https://github.com/paritytech/substrate", branch="polkadot-v0.9.10" }

[features]
default = ["std"]
Expand Down
Loading