Merged
Conversation
lexnv
approved these changes
Mar 21, 2024
niklasad1
reviewed
Mar 21, 2024
niklasad1
approved these changes
Mar 21, 2024
Co-authored-by: Niklas Adolfsson <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
[0.35.0] - 2024-03-21
This release contains several fixes, adds
no_stdsupport to a couple of crates (subxt-signerandsubxt-metadata) and introduces a few quality of life improvements, which I'll quickly cover:Reworked light client (#1475)
This PR reworks the light client interface. The "basic" usage of connecting to a parachain now looks like this:
This interface mirrors the requirement that we must connect to a relay chain before we can connect to a parachain. It also moves the light client specific logic into an
RpcClientTimplementation, rather than exposing it as asubxt::client::LightClient.Typed Storage Keys (#1419)
This PR changes the storage interface so that, where possible, we now also decode the storage keys as well as the values when iterating over storage entries:
When using the static interface, keys come back as a tuple of values corresponding to the different hashers used in constructing the key. When using a dynamic interface, keys will be encoded/decoded from the type given so long as it implements
subxt::storage::StorageKey, egVec<scale_value::Value>.Extrinsic Params Refinement (#1439)
Prior to this PR, one could configure extrinsic signed extensions by providing some params like so:
If you want to customize the account nonce, you'd use a different call like
create_signed_with_nonceinstead.One of the downsides of the above approach is that, if you don't provide any explicit params, transactions will be immortal by default (because the signed extensions didn't have the information to do any better).
Now, with the help of a
RefineParamstrait, transactions will default to being mortal and living for 32 blocks unless an explicit mortality is provided as above.One notable change is that the offline-only
create_signed_with_nonceandcreate_partial_signed_with_noncefunctions have lost the_with_noncesuffix. Since we can't discover nonce/mortality settings offline, you should now provideParamsand set an explicit nonce (and mortality, if you like) when using these calls, otherwise the nonce will be set to 0 and the mortality toImmortal.For a full list of changes, please see the following:
Added
no_stdcompatibility forsubxt-signer(#1477)no_stdcompatibility forsubxt-metadata(#1401)reconnecting-rpc-client(#1396)Changed
scale-type-resolverintegration (#1460)std::cmptraits for subxt payloads and addresses (#1429)FollowEvent::Initialized(#1476)Fixed