Skip to content
Snippets Groups Projects
  1. Mar 31, 2020
  2. Mar 30, 2020
    • yanganto's avatar
      Show network id/version in subkey (#5457) · 77b9771b
      yanganto authored
      
      * Show network id/version in subkey
      
      - show network id/version when creating
      - show network id/version when inspecting
      
      * Update bin/utils/subkey/src/main.rs
      
      use `unwrap_or_default` for more clean syntax
      
      Co-Authored-By: default avatarBastian Köcher <bkchr@users.noreply.github.com>
      
      Co-authored-by: default avatarBastian Köcher <bkchr@users.noreply.github.com>
      77b9771b
    • Stanislav Tkach's avatar
    • Max Inden's avatar
      src/service/src/builder: Fix memory metric exposed in bytes not KiB (#5459) · c3c8552a
      Max Inden authored
      The library `sysinfo` exposes process memory as kibibytes and not bytes,
      thus the value needs to be multiplied by 1024 to comply with the metric
      name and the Prometheus base units [1].
      
      [1] https://prometheus.io/docs/practices/naming/#base-units
      c3c8552a
    • Nikolay Volf's avatar
      pub instead of remove (#5451) · d82a2bf4
      Nikolay Volf authored
      d82a2bf4
    • Pierre Krieger's avatar
      Fix tried to send handshake twice (#5413) · dbba4f89
      Pierre Krieger authored
      * Fix tried to send handshake twice
      
      * Fix wrong boolean
      
      * Change to debug
      dbba4f89
    • Rakan Alhneiti's avatar
      Introduce `sign_with` method in keystore (#4925) · e17a23e9
      Rakan Alhneiti authored
      
      * Add KEY_KIND_ID to the public trait
      
      This change is being introduced for the purpose of identifying a public
      key with it's identifier and algorithm "kind".
      
      * Use `sign_with` as implemented in BareCryptoStore
      
      * Implement `sign_with` in sc_keystore
      
      * Fix inconsistencies, use *_KIND_ID in sp_core testing
      
      * Rename KeyKindId to CryptoTypeId
      
      * Remove pair-returning functions from BareCryptoStore trait
      
      * Define CryptoTypeId in app-crypto macros
      
      * Add functions to get keys supported by keystore
      
      * Fix sign_with signature to include CryptoTypePublicPair
      
      * Add `sign_with_any` and `sign_with_all`
      
      * Use keystore.sign_with in auth_discovery
      
      * Rename get_supported_keys -> supported_keys
      
      * Added headers to function docstrings
      
      * Use chain instead of extending a temp vector
      
      * Fixed some code formatting
      
      * Restrict size of CryptoTypeId
      
      This is to be able to use Encode/Decode derives and the overcome having
      the size being unknown at compile-time.
      
      * Implement sign_with in the trait itself
      
      * Remove whitespace
      
      * Use key_type also as a CryptoTypeId in app_crypto macros
      
      * Rename `get_keys` to `keys` in BareCryptoStore
      
      * Remove usage of key_pair funcs in tests
      
      * Adjust docstring for *_CYPTO_ID constants
      
      * Fix failures
      
      * Simplify mapping on keys
      
      * Remove one let
      
      * Fixed typo
      
      * PR feedback
      
      * remove whitespace
      
      * Zip keys and signatures
      
      * Use into_iter & remove cloned
      
      * Pass index to MissingSignature
      
      * Use typed errors instead of strings for BareCryptoStore
      
      * Implement Debug for trait error
      
      * Use hashsets for better performance for supported_keys
      
      * Make sure keys are inserted into the keystore
      
      * Make sign_with_all return type consistent with `sign_with`
      
      * Rename Error to BareCryptoStoreError
      
      * Rename CRYPT_TYPE_ID -> CRYPTO_ID
      
      * Remove unnecessary CRYPTO_ID declaration in Public trait
      
      * Convert pub key to CryptoTypePublicPair
      
      * Fix use
      
      * Fix code style
      
      * Implement From on CryptoTypePublicPair in app_crypto macros
      
      * Change CryptoTypePublicPair to a struct
      
      * Implement Display on CryptoTypePublicPair
      
      * Pass CryptoTypePublicPair to MissingSignature error
      
      * Adjust docs according to function signature
      
      * Unify keys implementation
      
      * Fix RPC author tests
      
      * Fix stackoverflow
      
      * Tabify spaces
      
      * Pass KeyTypeId to error for easier debugging
      
      * Fix asserts
      
      * Use ToHex to format public key
      
      * Use constants from sp_core
      
      * Rename testing KeyTypeId constants
      
      * Please compiler
      
      * Restore KeyTypeId names
      
      apparently, they're not only used in tests
      
      * Use BareCryptoStoreError instead of String
      
      * Document return value
      
      * Fix borrow check
      
      * Convert to hashset internally
      
      * WIP - iter_keys
      
      * Return raw_public_keys
      
      * Address PR feedback
      
      * Address PR Feedback
      
      * Fix hexdisplay import error
      
      * Update primitives/core/src/traits.rs
      
      Co-authored-by: default avatarBastian Köcher <bkchr@users.noreply.github.com>
      e17a23e9
    • Pierre Krieger's avatar
      Make transactions and block announces use notifications substre… (#5360) · 462eaa3f
      Pierre Krieger authored
      * Make transactions and block announces use notifications
      
      * Add documentation
      462eaa3f
    • pscott's avatar
      Build for only one target for docs.rs (#5427) · 408455f8
      pscott authored
      * Add docs.rs metadata to all cargo.toml files
      
      * Remove docs.rs metada in substrate's cargo.toml
      408455f8
  3. Mar 29, 2020
  4. Mar 28, 2020
  5. Mar 27, 2020
  6. Mar 26, 2020
    • gabriel klawitter's avatar
    • Web3 Philosopher's avatar
      Adds state_queryStorageAt (#5362) · ab0f7d21
      Web3 Philosopher authored
      
      * adds state_queryStorageAt
      
      * make at param for query_storage_at optional
      
      * Update client/rpc/src/state/state_full.rs
      
      Co-Authored-By: default avatarTomasz Drwięga <tomusdrw@users.noreply.github.com>
      
      * adds query_storage_at to StateBackend
      
      Co-authored-by: default avatarTomasz Drwięga <tomusdrw@users.noreply.github.com>
      ab0f7d21
    • Kian Paimani's avatar
      Offchain Phragmén BREAKING. (#4517) · 970c5f94
      Kian Paimani authored
      * Initial skeleton for offchain phragmen
      
      * Basic compact encoding decoding for results
      
      * add compact files
      
      * Bring back Self::ensure_storage_upgraded();
      
      * Make staking use compact stuff.
      
      * First seemingly working version of reduce, full of todos
      
      * Everything phragmen related works again.
      
      * Signing made easier, still issues.
      
      * Signing from offchain compile fine :sunglasses:
      
      * make compact work with staked asssignment
      
      * Evaluation basics are in place.
      
      * Move reduce into crate. Document stuff
      
      * move reduce into no_std
      
      * Add files
      
      * Remove other std deps. Runtime compiles
      
      * Seemingly it is al stable; cycle implemented but not integrated.
      
      * Add fuzzing code.
      
      * Cleanup reduce a bit more.
      
      * a metric ton of tests for staking; wip :hammer:
      
      * Implement a lot more of the tests.
      
      * wip getting the unsigned stuff to work
      
      * A bit gleanup for unsigned debug
      
      * Clean and finalize compact code.
      
      * Document reduce.
      
      * Still problems with signing
      
      * We officaly duct taped the transaction submission stuff. :nerd:
      
      * Deadlock with keys again
      
      * Runtime builds
      
      * Unsigned test works :raised_hands:
      
      * Some cleanups
      
      * Make all the tests compile and stuff
      
      * Minor cleanup
      
      * fix more merge stuff
      
      * Most tests work again.
      
      * a very nasty bug in reduce
      
      * Fix all integrations
      
      * Fix more todos
      
      * Revamp everything and everything
      
      * Remove bogus test
      
      * Some review grumbles.
      
      * Some fixes
      
      * Fix doc test
      
      * loop for submission
      
      * Fix cli, keyring etc.
      
      * some cleanup
      
      * Fix staking tests again
      
      * fix per-things; bring patches from benchmarking
      
      * better score prediction
      
      * Add fuzzer, more patches.
      
      * Some fixes
      
      * More docs
      
      * Remove unused generics
      
      * Remove max-nominator footgun
      
      * Better fuzzer
      
      * Disable it :x:
      
      
      
      * Bump.
      
      * Another round of self-review
      
      * Refactor a lot
      
      * More major fixes in perThing
      
      * Add new fuzz file
      
      * Update lock
      
      * fix fuzzing code.
      
      * Fix nominator retain test
      
      * Add slashing check
      
      * Update frame/staking/src/tests.rs
      
      Co-Authored-By: default avatarJoshy Orndorff <JoshOrndorff@users.noreply.github.com>
      
      * Some formatting nits
      
      * Review comments.
      
      * Fix cargo file
      
      * Almost all tests work again
      
      * Update frame/staking/src/tests.rs
      
      Co-Authored-By: default avatarthiolliere <gui.thiolliere@gmail.com>
      
      * Fix review comments
      
      * More review stuff
      
      * Some nits
      
      * Fix new staking / session / babe relation
      
      * Update primitives/phragmen/src/lib.rs
      
      Co-Authored-By: default avatarthiolliere <gui.thiolliere@gmail.com>
      
      * Update primitives/phragmen/src/lib.rs
      
      Co-Authored-By: default avatarthiolliere <gui.thiolliere@gmail.com>
      
      * Update primitives/phragmen/compact/src/lib.rs
      
      Co-Authored-By: default avatarthiolliere <gui.thiolliere@gmail.com>
      
      * Some doc updates to slashing
      
      * Fix derive
      
      * Remove imports
      
      * Remove unimplemented tests
      
      * nits
      
      * Remove dbg
      
      * Better fuzzing params
      
      * Remove unused pref map
      
      * Deferred Slashing/Offence for offchain Phragmen  (#5151)
      
      * Some boilerplate
      
      * Add test
      
      * One more test
      
      * Review comments
      
      * Fix build
      
      * review comments
      
      * fix more
      
      * fix build
      
      * Some cleanups and self-reviews
      
      * More minor self reviews
      
      * Final nits
      
      * Some merge fixes.
      
      * opt comment
      
      * Fix build
      
      * Fix build again.
      
      * Update frame/staking/fuzz/fuzz_targets/submit_solution.rs
      
      Co-Authored-By: default avatarGavin Wood <gavin@parity.io>
      
      * Update frame/staking/src/slashing.rs
      
      Co-Authored-By: default avatarGavin Wood <gavin@parity.io>
      
      * Update frame/staking/src/offchain_election.rs
      
      Co-Authored-By: default avatarGavin Wood <gavin@parity.io>
      
      * Fix review comments
      
      * fix test
      
      * === :key:
      
       Revamp without staking key.
      
      * final round of changes.
      
      * Fix cargo-deny
      
      * Update frame/staking/src/lib.rs
      
      Co-Authored-By: default avatarGavin Wood <gavin@parity.io>
      
      Co-authored-by: default avatarJoshy Orndorff <JoshOrndorff@users.noreply.github.com>
      Co-authored-by: default avatarthiolliere <gui.thiolliere@gmail.com>
      Co-authored-by: default avatarGavin Wood <gavin@parity.io>
      970c5f94
    • Max Inden's avatar
      client/finality-grandpa/src/until_imported: Refactor schedule_wait (#5386) · 2a67e6c4
      Max Inden authored
      
      * client/finality-grandpa/src/until_imported: Refactor schedule_wait
      
      Previously `BlockUntilImported::schedule_wait` took two closures, one to
      report ready items and one to report items to await. None of the implementors of
      `BlockUntilImported` call both closures. From a symantic perspective it
      would as well not make sense to both await something and state that it
      is ready.
      
      Instead with this commit `BlockUntilImported::schedule_wait` simply
      returns whether the given item needs waiting or is ready to be passed
      on.
      
      This reduces complexity by:
      
      - Removing side effects through the two closures.
      
      - Reducing borrowing given that `UntilImported` `ready` and `pending`
      don't need to be borrowed from within the two closures.
      
      - Removes the need for trait bounds for the two closures.
      
      * client/finality-grandpa/src/until_imported: Fix comments
      
      Co-Authored-By: default avatarAndré Silva <andre.beat@gmail.com>
      
      Co-authored-by: default avatarAndré Silva <andre.beat@gmail.com>
      2a67e6c4
    • gabriel klawitter's avatar
    • Pierre Krieger's avatar
      Improve sc-network's documentation for network protocols (#5364) · fdbbf14f
      Pierre Krieger authored
      
      * Improve sc-network's documentation for network protocols
      
      * Add note about protocol id
      
      * Apply suggestions from code review
      
      Co-Authored-By: default avatarMax Inden <mail@max-inden.de>
      
      Co-authored-by: default avatarMax Inden <mail@max-inden.de>
      fdbbf14f
    • Marcio Diaz's avatar
      Benchmark Democracy Pallet (#5257) · 5a48cade
      Marcio Diaz authored
      
      * Add origin bounds to benchmark macro.
      
      * Add democracy benchmark.
      
      * Fix tests
      
      * Remove collective from frame/benchmarking, partially use EnsureOrigin.
      
      * Remove collective stuff.
      
      * Make previous benches compile again.
      
      * Remove comments.
      
      * Make prev bench to work again.
      
      * Add remove votes.
      
      * Add new proxy calls.
      
      * Add runtime-benchmarks guard to EnsureOrigin and implementations.
      
      * Refactor.
      
      * Add missing import.
      
      * Remove duplicated import
      
      * Fix features.
      
      * Add some missing features.
      
      * Update frame/collective/Cargo.toml
      
      Co-Authored-By: default avatarKian Paimani <5588131+kianenigma@users.noreply.github.com>
      
      * Update frame/democracy/src/benchmarking.rs
      
      Co-Authored-By: default avatarKian Paimani <5588131+kianenigma@users.noreply.github.com>
      
      * Update frame/democracy/src/benchmarking.rs
      
      Co-Authored-By: default avatarKian Paimani <5588131+kianenigma@users.noreply.github.com>
      
      * Add referendums to state.
      
      * populate vecs before call
      
      * Update weight docs
      
      * More fixes and weight docs
      
      * More updates
      
      Co-authored-by: default avatarKian Paimani <5588131+kianenigma@users.noreply.github.com>
      Co-authored-by: default avatarShawn Tabrizi <shawntabrizi@gmail.com>
      5a48cade