Releases: StellarCN/py-stellar-base
12.0.0
This is the first stable release that supports Protocol 22. While the network has not upgraded yet, you can start integrating the new features into your codebase if you want a head start.
If you are using this SDK to call Soroban contracts, please check stellar-contract-bindings, which can automatically generate contract binding code for you, making it incredibly easy to call contracts.
The following log is the changes since 11.1.0:
Update
- feat: add
stellar_sdk.contract.ContractClient
andstellar_sdk.contract.ContractClientAsync
, this greatly reduces the difficulty of calling contracts, and you can learn more through the documentation and examples. (#998) - feat: add support for Soroban PRC's
getLedgers
API interfaces. (#992) - feat: add support for Soroban PRC's
getVersionInfo
API interfaces. (#984) - feat: Add
transaction_hash
toGetTransactionResponse
andGetTransactionsResponse
. (#984) - feat:
scval.from_enum
andscval.to_enum
now support multiple values. (#1004)
Breaking changes
- feat!: support constructors in contract creation via
TransactionBuilder.append_create_contract_op
, the signature of the function has been changed. (#979) - refactor!: The
EventInfo.paging_token
field has been marked as deprecated, use thecursor
inGetEventsResponse
instead. (#984) - refactor!: The legacy
cost
field has been removed fromSimulateTransactionResponse
, parse it fromtransaction_data
instead. (#984) - refactor!: Updated
signer
parameter in auth to accept a callable returning (public_key, signatures) instead of just public_key. (#982)
12.0.0-beta6
Update
- feat:
scval.from_enum
andscval.to_enum
now support multiple values. (#1004)
12.0.0-beta5
Update
- fix: fix a bug in
AssembledTransaction.simulate
. (#1000)
12.0.0-beta4
This version significantly reduces the difficulty of calling contracts.
Update
- feat: add
stellar_sdk.contract.ContractClient
andstellar_sdk.contract.ContractClientAsync
, this greatly reduces the difficulty of calling contracts, and you can learn more through the documentation and examples. (#998)from stellar_sdk import Network, scval from stellar_sdk.contract import ContractClient assembled = ContractClient( contract_id="CACZTW72246RA2MOCNKUBRRRRPT26UZ7LXE5ZHH44OGKIMCTQJ74O4D5", rpc_url="https://soroban-testnet.stellar.org:443", network_passphrase=Network.TESTNET_NETWORK_PASSPHRASE, ).invoke( function_name="hello", parameters=[scval.to_string("world")], parse_result_xdr_fn=lambda result: [ scval.from_string(s).decode() for s in scval.from_vec(result) ], ) print(f"Result from simulation: {assembled.result}")
12.0.0-beta3
Several hours ago, I released version 12.0.0-beta2, which added support for the Soroban RPC's getLedgers API interface.
However, some field names in the implementation need to be renamed.
Update
- refactor: rename
LedgerInfo.ledger_header
toLedgerInfo.header_xdr
,LedgerInfo.ledger_metadata
toLedgerInfo.metadata_xdr
. (#994)
12.0.0-beta2
Update
- feat: add support for Soroban PRC's
getLedgers
API interface. (#992)
12.0.0-beta1
Update
- refactor: add
paging_token
back toEventInfo
. This is to ensure compatibility with older versions of Soroban-RPC. We still recommend using theGetEventsResponse.cursor
field after upgrading Soroban-RPC. (#990)
12.0.0-beta0
This is the first release that supports Protocol 22. While the network has not upgraded yet,
you can start integrating the new features into your codebase if you want a head start.
Update
- feat: add support for Soroban PRC's
getVersionInfo
API interfaces. - feat: add
transaction_hash
toGetTransactionResponse
andGetTransactionsResponse
.
Breaking changes
- refactor!: the
paging_token
field has been removed fromEventInfo
, use thecursor
inGetEventsResponse
instead. - refactor!: the legacy
cost
field has been removed fromSimulateTransactionResponse
, parse it fromtransaction_data
instead. - feat!: support constructors in contract creation via
TransactionBuilder.append_create_contract_op
, the signature of the function has been changed. - refactor!: updated
signer
parameter in auth to accept a callable returning (public_key, signatures) instead of just public_key.
11.1.0
Update
- feat: add support for Soroban PRC's
getTransactions
andgetFeeStats
API interfaces. (#960) - feat: add support for Horizon's
transactions_async
API interfaces. (#961) - fix: fix
authorize_entry
to use the correct public key when passingKeypair
as signer. (#971) - feat: Expose
stellar_sdk.address.AddressType
for easy importing. (#973) - chore: bump dependencies.
11.0.0
Update
- feat:
SorobanServer.send_transaction
supports sending FeeBumpTransactionEnvelope. (#956) - fix: Corrected the issue where
TransactionBuilder.from_xdr
could not properly parse transactions containing Soroban operations. (#957) - fix: Corrected the issue where
FeeBumpTransactionEnvelope.from_xdr
could not properly parse transactions containing Soroban operations. (#957) - refactor:
TransactionBuilder.from_xdr
previously could returnTransactionBuilder
orFeeBumpTransactionEnvelope
. Now it will no longer returnTransactionBuilder
, but will returnTransactionEnvelope
orFeeBumpTransactionEnvelope
. (#957) - feat:
TransactionBuilder.build_fee_bump_transaction
now supports transactions containing Soroban operations. (#957) - fix: fix the issue where invoking
SorobanServer.prepare_transaction
for transactions that have already setSorobanData
could result in unexpected high fees. (#957) - chore: bump dependencies.
Breaking changes
- refactor:
FeeBumpTransactionEnvelope.base_fee
has been removed. Please useFeeBumpTransactionEnvelope.fee instead
. Note that their meanings are different: (#957)FeeBumpTransactionEnvelope.base_fee
represented the maximum fee you were willing to pay per operation for this transaction.FeeBumpTransactionEnvelope.fee
represents the maximum fee you are willing to pay for this transaction.
- refactor:
TransactionBuilder.from_xdr
previously could returnTransactionBuilder
orFeeBumpTransactionEnvelope
. Now it will no longer returnTransactionBuilder
, but will returnTransactionEnvelope
orFeeBumpTransactionEnvelope
. (#957) - refactor:
helpers.parse_transaction_envelope_from_xdr
has been marked as deprecated. Please use the refactoredTransactionEnvelope.from_xdr
instead. (#957)
Full Changelog: 10.0.0...11.0.0