Inspection extension to node CLI (#4697)

* Initial inspect.

* WiP

* Add parsing tests.

* Finalize CLI.

* Update to latest substrate.

* Remove unused imports.

* Support ImportParams as well, to get the right pruning setting.

* Mention in docs that hash is no 0x.

* Move bytes above extrinsics.

* Switch to fill helper from sc_cli.

* Remove overwrite.

* Fix error.

* Fix error message.

* Remove extra allow.

* init_config
This commit is contained in:
Tomasz Drwięga
2020-02-18 17:56:52 +01:00
committed by GitHub
parent 133a4f967f
commit a14d28150d
11 changed files with 518 additions and 12 deletions
+9
View File
@@ -133,6 +133,15 @@ impl Deref for Bytes {
fn deref(&self) -> &[u8] { &self.0[..] }
}
#[cfg(feature = "std")]
impl sp_std::str::FromStr for Bytes {
type Err = bytes::FromHexError;
fn from_str(s: &str) -> Result<Self, Self::Err> {
bytes::from_hex(s).map(Bytes)
}
}
/// Stores the encoded `RuntimeMetadata` for the native side as opaque type.
#[derive(Encode, Decode, PartialEq)]
pub struct OpaqueMetadata(Vec<u8>);