Commit Graph

438 Commits

Author SHA1 Message Date
James Wilson 9d5c1d5a24 WIP integrating new frame-decode and working out new storage APIS 2025-09-24 16:38:48 +01:00
dependabot[bot] 98efd20528 build(deps): bump tracing-subscriber from 0.3.19 to 0.3.20 (#2073)
Bumps [tracing-subscriber](https://github.com/tokio-rs/tracing) from 0.3.19 to 0.3.20.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-subscriber-0.3.19...tracing-subscriber-0.3.20)

---
updated-dependencies:
- dependency-name: tracing-subscriber
  dependency-version: 0.3.20
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-09-02 11:32:24 +01:00
James Wilson abcda67fc0 subxt-historic: add support for returning the default values of storage entries (#2072) 2025-09-02 11:32:09 +01:00
James Wilson f565bda011 Prep for 0.44.0 release (#2071) 2025-08-29 12:12:53 +01:00
James Wilson 3aabd6dc09 Add subxt-historic crate for accesing historic (non head-of-chain) blocks (#2040)
* WIP subxt-historic

* WIP subxt-historic

* WIP subxt-historic; flesh out basic foundations

* WIP filling in extrinsic decoding functionality

* iter and decode transaction extensions

* Fill in the Online/OfflineClient APIs and move more things to be part of the chain Config

* WIP storage

* clippy, fmt, finish extrinsics example

* prep for 0.0.1 release to claim crate name

* fix README link

* fmt

* WIP thinking about storage APIs

* WIP working out storage APIs

* Storage plain value fetching first pass

* WIP storage: first pass iterating over values done

* First apss finishing storage APIs

* fmt and clippy

* Create a storage example showing fetch and iteration

* Bump to frame-decode 0.9.0

* Bump subxt-historic to 0.0.3 for preview release

* Remove unused deps

* fix import

* clippy

* doc fixes

* tweak CI and fix some cargo hack findings

* Update README: subxt-historic is prerelease
2025-08-26 17:56:21 +01:00
James Wilson 841a43b1ec Prepare for 0.43.0 release (#2041) 2025-07-18 10:01:33 +01:00
James Wilson ff6fc1585e Add FFI example (#2037)
* Add FFI example

* Remove unnecessary dependency (libc)

* Tweak python example and add CI
CI Tweak; separate task for ffi-example run

* Remove OnceCell dep; use std

---------

Co-authored-by: wassimans <wassim@wassimans.com>
2025-07-08 12:06:13 +01:00
James Wilson 0473cfd292 Prep to release 0.42.1: Reduce rust-version to Rustc 1.85.0 (#2005)
* Reduce rust-version to Rustc 1.85.0

* Bump to 0.42.1 in prep to release patch version
2025-05-12 13:13:21 +01:00
James Wilson 77f83557a5 Actually bump Cargo.toml to 0.42.0 2025-05-12 11:36:58 +01:00
James Wilson 23c62f3d5d Update to 2024 edition (#2001)
* Update to 2024 edition

* Update to 2024 edition; fmt, use<> and remove refs

* async functions
2025-05-09 16:12:18 +01:00
James Wilson 98c1d153b6 Update Smoldot to latest version (#1991)
* Update Smoldot

* Update lockfile

* fix wasm example dependency issue
2025-05-09 15:27:34 +01:00
James Wilson 9ba89e3ed7 Support v16 metadata and use it by default if it's available (#1999)
* Support v16 metadata and use it by default if it's available

* lockfile

* fix blocks test; new transaction extension in kitchensink runtime

* Bump scale-typegen to 0.11.1 to cater for Duration prelude type

* fmt

* Fix no-std test building

* Cargo update and bump substrate deps

* Update test and no-std deps

* fmt

* fix test
2025-05-08 14:44:44 +01:00
James Wilson 4524590821 Metadata V16: Implement support for Pallet View Functions (#1981)
* Support Pallet View Functions in Subxt

* fmt

* clippy

* Move a little view function logic to subxt_core

* clippy

* Add back check that prob isnt needed

* avoid vec macro in core

* Add view funciton test and apply various fixes to get it working

* Add test for dynamic view fn call and fix issues

* clippy

* fix test-runtime

* fmt

* remove export

* avoid vec for nostd core

* use const instead of fn for view fn call name

* Update to support latest unstable metadata

* Update metadata stripping tests for new v16 version
2025-04-24 14:42:07 +01:00
Niklas Adolfsson 175f604ea7 chore(deps): tokio ^1.44.2 (#1989) 2025-04-08 12:03:54 +01:00
James Wilson cdab21e8c3 Use wat instead of wabt to avoid CI cmake error (and use supported dep) (#1980) 2025-04-03 10:22:46 +01:00
James Wilson 72ac18491c Support V16 metadata and refactor metadata code (#1967)
* WIP integrate unstable v16 metadata into Subxt

* first pass moving retain to the CLI tool

* Remove otuer enum variant stripping and move now simpler strip_metadata to new crate. test it

* tidyup to use stripmetadata package etc

* Fix / comment out tests

* fmt

* clippy

* Fix wasm example

* wasm-example fix

* wasm-example fix

* Maske sure to move IDs around after types.retain()

* fmt

* Tweak comment

* Find dispatch error separately to avoid issues during mapping

* Expose associated type information in pallet metadata

* Hopefully fix flaky archive RPC

* remove unwanted temp file

* Address nits

* Add back commented-otu tests and address review comments

* use either, and simplify for_each
2025-03-28 15:35:55 +00:00
James Wilson 4c32ee1e78 Prepare for 0.41.0 release (#1952)
* Prepare for 0.41.0 release

* Example fmt tweak and remove small entry from changes

Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>

---------

Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2025-03-11 15:29:15 +00:00
James Wilson c29edf6fef Bump frame-metadata to 20.0.0 (#1944) 2025-03-06 07:38:31 +01:00
Niklas Adolfsson 69ce6d726f deps: remove polkadot-sdk umbrella crate (#1926)
* deps: get rid of polkadot-sdk umbrella crate

* fix nits

* Update subxt/src/backend/mod.rs

* Update subxt/src/events/events_client.rs

* Update metadata/src/utils/validation.rs

* cargo clippy fix

* fix ui tests
2025-02-24 12:38:21 +01:00
James Wilson 816a86423b Split RPCs into a separate crate (#1910)
* WIP extract RPCs into separate crate

* fmt

* Fix test

* Remove unused deps

* fix import

* WIP: Fix up errors and most tests. Start extracintg some tests/code to rpc crate

* MockRpcClient sync or async

* MockRpcClient only async but better type inference

* WIP MockRpcClient FnMuts and some test updates to use it

* Get all but one test working with new MockRpcClient

* WIP trying to debug failure

* WIP, Tests mostly fixed, need to add back oen more

* Get mock RPC tests working

* fmt

* fmt

* Clippy and comment tweak

* update CI to explicitly check subxt-rpc features

* clippy

* small tweaks after pass over

* feature flag rename

* update some docs

* Fix some examples

* fmt

* Fix features flags to work with web/wasm32

* Fix unused dep warning

* explicit targets in wasm CI

* Add better crate level docs

* fmt

* Address review comments

* Comment out flaky test for now and make more obvious how similar POlkadot and Substrate configs are

* Not a doc comment

* Remove unused imports
2025-02-18 12:07:00 +00:00
James Wilson c96387c47d Prep to release 0.39.0 (#1918)
* Pre pto release 0.39.0

* Actually save updates in Cargo.toml

* Tweak changelog text
2025-02-05 11:00:09 +00:00
James Wilson c71ba59db9 Bump frame-decode and frame-metadata to latest (#1870) 2024-11-25 08:20:24 +01:00
Pavlo Khrystenko 7d1002192e Migrate custom error trait impls to thiserror (#1856)
* Migrate to thiserror

* missing bits

* review comment

* Apply suggestions from code review

Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>

* From<scale_decode::visitor::Error> to remove Into::intos

* scale crates for core::error::Error

* bump msrv 1.81

* make signer crate compile

---------

Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
Co-authored-by: James Wilson <james.wilson@parity.io>
2024-11-18 09:39:14 +00:00
James Wilson 9640ecc751 Prep to release v0.38.0 (#1841)
* Prep to release v0.38.0

* Remove entry from changelog
2024-10-24 15:45:02 +01:00
Niklas Adolfsson dc0795b3b9 move fetch metadata to a separate crate subxt_utils_fetchmetadata (#1829)
* macros: feature-gate jsonrpsee/fetch metadata url

* make CI happy

* Update codegen/src/error.rs

* extract `fetch-metdata` to separate crate

* add missing license headers

* introduce subxt-utils crate

* add missing files

* codegen: remove unused hex crate

* fix test build

* move subxt_utils -> subxt_utils_fetchmetadata

* cargo fmt

* runtime-path -> runtime-metadata-path

* Update utils/fetch-metadata/src/lib.rs
2024-10-24 14:45:39 +01:00
Niklas Adolfsson f358a3864e chore(deps): bump subxt signer deps (#1840) 2024-10-24 12:35:16 +02:00
Niklas Adolfsson 882e9df030 chore(deps): bump frame-decode from 0.4.0 to 0.5.0 (#1839) 2024-10-23 20:16:04 +02:00
Niklas Adolfsson 2f7ea3ff64 chore(deps): bump frame-metadata from 16 to 17 (#1836)
* chore(deps): bump frame-metadata from 16 to 17

* fix substrate test build

* revert test fix

---------

Co-authored-by: James Wilson <james@jsdw.me>
2024-10-23 17:57:06 +02:00
Niklas Adolfsson 03f63ef771 chore(deps): bump futures from 0.3.30 to 0.3.31 (#1837) 2024-10-23 11:07:49 +02:00
Niklas Adolfsson 9b5523e4b0 chore(deps): bump scale family crates, primitive-types and impl-serde (#1832)
* chore(deps): bump scale-encode and scale-decode

* Update Cargo.toml

* Update Cargo.toml

* Update Cargo.toml

* update Cargo.lock

* bump scale-typegen

* use primitive_types::H256

* cargo fmt

* remove old darling hack
2024-10-22 19:23:38 +02:00
Niklas Adolfsson 418bd88e62 chore(deps): replace instant with web-time (#1830)
* chore(deps): replace `instant` with `web-time`

Close https://github.com/paritytech/subxt/issues/1597

* fix build

* fix build v2

* cargo fmt
2024-10-22 15:54:54 +02:00
James Wilson c07c760d85 Update frame-decode to 0.4.0 (#1833) 2024-10-22 13:08:40 +02:00
Niklas Adolfsson 0e86993cd7 deps: use polkadot-sdk umbrella crate (#1786)
* deps: unify usage of polkadot-sdk crates

* cargo fmt

* fix macro crate

* make tests compile

* fix more nits

* fix doc tests

* fix more nits

* more nits

* core: remove polkadot-sdk/std

* cargo fmt

* remove polkadot-sdk/std by default

* Update metadata/Cargo.toml

* remove more std

* Update Cargo.toml
2024-10-11 14:19:11 +02:00
James Wilson b5209a162e Use frame-decode for core extrinsic decode logic (#1785)
* WIP using frame-decode for core extrinsic decode logic

* fmt

* Fix dependabot config

* clippy

* tidy some imports

* Fix a couple of tests

* Update to frame-decode 0.0.7

* fix docs

* Decode exts earlier to avoid doing it every iter/find step

* frame-decode to 0.1.0

* fmt

* clippy

* fix wasm example

* doc test fixes

* Fix test

* Fix a couple of subxt_core tests
2024-10-01 11:21:51 +01:00
Niklas Adolfsson dff16c6194 chore(deps): bump a few dependencies (#1788)
* chore(deps): bump a few dependencies

* signer: make it compile
2024-09-30 15:20:52 +02:00
dependabot[bot] 4d0b0e52ae build(deps): bump regex from 1.10.6 to 1.11.0 (#1791)
Bumps [regex](https://github.com/rust-lang/regex) from 1.10.6 to 1.11.0.
- [Release notes](https://github.com/rust-lang/regex/releases)
- [Changelog](https://github.com/rust-lang/regex/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/regex/compare/1.10.6...1.11.0)

---
updated-dependencies:
- dependency-name: regex
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-30 11:04:29 +02:00
dependabot[bot] 1ade5cf298 build(deps): bump jsonrpsee from 0.24.4 to 0.24.5 (#1792)
Bumps [jsonrpsee](https://github.com/paritytech/jsonrpsee) from 0.24.4 to 0.24.5.
- [Release notes](https://github.com/paritytech/jsonrpsee/releases)
- [Changelog](https://github.com/paritytech/jsonrpsee/blob/master/CHANGELOG.md)
- [Commits](https://github.com/paritytech/jsonrpsee/compare/v0.24.4...v0.24.5)

---
updated-dependencies:
- dependency-name: jsonrpsee
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-30 11:04:08 +02:00
dependabot[bot] 04e1ca31ae build(deps): bump scale-value from 0.16.2 to 0.16.3 (#1793)
Bumps [scale-value](https://github.com/paritytech/scale-value) from 0.16.2 to 0.16.3.
- [Release notes](https://github.com/paritytech/scale-value/releases)
- [Changelog](https://github.com/paritytech/scale-value/blob/main/CHANGELOG.md)
- [Commits](https://github.com/paritytech/scale-value/commits)

---
updated-dependencies:
- dependency-name: scale-value
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-30 11:03:54 +02:00
dependabot[bot] 38cfa4466c build(deps): bump async-trait from 0.1.82 to 0.1.83 (#1794)
Bumps [async-trait](https://github.com/dtolnay/async-trait) from 0.1.82 to 0.1.83.
- [Release notes](https://github.com/dtolnay/async-trait/releases)
- [Commits](https://github.com/dtolnay/async-trait/compare/0.1.82...0.1.83)

---
updated-dependencies:
- dependency-name: async-trait
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-30 11:03:42 +02:00
dependabot[bot] bbea605344 build(deps): bump sc-executor from 0.40.0 to 0.40.1 (#1795)
Bumps [sc-executor](https://github.com/paritytech/polkadot-sdk) from 0.40.0 to 0.40.1.
- [Release notes](https://github.com/paritytech/polkadot-sdk/releases)
- [Changelog](https://github.com/paritytech/polkadot-sdk/blob/master/docs/RELEASE.md)
- [Commits](https://github.com/paritytech/polkadot-sdk/commits)

---
updated-dependencies:
- dependency-name: sc-executor
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-30 11:03:26 +02:00
dependabot[bot] b08ff7b48b build(deps): bump clap from 4.5.17 to 4.5.18 (#1778)
Bumps [clap](https://github.com/clap-rs/clap) from 4.5.17 to 4.5.18.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.17...clap_complete-v4.5.18)

---
updated-dependencies:
- dependency-name: clap
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-09-24 16:46:15 +02:00
drewstone aab1ef8a6c Upgrade sp-core, sp-runtime and sp-keyring (#1777)
* Upgrade sp-core to v34

* Update Cargo.toml

Co-authored-by: James Wilson <james@jsdw.me>

* Fix clippy

---------

Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
Co-authored-by: James Wilson <james@jsdw.me>
2024-09-24 16:27:39 +02:00
dependabot[bot] 916f6c96d5 build(deps): bump thiserror from 1.0.63 to 1.0.64 (#1779)
Bumps [thiserror](https://github.com/dtolnay/thiserror) from 1.0.63 to 1.0.64.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/1.0.63...1.0.64)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-09-24 16:23:48 +02:00
Niklas Adolfsson 9db5a39013 substrate runner: increase line read + dump CLI output if parsing fails (#1781)
* substrate runner: dump CLI output parsing fails

* cargo fmt

* Update testing/substrate-runner/src/lib.rs

* fix grumbles

* disable flaky test

* ignore reconn test too

* ignore more tests

* fix tests

* improve log parsing

* Update testing/integration-tests/src/full_client/client/unstable_rpcs.rs

* Update testing/integration-tests/src/full_client/client/unstable_rpcs.rs

* fix nits

* fix reconn test
2024-09-24 15:33:08 +02:00
dependabot[bot] b25d56f3d1 build(deps): bump jsonrpsee from 0.24.3 to 0.24.4 (#1771)
Bumps [jsonrpsee](https://github.com/paritytech/jsonrpsee) from 0.24.3 to 0.24.4.
- [Release notes](https://github.com/paritytech/jsonrpsee/releases)
- [Changelog](https://github.com/paritytech/jsonrpsee/blob/master/CHANGELOG.md)
- [Commits](https://github.com/paritytech/jsonrpsee/compare/v0.24.3...v0.24.4)

---
updated-dependencies:
- dependency-name: jsonrpsee
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-16 19:14:57 +03:00
dependabot[bot] a49a09159f build(deps): bump async-trait from 0.1.81 to 0.1.82 (#1772)
Bumps [async-trait](https://github.com/dtolnay/async-trait) from 0.1.81 to 0.1.82.
- [Release notes](https://github.com/dtolnay/async-trait/releases)
- [Commits](https://github.com/dtolnay/async-trait/compare/0.1.81...0.1.82)

---
updated-dependencies:
- dependency-name: async-trait
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-16 11:07:09 +03:00
dependabot[bot] 39e715d360 build(deps): bump pretty_assertions from 1.4.0 to 1.4.1 (#1770)
Bumps [pretty_assertions](https://github.com/rust-pretty-assertions/rust-pretty-assertions) from 1.4.0 to 1.4.1.
- [Release notes](https://github.com/rust-pretty-assertions/rust-pretty-assertions/releases)
- [Changelog](https://github.com/rust-pretty-assertions/rust-pretty-assertions/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rust-pretty-assertions/rust-pretty-assertions/compare/v1.4.0...v1.4.1)

---
updated-dependencies:
- dependency-name: pretty_assertions
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-16 11:06:39 +03:00
Pavlo Khrystenko 07d5c9d8e8 update proc_macro_error to proc_macro_error2 (#1767)
closes #1757
2024-09-11 14:46:22 +02:00
dependabot[bot] e37986cc3c build(deps): bump serde from 1.0.209 to 1.0.210 (#1761)
Bumps [serde](https://github.com/serde-rs/serde) from 1.0.209 to 1.0.210.
- [Release notes](https://github.com/serde-rs/serde/releases)
- [Commits](https://github.com/serde-rs/serde/compare/v1.0.209...v1.0.210)

---
updated-dependencies:
- dependency-name: serde
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-09 11:40:00 +03:00
dependabot[bot] aec0a3f125 build(deps): bump clap from 4.5.16 to 4.5.17 (#1760)
Bumps [clap](https://github.com/clap-rs/clap) from 4.5.16 to 4.5.17.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.16...clap_complete-v4.5.17)

---
updated-dependencies:
- dependency-name: clap
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Alexandru Vasile <60601340+lexnv@users.noreply.github.com>
2024-09-09 10:08:16 +02:00