paritytech / paritytech/subxt

Support extracting metadata from runtimes in the CLI tool

Open
#1,934 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
489
Forks
293
Avg merge
18h 35m
Merged PRs (30d)
3

Description

We can already extract metadata from the WAMS file in the macro, ie we can do:

#[subxt::subxt(
    runtime_path = "./some_runtime.wasm",
)]
mod runtime {}

Let's allow this in the CLI too, so subxt metadata will extract from WASM if that is what is provided as a file input.

@AlexD10S would like to be able to programmatically call this sort of function too; we could move the wasm extracting logic to a small subxt/utils crate so that pub fn from_wasm_file(wasm_file_path: &Path) -> WasmMetadataResult<Metadata> is the only thing exposed

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by finding the existing WASM metadata-extraction logic used by the #[subxt::subxt] macro, then trace the subxt metadata CLI entry point and its file-input handling. Done means the CLI extracts metadata when given a WASM file, with the reusable API or subxt/utils crate considered as described in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust, wasm
Domain
cli
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.