mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-09 20:11:09 +00:00
Update to latest frame-metadata changes
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
This commit is contained in:
@@ -41,6 +41,7 @@ pub struct Opts {
|
||||
}
|
||||
|
||||
pub async fn run(opts: Opts, output: &mut impl Write) -> color_eyre::Result<()> {
|
||||
println!("opts {:?}", opts);
|
||||
validate_url_security(opts.file_or_url.url.as_ref(), opts.allow_insecure)?;
|
||||
let bytes = opts.file_or_url.fetch().await?;
|
||||
let mut metadata = RuntimeMetadataPrefixed::decode(&mut &bytes[..])?;
|
||||
|
||||
+3
-1
@@ -122,7 +122,9 @@ impl FileOrUrl {
|
||||
// Default if neither is provided; fetch from local url
|
||||
(None, None, version) => {
|
||||
let url = Url::parse("ws://localhost:9944").expect("Valid URL; qed");
|
||||
Ok(fetch_metadata_from_url(url, version.unwrap_or_default()).await?)
|
||||
let version = version.unwrap_or_default();
|
||||
// println!("Fetching metadata from {url} with version {version:?}");
|
||||
Ok(fetch_metadata_from_url(url, version).await?)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user