Python SCALE Codec Library
Project description
Python SCALE Codec
Python SCALE Codec Library
Description
Most of the data that the Substrate RPCs output is encoded with the SCALE Codec. This codec is used by the Substrate nodes' internal runtime. In order to get to meaningful data this data will need to be decoded. The Python SCALE Codec Library will specialize in this task.
Documentation
https://polkascan.github.io/py-scale-codec/
Example
RuntimeConfiguration().update_type_registry(load_type_registry_preset("default"))
RuntimeConfiguration().update_type_registry(load_type_registry_preset("kusama"))
obj = ScaleDecoder.get_decoder_class('Compact<Balance>', ScaleBytes("0x130080cd103d71bc22"))
obj.decode()
print(obj.value)
License
https://github.com/polkascan/py-scale-codec/blob/master/LICENSE
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
scalecodec-0.9.1.tar.gz
(205.2 kB
view details)
Built Distribution
File details
Details for the file scalecodec-0.9.1.tar.gz
.
File metadata
- Download URL: scalecodec-0.9.1.tar.gz
- Upload date:
- Size: 205.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.1.0 requests-toolbelt/0.9.1 tqdm/4.42.0 CPython/3.7.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 338bd82c0e20915459a1d6b8cb05e4a5a4cb86cccb0c4fc6aac0f794012dc060 |
|
MD5 | 3baf1d1bbf54484de4de28ea2ab7e562 |
|
BLAKE2b-256 | 94466a939aa0c5da31bca3ad646ed82f933a7e5f618e8d6bc21c61b61c754233 |
File details
Details for the file scalecodec-0.9.1-py3-none-any.whl
.
File metadata
- Download URL: scalecodec-0.9.1-py3-none-any.whl
- Upload date:
- Size: 45.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/45.1.0 requests-toolbelt/0.9.1 tqdm/4.42.0 CPython/3.7.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 525d78b585059e23fc74ae901f58e5c31b5408a16897515730205a06c0093d06 |
|
MD5 | c0c1d8c6534934695a5a448a02006d67 |
|
BLAKE2b-256 | d178c300612194b7b0f69a0ee02c2828549c00fa4fddd620fce564de739fbf59 |