Skip to content

Releases: paritytech/scale-value

v0.18.0

15 Nov 14:31
v0.18.0
a6951d7
Compare
Choose a tag to compare

0.18.0 (2024-11-15)

This release makes scale-value entirely no_std which is now using core::error::Error instead of std::error::Error as it was using before behind
the std feature. Because of that the std feature is now removed and the MSRV is bumped to 1.81.0. In addition it bumps a few dependencies to their latest versions.

Changed

  • Remove std feature and make the crate fully no_std
  • Update scale-decode to v0.16.0
  • Update scale-encode to v0.10.0
  • Update yap to v0.12.0
  • Update scale-bits to v0.7.0
  • Remove scale-info dependency and the re-export PortableRegistry
  • Bump MSRV to 1.81.0
  • Replace derive_more with thiserror

Full Changelog: v0.17.0...v0.18.0

v0.17.0

22 Oct 10:50
v0.17.0
9f16614
Compare
Choose a tag to compare

0.17.0 (2024-10-22)

This release:

  • Bumps derive_more from 0.99 to 1.0 (#57)
  • Bumps scale-decode from 0.13 to 0.14 (#58)
  • Bumps scale-encode from 0.7 to 0.8 (#59)
  • Removes frame-metadata dependency (#60)

Full Changelog: v0.16.2...v0.17.0

v0.16.2

09 Aug 10:11
9110e02
Compare
Choose a tag to compare

0.16.2 (2024-08-08)

This release adds scale_value::stringify::to_writer and scale_value::stringify::to_writer_custom (to align with the already present scale_value::stringify::from_str_custom), and also exposes a new scale_value::stringiy::custom_formatters containing a formatter for displaying things as hex.

scale_value::stringify::to_writer_custom allows for custom formatting of values, including a "pretty" spaced/indented formatting and a "compact" formatting which removes all unnecessary spaces. It also allows customising of the indentation and for custom formatters to be applied, as well as displaying the contexts of values if desired.

See #52 for more information.

v0.16.1

24 Jul 16:18
6b58d3d
Compare
Choose a tag to compare

0.16.1 (2024-07-24)

This release:

  • Adds a "tracing decoder" (via scale_value::scale::tracing::{decode_as_type,*}), which is like scale_value::scale::decode_as_type, but traces and hands back much more detail in case of a decoding failure, so that it's easier to track down where decoding failed. This is particularly useful when working with historic type information, which must be provided independently and could easily be misaligned with reality. (#52)

v0.16.0

24 Jul 16:18
9fc05e9
Compare
Choose a tag to compare

0.16.0 (2024-05-15)

This release:

  • Bumps scale-decode to its latest version (0.13.0).

v0.15.0

29 Apr 14:18
c5c3512
Compare
Choose a tag to compare

0.15.0 (2024-04-29)

This release bumps scale-type-resolver, scale-encode, scale-decode and scale-bits to their latest versions.

v0.14.1

05 Mar 07:10
372a748
Compare
Choose a tag to compare

0.14.1 (2024-03-04)

Added

A scale_value::decode_as_fields function was added that can decode a series of values from some bytes given an iterator of type ids. Previously it was only possible through the scale_decode::DecodeAsFields implementation of scale_value::Composite<()>. With the new function scale_value::Composite<R::TypeId>'s can be decoded for any type resolver R.

v0.14.0

27 Feb 11:49
fb915f4
Compare
Choose a tag to compare

0.14.0 (2024-02-27)

Changed

The crate now uses scale-type-resolver to be generic over the provider of type information that is used when encoding and decoding Values.

One implication is that scale_decode::IntoVisitor is now only implemented for Value<()> and no longer for Value<u32>. So Value::decode_from_type() cannot be used anymore to create a Value<u32> that keeps type id information. Instead you now use scale_value::scale::decode_as_type() which can return the desired Value<u32>.

v0.13.0

10 Nov 15:47
1a404c1
Compare
Choose a tag to compare

0.13.0 (2023-11-10)

This release:

  • Bumps scale-decode to its latest version.

v0.12.0

02 Aug 10:32
b4772d5
Compare
Choose a tag to compare

0.12.0 (2023-08-02)

Bumps scale-encode and scale-decode to their latest versions (0.5 and 0.9 respectively).

One effect that this has is that structs containing compact encoded values, after being encoded, now decode to composite types that better
reflect their original shape. For example, Compact(MyWrapper { inner: 123 }), when encoded, used to decode to Value::u128(123),
but now it decodes to Value::named_composite(vec![("inner", Value::u128(123))]).