Pierre Krieger
f7bd56d2a8
Handle RPC requests in the substrate-service ( #2866 )
...
* Rework RPC queries
* Remove SyncProvider trait
* Fix RPC tests
2019-06-15 15:44:04 +02:00
Pierre Krieger
68f4d11df3
Move the telemetry information to service ( #2846 )
...
* Move the telemetry information to service
* Proper exit
2019-06-12 21:32:52 +02:00
Bastian Köcher
6142f95611
Fix tons of warnings in newest nightly ( #2784 )
...
* Fix tons of warnings in newest nightly
* Fix sr-api-macro doc tests
2019-06-04 20:09:49 +02:00
Pierre Krieger
5df89a8a6f
Client::info() no longer returns a Result ( #2776 )
2019-06-04 16:09:46 +02:00
Tomasz Drwięga
d4e1bb518d
Bump structopt and fix compilation. ( #2736 )
2019-05-30 17:30:21 +02:00
Michael Müller
a706d994cb
Transaction factory ( #2481 )
...
* Fix typos
* Add transaction factory
`cargo run -- purge-chain -y --chain dev && cargo run -- --dev --transaction-factory 10`
* Fix comment and remove build deps
* Move crate to test-utils
* Switch from flag to subcommand
`cargo run -- factory --dev --num 5`
* Decouple factory from node specifics
* Introduce different manufacturing modes
* Remove unrelated changes
* Update Cargo.lock
* Use SelectChain to fetch best block
* Improve expect proof
* Panic if factory executed with unsupported chain spec
* Link ToDo comments to follow-up ticket
* Address comments and improve style
* Remove unused dependencies
* Fix indent level
* Replace naked unwrap
* Update node/cli/src/factory_impl.rs
* Fix typo
* Use inherent_extrinsics instead of timestamp
* Generalize factory and remove saturated conversions
* Format imports
* Make it clearer that database needs to be empty
* Ensure factory settings
* Apply suggestions from code review
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
* Update test-utils/transaction-factory/src/lib.rs
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
* Fix match guard syntax
* Simplify import, remove empty line
* Update node/cli/Cargo.toml
* Update lockfile
2019-05-28 17:01:43 +02:00
Jordan Beauchamp
1638f6690e
Pass through authority key with --dev ( #2603 )
2019-05-28 16:51:10 +02:00
Benjamin Kampmann
22d3043917
Silence known deprecation warnings ( #2651 )
...
* Silence known deprecation warnings
1. Prefixes known instances of usages of client.backend and client.import_lock with `#[allow(deprecated)]` to silence the warnings. 2. Remove file-global `#![allow(deprecated)]` used in these cases. Both to prevent us overlooking externally caused deprecation messages.
* fixing missing ;
* fix missing test cases
* move deprecated markers to make CI happy
* move deprecated markers to make CI happy
* attempt to fix the test
* bumping impl_version of node runtime
* Minor cleanup
2019-05-28 10:34:59 +02:00
Tomasz Drwięga
c162fc5ff1
Expunge error-chain (feat. tomaka) ( #2662 )
...
* Remove error_chain
* Expunge error-chain from rpc and service.
* Expunge from transaction pool.
* Expunge from node/cli
* Expunge from keystore.
* Remove some boilerplate.
* Fix remaining stuff.
* Improve on deprecation message.
* Fix issues.
* Fix trnsaction pool tests.
* Fix the rest.
* Fix borked merge.
* Update lock
2019-05-24 10:35:31 +01:00
André Silva
563a67b8e4
core: allow setting max ws rpc connections ( #2632 )
...
* core: allow setting max ws rpc connections
* style: break long lines
* core: fix service tests
2019-05-23 10:50:36 +01:00
Pierre Krieger
6431cdf601
Remove TaskExecutor from the API of the informant ( #2642 )
...
* Remove TaskExecutor from the API of the informant
* Fix node-template
2019-05-23 09:44:36 +01:00
Gavin Wood
3860d7c810
Remove As ( #2602 )
...
* Start to remove the `As` bound on `SimpleArtithmetic`
This just introduces standard numeric bounds, assuming a minimum of
`u32`. Also included is a saturating from/into trait allowing ergonomic
infallible conversion when you don't care if it saturates.
* Remove As from Balances trait
* Remove As from Aura module
* Remove As from Babe module
* Expunge `As` from contract
* Council module
* Democracy
* Finality tracker
* Grandpa
* First bit of indices
* indices
* Line lengths
* session
* system
* Staking
* Square up all other uses of As.
* RHD update
* Fix build/test
* Remove As trait
* line widths
* Remove final As ref
* Update srml/staking/src/lib.rs
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
* Update core/client/src/cht.rs
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
* Update core/client/db/src/light.rs
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
* Apply suggestions from code review
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
* whitespace
* Apply suggestions from code review
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
Co-Authored-By: André Silva <andre.beat@gmail.com >
* Bring back u32 check for number on CLI
2019-05-22 23:11:38 +01:00
Pierre Krieger
85ce4623ce
Update to libp2p 0.8 ( #2607 )
...
* Update to libp2p 0.8
* Fix CLI tests
* Zeroize
2019-05-20 15:47:52 +02:00
郭光华
b399ea0b31
Add tty password input ( #2503 )
...
* Add tty password input
* Move password from core/service to core/cli
* Fix test build error
* Password should be entered only once if it's for decoding
* Update Cargo.lock from rebuild
2019-05-15 18:11:59 +02:00
Andrew Jones
e5627e2480
Prevent divide by zero panic with checked_div ( #2575 )
2019-05-14 11:54:56 +02:00
André Silva
9d23d2a25a
Bump master to v2.0.0 ( #2514 )
...
* bump crates to v2.0.0
* fix crate authors
* bump node runtime spec_version
* remove unused import for no-std
2019-05-10 16:55:15 +02:00
Michael Müller
47e3dacc2d
Imply forced authoring on --dev ( #2498 )
...
* Imply forced authoring on --dev
* Combine conditionals
2019-05-09 19:01:57 +02:00
Pierre Krieger
747df1f332
Disable mDNS when passing --dev ( #2467 )
2019-05-04 13:58:06 +02:00
Xiliang Chen
ef142722e3
Pass RunCmd to user ( #2425 )
2019-05-01 20:08:17 +02:00
Michael Müller
a0e0d9b03d
Fix typos and markdown ( #2388 )
...
* Fix typos
* Align properly
* Update core/consensus/slots/src/lib.rs
Co-Authored-By: cmichi <mich@elmueller.net >
* Update core/network/src/test/mod.rs
Co-Authored-By: cmichi <mich@elmueller.net >
* Update core/finality-grandpa/src/communication/mod.rs
Co-Authored-By: cmichi <mich@elmueller.net >
* Update core/consensus/common/src/import_queue.rs
Co-Authored-By: cmichi <mich@elmueller.net >
2019-04-26 14:09:13 +02:00
Tomasz Drwięga
f0202aa425
Unify & enforce same interface of sr-io (std & without-std) ( #2381 )
...
* WiP: HTTP Apis.
* Working on the API.
* Add docs, clean up the API.
* Expose ext_ stuff as well.
* Implement HTTP helpers for offchain sr-io.
* Remove HTTP stuff.
* Remove spurious leading `::`
Co-Authored-By: DemiMarie-parity <48690212+DemiMarie-parity@users.noreply.github.com >
* Rename in toml.
* Add issue number.
* Bump version.
2019-04-25 15:49:34 +02:00
Tomasz Drwięga
93bc03cfe6
Allow localhost IP by default. ( #2380 )
2019-04-25 13:31:50 +02:00
Michael Müller
c6d15e2cea
Configurable state cache size and enforce exact state cache size ( #2314 )
...
* Allow configuring state cache size via cli
* Track used cache size
* Expose memory counter to informant
* Enforce max cache size constraint exactly
* Default to 64 MiB
Co-Authored-By: cmichi <mich@elmueller.net >
* Remove self as parameter
2019-04-23 18:47:11 +01:00
mattrutherford
778bf0256f
Telemetry - change NetworkState from string to json ( #2338 )
...
* change NetworkState from string to json in telemetry
2019-04-22 18:30:01 +01:00
Pierre Krieger
0ae060d4d1
Use ed25519 by default for network keys ( #2290 )
2019-04-17 12:03:00 +02:00
Tomasz Drwięga
a6cbc965a0
Disable CORS when running in --dev ( #2291 )
...
* Disable cors in dev mode,
* Whitelist substrate-ui.
* Fix build.
* Update docs.
2019-04-16 12:57:51 +02:00
Xiliang Chen
72a1c6298e
handle not found error in purge-chain ( #2274 )
2019-04-14 14:57:56 +02:00
Andrew Jones
7f59cdb900
Replace error-chain for client error ( #2231 )
...
* WIP: convert client error
* Remove error_chain for client error
* Ignore tx-pool error deprecation warning
* Update Cargo.lock files
* Fix tests
* Increment impl_version
* Derive From impls, remove allow(missing_docs)
* Remove space
* Remove redundant into()s
* Blockchain Error source
* Bump impl version
2019-04-11 21:33:43 +02:00
Luke Schoen
7e24278634
docs: Fix off-chain worker execution strategy comment ( #2253 )
2019-04-11 09:19:10 +02:00
Tomasz Drwięga
25f56283b1
Enable CORS checks ( #2248 )
...
* Introduce CORS CLI flags.
* Fix test.
2019-04-10 23:47:27 +02:00
Luke Schoen
296d37ac7f
docs: Update Substrate CLI Light option to be experimental ( #2250 )
...
Consistency with Parity Ethereum CLI Light option https://github.com/paritytech/parity-ethereum/blob/master/parity/cli/mod.rs#L263
2019-04-10 21:43:50 +02:00
Gav Wood
eca163ba64
Bump version to 1.0.0 globally ( #2149 )
...
* Bump versionb globally
* Rebuild and fix
* Rename fixes
* Rebuild
* Minor fix and code formatting for validator election
* Fix tests
* More test fixes
* Fix several bugs in phragmen elections.
* Rebuild, remove pointless closures
2019-04-01 15:16:06 +02:00
Pierre Krieger
3dfda381d5
Add support for mDNS ( #2153 )
...
* Use libp2p 0.6.0 instead of a custom branch
* Add support for mDNS
* Fix tests
* Nit
2019-03-31 19:47:15 -04:00
Tomasz Drwięga
823abc2fc0
Use NativeWhenPossible for offchain worker. ( #2126 )
2019-03-27 16:49:53 +01:00
Stefanie Doll
d3ae05b454
Fixed wrong default value for offchain-worker-execution ( #2118 )
2019-03-26 12:14:02 +01:00
Tomasz Drwięga
e2f5e40876
Initial: Offchain Workers ( #1942 )
...
* Refactor state-machine stuff.
* Fix tests.
* WiP
* WiP2
* Service support for offchain workers.
* Service support for offchain workers.
* Testing offchain worker.
* Initial version working.
* Pass side effects in call.
* Pass OffchainExt in context.
* Submit extrinsics to the pool.
* Support inherents.
* Insert to inherents pool.
* Inserting to the pool asynchronously.
* Add test to offchain worker.
* Implement convenience syntax for modules.
* Dispatching offchain worker through executive.
* Fix offchain test.
* Remove offchain worker from timestamp.
* Update Cargo.lock.
* Address review comments.
* Use latest patch version for futures.
* Add CLI parameter for offchain worker.
* Fix compilation.
* Fix test.
* Fix extrinsics format for tests.
* Fix RPC test.
* Bump spec version.
* Fix executive.
* Fix support macro.
* Address grumbles.
* Bump runtime
2019-03-25 23:22:11 +01:00
André Silva
e28ff32b89
core: cli flag to disable grandpa ( #2105 )
...
* core: cli flag to disable grandpa
* core: fix test service configuration
* Update core/service/test/src/lib.rs
2019-03-25 15:19:36 +00:00
Arkadiy Paronyan
c6addc9bd5
CLI option to enable authoring when offline ( #2104 )
...
* CLI option to enable authoring when offline
* Update core/service/src/config.rs
Co-Authored-By: arkpar <arkady.paronyan@gmail.com >
2019-03-25 11:28:35 +01:00
Roman Borschel
57387ef585
libp2p-0.5.0 ( #1971 )
...
* Update libp2p. Add support for ed25519 node (network) keys.
* Update networking to the changes from https://github.com/libp2p/rust-libp2p/pull/972 .
* Add support for using ed25519 keys for libp2p networking.
* Add support for reading libp2p secret keys from (external) files.
* Adapt to changes from https://github.com/libp2p/rust-libp2p/pull/992
* More tests.
* Cosmetics
* Deduplicate tests.
* Remove quickcheck from tests that don't use extra random inputs.
* Remove quickcheck.
* Swap new/default impls for NetworkConfiguration.
* Use libp2p-0.5.0 from crates.io.
* Post-rebase update.
* Remove unnecessary wildcard pattern.
* Combine two overlapping tests.
2019-03-19 11:16:25 +01:00
Bastian Köcher
530c12b4dc
Expose keyring accounts in CLI ( #2032 )
...
* Expose keyring accounts in CLI
So, `--alice` will give you a node with `--key //Alice --name Alice`.
* Update readme
2019-03-18 18:15:18 +01:00
Michael Müller
c52c528ee8
Add grandpa telemetry (+ other minor improvements) ( #1997 )
...
* Support skipping the interactive purge prompt
Skip it via `cargo run -- purge-chain -y`.
* Fix typos
* Add Grandpa telemetry
* Address comments
* Revert unnecessary version bump
* Version bump to make CI run
* Remove unnecessary cast
* Do not bump version
2019-03-15 15:04:01 +01:00
Gav Wood
03d52fdbeb
Crypto fixes/improvements ( #2008 )
...
* Crypto fixes:
- Use schnorrkel's HDKD derive
- Assume all key URIs beginning with `/` are prefixed with public
root phrase.
* Remove commented code.
* Update README
* Update core/primitives/src/ed25519.rs
Co-Authored-By: gavofyork <github@gavwood.com >
2019-03-15 13:53:09 +01:00
Gav Wood
d7fcf5dc9d
Overhaul crypto (Schnorr/Ristretto, HDKD, BIP39) ( #1795 )
...
* Rijig to Ristretto
* Rebuild wasm
* adds compatibility test with the wasm module
* Add Ed25519-BIP39 support
* Bump subkey version
* Update CLI output
* New keys.
* Standard phrase/password/path keys.
* Subkey uses S-URI for secrets
* Move everything to use new HDKD crypto.
* Test fixes
* Ignore old test vector.
* fix the ^^ old test vector.
* Fix tests
* Test fixes
* Cleanups
* Fix broken key conversion logic in grandpa
CC @rphmeier
* Remove legacy Keyring usage
* Traitify `Pair`
* Replace Ed25519AuthorityId with ed25519::Public
* Expunge Ed25519AuthorityId type!
* Replace Sr25519AuthorityId with sr25519::Public
* Remove dodgy crypto type-punning conversions
* Fix some tests
* Avoid trait
* Deduplicate DeriveJunction string decode
* Remove cruft code
* Fix test
* Minor removals
* Build fix
* Subkey supports sign and verify
* Inspect works for public key URIs
* Remove more crypto type-punning
* Fix typo
* Fix tests
2019-03-13 14:08:31 +01:00
Gregory Terzian
90cd8a8479
Add network state to system.interval telemetry ( #1959 )
...
* add network state to system.interval telemetry
* use serde_json
* use unwrap_or_default
2019-03-12 10:17:29 +01:00
Bastian Köcher
7927054f86
Update copyrights to 2019 ( #1932 )
2019-03-06 15:04:28 +01:00
thiolliere
b599556e21
remove unused code ( #1920 )
2019-03-04 17:10:31 +01:00
Michael Müller
c485eb8fdc
Get rid of wildcard imports ( #1916 )
...
* Get rid of wildcard imports
* Update core/service/src/lib.rs
Co-Authored-By: cmichi <mich@elmueller.net >
* Update core/client/src/client.rs
Co-Authored-By: cmichi <mich@elmueller.net >
* Import by namespace
2019-03-04 14:00:46 +01:00
Gregory Terzian
a81f7f48a0
Refactor Sync status updates into a stream of updates ( #1858 )
...
* refactor sync provider
* relative use of interval
* typo
* set propagate timeout to 2500ms
* address comments
* fix instant calc
* update intervals
2019-03-02 14:35:16 +01:00
Michael Müller
90e5c5ddfb
Telemetry improvements ( #1886 )
...
* Fix typo
* Support multiple telemetry endpoints and verbosity levels
* Bump substrate-telemetry version
* Telemetrify Aura consensus
* Telemetrify Grandpa
* Fix CI version conflicts
* Implement style remarks
* Fix fixture
* Implement style remarks
* Clone only when necessary
* Get rid of Arc for URL
* Handle connection issues better
2019-02-28 12:22:05 +01:00
Pierre Krieger
2b71b3e84b
Update to libp2p v0.4 ( #1836 )
2019-02-21 10:04:53 +01:00