merge changes/fixes from v2 back into main (#333)

* update version for antora

* improving zombienet guide (#280)

* update docs version to 2.0.1 (#315)

* Change all references from rococo to paseo (#330)

* remove rococo-native featire from cargo.toml and other doc changes

* use evm compatible accounts, and fix properties for chain spec (#326)

* doc changes

* bump node and docs versions

* impl_runtime_apis need to be in the same file with construct runtime for the moment

* account type fix

* zombienet script update

* slot duration fix

---------

Co-authored-by: Nikita Khateev <nikita.khateev@gmail.com>
Co-authored-by: Özgün Özerk <ozgunozerk.elo@gmail.com>
Co-authored-by: Gustavo Gonzalez <gustavo.gonzalez@openzeppelin.com>

---------
This commit is contained in:
Özgün Özerk
2024-10-24 09:36:38 +03:00
committed by GitHub
parent d074bd97e9
commit 033cf12f34
31 changed files with 767 additions and 801 deletions
+1 -1
View File
@@ -54,7 +54,7 @@ substrate-frame-rpc-system = { workspace = true }
substrate-prometheus-endpoint = { workspace = true }
# Polkadot
polkadot-cli = { workspace = true, features = [ "rococo-native" ] }
polkadot-cli = { workspace = true }
polkadot-primitives = { workspace = true }
xcm = { workspace = true }
+2 -2
View File
@@ -76,7 +76,7 @@ pub fn development_config() -> ChainSpec {
ChainSpec::builder(
generic_runtime_template::WASM_BINARY.expect("WASM binary was not built, please build it!"),
Extensions {
relay_chain: "rococo-local".into(),
relay_chain: "paseo-local".into(),
// You MUST set this to the correct network!
para_id: 1000,
},
@@ -127,7 +127,7 @@ pub fn local_testnet_config() -> ChainSpec {
ChainSpec::builder(
generic_runtime_template::WASM_BINARY.expect("WASM binary was not built, please build it!"),
Extensions {
relay_chain: "rococo-local".into(),
relay_chain: "paseo-local".into(),
// You MUST set this to the correct network!
para_id: 1000,
},
+3 -3
View File
@@ -49,12 +49,12 @@ const AFTER_HELP_EXAMPLE: &str = color_print::cstr!(
r#"<bold><underline>Examples:</></>
<bold>parachain-template-node build-spec --disable-default-bootnode > plain-parachain-chainspec.json</>
Export a chainspec for a local testnet in json format.
<bold>parachain-template-node --chain plain-parachain-chainspec.json --tmp -- --chain rococo-local</>
<bold>parachain-template-node --chain plain-parachain-chainspec.json --tmp -- --chain paseo-local</>
Launch a full node with chain specification loaded from plain-parachain-chainspec.json.
<bold>parachain-template-node</>
Launch a full node with default parachain <italic>local-testnet</> and relay chain <italic>rococo-local</>.
Launch a full node with default parachain <italic>local-testnet</> and relay chain <italic>paseo-local</>.
<bold>parachain-template-node --collator</>
Launch a collator with default parachain <italic>local-testnet</> and relay chain <italic>rococo-local</>.
Launch a collator with default parachain <italic>local-testnet</> and relay chain <italic>paseo-local</>.
"#
);
#[derive(Debug, clap::Parser)]
+1 -1
View File
@@ -21,7 +21,7 @@ use crate::{
fn load_spec(id: &str) -> std::result::Result<Box<dyn ChainSpec>, String> {
Ok(match id {
"dev" => Box::new(chain_spec::development_config()),
"template-rococo" => Box::new(chain_spec::local_testnet_config()),
"template-paseo" => Box::new(chain_spec::local_testnet_config()),
"" | "local" => Box::new(chain_spec::local_testnet_config()),
path => Box::new(chain_spec::ChainSpec::from_json_file(std::path::PathBuf::from(path))?),
})
+2 -2
View File
@@ -48,7 +48,7 @@ use crate::{
constants::{
currency::{deposit, CENTS, EXISTENTIAL_DEPOSIT, GRAND, MICROCENTS},
AVERAGE_ON_INITIALIZE_RATIO, DAYS, HOURS, MAXIMUM_BLOCK_WEIGHT, MAX_BLOCK_LENGTH,
NORMAL_DISPATCH_RATIO, VERSION,
NORMAL_DISPATCH_RATIO, SLOT_DURATION, VERSION,
},
types::{
AccountId, AssetKind, Balance, Beneficiary, Block, BlockNumber,
@@ -512,7 +512,7 @@ impl pallet_aura::Config for Runtime {
type AuthorityId = AuraId;
type DisabledValidators = ();
type MaxAuthorities = MaxAuthorities;
type SlotDuration = pallet_aura::MinimumPeriodTimesTwo<Self>;
type SlotDuration = ConstU64<SLOT_DURATION>;
}
parameter_types! {
+1 -1
View File
@@ -54,7 +54,7 @@ impl WeightToFeePolynomial for WeightToFee {
type Balance = Balance;
fn polynomial() -> WeightToFeeCoefficients<Self::Balance> {
// in Rococo, extrinsic base weight (smallest non-zero weight) is mapped to 1
// in Paseo, extrinsic base weight (smallest non-zero weight) is mapped to 1
// MILLIUNIT: in our template, we map to 1/10 of that, or 1/10 MILLIUNIT
let p = MILLICENTS / P_FACTOR;
let q = Q_FACTOR * Balance::from(ExtrinsicBaseWeight::get().ref_time());
+3 -3
View File
@@ -1,7 +1,7 @@
#!/bin/bash
ZOMBIENET_V=v1.3.106
POLKADOT_V=v1.6.0
POLKADOT_V=stable-2407-01
# Detect the operating system
case "$(uname -s)" in
@@ -92,7 +92,7 @@ zombienet_build() {
zombienet_devnet() {
zombienet_init
cargo build --release
echo "spawning rococo-local relay chain plus devnet as a parachain..."
echo "spawning paseo-local relay chain plus devnet as a parachain..."
local dir=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
./$ZOMBIENET_BIN spawn "$dir/../zombienet-config/devnet.toml" -p native
}
@@ -103,7 +103,7 @@ print_help() {
echo ""
echo "$ ./zombienet.sh init # fetches zombienet and polkadot executables"
echo "$ ./zombienet.sh build # builds polkadot executables from source"
echo "$ ./zombienet.sh devnet # spawns a rococo-local relay chain plus parachain devnet-local as a parachain"
echo "$ ./zombienet.sh devnet # spawns a paseo-local relay chain plus parachain devnet-local as a parachain"
}
SUBCOMMAND=$1
@@ -1,5 +1,5 @@
[relaychain]
chain = "rococo-local"
chain = "paseo-local"
default_command = "./bin-v1.6.0/polkadot"
[[relaychain.nodes]]