Skip to content

Latest commit

 

History

History
309 lines (244 loc) · 20 KB

CHANGELOG.md

File metadata and controls

309 lines (244 loc) · 20 KB

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

[0.21.0] - 2022-05-02

This release adds static metadata validation, via comparing the statically generated API with the target node's runtime metadata. This implies a breaking change in the subxt API, as the user receives an error when interacting with an incompatible API at the storage, call, and constant level.

The subxt-cli can check the compatibility of multiple runtime nodes, either full metadata compatibility or compatibility at the pallet level.

Users can define custom derives for specific generated types of the API via adding the derive_for_type configuration to the subxt attribute.

The metadata documentation is propagated to the statically generated API.

Previously developers wanting to build the subxt crate needed the substrate binary dependency in their local environment. This restriction is removed via moving the integration tests to a dedicated crate.

The number of dependencies is reduced for individual subxt crates.

Fixed

  • test-runtime: Add exponential backoff (#518)

Added

  • Add custom derives for specific generated types (#520)
  • Static Metadata Validation (#478)
  • Propagate documentation to runtime API (#511)
  • Add tidext in real world usage (#508)
  • Add system health rpc (#510)

Changed

  • Put integration tests behind feature flag (#515)
  • Use minimum amount of dependencies for crates (#524)
  • Export BaseExtrinsicParams (#516)
  • bump jsonrpsee to v0.10.1 (#504)

[0.20.0] - 2022-04-06

The most significant change in this release is how we create and sign extrinsics, and how we manage the "additional" and "extra" data that is attached to them. See paritytech#477, and the associated PR paritytech#490 for a more detailed look at the code changes.

If you're targeting a node with compatible additional and extra transaction data to Substrate or Polkadot, the main change you'll have to make is to import and use subxt::PolkadotExtrinsicParams or subxt::SubstrateExtrinsicParams instead of subxt::DefaultExtra (depending on what node you're compatible with), and then use sign_and_submit_default instead of sign_and_submit when making a call. Now, sign_and_submit accepts a second argument which allows these parameters (such as mortality and tip payment) to be customized. See examples/balance_transfer_with_params.rs for a small usage example.

If you're targeting a node which involves custom additional and extra transaction data, you'll need to implement the trait subxt::extrinsic::ExtrinsicParams, which determines the parameters that can be provided to sign_and_submit, as well as how to encode these into the "additional" and "extra" data needed for a transaction. Have a look at subxt/src/extrinsic/params.rs for the trait definition and Substrate/Polkadot implementations. The aim with this change is to make it easier to customise this for your own chains, and provide a simple way to provide values at runtime.

Fixed

  • Test utils: parse port from substrate binary output to avoid races (#501)
  • Rely on the kernel for port allocation (#498)

Changed

  • Export ModuleError for downstream matching (#499)
  • Bump jsonrpsee to v0.9.0 (#496)
  • Use tokio instead of async-std in tests/examples (#495)
  • Read constants from metadata at runtime (#494)
  • Handle sp_runtime::ModuleError substrate updates (#492)
  • Simplify creating and signing extrinsics (#490)
  • Add dev_getBlockStats RPC (#489)
  • scripts: Hardcode github subxt pull link for changelog consistency (#482)

[0.19.0] - 2022-03-21

Changed

  • Return events from blocks skipped over during Finalization, too (#473)
  • Use RPC call to get account nonce (#476)
  • Add script to generate release changelog based on commits (#465)
  • README updates (#472)
  • Make EventSubscription and FilterEvents Send-able (#471)

[0.18.1] - 2022-03-04

Fixed

  • Remove unused sp_version dependency to fix duplicate parity-scale-codec deps (#466)

[0.18.0] - 2022-03-02

Added

  • Expose method to fetch nonce via Client (#451)

Changed

  • Reference key storage api (#447)
  • Filter one or multiple events by type from an EventSubscription (#461)
  • New Event Subscription API (#442)
  • Distinct handling for N fields + 1 hasher vs N fields + N hashers (#458)
  • Update scale-info and parity-scale-codec requirements (#462)
  • Substitute BTreeMap/BTreeSet generated types for Vec (#459)
  • Obtain DispatchError::Module info dynamically (#453)
  • Add hardcoded override to ElectionScore (#455)
  • DispatchError::Module is now a tuple variant in latest Substrate (#439)
  • Fix flaky event subscription test (#450)
  • Improve documentation (#449)
  • Export codegen::TypeGenerator (#444)
  • Fix conversion of Call struct names to UpperCamelCase (#441)
  • Update release documentation with dry-run (#435)

[0.17.0] - 2022-02-04

Added

  • introduce jsonrpsee client abstraction + kill HTTP support. (#341)
  • Get event context on EventSubscription (#423)

Changed

  • Add more tests for events.rs/decode_and_consume_type (#430)
  • Update substrate dependencies (#429)
  • export RuntimeError struct (#427)
  • remove unused PalletError struct (#425)
  • Move Subxt crate into a subfolder (#424)
  • Add release checklist (#418)

[0.16.0] - 2022-02-01

Note: This is a significant release which introduces support for V14 metadata and macro based codegen, as well as making many breaking changes to the API.

Changed

  • Log debug message for JSON-RPC response (#415)
  • Only convert struct names to camel case for Call variant structs (#412)
  • Parameterize AccountData (#409)
  • Allow decoding Events containing BitVecs (#408)
  • Custom derive for cli (#407)
  • make storage-n-map fields public too (#404)
  • add constants api to codegen (#402)
  • Expose transaction::TransactionProgress as public (#401)
  • add interbtc-clients to real world usage section (#397)
  • Make own version of RuntimeVersion to avoid mismatches (#395)
  • Use the generated DispatchError instead of the hardcoded Substrate one (#394)
  • Remove bounds on Config trait that aren't strictly necessary (#389)
  • add crunch to readme (#388)
  • fix remote example (#386)
  • fetch system chain, name and version (#385)
  • Fix compact event field decoding (#384)
  • fix: use index override when decoding enums in events (#382)
  • Update to jsonrpsee 0.7 and impl Stream on TransactionProgress (#380)
  • Add links to projects using subxt (#376)
  • Use released substrate dependencies (#375)
  • Configurable Config and Extra types (#373)
  • Implement pre_dispatch for SignedExtensions (#370)
  • Export TransactionEvents (#363)
  • Rebuild test-runtime if substrate binary is updated (#362)
  • Expand the subscribe_and_watch example (#361)
  • Add TooManyConsumers variant to track latest sp-runtime addition (#360)
  • Implement new API for sign_and_submit_then_watch (#354)
  • Simpler dependencies (#353)
  • Refactor type generation, remove code duplication (#352)
  • Make system properties an arbitrary JSON object, plus CI fixes (#349)
  • Fix a couple of CI niggles (#344)
  • Add timestamp pallet test (#340)
  • Add nightly CI check against latest substrate. (#335)
  • Ensure metadata is in sync with running node during tests (#333)
  • Update to jsonrpsee 0.5.1 (#332)
  • Update substrate and hardcoded default ChargeAssetTxPayment extension (#330)
  • codegen: fix compact unnamed fields (#327)
  • Check docs and run clippy on PRs (#326)
  • Additional parameters for SignedExtra (#322)
  • fix: also processess initialize and finalize events in event subscription (#321)
  • Release initial versions of subxt-codegen and subxt-cli (#320)
  • Add some basic usage docs to README. (#319)
  • Update jsonrpsee (#317)
  • Add missing cargo metadata fields for new crates (#311)
  • fix: keep processing a block's events after encountering a dispatch error (#310)
  • Codegen: enum variant indices (#308)
  • fix extrinsics retracted (#307)
  • Add utility pallet tests (#300)
  • fix metadata constants (#299)
  • Generate runtime API from metadata (#294)
  • Add NextKeys and QueuedKeys for session module (#291)
  • deps: update jsonrpsee 0.3.0 (#289)
  • deps: update jsonrpsee 0.2.0 (#285)
  • deps: Reorg the order of deps (#284)
  • Expose the rpc client in Client (#267)
  • update jsonrpsee to 0.2.0-alpha.6 (#266)
  • Remove funty pin, upgrade codec (#265)
  • Use async-trait (#264)
  • [jsonrpsee http client]: support tokio1 & tokio02. (#263)
  • impl From<Arc<WsClient>> and From<Arc<HttpClient>> (#257)
  • update jsonrpsee (#251)
  • return none if subscription returns early (#250)

[0.15.0] - 2021-03-15

Added

  • implement variant of subscription that returns finalized storage changes - #237
  • implement session handling for unsubscribe in subxt-client - #242

Changed

  • update jsonrpsee #251
  • return none if subscription returns early #250
  • export ModuleError and RuntimeError for downstream usage - #246
  • rpc client methods should be public for downstream usage - #240
  • re-export WasmExecutionMethod for downstream usage - #239
  • integration with jsonrpsee v2 - #214
  • expose wasm execution method on subxt client config - #230
  • Add hooks to register event types for decoding - #227
  • Substrate 3.0 - #232

[0.14.0] - 2021-02-05

  • Refactor event type decoding and declaration #221
  • Add Balances Locks #197
  • Add event Phase::Initialization #215
  • Make type explicit #217
  • Upgrade dependencies, bumps substrate to 2.0.1 #219
  • Export extra types #212
  • Enable retrieval of constants from rutnime metadata #207
  • register type sizes for u64 and u128 #200
  • Remove some substrate dependencies to improve compile time #194
  • propagate 'RuntimeError's to 'decode_raw_bytes' caller #189
  • Derive Clone for PairSigner #184

[0.13.0]

  • Make the contract call extrinsic work #165
  • Update to Substrate 2.0.0 #173
  • Display RawEvent data in hex #168
  • Add SudoUncheckedWeightCall #167
  • Add Add SetCodeWithoutChecksCall #166
  • Improve contracts pallet tests #163
  • Make Metadata types public #162
  • Fix option decoding and add basic sanity test #161
  • Add staking support #160
  • Decode option event arg #158
  • Remove unnecessary Sync bound #172

[0.12.0]

  • Only return an error if the extrinsic failed. #156
  • Update to rc6. #155
  • Different assert. #153
  • Add a method to fetch an unhashed key, close #100 #152
  • Fix port number. #151
  • Implement the concat in twox_64_concat #150
  • Storage map iter #148

[0.11.0]

  • Fix build error, wabt 0.9.2 is yanked #146
  • Rc5 #143
  • Refactor: extract functions and types for creating extrinsics #138
  • event subscription example #140
  • Document the Call derive macro #137
  • Document the #[module] macro #135
  • Support authors api. #134

[0.10.1] - 2020-06-19

  • Release client v0.2.0 #133

[0.10.0] - 2020-06-19

  • Upgrade to substrate rc4 release #131
  • Support unsigned extrinsics. #130

[0.9.0] - 2020-06-25

  • Events sub #126
  • Improve error handling in proc-macros, handle DispatchError etc. #123
  • Support embedded full/light node clients. #91
  • Zero sized types #121
  • Fix optional store items. #120
  • Make signing fallable and asynchronous #119

[0.8.0] - 2020-05-26

  • Update to Substrate release candidate #116
  • Update to alpha.8 #114
  • Refactors the api #113

[0.7.0] - 2020-05-13

  • Split subxt #102
  • Add support for RPC state_getReadProof #106
  • Update to substrate alpha.7 release #105
  • Double map and plain storage support, introduce macros #93
  • Raw payload return SignedPayload struct #92

[0.6.0] - 2020-04-15

  • Raw extrinsic payloads in Client #83
  • Custom extras #89
  • Wrap and export BlockNumber #87
  • All substrate dependencies upgraded to alpha.6

[0.5.0] - 2020-03-25

  • First release
  • All substrate dependencies upgraded to alpha.5