Skip to content

Commit

Permalink
Merge pull request #2004 from subspace/devnet-chain-spec
Browse files Browse the repository at this point in the history
Devnet chain spec
  • Loading branch information
nazar-pc authored Sep 25, 2023
2 parents 65a27a3 + 48aa4d4 commit 0b55a60
Show file tree
Hide file tree
Showing 10 changed files with 23 additions and 7 deletions.
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
!/crates
!/domains
!/orml
!/shared
!/test
!/Cargo.lock
!/Cargo.toml
Expand Down
1 change: 1 addition & 0 deletions Dockerfile-bootstrap-node
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ COPY rust-toolchain.toml /code/rust-toolchain.toml
COPY crates /code/crates
COPY domains /code/domains
COPY orml /code/orml
COPY shared /code/shared
COPY test /code/test

# Up until this line all Rust images in this repo should be the same to share the same layers
Expand Down
1 change: 1 addition & 0 deletions Dockerfile-bootstrap-node.aarch64
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ COPY rust-toolchain.toml /code/rust-toolchain.toml
COPY crates /code/crates
COPY domains /code/domains
COPY orml /code/orml
COPY shared /code/shared
COPY test /code/test

# Up until this line all Rust images in this repo should be the same to share the same layers
Expand Down
1 change: 1 addition & 0 deletions Dockerfile-farmer
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ COPY rust-toolchain.toml /code/rust-toolchain.toml
COPY crates /code/crates
COPY domains /code/domains
COPY orml /code/orml
COPY shared /code/shared
COPY test /code/test

# Up until this line all Rust images in this repo should be the same to share the same layers
Expand Down
1 change: 1 addition & 0 deletions Dockerfile-farmer.aarch64
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ COPY rust-toolchain.toml /code/rust-toolchain.toml
COPY crates /code/crates
COPY domains /code/domains
COPY orml /code/orml
COPY shared /code/shared
COPY test /code/test

# Up until this line all Rust images in this repo should be the same to share the same layers
Expand Down
1 change: 1 addition & 0 deletions Dockerfile-node
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ COPY rust-toolchain.toml /code/rust-toolchain.toml
COPY crates /code/crates
COPY domains /code/domains
COPY orml /code/orml
COPY shared /code/shared
COPY test /code/test

# Up until this line all Rust images in this repo should be the same to share the same layers
Expand Down
1 change: 1 addition & 0 deletions Dockerfile-node.aarch64
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ COPY rust-toolchain.toml /code/rust-toolchain.toml
COPY crates /code/crates
COPY domains /code/domains
COPY orml /code/orml
COPY shared /code/shared
COPY test /code/test

# Up until this line all Rust images in this repo should be the same to share the same layers
Expand Down
1 change: 1 addition & 0 deletions Dockerfile-runtime
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ COPY rust-toolchain.toml /code/rust-toolchain.toml
COPY crates /code/crates
COPY domains /code/domains
COPY orml /code/orml
COPY shared /code/shared
COPY test /code/test

# Up until this line all Rust images in this repo should be the same to share the same layers
Expand Down
16 changes: 10 additions & 6 deletions crates/subspace-node/res/chain-spec-raw-devnet.json

Large diffs are not rendered by default.

6 changes: 5 additions & 1 deletion crates/subspace-node/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,10 @@ pub enum Subcommand {
fn parse_timekeeper_cpu_cores(
s: &str,
) -> Result<HashSet<usize>, Box<dyn std::error::Error + Send + Sync>> {
if s.is_empty() {
return Ok(HashSet::new());
}

let mut cpu_cores = HashSet::new();
for s in s.split(',') {
let mut parts = s.split('-');
Expand Down Expand Up @@ -302,7 +306,7 @@ pub struct Cli {
/// * `0,1` - use cores 0 and 1
/// * `0-3` - use cores 0, 1, 2 and 3
/// * `0,1,6-7` - use cores 0, 1, 6 and 7
#[arg(long, value_parser = parse_timekeeper_cpu_cores, verbatim_doc_comment)]
#[arg(long, default_value = "", value_parser = parse_timekeeper_cpu_cores, verbatim_doc_comment)]
pub timekeeper_cpu_cores: HashSet<usize>,

/// External entropy, used initially when PoT chain starts to derive the first seed
Expand Down

0 comments on commit 0b55a60

Please sign in to comment.