Python binding to the Solana Rust SDK
Project description
Solders
solders
is a Python binding to the
Solana Rust SDK.
It provides robust, high-performance solutions to core Solana tasks such as transaction signing and serialization, and saves us from reimplementing Solana logic in pure Python.
Installation
pip install solders
Note: Requires Python >= 3.7.
Example Usage
>>> from solders.message import Message
>>> from solders.keypair import Keypair
>>> from solders.instruction import Instruction
>>> from solders.hash import Hash
>>> from solders.transaction import Transaction
>>> from solders.pubkey import Pubkey
>>> program_id = Pubkey.default()
>>> arbitrary_instruction_data = bytes([1])
>>> accounts = []
>>> instruction = Instruction(program_id, arbitrary_instruction_data, accounts)
>>> payer = Keypair()
>>> message = Message([instruction], payer.pubkey())
>>> blockhash = Hash.default() # replace with a real blockhash
>>> tx = Transaction([payer], message, blockhash)
Development
Setup
- Install poetry
- Install dev dependencies:
poetry install
- Activate the poetry shell:
poetry shell
Testing
- Run
maturin develop
to compile the Rust code. - Run
make fmt
,make lint
, andmake test
.
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
solders-0.1.4.tar.gz
(28.5 kB
view hashes)
Built Distributions
solders-0.1.4-cp37-abi3-win_amd64.whl
(507.8 kB
view hashes)
Close
Hashes for solders-0.1.4-cp37-abi3-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 25ddb4fc5d845c33db8e9a26dc0fdec757d5c10cd4c0440f61feba34cf9ff012 |
|
MD5 | feb2b8423623a8c462246eae8d823d4f |
|
BLAKE2b-256 | 909127f8ad25716443e808e774308bb835a12019299f41355fb40c32169a7e11 |
Close
Hashes for solders-0.1.4-cp37-abi3-musllinux_1_2_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 64bf6aa95f76d3431db8cba111729f902cdb4972adfbb7c09e559517180a7bbd |
|
MD5 | 4138d59fb61fdf347abab8ad76f38812 |
|
BLAKE2b-256 | 9d0e3bd6119d024353ecf688a32792df06e5f92a83d6438e589db229fa8f245f |
Close
Hashes for solders-0.1.4-cp37-abi3-musllinux_1_2_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1ae409539e37abec97763c65317381552f294a1639959d0c2e83fa81342d032f |
|
MD5 | 3d8d6004b5995b206e2cad2a3963e0da |
|
BLAKE2b-256 | 2a034f42c1c537e0c62726e4d26c845ffbd057b23eddfb88d92d022810912edc |
Close
Hashes for solders-0.1.4-cp37-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7886c4eb9865fbd8c3acae2ae27bede09d206257b24a7ed254609e7d81a03e44 |
|
MD5 | 4560aa3c028426a592050b49ae6d2882 |
|
BLAKE2b-256 | f15569dee62557846fc531ec6470c1de9c19630ba20b22c8522a8c80698b8a07 |
Close
Hashes for solders-0.1.4-cp37-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d448806cf1e835fe60d3a303f3025606490328ced2cac5c018c03cdc2b866f0f |
|
MD5 | bd571e6193f3b7efdae3640e649bd5a3 |
|
BLAKE2b-256 | 7aa7069d4a6a1cbbc7248213e15fa6b5fd8b4344328d4e7e2e68258ee6c17a35 |
Close
Hashes for solders-0.1.4-cp37-abi3-manylinux_2_17_ppc64.manylinux2014_ppc64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bd56365f0beb498a82dc92fce71fa5900b42d7c6f566f1b29e4cda9b3b4e0497 |
|
MD5 | 195ad3302ac476533fe508b18053e0ca |
|
BLAKE2b-256 | 025536baf2a0e68590240856cd619b1685d126f210b8569137ff8e40352130e0 |
Close
Hashes for solders-0.1.4-cp37-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f57434ff72d073a4fe5050a54d08e4915b466a472523ce2ef0dc702e17202150 |
|
MD5 | 07b46a51e7f6d7277059a5869528e756 |
|
BLAKE2b-256 | 3e2c92bf6435461f07612988512a9875b3b090ab57597d166c382aa25171a521 |
Close
Hashes for solders-0.1.4-cp37-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 073b647781a26ad016c9a79a2c9d5fb71a94ef86f91575b85c88208fa27e0082 |
|
MD5 | 569d89fa9cbd25abd15faeca3b3b6cb1 |
|
BLAKE2b-256 | 5899c3cbe11149ce9ad5a7505e773a5ccfea28510d1b0ba47e63a3c8cd7f94c5 |
Close
Hashes for solders-0.1.4-cp37-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4579a92927b9786331aa310b7b93032abece1baf4178a681108900aa5676c8d5 |
|
MD5 | a690a93fccec8d6d396f3e27cb50434b |
|
BLAKE2b-256 | 7344c157b623d2106a8e9055b87fb662e1fba5ddb8ab08902d47d0949e2363fd |
Close
Hashes for solders-0.1.4-cp37-abi3-manylinux_2_5_i686.manylinux1_i686.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | abc42baf583e1b45260eb41179c67296aeee27146f588ee1abb6c54f1777aaf5 |
|
MD5 | b067467e40c03dbb6fcc2589e7dab6ab |
|
BLAKE2b-256 | c37d38df4ac477045a64408d71acb47f9bf757f3409c79396a4977848f601a72 |
Close
Hashes for solders-0.1.4-cp37-abi3-macosx_10_9_x86_64.macosx_11_0_arm64.macosx_10_9_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e503727a4d303faf2f7aafc44d5d278d905f89ab690455d3e8bfe2e505ba05fa |
|
MD5 | 02a573e7fad99ba734a2a37e903d0a25 |
|
BLAKE2b-256 | b5e32b816501b51cc1ac14dfa5ea7090068e426bb3da65fac6cf4bcc05c8b082 |
Close
Hashes for solders-0.1.4-cp37-abi3-macosx_10_7_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ca760e04e84c6ee02d7357146432d009ad07e5828d64e17b66594297af2fd6fe |
|
MD5 | c55b1271d5f42f125406fe8172f5c830 |
|
BLAKE2b-256 | 8d40af3e5e33946d62a075f4882974ab2663ab84654f686cea8c727d1cb09344 |