Commit Graph

136 Commits

Author SHA1 Message Date
Niklas Adolfsson bcdf0bb054 light client tests: use ChainheadBackendBuilder::build_with_background_driver (#1823)
* backend rpc tests: use background task

* fix build
2024-10-14 12:02:12 +02:00
paritytech-subxt-pr-maker[bot] 77a36773ae Update Artifacts (auto-generated) (#1826)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
2024-10-14 09:15:18 +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
paritytech-subxt-pr-maker[bot] fefb324b24 Update Artifacts (auto-generated) (#1815)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
2024-10-07 11:40:08 +03:00
Niklas Adolfsson 8f3c0b44fb stabilize reconnecting-rpc-client (#1803)
* stabilize reconnecting-rpc-client

* fix build

* remove missed unstable stuff
2024-10-03 20:03:16 +02:00
Niklas Adolfsson 3807b29f36 rpc: stabilize chainhead backend (#1802)
* rpc: stabilize ChainHeadBackend

* remove noise from example

* add missing features

* make tests compile

* make tests compile v2

* revert stop event

* feature-gate runtime

* Update subxt/Cargo.toml

* add docsrs feature stuff

* Update subxt/src/backend/chain_head/mod.rs

* Update subxt/src/backend/chain_head/mod.rs

* Update subxt/src/backend/chain_head/mod.rs
2024-10-03 18:14:38 +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
paritytech-subxt-pr-maker[bot] 7dff932382 Update Artifacts (auto-generated) (#1790)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
2024-09-30 12:47:57 +03: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
Pavlo Khrystenko 52252242b0 fix flaky test with temporary solution (#1768)
* fix flaky test with temporary solution

* clippy
2024-09-11 17:34:11 +02:00
Alexandru Vasile 1cf206f671 chore(deps): Update smoldot to the latest version (#1400)
* Update smoldot to 0.17 and smoldot-light to 0.15

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Update cargo lock

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Add generic platform for AddedChain

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* debug: Finalized heads

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Use generic TPlat for chainSuccess

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Trim response for logs

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Backup

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests/lightclient: Switch to localnode for testing

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* cargo: Point smoldot to crates.io

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Solve merge conflicts

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Add subxt macro for tests

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient/wasm: Impl log of the PlatformRef

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Use git dep

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Revert "tests/lightclient: Switch to localnode for testing" + max log
size

This reverts commit 74dd9d7cff.

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Comment chainspec

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient/wasm: Import IpAddr from core::net

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Enable all tests again

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests/wasm: Update cargo lock

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Add trace logs to easily reproduce problems

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* cargo: Use released smoldot version

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Use chainspec and optionally make use of unstable backend

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Fix clippy

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Better trimming for log messages

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Remove max log size

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Use both backends for testing

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Update Cargo.toml

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

* Update Cargo.toml

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

* Update testing/integration-tests/src/light_client/mod.rs

* Update testing/integration-tests/src/light_client/mod.rs

---------

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-09-09 10:30:51 +03:00
paritytech-subxt-pr-maker[bot] 398d2a8605 Update Artifacts (auto-generated) (#1744)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-09-03 10:26:34 +01:00
Niklas Adolfsson e4f6f08eb7 fix: nits in tests (#1750)
* fix: nits in tests

* fix filter nit
2024-09-02 14:13:27 +02:00
Pavlo Khrystenko 9ea7b14fec Integration tests for unstable-reconnecting-rpc-client (#1711)
---------

Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-08-30 10:16:39 +02:00
paritytech-subxt-pr-maker[bot] 270f74a0b3 Update Artifacts (auto-generated) (#1712)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-08-21 17:07:29 +01:00
paritytech-subxt-pr-maker[bot] 90b47faad8 Update Artifacts (auto-generated) (#1706)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
2024-08-12 13:44:32 +01:00
paritytech-subxt-pr-maker[bot] 11a99e1ee6 Update Artifacts (auto-generated) (#1691)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-07-30 10:16:47 +01:00
James Wilson c3267ed488 Add hash method to ExtrinsicDetails (#1676)
* Add hash method to ExtrinsicDetails

* fix test
2024-07-22 13:54:32 +01:00
paritytech-subxt-pr-maker[bot] 9517c87163 Update Artifacts (auto-generated) (#1671)
* Update Artifacts (auto-generated)

* fix test

---------

Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
Co-authored-by: James Wilson <james@jsdw.me>
2024-07-08 14:31:33 +01:00
Alexandru Vasile 25583dcc65 testing: Modify the storage_fetch_raw_keys to reflect substrate-binary (#1667)
* testing: Modify the storage_fetch_raw_keys to reflect substrate-binary
changes

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* 13 -> 14 accounts

---------

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-07-01 13:19:22 +02:00
paritytech-subxt-pr-maker[bot] b48f68001b Update Artifacts (auto-generated) (#1651)
* Update Artifacts (auto-generated)

* update extrinsic bytes

* XcmDryRunApi -> DryRunApi

---------

Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
Co-authored-by: James Wilson <james@jsdw.me>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-06-24 15:33:33 +01:00
James Wilson 4a07b64c27 Allow running integration tests given a SUBXT_TEST_URL=ws://foo:port (#1640)
* Allow running integration tests given a SUBXT_TEST_URL=ws://foo:port

* update comment

* fmt

* Fix lightclient get_url usage

* fix light client

* fix lightclient tests take 2
2024-06-24 14:29:08 +01:00
Niklas Adolfsson ad4fae6a2a fix(tests): don't assume order of balance transfer extrinsics (#1655)
* fix(tests): don't assert order of balanace ext

* move timestamp to loop
2024-06-24 13:01:22 +02:00
Niklas Adolfsson 13747dbd6d fix tests: add CheckMetadataHash ext (#1606) 2024-05-24 09:48:39 +01:00
paritytech-subxt-pr-maker[bot] 4e53d5a4d5 Update Artifacts (auto-generated) (#1596)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
2024-05-20 13:11:03 +03:00
Pavlo Khrystenko 3c9984c7e4 fix flaky testcase (#1589)
full_client::client::unstable_rpcs::chainhead_v1_follow

Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-05-16 16:17:05 +01:00
paritytech-subxt-pr-maker[bot] 910a62e184 Update Artifacts (auto-generated) (#1577)
* Update Artifacts (auto-generated)

* Fix test for new artifacts

---------

Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
Co-authored-by: James Wilson <james@jsdw.me>
2024-05-13 15:23:06 +01:00
Alexandru Vasile 33a891b9da Stabilize transactionWatch methods (#1539)
* Stabilize transactionWatch

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Keep consistency in naming method class

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

---------

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-04-20 14:31:05 +02:00
Alexandru Vasile c57df0845c Stabilize transactionBroadcast methods (#1540)
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-04-20 13:58:58 +02:00
Alexandru Vasile c124e17336 Stabilize chainHead methods (#1538)
* Stabilize chainHead methods

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Rename fn snake case

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* docs: Fix documentation

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

---------

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
2024-04-19 11:27:50 +02:00
James Wilson ac606cf625 Rename traits to remove T suffix (#1535)
* Rename traits to renmove T suffix

* Fix doc links

* Fix straggler doc links
2024-04-16 16:35:14 +01:00
James Wilson 1e111ea9db Make subxt-core ready for publishing (#1508)
* Move Extrinsic decoding things to subxt_core and various tidy-ups

* A couple more fixes and fmt

* first pass moving tx logic to subxt_core

* cargo fmt

* fix wasm example

* clippy

* more clippy

* WIP Adding examples and such

* Move storage functionality more fully to subxt_core and nice examples for storage and txs

* Add example for events

* consistify how addresses/payloads are exposed in subxt-core and add runtime API fns

* Add runtime API core example

* fmt

* remove scale-info patch

* Add a little to the top level docs

* swap args around

* clippy

* cargo fmt and fix wasm-example

* doc fixes

* no-std-ise new subxt-core additions

* alloc, not core

* more no-std fixes

* A couple more fixes

* Add back extrinsic decode test
2024-04-15 15:20:11 +01:00
Alexandru Vasile c07ee0cd7f storage_type: Strip key proper hash and entry bytes (32 instead of 16) (#1522)
* storage_type: Strip key proper hash and entry bytes (32 instead of 16)

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* storage_type: Fix typo

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* storage/tests: Check keys decode properly and don't cause errors

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Update testing/integration-tests/src/full_client/storage/mod.rs

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

---------

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
Co-authored-by: James Wilson <james@jsdw.me>
2024-04-09 14:08:36 +03:00
Alexandru Vasile b31131d21d testing: Prepare light client testing with substrate binary and add subxt-test macro (#1507)
* testing: Add long running light client flag and cfg aliases

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Expose clients depending on feature flags

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* subxt: Use unstable backend for light client

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Disable flaky lightclient tests

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Add long runnnig step

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Revert "subxt: Use unstable backend for light client"

This reverts commit ea6f3cc58b.

* ci: Long running tests for 60 mins

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Use 16 cores for light-client testing

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Isolate light-client testing to save CI minutes

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Retry on Tx::Dropped for lightclinet only

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Wait for more blocks for the lightclient init

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* subxt: Use unstable backend for light client

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Disable legacy RPC tests

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Disable sudo and contracts tests

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Retry constructing lightclient on read-proof errors

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Disable tx dynamic test

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* proc-macro: Timeout for tests

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Add timeout 800 seconds

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* proc-macro/tests: Adjust subxt-test proc-macro

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* proc-macro: Rename crate to subxt-test-proc-macro

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Use default subxt-proc-macro timeout

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* light-client: Remove println

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* subxt: Remove tokio as dependency, use it only for testing

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Chagne default timeout to 6 seconds

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* proc-macro: Add env timeout variable

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Add subxt env var for controling test timeouts

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests/tx-retries: Retry on `Non node available` error

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Use unstable backend for testing lightclient

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Remove old lightclient object

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Adjust for the new interface

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* backend/rpc: Allow older version of the initialized event

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* rpc/tests: Check initialized decodes correctly

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Reset workflow

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Apply cargo fmt

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Remove unused dep

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Remove gitmerge old file

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Remove unused dep

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* rename proc-macro to subxt-test-macro

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Remove txretries for lightclient

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Wait for 5 blocks for the lightclient full testing suite

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Group imports

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* macro: Rename const value

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

---------

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
2024-04-08 11:34:20 +03:00
Tadeo Hepperle a0cb14aa4f subxt-core crate (#1466)
* start migrating, broken

* first iteration of updating

* fmt and clippy

* add Composite<u32> decoding via scale value patch

* bump scale type gen versions

* fix decoding with new scale decode

* compiling with changed deps

* core utils, condig, client, metadata

* core crate compiling

* signer crate no once lock

* add core to no-std-tests, change imports

* broken commit, start pulling everything together in subxt

* port more things to subxt

* events in core crate, extrinsics sadly much more difficult

* almost all examples pass again

* dynamic values fix in examples

* fix no std issue and fmt

* remove unused dependencies

* fix lightclient impl

* runtime version refactor

* formatting and addressing nits

* more comments addressed

* update wasm example and no-std-signer tests

* other nits and error impl on signer errors

* fix feature flag

* fix runtime version refactor

* fix doc links

* fix integration tests

* fix feature flag gated client state

* fix native feature in CI

* fix lightclient utils

* make imports more lean in subxt-core

* integrate changes from subxt-core imports into subxt

* other changes in subxt simplify imports more

* fix  and docs

* doc false for cli

* fix clippy

* remove events block hash in tests

* codegen no-std support in generated code

* export alloc crate for no-std codegen

* fix doc test

* implement James comments

* remove std traits, use core traits instead

* address nits

* remove unusued dep in no-std tests

* fix Box import in no_std

* sp-crypto-hashing instead of sp-core-hashing

* bump scale-typegen, add no std codegen tests

* fix some things

* replace unmaintained derivative with derive_where to remove non-canonical warnings

* fmt

* remove unused dep

* fix deps

* update artifacts to fix type ID mismatches

* bump to latest scale-typegen

---------

Co-authored-by: James Wilson <james@jsdw.me>
2024-03-27 08:55:08 +00:00
Alexandru Vasile 92c1ba7f66 unstable_rpc: Add transactionBroadcast and transactionStop (#1497)
* unstable_rpc: Add transactionBroadcast and transactionStop

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Check transactionBroadcast works

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* testing: Enable default feature for subxt-signer

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Increase number of blocks to look for

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Fix clippy for unneed let binds

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Update subxt/src/backend/unstable/rpc_methods.rs

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

* tests: Adjust txBroadcast test

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Add test for txStop

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Ignore compact encoded lenght prefix

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

---------

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-03-26 17:14:54 +02:00
paritytech-subxt-pr-maker[bot] 22e2796787 Update Artifacts (auto-generated) (#1480)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
2024-03-18 10:35:15 +01:00
James Wilson b069c4425a Rework light client (#1475)
* WIP second pass over light client code for simpler API

* First pass new light client

* pub(crate) LightClientRpc::new_raw(), and fmt

* Update examples and add back a way to configure boot nodes and fetch chainspec from a URL

* Fix light client examples

* remove unused deps and tidy lightclient feature flags

* fix wasm error

* LightClientRpc can be cloned

* update light client tests

* Other small fixes

* exclude mod unless jsonrpsee

* Fix wasm-lightclient-tests

* add back docsrs bit and web+native feature flag compile error

* update book and light client example names

* fix docs
2024-03-15 15:21:06 +00:00
paritytech-subxt-pr-maker[bot] a44d28b26b Update Artifacts (auto-generated) (#1469)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
2024-03-12 19:43:37 +01:00
Niklas Adolfsson dfd6e108cd rpc v2: chainhead support multiple finalized block hashes in FollowEvent::Initialized (#1476)
* chainhead rpc `block_hash -> finalized_block_hashs`

* cleanup

* address grumbles

* address grumbles: inc this.rel_block_num

* rel_block_num => rel_block_age for clarity

---------

Co-authored-by: James Wilson <james@jsdw.me>
2024-03-12 17:42:29 +00:00
Tadeo Hepperle a2ee750365 Typed Storage Keys (#1419)
* first iteration on storage multi keys

* decoding values from concat style hashers

* move util functions and remove comments

* change codegen for storage keys and fix examples

* trait bounds don't match scale value...

* fix trait bounds and examples

* reconstruct storage keys in iterations

* build(deps): bump js-sys from 0.3.67 to 0.3.68 (#1428)

Bumps [js-sys](https://github.com/rustwasm/wasm-bindgen) from 0.3.67 to 0.3.68.
- [Release notes](https://github.com/rustwasm/wasm-bindgen/releases)
- [Changelog](https://github.com/rustwasm/wasm-bindgen/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rustwasm/wasm-bindgen/commits)

---
updated-dependencies:
- dependency-name: js-sys
  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>

* build(deps): bump clap from 4.4.18 to 4.5.0 (#1427)

Bumps [clap](https://github.com/clap-rs/clap) from 4.4.18 to 4.5.0.
- [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/v4.4.18...clap_complete-v4.5.0)

---
updated-dependencies:
- dependency-name: clap
  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>

* build(deps): bump either from 1.9.0 to 1.10.0 (#1425)

Bumps [either](https://github.com/rayon-rs/either) from 1.9.0 to 1.10.0.
- [Commits](https://github.com/rayon-rs/either/compare/1.9.0...1.10.0)

---
updated-dependencies:
- dependency-name: either
  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>

* build(deps): bump thiserror from 1.0.56 to 1.0.57 (#1424)

Bumps [thiserror](https://github.com/dtolnay/thiserror) from 1.0.56 to 1.0.57.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/1.0.56...1.0.57)

---
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>

* build(deps): bump jsonrpsee from 0.21.0 to 0.22.0 (#1426)

* build(deps): bump jsonrpsee from 0.21.0 to 0.22.0

Bumps [jsonrpsee](https://github.com/paritytech/jsonrpsee) from 0.21.0 to 0.22.0.
- [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.21.0...v0.22.0)

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

Signed-off-by: dependabot[bot] <support@github.com>

* Update Cargo.lock

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: James Wilson <james@jsdw.me>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>

* subxt: Derive `std::cmp` traits for subxt payloads and addresses (#1429)

* subxt/tx: Derive std::cmp traits

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* subxt/runtime_api: Derive std::cmp traits

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* subxt/constants: Derive std::cmp traits

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* subxt/custom_values: Derive std::cmp traits

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* subxt/storage: Derive std::cmp traits

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* subxt: Fix non_canonical_partial_ord_impl clippy introduced in 1.73

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* subxt: Add comment wrt derivative issue that triggers clippy warning

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* Update subxt/src/backend/mod.rs

* Update subxt/src/constants/constant_address.rs

---------

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>

* fix clippy

* add integration tests

* fix doc tests

* change hashing logic for hashers=1

* refactor

* clippy and fmt

* regenerate polkadot file which got changed by the automatic PR

* nested design for storage keys

* refactor codegen

* codegen adjustments

* fix storage hasher codegen test

* Suggestions for storage value decoding (#1457)

* Storage decode tweaks

* doc tweak

* more precise error when leftover or not enough bytes

* integrate nits from PR

* add fuzztest for storage keys, fix decoding bug

* clippy and fmt

* clippy

* Niklas Suggestions

* lifetime issues and iterator impls

* fmt and clippy

* regenerate polkadot.rs

* fix storage key encoding for empty keys

* rename trait methods for storage keys

* fix hasher bug...

* impl nits, add iterator struct seperate from `StorageHashers`

* clippy fix

* remove println

---------

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: James Wilson <james@jsdw.me>
Co-authored-by: Niklas Adolfsson <niklasadolfsson1@gmail.com>
Co-authored-by: Alexandru Vasile <60601340+lexnv@users.noreply.github.com>
2024-03-06 14:04:51 +01:00
paritytech-subxt-pr-maker[bot] 9773cb53c9 Update Artifacts (auto-generated) (#1463)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
2024-03-04 10:20:25 +01:00
Tadeo Hepperle 2727f77910 Extrinsic Params Refinement (#1439)
* refinement based approach to params

* doc and test fixes

* bundle refine data into struct
2024-03-01 10:04:34 +01:00
James Wilson ddd0865fa9 Make storage_page_size for the LegacyBackend configurable (#1458) 2024-02-29 13:13:58 +00:00
paritytech-subxt-pr-maker[bot] 08ae4059d8 Update Artifacts (auto-generated) (#1446)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
2024-02-26 11:28:46 +00:00
paritytech-subxt-pr-maker[bot] 1ea84c6cde Update Artifacts (auto-generated) (#1433)
Co-authored-by: tadeohepperle <62739623+tadeohepperle@users.noreply.github.com>
2024-02-19 10:32:24 +01:00
Tadeo Hepperle e39791a5bc Add missing codegen mod in integration tests (#1418)
* add codgen mod to the module tree

* port codegen tests to scale-typegen

* remove test flag
2024-02-14 17:17:08 +01:00
Tadeo Hepperle 8fa496b866 Build Polkadot Nodes in CI - fixes artifact generation (#1410)
* new workflow and adjust node builder

* fix examples by fixing artifacts script

* use-nodes instead of use-substrate

* update yamls

* build polkadot

* remove the on-push trigger again, now that polkadot built in the CI

* add default implementation again
2024-02-01 21:54:30 +01:00
Alexandru Vasile c1073bc8d1 ci: Better job parallelism, cancel pipeline on failure and extra clippy checks (#1409)
* ci: Change CI order for better parallelism

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Cancel ongoing jobs

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* TO REVERT: Check early termination due to clipp/check

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci/clippy: Extend clippy checks for lightclient and web feature flags

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Use cancel-action@3

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Derive Default

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* subxt/rpc: Resolve redundant closure

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* tests: Fix clippy

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Fix clippy warnings

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Extend clippy rules

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* lightclient: Remove redundant clone

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Use subxt instead of subxt-lightclient

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Add wasm clippy step

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Simplify the clippy step into a single run command

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Pin version for cancel-action

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

* ci: Fix pinned version

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>

---------

Signed-off-by: Alexandru Vasile <alexandru.vasile@parity.io>
2024-01-31 11:53:33 +02:00
James Wilson f4acd1bae8 resolve clippy err 2024-01-18 10:27:16 +00:00