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
This commit is contained in:
Michael Müller
2019-03-15 15:04:01 +01:00
committed by Bastian Köcher
parent 35a67b31e5
commit c52c528ee8
31 changed files with 139 additions and 45 deletions
+1 -1
View File
@@ -30,7 +30,7 @@ pub use srml_metadata::{
/// A type that can not be instantiated.
pub enum Never {}
/// Result of a module function call; either nothing (functions are only called for "side efeects")
/// Result of a module function call; either nothing (functions are only called for "side effects")
/// or an error message.
pub type Result = result::Result<(), &'static str>;
+1 -1
View File
@@ -121,7 +121,7 @@ pub trait StorageDoubleMap {
fn derive_key2(key2_data: Vec<u8>) -> Vec<u8>;
/// Returns a compound key that consist of the two parts: (prefix, `k1`) and `k2`.
/// The first part is hased and then concatenated with a hash of `k2`.
/// The first part is hashed and then concatenated with a hash of `k2`.
fn full_key<Q, R>(k1: &Q, k2: &R) -> Vec<u8>
where
Self::Key1: Borrow<Q>,
+1 -1
View File
@@ -67,7 +67,7 @@ pub use srml_metadata::{EventMetadata, DecodeDifferent, OuterEventMetadata, FnEn
///
/// mod event2 {
/// // Event that uses the generic parameter `Balance`.
/// // If no name for the generic parameter is speciefied explicitly,
/// // If no name for the generic parameter is specified explicitly,
/// // the name will be taken from the type name of the trait.
/// decl_event!(
/// pub enum Event<T> where <T as super::Trait>::Balance {
+3 -3
View File
@@ -176,7 +176,7 @@ pub trait Currency<AccountId> {
/// they can be individually replaced or removed.
pub type LockIdentifier = [u8; 8];
/// A currency whose accounts can have liquidity restructions.
/// A currency whose accounts can have liquidity restrictions.
pub trait LockableCurrency<AccountId>: Currency<AccountId> {
/// The quantity used to denote time; usually just a `BlockNumber`.
type Moment;
@@ -210,7 +210,7 @@ pub trait LockableCurrency<AccountId>: Currency<AccountId> {
/// Charge bytes fee trait
pub trait ChargeBytesFee<AccountId> {
/// Charge fees from `transactor` for an extrinsic (transaction) of encoded length
/// `encoded_len` bytes. Return Ok iff the payment was successful.
/// `encoded_len` bytes. Return Ok if the payment was successful.
fn charge_base_bytes_fee(transactor: &AccountId, encoded_len: usize) -> Result<(), &'static str>;
}
@@ -222,7 +222,7 @@ pub trait ChargeFee<AccountId>: ChargeBytesFee<AccountId> {
/// Charge `amount` of fees from `transactor`. Return Ok iff the payment was successful.
fn charge_fee(transactor: &AccountId, amount: Self::Amount) -> Result<(), &'static str>;
/// Refund `amount` of previous charged fees from `transactor`. Return Ok iff the refund was successful.
/// Refund `amount` of previous charged fees from `transactor`. Return Ok if the refund was successful.
fn refund_fee(transactor: &AccountId, amount: Self::Amount) -> Result<(), &'static str>;
}