-
Notifications
You must be signed in to change notification settings - Fork 754
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
omni-node: --dev sets manual seal and allows --chain to be set #6646
Changes from 15 commits
9eab6a1
e321830
922285c
c5838ce
61fda5c
8b923a8
3e96f98
dbb1d1e
6f9e5e8
ff46e59
897ea81
f913cec
8813409
f696909
06bbd5e
d6faae7
7210dc9
1833acd
d8395bb
405485a
5d32b16
4729516
81bd3eb
14cbdb4
c8c1bd2
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# Schema: Polkadot SDK PRDoc Schema (prdoc) v1.0.0 | ||
# See doc at https://raw.githubusercontent.com/paritytech/polkadot-sdk/master/prdoc/schema_user.json | ||
|
||
title: OmniNode --dev flag starts node with manual seal | ||
|
||
doc: | ||
- audience: [ Runtime Dev, Node Dev ] | ||
description: | | ||
`polkadot-omni-node` lib supports `--dev` flag now by allowing also to pass over a chain spec, | ||
and starts the node with manual seal. It will seal the node at each `dev_block_time` milliseconds, | ||
which can be set via `--dev-block-time`, and if not set will default to `3000ms`. | ||
|
||
crates: | ||
- name: sc-cli | ||
bump: patch | ||
- name: polkadot-omni-node-lib | ||
bump: patch | ||
- name: polkadot-omni-node | ||
bump: patch |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,10 +33,10 @@ pub struct SharedParams { | |
|
||
/// Specify the development chain. | ||
/// | ||
/// This flag sets `--chain=dev`, `--force-authoring`, `--rpc-cors=all`, | ||
/// `--alice`, and `--tmp` flags, unless explicitly overridden. | ||
/// It also disables local peer discovery (see --no-mdns and --discover-local) | ||
#[arg(long, conflicts_with_all = &["chain"])] | ||
/// This flag sets `--chain=dev`, `--force-authoring`, `--rpc-cors=all`, `--alice`, and `--tmp` | ||
/// flags, unless explicitly overridden. It also disables local peer discovery (see `--no-mdns` | ||
/// and `--discover-local`). | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should we mention manual seal here? (I know it does not enable it for every node, but I think it would be good to have this information in cli). There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Added a note here: d6faae7. |
||
#[arg(long)] | ||
pub dev: bool, | ||
|
||
/// Specify custom base path. | ||
|
@@ -109,12 +109,8 @@ impl SharedParams { | |
pub fn chain_id(&self, is_dev: bool) -> String { | ||
match self.chain { | ||
Some(ref chain) => chain.clone(), | ||
None => | ||
if is_dev { | ||
"dev".into() | ||
} else { | ||
"".into() | ||
}, | ||
None if is_dev => "dev".into(), | ||
_ => "".into(), | ||
} | ||
} | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would be more explicit here about enabling manual sealing and fact that
--dev
enables this.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Used your phrasing here: d6faae7