From 6bacf198a0afe52bbc45edc7290331b38967eb80 Mon Sep 17 00:00:00 2001 From: Brord van Wierst Date: Mon, 11 Dec 2023 17:37:34 +0100 Subject: [PATCH] added protocol params to sign --- bindings/python/iota_sdk/secret_manager/secret_manager.py | 7 +++++-- bindings/python/iota_sdk/types/balance.py | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/bindings/python/iota_sdk/secret_manager/secret_manager.py b/bindings/python/iota_sdk/secret_manager/secret_manager.py index 54eced05ad..6ba6d35e3c 100644 --- a/bindings/python/iota_sdk/secret_manager/secret_manager.py +++ b/bindings/python/iota_sdk/secret_manager/secret_manager.py @@ -8,6 +8,7 @@ from iota_sdk.external import create_secret_manager, call_secret_manager_method from iota_sdk.types.block.signed_block import SignedBlock, UnsignedBlock from iota_sdk.types.common import HexStr +from iota_sdk.types.node_info import ProtocolParameters from iota_sdk.types.signature import Ed25519Signature, Bip44 from iota_sdk.types.transaction_data import PreparedTransactionData from iota_sdk.types.payload import SignedTransactionPayload @@ -268,14 +269,16 @@ def sign_secp256k1_ecdsa(self, message: HexStr, chain: Bip44): }) def sign_transaction( - self, prepared_transaction_data: PreparedTransactionData) -> SignedTransactionPayload: + self, prepared_transaction_data: PreparedTransactionData, protocol_parameters: ProtocolParameters) -> SignedTransactionPayload: """Sign a transaction. Args: prepare_transaction_data: The prepared transaction data that needs to be signed. + protocol_parameters: The protocol parameters used in creating the signed transaction. """ return SignedTransactionPayload.from_dict(self._call_method('signTransaction', { - 'preparedTransactionData': prepared_transaction_data.to_dict() + 'preparedTransactionData': prepared_transaction_data.to_dict(), + 'protocolParameters': protocol_parameters })) def sign_block( diff --git a/bindings/python/iota_sdk/types/balance.py b/bindings/python/iota_sdk/types/balance.py index 27785e4155..c13f0f1466 100644 --- a/bindings/python/iota_sdk/types/balance.py +++ b/bindings/python/iota_sdk/types/balance.py @@ -28,7 +28,7 @@ class BaseCoinBalance: @json @dataclass class RequiredStorageDeposit: - """Required storage deposit for the outputs in the account. + """Required storage deposit for the outputs in the wallet. Attributes: basic: The required amount for basic outputs.