It changes the way we extended the CLI functionalities of substrate to allow more flexibility. (If this was not clear, here is another version: it changes the `sc_cli` API to allow more flexibility).
This touches a few important things:
- the startup of the async task with tokei:
This was in node and node-template and I moved it to substrate. The idea is to have 1 time the code that handles unix signals (SIGTERM and SIGINT) properly. It is however possible to make this more generic to wait for a future instead and provide only a helper for the basic handling of SIGTERM and SIGINT.
- increased the version of structopt and tokei
- no more use of structopt internal's API
- less use of generics
Related to #4643 and https://github.com/paritytech/cumulus/pull/42: the implementation of "into_configuration" and "get_config" are similar but with better flexibility so it is now possible in cumulus to have the command-line arguments only of the run command for polkadot if we want
Related to https://github.com/paritytech/cumulus/issues/24 and https://github.com/paritytech/cumulus/issues/34 : it will now be possible to make a configuration struct for polkadot with some overrides of the default parameters much more easily.
* instant/manual seal
unbounded queues are evil
Apply suggestions from code review
Co-Authored-By: Robert Habermeier <rphmeier@gmail.com>
add fork tests, docs, remove todos
moar docs
Update client/consensus/manual-seal/src/rpc.rs
Co-Authored-By: Robert Habermeier <rphmeier@gmail.com>
remove unbound generic, parameter, docs, deps, code style changes
Apply suggestions from code review
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
code style chnges
remove unused deps, remove dep renames, check if block is empty before importing, use ? for error propagation
fix tests
log errors for instant seal
use debug
code style changes, updated copyright dates
use txpool::Pool instead of BasicPool, code style changes
fixed tests
* fix tests
* requested changes from review
* check inherents len
* rebase
* Switch GrandPa to new futures
* Work on making tests work
* until_imported tests working again
* Work on switching tests to stable futures
* Modifications
* Re-add test as #[ignore]
* Don't ignore
* Add manual unpins
* Remove Header import
* Return concrete Sink type
* Switch to crates.io finality-grandpa version
* Remove use statement that slipped in
* Fix some nitpicks
* Remove unpin from i
* Fixed typo
* Move futures01 to dev-deps
* Fix nitpicks
* Update client/finality-grandpa/src/communication/mod.rs
Co-Authored-By: André Silva <andre.beat@gmail.com>
* nitpicking
Co-authored-by: Pierre Krieger <pierre.krieger1708@gmail.com>
Co-authored-by: André Silva <andre.beat@gmail.com>
* consensus, pow: intermediate separation and fail
* Fix compiles
* Update primitives/consensus/common/src/block_import.rs
Co-Authored-By: Robert Habermeier <rphmeier@gmail.com>
* Update primitives/consensus/common/src/block_import.rs
Co-Authored-By: Robert Habermeier <rphmeier@gmail.com>
* Document what None means for `fork_choice` in block import params
Co-authored-by: Robert Habermeier <rphmeier@gmail.com>
* Make debug builds more usable
This pr makes debug builds more usable in terms of `cargo run -- --dev`.
1. `--dev` activates `--execution native`, iff `--execution` is not
given or no sub `--execution-*` is given.
2. It was probably a mistake to compile WASM in debug for a debug build.
So, we now build the WASM binary always as `release` (if not requested
differently by the user). So, we trade compilation time for a better
debug experience.
* Make sure we only overwrite default values
* Make it work
* Apply suggestion
* Add `max_members` to `found`, add society genesis for Substrate node
* Update test
* Use `Option<bool>` rather than `Option<()>`
* Update from feedback
* Make Proposer instantiation potentially async.
* fix node-service test
* fix basic-authority doc-test
* only block once on futures in test
* use async/await
* reset a couple of versions down from v0.2.0
* Unstablise browser-utils (very new) and grafana-data-source (going to be replaced with prometheus sometime)
* unmark a bunch more client crates for stabilization
* fix versions in Cargo.tomls
* Downgrade network-test
* Set frame-metadata version to `10.0.0`
* Hide and documented storage generator as internal api
* Downgrade `sp-externalities`
* Downgrade `sc-cli`
* Downgrade sc-executor et al to 0.8.0
* Downgrade sp-state-machine to 0.8.0
* Downgrade pallet-contracts et al to 0.8.0
* Downgrade sp-sandbox to 0.8.0
* downgrade pallet-evm to 0.8.0
* Downgrade pallet-staking to 0.8.0
2.0 should be implementation of lazy payout alongside all the fixes of
current module
* Downgrade node-transaction-factory to 0.8.0
* frame pallets are 2.0.0
Co-authored-by: Ashley <ashley.ruglys@gmail.com>
Co-authored-by: Pierre Krieger <pierre.krieger1708@gmail.com>
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
Co-authored-by: Sergei Pepyakin <s.pepyakin@gmail.com>
Co-authored-by: Wei Tang <accounts@that.world>
Co-authored-by: thiolliere <gui.thiolliere@gmail.com>
Co-authored-by: Marcio Diaz <marcio@parity.io>
* Switch service to futures03
* Fix tests
* Fix service test and cli
* Re-add Executor trait to SpawnTaskHandle
* Fix node-service
* Update babe
* Fix browser node
* Update aura
* Revert back to tokio-executor to fix runtime panic
* Add todo item
* Fix service tests again
* Timeout test futures
* Fix tests
* nits
* Fix service test
* Remove zstd patch
* Re-add futures01 to aura and babe tests as a dev-dep
* Change failing test to tee
* Fix node
* Upgrade tokio
* fix society
* Start switching grandpa to stable futures
* Revert "Start switching grandpa to stable futures"
This reverts commit 9c1976346237637effc07c13f7d0403daf5e71cf.
* Fix utils
* Revert substrate service test
* Revert gitlab
Co-authored-by: thiolliere <gui.thiolliere@gmail.com>
* Extend `Proposer` to optionally generate a proof of the proposal
* Something
* Refactor sr-api to not depend on client anymore
* Fix benches
* Apply suggestions from code review
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* Apply suggestions from code review
* Introduce new `into_storage_changes` function
* Switch to runtime api for `execute_block` and don't require `H256`
anywhere in the code
* Put the `StorageChanges` into the `Proposal`
* Move the runtime api error to its own trait
* Adds `StorageTransactionCache` to the runtime api
This requires that we add `type NodeBlock = ` to the
`impl_runtime_apis!` macro to work around some bugs in rustc :(
* Remove `type NodeBlock` and switch to a "better" hack
* Start using the transaction cache from the runtime api
* Make it compile
* Move `InMemory` to its own file
* Make all tests work again
* Return block, storage_changes and proof from Blockbuilder::bake()
* Make sure that we use/set `storage_changes` when possible
* Add test
* Fix deadlock
* Remove accidentally added folders
* Introduce `RecordProof` as argument type to be more explicit
* Update client/src/client.rs
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* Update primitives/state-machine/src/ext.rs
Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
* Integrates review feedback
* Remove `unsafe` usage
* Update client/block-builder/src/lib.rs
Co-Authored-By: Benjamin Kampmann <ben@gnunicorn.org>
* Update client/src/call_executor.rs
* Bump versions
Co-authored-by: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
Co-authored-by: Benjamin Kampmann <ben.kampmann@googlemail.com>
* Entirely update substrate-telemetry to futures 0.3
* Add a Closed error
* Update to libp2p 0.14
* More work
* More work
* More work
* More work
* Fix warnings
* Remove unwrap()
* Work on tests fixing
* Fix network tests
* Fix external network tests
* Update libp2p and restore Yamux in discovery test
* Ignore DNS if initializatio nfails
* Restore variables ordering
* Forgot browser-utils
* Fix downfall after merge
* Fix tests
Previously one would create a sender and receiver channel pair, pass the
sender to the `build_network_future` through the service builder and
funnel network events returned from polling the network service into the
sender to be consumed by the authority discovery module owning the
receiver.
With recent changes it is now possible to register an `event_stream`
with the network service directly, thus one does not need to make the
detour through the `build_network_future`.
* Fix cli for structopt 0.3.7 and pin to that version
This is just some hotfix to make everything compile. In the future it
will require another pr to not depend on internals of StructOpt, but
that will probably also require some additions to StructOpt itself. To
not break the code again with another StructOpt, this also pins the
StructOpt version.
* Fix benches
* Fix for fix
* clean up cargo.toml syntax
* bumping versions to 2.0
* bump networking to 0.8
* move consensus down to 0.8
* bump consensus pallets to 0.8.0, too
* Upping babe and aura pallets
* add remaining, missing version definitions
* missed some
* client/authority-discovery: Add smoke tests for intervall_at
* client/authority-discovery: Fix interval_at to fire on start
* .maintain/sentry-node: Update docker compose file
* client: Introduce --sentry-nodes flag
Enable operators to specify the public addresses of sentry nodes infront
of a validator node so that the validator node can announce the sentry
node addresses instead of its own public addresses on the DHT via the
authority discovery module.
* client/authority-discovery: Break lines at 100 characters
Limit line length to 100 instead of 120 characters.
* Adding script for rename, could be applicable for nodes on top of it, too
* add stderr and gitlab ci features
* apply script
* fix now minor details in expected stderr
* Update the Cargo.lock
* fix name: sc-transaction -> sc-tracing
* fix rename in script, too