- Jan 10, 2020
-
-
Tomasz Drwięga authored
* Add documentation to signed transactions and actually make them work. * Fix naming and bounds. * Forgotten import. * Remove warning. * Make accounts optional, fix logic. * Split the method to avoid confusing type error message. * Move executor tests to integration. * Add submit transactions tests. * Make `submit_transaction` tests compile * Remove a file that was accidently committed * Add can_sign helper function. * Fix compilation. * Add a key to keystore. * Fix the tests. * Remove env_logger. * Fix sending multiple transactions. * Remove commented code. * Bring back criterion. * Remove stray debug log. * Apply suggestions from code review Co-Authored-By: Bastian Köcher <[email protected]> * Make sure to initialize block correctly. * Initialize block for offchain workers. * Add test for transaction validity. * Fix tests. * Review suggestions. * Remove redundant comment. * Make sure to use correct block number of authoring. * Change the runtime API. * Support both versions. * Bump spec version, fix RPC test. Co-authored-by: Hernando Castano <[email protected]> Co-authored-by: Gavin Wood <[email protected]> Co-authored-by: Bastian Köcher <[email protected]>
-
- Jan 05, 2020
-
-
Shawn Tabrizi authored
-
- Dec 21, 2019
-
-
* Migrate generic-asset, identity and im-online to decl_error * Update democracy tests * Update nicks test
-
- Dec 19, 2019
-
-
Bastian Köcher authored
* Make `decl_error!` errors usable This pr implements support for returning errors of different pallets in a pallet. These errors need to be declared with `decl_error!`. The pr changes the following: - Each dispatchable function now returns a `DispatchResult` which is an alias for `Result<(), DispatchError>`. - `DispatchError` is an enum that has 4 variants: - `Other`: For storing string error messages - `CannotLookup`: Variant that is returned when something returns a `sp_runtime::LookupError` - `BadOrigin`: Variant that is returned for any kind of bad origin - `Module`: The error of a specific module. Contains the `index`, `error` and the `message`. The index is the index of the module in `construct_runtime!`. `error` is the index of the error in the error enum declared by `decl_error!`. `message` is the message to the error variant (this will not be encoded). - `construct_runtime!` now creates a new struct `ModuleToIndex`. This struct implements the trait `ModuleToIndex`. - `frame_system::Trait` has a new associated type: `ModuleToIndex` that expects the `ModuleToIndex` generated by `construct_runtime!`. - All error strings returned in any module are being converted now to `DispatchError`. - `BadOrigin` is the default error returned by any type that implements `EnsureOrigin`. * Fix frame system benchmarks
-
- Dec 16, 2019
-
-
Tomasz Drwięga authored
* Rename: Phase 1. * Unify codec. * Fixing: Phase 2 * Fixing: Phase 3. * Fixing: Phase 4. * Fixing: Phase 5. * Fixing: Phase 6. * Fixing: Phase 7. * Fixing: Phase 8. Tests * Fixing: Phase 9. Tests!!! * Fixing: Phase 10. Moar tests! * Finally done! * More fixes. * Rename primitives:: to sp_core:: * Apply renames in finality-grandpa. * Fix benches. * Fix benches 2. * Revert node-template. * Fix frame-system in our modules.
-
- Dec 10, 2019
-
-
Weiliang Li authored
* primitives/sr-io -> primitives/io * fix * rename * runtime-io -> sp-io * git mv * fix ci * remove package name * fix * fix * try minimizing diff * try minimizing diff again * try minimizing diff again
-
Tomasz Drwięga authored
* Remove warnings when compiling runtime. * Remove dispatch::Result imports. * Add missing imports. * Fix missing vecs. #4333 * Fix oom function. * Remove superfluous import. * More warnings.
-
Weiliang Li authored
* primitives/sr-std -> primitives/std * fix * fix conflict * rstd -> sp-std * git mv * fix review * fix merge
-
- Dec 02, 2019
-
-
Benjamin Kampmann authored
* 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
-
- Nov 27, 2019
-
-
Gavin Wood authored
* Validators don't get slashed for offlineness until 10% at once * Update frame/im-online/src/tests.rs Co-Authored-By: Marcio Diaz <[email protected]> * Update frame/im-online/src/tests.rs Co-Authored-By: Marcio Diaz <[email protected]> * Apply suggestions from code review Co-Authored-By: joe petrowski <[email protected]>
-
- Nov 25, 2019
-
-
Shawn Tabrizi authored
* Remove `frame/` prefix from `im_online` DB_KEY. Caught in the renaming process. It is not obvious to me why `frame/` or `palette/` or `srml/` was included in the DB key. * Update lib.rs
-
- Nov 22, 2019
-
-
Shawn Tabrizi authored
* palette -> frame * PALETTE, Palette -> FRAME * Move folder pallete -> frame * Update docs/Structure.adoc Co-Authored-By: Benjamin Kampmann <[email protected]> * Update docs/README.adoc Co-Authored-By: Benjamin Kampmann <[email protected]> * Update README.adoc
-
- Nov 21, 2019
-
-
joe petrowski authored
* /paint to /palette * rename paint to palette * rename the modules in palette to be pallets * update Structure.adoc * bump impl * fix CI directory * Update docs/Structure.adoc Co-Authored-By: Benjamin Kampmann <[email protected]>
-
- Nov 14, 2019
-
-
Benjamin Kampmann authored
* Adding first rough ouline of the repository structure * Remove old CI stuff * add title * formatting fixes * move node-exits job's script to scripts dir * Move docs into subdir * move to bin * move maintainence scripts, configs and helpers into its own dir * add .local to ignore * move core->client * start up 'test' area * move test client * move test runtime * make test move compile * Add dependencies rule enforcement. * Fix indexing. * Update docs to reflect latest changes * Moving /srml->/paint * update docs * move client/sr-* -> primitives/ * clean old readme * remove old broken code in rhd * update lock * Step 1. * starting to untangle client * Fix after merge. * start splitting out client interfaces * move children and blockchain interfaces * Move trie and state-machine to primitives. * Fix WASM builds. * fixing broken imports * more interface moves * move backend and light to interfaces * move CallExecutor * move cli off client * moving around more interfaces * re-add consensus crates into the mix * fix subkey path * relieve client from executor * starting to pull out client from grandpa * move is_decendent_of out of client * grandpa still depends on client directly * lemme tests pass * rename srml->paint * Make it compile. * rename interfaces->client-api * Move keyring to primitives. * fixup libp2p dep * fix broken use * allow dependency enforcement to fail * move fork-tree * Moving wasm-builder * make env * move build-script-utils * fixup broken crate depdencies and names * fix imports for authority discovery * fix typo * update cargo.lock * fixing imports * Fix paths and add missing crates * re-add missing crates
-
- Nov 10, 2019
-
-
Bastian Köcher authored
* Adds first version of traits for generating the host functions * First steps of the procedural macro * Implements generation of the host extern functions * Prefix ext host function with snake case trait name * Implement host functions implementation on the host * Change `HostFunctions` interface * Implement `HostFunctions` for tuples * Make `WasmExecutor` generic over the host functions * Begin to add a test and make it compile * Make the test succeed * Add test to ensure that host functions are not found * It's alive! Make the `set_storage` test work * Add test for mutable references * Code cleanup and documentation etc * Add marker trait for types that should be passed as SCALE encoded * Inherit the visibility from the trait and more improvements * More impls and move them into their own file * Code simplification by dropping one trait * Give it a better name * Implement traits for arrays * Refactor code to support pass by codec/inner * Docs * Implement pass by inner for some crypto types and add a test * Implement exchangeable function support * Rewrite sr-io with as runtime interface * Start reworking after master merge * Adds `PassByCodec` derive * Adds `PassByInner` derive * Fix compilation errors * More implementations * Implement runtime interface traits for `str` * Make `sr-io` compile again * Fix more compilation errors * More progress on getting stuff back to compile * More compilation fixes * Fix warnings * Remove le conversions * Add support for `wasm_only` interfaces * Implement `Allocator` interface * Improve error message * Move `WasmAllocator` to `sr-io` and more clean ups * Use correct function signature for wasm functions * Store the host functions with the Wasm runtime * Docs update * Fix compilation after master merge * Remove `sr-io/without_std` * Make `srml-support` tests run again * More compilation error fixes * Use correct doc syntax * Fix test-runtime * Fix compilation * Catch native panics when executing the wasm runtime As with the native runtime, we now catch all native panics when we execute the wasm runtime. The panics inside the wasm runtime were already catched before by the wasm executor automatically, but any panic in the host functions could bring down the node. The recent switch to execute the native counterpart of the host function in `sr-io`, makes this change required. The native `sr-io` functions just `panic` when something is not provided or any other error occured. * Fix compilation * Don't panic in a panic * Move `sr-sandbox` to new runtime interface * Fixes tests after sandbox changes * Make sure we detect invalid utf8 * Fixes after master merge * Adds pass by enum strategy * Fix wasmtime integration * Some macro structure clean up * Rework and test exchangebale host functions * PassBy derive macros documentation * Docs for `runtime_interface` macro * Support wild card argument names * Adds ui tests * Make sure that we are backwards compatible to the old runtime interfaces * Documentation * Fixes after latest master merge * Make `wasmtime` happy * Make `full_crypto` work * Make the new interface versionable * Rename `Sanboxing` to `Sandbox` * Don't finalize in test while importing * Fix Performance regression * Fix test
-
- Nov 05, 2019
-
-
Tomasz Drwięga authored
* Limit longevity of im-online heartbeats. * Unused import. * Use parameter for session duration.
-
- Nov 03, 2019
-
-
Tomasz Drwięga authored
* Add pre-dispatch checks for ValidateUnsigned * Deprecate ValidateUnsigned. * Bump specversion. * Fix test.
-
Tomasz Drwięga authored
* Don't send a heartbeat if already online. * Remove env_logger. * Update lock. * Bump runtime. * Merge master
-
- Nov 01, 2019
-
-
Gavin Wood authored
* Add AllGood event for im_online * Another event just in case. * Bump runtime
-
- Oct 31, 2019
-
-
André Silva authored
* im-online: account for block authorship * im-online: add test for block authorship onlineness * im-online: cleanup * im-online: fix test
-
- Oct 30, 2019
-
-
* Make sure im-online reports are high priority. * Bump runtime.
-
- Oct 28, 2019
-
-
Bastian Köcher authored
* Remove footgun around session keys/handlers - `OpaqueKeys` now has an associated type `KeyTypeIdProviders`. This can be used in the runtime as input for `SessionHandler` from the session trait. - `impl_opaque_keys` now works with modules and extracts the `KeyTypeId` from the module directly. - Added some checks to the `session` storage initialization that checks that the `SessionHandler` and `Keys` use the same number of keys and that the order is equal. * Update core/sr-primitives/src/traits.rs
-
- Oct 25, 2019
-
-
Tomasz Drwięga authored
* Bring back SubmitSignedTransaction. * Fix long lines. * Add missing docs. * Update core/primitives/src/crypto.rs Co-Authored-By: Bastian Köcher <[email protected]> * Update node/runtime/src/lib.rs Co-Authored-By: Bastian Köcher <[email protected]> * Update core/primitives/src/crypto.rs Co-Authored-By: Bastian Köcher <[email protected]>
-
- Oct 22, 2019
-
-
Tomasz Drwięga authored
* Implement Printable for tuples. * Add debugging function. * Add debug 1. * Implement for everything. * RuntimeDebug derive. * Introduce RuntimeDebug. * Add some dummy logging. * Replace RuntimeDebug with Debug. * Revert "Replace RuntimeDebug with Debug." This reverts commit bc47070a8cb30241b2b590b2fa29fd195088162f. * Working on Debug for all. * Fix bounds. * Add debug utils. * Implement runtime logging. * Add some docs and clean up. * Clean up derives. * Fix custom derive impl. * Bump runtime. * Fix long lines. * Fix doc test. * Use CARGO_CFG_STD. * Revert "Use CARGO_CFG_STD." This reverts commit ea429566de18ed0fa052571b359eb9826a64a9f4. * Use parse_macro_input * Update lockfile. * Apply review suggestions. * Remove stray re-export. * Add no-std impl. * Update lockfile.
-
asynchronous rob authored
* parse decl_storage getters with fn keyword * test for get in decl_storage * update all decl_storage! getters * bump version * adjust missed doc line
-
- Oct 01, 2019
-
-
thiolliere authored
* impl * patch * lock * some refactor * some avoided copy * new api without ref for doublemap * fix * version bump * fix * point to incoming release * use codec latest * bumpd impl version * fix unused * fix * Update srml/support/src/storage/mod.rs Co-Authored-By: Bastian Köcher <[email protected]>
-
- Sep 30, 2019
-
-
André Silva authored
* srml: im-online: fix pruning of received heartbeats * srml: im-online: add test for received heartbeats pruning * srml: im-online: remove unused variables from test * node: bump spec_version
-
- Sep 25, 2019
-
-
Kian Paimani authored
* Macro-ify perthings. * Refactor fixed64 * Half-workign phragmen refactor. * Finalize phragmen refactor. * Fix creation of perquintill * Fix build errors * Line-width * Fix more build errors. * Line-width * Fix offence test * Resolve all TODOs. * Apply suggestions from code review Co-Authored-By: Gavin Wood <[email protected]> Co-Authored-By: thiolliere <[email protected]> * Fix most of the review comments. * Updates to multiply by rational * Fxi build * Fix abs issue with Fixed64 * Fix tests and improvements. * Fix build * Remove more tests from staking. * Review comments. * Add fuzzing stuff. * Better fuzzing * Better doc. * Bump. * Master.into() * A bit more hardening. * Final nits. * Update lock * Fix indent. * Revert lock file. * Bump.
-
- Sep 24, 2019
-
-
Ashley authored
* decl_storage imports needed traits * bump impl_version * Update srml/system/src/lib.rs Co-Authored-By: Kian Paimani <[email protected]> * Update srml/system/src/lib.rs Co-Authored-By: Kian Paimani <[email protected]>
-
- Sep 13, 2019
-
-
Bastian Köcher authored
* Move trait `Printable` into `sr-primitives` * Cleanup runtime io trie_root interfaces * Remove last generic bits from sr-io interface * Fix srml-sudo after master merge * Fix benchmarks * Runtime bump
-
Tomasz Drwięga authored
* Use session::validators instead of staking::current_elected * Basic test framework. * Initialize validators, attempt to heartbeat. * Use dummy crypto for im-online testing. * Remove printlns. * Finish test, make it invalid. * Add reporting test. * Finalize the test. * Remove dumbness. * Updates. * Update AuRa * Update srml/im-online/src/tests.rs Co-Authored-By: Bastian Köcher <[email protected]> * Derive Ord * Add some more tests. * Remove stray todo. * Bump runtime version. * Bump impl-trait-for-tuples. * Enforce new version of trait-for-tuples.
-
Kian Paimani authored
* Fix locking. * Some reformattings. * Fix build. * Fix doc comment. * Bump.
-
- Sep 06, 2019
-
-
Max Inden authored
With the *authority-discovery* module an authoritative node makes itself discoverable and is able to discover other authorities. Once discovered, a node can directly connect to other authorities instead of multi-hop gossiping information. 1. **Making itself discoverable** 1. Retrieve its external addresses 2. Adds its network peer id to the addresses 3. Sign the above 4. Put the signature and the addresses on the libp2p Kademlia DHT 2. **Discovering other authorities** 1. Retrieve the current set of authorities 2. Start DHT queries for the ids of the authorities 3. Validate the signatures of the retrieved key value pairs 4. Add the retrieved external addresses as ~reserved~ priority nodes to the peerset * node/runtime: Add authority-discovery as session handler The srml/authority-discovery module implements the OneSessionHandler in order to keep its authority set in sync. This commit adds the module to the set of session handlers. * core/network: Make network worker return Dht events on poll Instead of network worker implement the Future trait, have it implement the Stream interface returning Dht events. For now these events are ignored in build_network_future but will be used by the core/authority-discovery module in subsequent commits. * *: Add scaffolding and integration for core/authority-discovery module * core/authority-discovery: Implement module logic itself
-
- Sep 04, 2019
-
-
Bastian Köcher authored
* srml-system checks * wip * more modules compiles * node-runtime checks * build.sh passes * include dispatch error in failed event * revert some unnecessary changes * refactor based on comments * more compile error fixes * avoid unnecessary into * reorder code * fixes some tests * manually implement encode & decode to avoid i8 workaround * more test fixes * more fixes * more error fixes * Apply suggestions from code review Co-Authored-By: Tomasz Drwięga <[email protected]> * address comments * test for DispatchError encoding * tyep alias for democracy * make error printable * line width * fix balances tests * fix executive test * fix system tests * bump version * ensure consistent method signature * Apply suggestions from code review Co-Authored-By: Gavin Wood <[email protected]> * changes based on review * Add issue number for TODOs * fix * line width * fix test * Update core/sr-primitives/src/lib.rs Co-Authored-By: Bastian Köcher <[email protected]> * Update core/sr-primitives/src/traits.rs Co-Authored-By: Bastian Köcher <[email protected]> * Update srml/council/src/motions.rs Co-Authored-By: Bastian Köcher <[email protected]> * Update srml/council/src/motions.rs Co-Authored-By: Bastian Köcher <[email protected]> * update based on review * More concrete macro matching * fix test build issue * Update hex-literal dependency version. (#3141) * Update hex-literal dep version. * Update lock file. * Start to rework the new error handling * More work to get it back compiling * Start to fix after master merge * The great transaction error handling refactoring * Make `decl_error` errors convertible to `&'static str` * Make srml-executive build again * Fix `sr-primitives` tests * More fixes * Last round of fix ups * Fix build * Fix build * Apply suggestions from code review Co-Authored-By: Tomasz Drwięga <[email protected]> * Rename some stuff * Fixes after master merge * Adds `CheckBlockGasLimit` signed extension * Remove debug stuff * Fix srml-balances test * Rename `InvalidIndex` to `CannotLookup` * Remove weird generic parameters * Rename function again * Fix import * Document the signed extension * Change from `Into` to `From` * Update srml/contracts/src/lib.rs Co-Authored-By: Sergei Pepyakin <[email protected]> * Fix compilation * Update srml/contracts/src/lib.rs Co-Authored-By: Tomasz Drwięga <[email protected]> * Update core/sr-primitives/src/transaction_validity.rs Co-Authored-By: Tomasz Drwięga <[email protected]> * Remove unused code * Fix compilation * Some cleanups * Fix compile errors * Make `TransactionValidity` a `Result` * Apply suggestions from code review Co-Authored-By: Gavin Wood <[email protected]> * Beautify the code a little bit and fix test * Make `CannotLookup` an inherent error declared by `decl_error!` * Adds some documentation * Make `ApplyOutcome` a result * Up the spec_version * Apply suggestions from code review Co-Authored-By: Gavin Wood <[email protected]> Co-Authored-By: DemiMarie-parity <[email protected]>
-
Shawn Tabrizi authored
* Fix some instances of `runtime-io` * Patch a bunch * More patches for consistancy * more patch * Fix various build issues * Fix tests * Patch `srml-support-*` crates * Fix doc tests * Revert "Fix doc tests" This reverts commit ba2ec61da7acc36821a70e76a31a6a5bf13bbe95. * Revert "Patch `srml-support-*` crates" This reverts commit 9a6070450107dec17784ba34af4b871023f6dc81. * Missed one * Fix doc tests
-
- Sep 01, 2019
-
-
Tomasz Drwięga authored
* Abstract constructing extrinsic and signing. * Initial impl of signer. * Implement get payload. * Clean up the code. * Improve docs. * Bump version. * Update core/sr-primitives/src/generic/unchecked_extrinsic.rs Co-Authored-By: Bastian Köcher <[email protected]> * Fix tests & address grumbles. * Fix build. * Fix runtime tests. * Fix bound test. * Fix bound test.
-
- Aug 29, 2019
-
-
thiolliere authored
* impl * file split * old comment * better error message * WIP * basti test works * comment * remove old files * impl swap for storage map * fix * fix and comment * code refactor * code refactor * code format * code refactor * fix * fix * fix * document generators * license * doc * doc * fmt Co-Authored-By: Bastian Köcher <[email protected]> * some comment addressed * storage_items small refactor * fix storage_items * more precise returned type * fix * code fmt suggestion Co-Authored-By: Bastian Köcher <[email protected]> * remove box allocation * bump version * rename function as behavior has changed * fix doc
-
thiolliere authored
* simplify module deposit_event declaration * fix * bump version * fix * fix test * fix doc
-
- Aug 28, 2019
-
-
André Silva authored
* im-online: support using ed25519 and sr25519 crypto * app-crypto: add trait bounds to RuntimePublic::Signature * im-online: add missing type annotations * authority-discovery: depend on im-online module and use its crypto * node: set i'm online crypto to sr25519 * node: bump spec_version * rpc: don't generate i'm online pubkey in insert_key method * im-online: fix docs * im-online: move app crypto packages * aura: move app crypto packages
-
- Aug 21, 2019
-
-
thiolliere authored
-