1. Dec 10, 2019
  2. Dec 06, 2019
  3. Dec 02, 2019
  4. Dec 01, 2019
  5. Nov 28, 2019
    • Svyatoslav Nikolsky's avatar
      Recover transaction pool on light client (#3833) · 2ffaf054
      Svyatoslav Nikolsky authored
      
      
      * recover tx pool on light client
      
      * revert local tests fix
      
      * removed import renamings
      
      * futures03::Future -> std::future::Future
      
      * Update core/transaction-pool/graph/src/error.rs
      
      Co-Authored-By: default avatarTomasz Drwięga <[email protected]>
      
      * replace remove_from_ready with remove_invalid
      
      * avoid excess hashing
      
      * debug -> warn
      
      * TransactionPool + BasicTransactionPool
      
      * pause future tx reject when resubmitting
      
      * bump impl_version to make CI happy
      
      * and revert back local test fixes
      
      * alter doc to restart CI
      
      * Transaction::clone() -> Transaction::duplicate()
      
      * transactions -> updated_tranasctions
      
      * remove explicit consensus-common ref
      
      * ::std:: -> std::
      
      * manual set/unset flag -> calling clusore with given flag value
      
      * removed comments
      
      * removed force argument
      
      * BestIterator -> Box<Iterator>
      
      * separate crate for TxPool + Maintainer trait
      
      * long line fix
      
      * pos-merge fix
      
      * fix benches compilation
      
      * Rename txpoolapi to txpool_api
      
      * Clean up.
      
      * Finalize merge.
      
      * post-merge fix
      
      * Move transaction pool api to primitives directly.
      
      * Consistent naming for txpool-runtime-api
      
      * Warn about missing docs.
      
      * Move  abstraction for offchain calls to tx-pool-api.
      
      * Merge RPC instantiation.
      
      * Update cargo.lock
      
      * Post merge fixes.
      
      * Avoid depending on client.
      
      * Fix build
      2ffaf054
  6. Nov 27, 2019
    • asynchronous rob's avatar
      safe multi-era slashing for NPoS (#3846) · b853a4f9
      asynchronous rob authored
      
      
      * define slashing spans
      
      * tests and pruning for slashing-spans record
      
      * validators get slashed before nominators
      
      * apply slash to nominators as well
      
      * chill and end slashing spans
      
      * actually perform slashes
      
      * integration (tests failing)
      
      * prune metadata
      
      * fix compilation
      
      * some tests for slashing and metadata garbage collection
      
      * correctly pass session index to slash handler
      
      * test span-max property for nominators and validators
      
      * test that slashes are summed correctly
      
      * reward value computation
      
      * implement rewarding
      
      * add comment about rewards
      
      * do not adjust slash fraction in offences module
      
      * fix offences tests
      
      * remove unused new_offenders field
      
      * update runtime version
      
      * fix up some docs
      
      * fix some CI failures
      
      * remove no-std incompatible vec! invocation
      
      * try to fix span-max rounding error
      
      * Update srml/staking/src/slashing.rs
      
      Fix type: winow -> window
      
      Co-Authored-By: default avatarTomasz Drwięga <[email protected]>
      
      * slashes from prior spans don't kick validator again
      
      * more information for nominators, suppression
      
      * ensure ledger is consistent with itself post-slash
      
      * implement slash out of unlocking funds also
      
      * slashing: create records to be applied after-the-fact
      
      * queue slashes for a few eras later
      
      * method for canceling deferred slashes
      
      * attempt to fix test in CI
      
      * storage migration for `Nominators`
      
      * update node-runtime to use SlashDeferDuration
      
      * adjust migration entry-points somewhat
      
      * fix migration compilation
      
      * add manual Vec import to migration
      
      * enable migrations feature in node-runtime
      
      * bump runtime version
      
      * update to latest master crate renames
      
      * update to use ensure-origin
      
      * Apply suggestions from code review
      
      use `ensure!`
      
      Co-Authored-By: default avatarGavin Wood <[email protected]>
      
      * fix multi-slash removal
      
      * initialize storage version to current in genesis
      
      * add test for version initialization
      b853a4f9
    • thiolliere's avatar
      Implement all storage after prefix (#4227) · a512dcdd
      thiolliere authored
      * Implement all storage after prefix
      
      * fix test, bump version and fix doc
      
      * bump metadata version
      
      * Update frame/support/procedural/src/storage/storage_struct.rs
      a512dcdd
  7. Nov 25, 2019
    • Alexey's avatar
      Refactor `construct_runtime` to procedural (#3810) · 298b6324
      Alexey authored
      
      
      * interim
      
      * interim
      
      * interim
      
      * first working section
      
      * cleanup
      
      * finished parsing
      
      * cleanup
      
      * added system module search
      
      * added clone and find_entry
      
      * generic find_module_entry
      
      * interim
      
      * working event
      
      * added generic event with no instance error
      
      * cleanup
      
      * added decl origin
      
      * cleanup
      
      * added all modules
      
      * added outer dispatch
      
      * added modules expansion
      
      * refactored transformations
      
      * updated error message
      
      * added resolve mechanics
      
      * added metadata
      
      * finished config
      
      * finished inherents
      
      * added validate_unsigned
      
      * added compares
      
      * cleanup
      
      * cleanup
      
      * cleanup
      
      * fix
      
      * updated modules for last one wins
      
      * cleanup
      
      * made nested modules
      
      * updated impl version
      
      * removed comment
      
      * cleanup
      
      * added ui tests
      
      * added optional comma
      
      * removed unnecessary to string cast
      
      * removed no compile
      
      * cleanup
      
      * fmt
      
      * returned nocompile
      
      * Update srml/support/procedural/src/construct_runtime/parse.rs
      
      Co-Authored-By: default avatarthiolliere <[email protected]>
      
      * added where definition
      
      * updated ui tests
      
      * updated ui test cases
      
      * added test case
      
      * updated tests
      
      * interim
      
      * added parse for module part
      
      * removed totokens
      
      * fixes
      
      * fixed multiple iter
      
      * changed TokenStream
      
      * fmt
      
      * updated trybuild
      
      * added test for arguments
      
      * fmt
      
      * fixes + more tests
      
      * fixes
      
      * fmt
      
      * rolled back runtime
      
      * minor fixes
      
      * empty
      
      * fixes
      
      * fmt
      
      * Update paint/support/procedural/src/lib.rs
      
      Co-Authored-By: default avatarBastian Köcher <[email protected]>
      
      * Update paint/support/procedural/src/lib.rs
      
      Co-Authored-By: default avatarBastian Köcher <[email protected]>
      
      * Update paint/support/procedural/src/construct_runtime/parse.rs
      
      Co-Authored-By: default avatarBastian Köcher <[email protected]>
      
      * interim
      
      * refactored seen_keys
      
      * refactored hash_set
      
      * Update paint/support/procedural/src/construct_runtime/mod.rs
      
      Co-Authored-By: default avatarBastian Köcher <[email protected]>
      
      * refactored find
      
      * fix
      
      * fixed all_modules
      
      * added double declaration check
      
      * small fix
      
      * fmt
      
      * fix
      
      * fix default
      
      * format
      298b6324
  8. Nov 22, 2019
    • Sergey Pepyakin's avatar
      Renaming and documentation for ApplyResult, ApplyOutcome and et al (#4134) · d88fff59
      Sergey Pepyakin authored
      
      
      * Remove superflous errors from the system module
      
      * Rename and document InclusionOutcome
      
      * Rename InclusionError
      
      * Remove unused inclusion errors.
      
      I left the enumeration though since other elements might be used some day.
      
      * Rename and document DispatchOutcome
      
      * Apply suggestions from code review
      
      Co-Authored-By: default avatarTomasz Drwięga <[email protected]>
      
      * TransactionValidityError instead of InclusionError
      
      * Rename InclusionOutcome to ApplyExtrinsicResult
      
      * Update docs.
      
      * Update lib.rs
      
      should be → is
      
      * Bump the block builder API version.
      
      * Fix the should_return_runtime_version test
      
      * Clean the evidence
      d88fff59
    • Tomasz Drwięga's avatar
      Offchain execution extensions (#4145) · 06f6daab
      Tomasz Drwięga authored
      * Pass Extensions instead of individual objects.
      
      * Move TransactionPool to a separate ExternalitiesExtension.
      
      * Fix compilation.?
      
      * Clean up.
      
      * Refactor testing utilities.
      
      * Add docs, fix tests.
      
      * Fix doctest.
      
      * Fix formatting and add some logs.
      
      * Add some docs.
      
      * Remove unused files.
      06f6daab
    • Gavin Wood's avatar
      Publish the dispatch info in extrinsic events (#4148) · 371074cb
      Gavin Wood authored
      * Publish the dispatch info in extrinsic events
      
      Place the DispatchInfo (which contains weight information about the
      extrinsic that is otherwise difficult to determine) in the dispatch
      result value.
      
      * Runtime bump.
      
      * Fix build
      
      * Fix tests
      
      * Fix build?
      371074cb
    • Kian Paimani's avatar
      Relocate weight to paint + decouple from extensions (#4124) · f718dd06
      Kian Paimani authored
      
      
      * Fisr migrated version of weight to paint
      
      * Bump
      
      * Minor nits
      
      * Some review fixes.
      
      * Line width
      
      * Revert spec bump
      
      * Fix build
      
      * Update lock file
      
      * Update palette/executive/src/lib.rs
      
      Co-Authored-By: default avatarBastian Köcher <[email protected]>
      
      * Update palette/membership/src/lib.rs
      
      Co-Authored-By: default avatarBastian Köcher <[email protected]>
      f718dd06
  9. Nov 21, 2019
  10. Nov 20, 2019
  11. Nov 14, 2019
    • Benjamin Kampmann's avatar
      Reorganising the repository - external renames and moves (#4074) · f44873dc
      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 interfac...
      f44873dc
    • Max Inden's avatar
      *: Refactor authority discovery (key mngmt, runtime API) (#3955) · 6ae3b6c4
      Max Inden authored
      * {core,srml}/authority-discovery: Move generic to specific session keys
      
      * {srml,core}/authority-discovery: Verify signature outside of runtime
      
      Given that the `core/authority-discovery` uses concrete authority
      identifiers and signatures, one can verify a signature with the
      authority discovery within `core`. Given the above, the `verify` runtime
      api is obsolete and thus removed.
      
      * *: Add authority discovery to the set of session keys
      
      * *: Sign authority discovery DHT payload with keystore instead of runtime
      
      Instead of calling a runtime function to sign a dht payload, which then
      invokes the keystore, pass the keystore to the authority discovery
      module and use it directly.
      
      * core/authority-discovery: Give libp2p Kademlia time to start up
      
      * core/authority-discovery: Move authorities priority group name to const
      
      * node/runtime/src/lib.rs: Bump runtime spec version
      
      * *: Fix lints and node/testing test failures
      
      * *: Fix formatting
      
      * core/authority-discovery: Box dht event channel in unit tests
      
      * node/cli/src/service.rs: Fix future import
      
      * node/cli/src/service.rs: Replace unwrap by expect with proof
      
      * node/cli/src/chain_spec: Remove TODO for testnet key generation
      
      * core/authority-discovery/src/lib: Remove scale encoding TODOs
      
      * srml/authority-discovery: Make comment a doc comment
      
      * core/authority-discovery: Remove unused StreamExt import
      
      * node/runtime: Bump impl version to debug CI
      
      * Test ci.
      
      * Change the line width to 100.
      
      * Revert "Change the line width to 100."
      
      This reverts commit edff1f85.
      
      * Fix a check for polkadot to work on forked repos.
      
      * Revert "node/runtime: Bump impl version to debug CI"
      
      This reverts commit 1a90903b.
      
      * Revert "Test ci."
      
      This reverts commit a2c9df57.
      
      * Cargo.lock: Fix wrong lock file merge
      
      * srml/authority-discovery: Keep track of new validator set not upcoming
      
      * core/authority-discovery: Document key retrieval functions
      6ae3b6c4
  12. Nov 12, 2019
  13. Nov 11, 2019
  14. Nov 10, 2019
    • Bastian Köcher's avatar
      Substrate runtime interface 2.0 (#4057) · a86bb37b
      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
      a86bb37b
  15. Nov 07, 2019
  16. Nov 06, 2019
  17. Nov 05, 2019
  18. Nov 03, 2019
  19. Nov 01, 2019
  20. Oct 31, 2019
  21. Oct 30, 2019
  22. Oct 29, 2019
    • Gavin Wood's avatar
      More robust punishment (#3952) · 2b74b2d4
      Gavin Wood authored
      * Introduce new option "always force new era".
      
      * Take appropriate action, even for small offences.
      
      - Deselect the offender in all circumstances
      - Ensure that deselection forces a new era
      - Ensure that forcing a new era works with the always-forcing.
      
      * Bump runtime
      2b74b2d4
  23. Oct 28, 2019
    • Bastian Köcher's avatar
      Remove footgun around session keys/handlers (#3949) · 43961e85
      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
      43961e85
    • Kian Paimani's avatar
      RPC to query transaction fee + weight + info (#3876) · 4f6f830a
      Kian Paimani authored
      * initial version for testing
      
      * New version that compiles
      
      * optional at block parameter
      
      * Fix some more view grumbles.
      
      * Update srml/transaction-payment/src/lib.rs
      4f6f830a
    • Kian Paimani's avatar
      Updates to elections-phragmen and some runtime docs. (#3940) · 33e56523
      Kian Paimani authored
      * minor changes
      
      * Refactors for phragmen-election
      
      * Bump.
      
      * Fix genesis stuff
      
      * Fix rest of the errors
      33e56523
    • Max Inden's avatar
      *: Disable authority discovery module (#3914) · 5c505d19
      Max Inden authored
      The authority discovery module enables authorities to be discoverable
      and discover other authorities to improve interconnection among them. In
      order to achieve this the module needs to know when the authority set
      changes, thus when a session changes.
      
      One has to register a module as a *session handler* in order for it to
      be notified of changing sessions. The order and number of these *session
      handlers* **MUST** correspond to the order and number of the *session
      keys*.
      
      Commit 7fc21cea added the authority discovery to the `SessionHandlers`.
      Given that the authority discovery module piggybacks on the Babe session
      keys the commit violated the above constraint.
      
      This commit reverts most of 7fc21cea, leaving `core/authority-discovery`
      and `srml/authority-discovery` untouched.
      5c505d19
  24. Oct 27, 2019