Skip to content
This repository was archived by the owner on Jul 10, 2026. It is now read-only.

v2.0.0

Choose a tag to compare

@thewhaleking thewhaleking released this 21 Apr 16:53
· 127 commits to master since this release
9638b09

Breaking changes:

  • SS58 format now defaults to 42 instead of None. It can still be manually set to None, which will trigger the chain
    pull.

  • query now always returns a ScaleType object. Previously it could return ScaleObj | None | dict. The underlying data
    has not changed, but always needs to be retrieved by the .value (or .value_object or .value_serialized).

  • runtime_call now always returns the decoded value. Previously it could return the decoded object, or a ScaleObj. This
    was done for consistency, as legacy methods (pre-v15 metadata) required their own predefined decoders, and the
    decoders did not give a ScaleType object, so to keep things consistent, it's always the decoded value.

  • query_multi previously returned [(StorageKey, ScaleType), ...], now returns [(StorageKey, decoded value), ...]. We
    made significant speed improvements in cyscale with batch-decoding, and this works great here.

  • query_map.records previously returned [(key, ScaleObj), ...]. Now returns [(key, decoded value), ...] for the same
    reasons as listed in the query_multi note.

  • query_multiple: removed, was not so useful

  • reuse_block_hash: removed, was not so useful

  • SS58 addresses are always decoded now. No more need to manually decode after retrieving results.

  • For instantiation of any of the *Substrate classes, only the uri is a positional argument. All other arguments are
    keyword-only.

Non-breaking improvements:

  • Better DiskCached behavior. Loading from cache is 2-3x faster, and dumping to cache 3-∞ faster (does not dump if the
    object is unchanged).

  • Mypy support added.

Important for upgrade:

Because of the change from the combination py-scale-codec and bt-decode to cyscale, we no longer support having the
py-scale-codec installed (cyscale fits the same namespace, scalecodec). If you attempt to run ASI with py-scale-codec
installed, you will receive an error and instructions to uninstall that first. To prevent this, before upgrade, you can
remove it as such:

pip uninstall scalecodec -y
pip install -U cyscale