diff --git a/multiversx_sdk/core/address.py b/multiversx_sdk/core/address.py index 5c9d635c..f95979da 100644 --- a/multiversx_sdk/core/address.py +++ b/multiversx_sdk/core/address.py @@ -168,10 +168,8 @@ def compute_contract_address(self, deployer: Address, deployment_nonce: int) -> deployer_pubkey = deployer.get_public_key() nonce_bytes = deployment_nonce.to_bytes(8, byteorder="little") bytes_to_hash = deployer_pubkey + nonce_bytes - contract_pubkey = keccak.new( - digest_bits=256).update(bytes_to_hash).digest() - contract_pubkey = bytes([0] * 8) + bytes([5, 0]) + \ - contract_pubkey[10:30] + deployer_pubkey[30:] + contract_pubkey = keccak.new(digest_bits=256).update(bytes_to_hash).digest() + contract_pubkey = bytes([0] * 8) + bytes([5, 0]) + contract_pubkey[10:30] + deployer_pubkey[30:] return Address(contract_pubkey, deployer.get_hrp()) def get_shard_of_address(self, address: Address) -> int: diff --git a/multiversx_sdk/entrypoints/entrypoints_test.py b/multiversx_sdk/entrypoints/entrypoints_test.py index fa4b0b02..2b6697dd 100644 --- a/multiversx_sdk/entrypoints/entrypoints_test.py +++ b/multiversx_sdk/entrypoints/entrypoints_test.py @@ -1,4 +1,3 @@ -import time from pathlib import Path import pytest diff --git a/multiversx_sdk/network_providers/http_resources.py b/multiversx_sdk/network_providers/http_resources.py index eb230a6d..6e324d2a 100644 --- a/multiversx_sdk/network_providers/http_resources.py +++ b/multiversx_sdk/network_providers/http_resources.py @@ -35,12 +35,9 @@ def smart_contract_query_to_vm_query_request(query: SmartContractQuery) -> dict[ def vm_query_response_to_smart_contract_query_response( raw_response: dict[str, Any], function: str) -> SmartContractQueryResponse: - return_data = raw_response.get( - "returnData", []) or raw_response.get("ReturnData", []) - return_code = raw_response.get( - "returnCode", "") or raw_response.get("ReturnCode", "") - return_message = raw_response.get( - "returnMessage", "") or raw_response.get("ReturnMessage", "") + return_data = raw_response.get("returnData", []) or raw_response.get("ReturnData", []) + return_code = raw_response.get("returnCode", "") or raw_response.get("ReturnCode", "") + return_message = raw_response.get("returnMessage", "") or raw_response.get("ReturnMessage", "") return SmartContractQueryResponse( function=function, @@ -74,8 +71,7 @@ def transaction_from_api_response(tx_hash: str, response: dict[str, Any]) -> Tra logs = transaction_logs_from_response(response.get("logs", {})) sc_results = response.get("results", []) - smart_contract_results = [smart_contract_result_from_api_response( - result) for result in sc_results] + smart_contract_results = [smart_contract_result_from_api_response(result) for result in sc_results] return TransactionOnNetwork( raw=response, @@ -130,8 +126,7 @@ def transaction_from_proxy_response( logs = transaction_logs_from_response(response.get("logs", {})) sc_results = response.get("smartContractResults", []) - smart_contract_results = [smart_contract_result_from_proxy_response( - result) for result in sc_results] + smart_contract_results = [smart_contract_result_from_proxy_response(result) for result in sc_results] if process_status: status = process_status @@ -293,8 +288,7 @@ def network_config_from_response(raw_response: dict[str, Any]) -> NetworkConfig: gas_price_modifier = float(raw_response.get("erd_gas_price_modifier", 0)) min_gas_limit = raw_response.get("erd_min_gas_limit", 0) min_gas_price = raw_response.get("erd_min_gas_price", 0) - extra_gas_limit_guarded_tx = raw_response.get( - "erd_extra_gas_limit_guarded_tx", 0) + extra_gas_limit_guarded_tx = raw_response.get("erd_extra_gas_limit_guarded_tx", 0) num_shards = raw_response.get("erd_num_shards_without_meta", 0) round_duration = raw_response.get("erd_round_duration", 0) rounds_per_epoch = raw_response.get("erd_rounds_per_epoch", 0) @@ -336,8 +330,7 @@ def block_from_response(raw_response: dict[str, Any]) -> BlockOnNetwork: shard = raw_response.get("shard", 0) nonce = raw_response.get("nonce", 0) hash = raw_response.get("hash", "") - previous_hash = raw_response.get( - "prevBlockHash", "") or raw_response.get("prevHash", "") + previous_hash = raw_response.get("prevBlockHash", "") or raw_response.get("prevHash", "") timestamp = raw_response.get("timestamp", 0) round = raw_response.get("round", 0) epoch = raw_response.get("epoch", 0) @@ -429,8 +422,7 @@ def account_from_api_response(raw_response: dict[str, Any]) -> AccountOnNetwork: is_upgradeable = bool(raw_response.get("isUpgradeable", False)) is_readable = bool(raw_response.get("isReadable", False)) is_payable = bool(raw_response.get("isPayable", False)) - is_payable_by_sc = bool(raw_response.get( - "isPayableBySmartContract", False)) + is_payable_by_sc = bool(raw_response.get("isPayableBySmartContract", False)) return AccountOnNetwork( raw=raw_response, diff --git a/multiversx_sdk/smart_contracts/smart_contract_transactions_outcome_parser_test.py b/multiversx_sdk/smart_contracts/smart_contract_transactions_outcome_parser_test.py index 7024e7ce..7644e027 100644 --- a/multiversx_sdk/smart_contracts/smart_contract_transactions_outcome_parser_test.py +++ b/multiversx_sdk/smart_contracts/smart_contract_transactions_outcome_parser_test.py @@ -5,7 +5,6 @@ from multiversx_sdk.abi.abi import Abi from multiversx_sdk.core.address import Address -from multiversx_sdk.core.codec import encode_unsigned_number from multiversx_sdk.core.transaction_on_network import (SmartContractResult, TransactionEvent, TransactionLogs) diff --git a/multiversx_sdk/token_management/token_management_controller.py b/multiversx_sdk/token_management/token_management_controller.py index 81a9d7c7..41857eb8 100644 --- a/multiversx_sdk/token_management/token_management_controller.py +++ b/multiversx_sdk/token_management/token_management_controller.py @@ -25,8 +25,7 @@ def await_transaction_completed(self, transaction_hash: Union[str, bytes], optio class TokenManagementController: def __init__(self, chain_id: str, network_provider: INetworkProvider) -> None: - self.factory = TokenManagementTransactionsFactory( - TransactionsFactoryConfig(chain_id)) + self.factory = TokenManagementTransactionsFactory(TransactionsFactoryConfig(chain_id)) self.network_provider = network_provider self.tx_computer = TransactionComputer() self.parser = TokenManagementTransactionsOutcomeParser() @@ -63,8 +62,7 @@ def create_transaction_for_issuing_fungible(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -106,8 +104,7 @@ def create_transaction_for_issuing_semi_fungible(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -116,8 +113,7 @@ def parse_issue_semi_fungible(self, transaction_on_network: TransactionOnNetwork def await_completed_issue_semi_fungible( self, transaction_hash: Union[str, bytes]) -> list[IssueSemiFungibleOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_issue_semi_fungible(transaction) def create_transaction_for_issuing_non_fungible(self, @@ -159,8 +155,7 @@ def parse_issue_non_fungible(self, transaction_on_network: TransactionOnNetwork) return self.parser.parse_issue_non_fungible(transaction_on_network) def await_completed_issue_non_fungible(self, transaction_hash: Union[str, bytes]) -> list[IssueNonFungibleOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_issue_non_fungible(transaction) def create_transaction_for_registering_meta_esdt(self, @@ -195,8 +190,7 @@ def create_transaction_for_registering_meta_esdt(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -228,8 +222,7 @@ def create_transaction_for_registering_and_setting_roles(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -237,8 +230,7 @@ def parse_register_and_set_all_roles(self, transaction_on_network: TransactionOn return self.parser.parse_register_and_set_all_roles(transaction_on_network) def await_completed_register_and_set_all_roles(self, transaction_hash: Union[str, bytes]) -> list[RegisterAndSetAllRolesOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_register_and_set_all_roles(transaction) def create_transaction_for_setting_burn_role_globally(self, @@ -255,8 +247,7 @@ def create_transaction_for_setting_burn_role_globally(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -282,8 +273,7 @@ def create_transaction_for_unsetting_burn_role_globally(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -291,8 +281,7 @@ def parse_unset_burn_role_globally(self, transaction_on_network: TransactionOnNe return self.parser.parse_unset_burn_role_globally(transaction_on_network) def await_completed_unset_burn_role_globally(self, transaction_hash: Union[str, bytes]): - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_unset_burn_role_globally(transaction) def create_transaction_for_setting_special_role_on_fungible_token(self, @@ -317,8 +306,7 @@ def create_transaction_for_setting_special_role_on_fungible_token(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -326,8 +314,7 @@ def parse_set_special_role_on_fungible_token(self, transaction_on_network: Trans return self.parser.parse_set_special_role(transaction_on_network) def await_completed_set_special_role_on_fungible_token(self, transaction_hash: Union[str, bytes]) -> list[SetSpecialRoleOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_set_special_role_on_fungible_token(transaction) def create_transaction_for_setting_special_role_on_semi_fungible_token(self, @@ -354,8 +341,7 @@ def create_transaction_for_setting_special_role_on_semi_fungible_token(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -363,8 +349,7 @@ def parse_set_special_role_on_semi_fungible_token(self, transaction_on_network: return self.parser.parse_set_special_role(transaction_on_network) def await_completed_set_special_role_on_semi_fungible_token(self, transaction_hash: Union[str, bytes]) -> list[SetSpecialRoleOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_set_special_role_on_semi_fungible_token(transaction) def create_transaction_for_setting_special_role_on_non_fungible_token(self, @@ -393,8 +378,7 @@ def create_transaction_for_setting_special_role_on_non_fungible_token(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -402,8 +386,7 @@ def parse_set_special_role_on_non_fungible_token(self, transaction_on_network: T return self.parser.parse_set_special_role(transaction_on_network) def await_completed_set_special_role_on_non_fungible_token(self, transaction_hash: Union[str, bytes]) -> list[SetSpecialRoleOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_set_special_role_on_non_fungible_token(transaction) def create_transaction_for_creating_nft(self, @@ -432,8 +415,7 @@ def create_transaction_for_creating_nft(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -441,8 +423,7 @@ def parse_create_nft(self, transaction_on_network: TransactionOnNetwork) -> list return self.parser.parse_nft_create(transaction_on_network) def await_completed_create_nft(self, transaction_hash: Union[str, bytes]) -> list[NFTCreateOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_create_nft(transaction) def create_transaction_for_pausing(self, @@ -459,8 +440,7 @@ def create_transaction_for_pausing(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -468,8 +448,7 @@ def parse_pause(self, transaction_on_network: TransactionOnNetwork) -> list[Paus return self.parser.parse_pause(transaction_on_network) def await_completed_pause(self, transaction_hash: Union[str, bytes]) -> list[PauseOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_pause(transaction) def create_transaction_for_unpausing(self, @@ -486,8 +465,7 @@ def create_transaction_for_unpausing(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -495,8 +473,7 @@ def parse_unpause(self, transaction_on_network: TransactionOnNetwork) -> list[Un return self.parser.parse_unpause(transaction_on_network) def await_completed_unpause(self, transaction_hash: Union[str, bytes]) -> list[UnPauseOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_unpause(transaction) def create_transaction_for_freezing(self, @@ -515,8 +492,7 @@ def create_transaction_for_freezing(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -524,8 +500,7 @@ def parse_freeze(self, transaction_on_network: TransactionOnNetwork) -> list[Fre return self.parser.parse_freeze(transaction_on_network) def await_completed_freeze(self, transaction_hash: Union[str, bytes]) -> list[FreezeOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_freeze(transaction) def create_transaction_for_unfreezing(self, @@ -544,8 +519,7 @@ def create_transaction_for_unfreezing(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -553,8 +527,7 @@ def parse_unfreeze(self, transaction_on_network: TransactionOnNetwork) -> list[U return self.parser.parse_unfreeze(transaction_on_network) def await_completed_unfreeze(self, transaction_hash: Union[str, bytes]) -> list[UnFreezeOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_unfreeze(transaction) def create_transaction_for_wiping(self, @@ -573,8 +546,7 @@ def create_transaction_for_wiping(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -582,8 +554,7 @@ def parse_wipe(self, transaction_on_network: TransactionOnNetwork) -> list[WipeO return self.parser.parse_wipe(transaction_on_network) def await_completed_wipe(self, transaction_hash: Union[str, bytes]) -> list[WipeOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_wipe(transaction) def create_transaction_for_local_minting(self, @@ -602,8 +573,7 @@ def create_transaction_for_local_minting(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -611,8 +581,7 @@ def parse_local_mint(self, transaction_on_network: TransactionOnNetwork) -> list return self.parser.parse_local_mint(transaction_on_network) def await_completed_local_mint(self, transaction_hash: Union[str, bytes]) -> list[MintOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_local_mint(transaction) def create_transaction_for_local_burning(self, @@ -631,8 +600,7 @@ def create_transaction_for_local_burning(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -640,8 +608,7 @@ def parse_local_burn(self, transaction_on_network: TransactionOnNetwork) -> list return self.parser.parse_local_burn(transaction_on_network) def await_completed_local_burn(self, transaction_hash: Union[str, bytes]) -> list[BurnOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_local_burn(transaction) def create_transaction_for_updating_attributes(self, @@ -662,8 +629,7 @@ def create_transaction_for_updating_attributes(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -671,8 +637,7 @@ def parse_update_attributes(self, transaction_on_network: TransactionOnNetwork) return self.parser.parse_update_attributes(transaction_on_network) def await_completed_update_attributes(self, transaction_hash: Union[str, bytes]) -> list[UpdateAttributesOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_update_attributes(transaction) def create_transaction_for_adding_quantity(self, @@ -693,8 +658,7 @@ def create_transaction_for_adding_quantity(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -702,8 +666,7 @@ def parse_add_quantity(self, transaction_on_network: TransactionOnNetwork) -> li return self.parser.parse_add_quantity(transaction_on_network) def await_completed_add_quantity(self, transaction_hash: Union[str, bytes]) -> list[AddQuantityOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_add_quantity(transaction) def create_transaction_for_burning_quantity(self, @@ -724,8 +687,7 @@ def create_transaction_for_burning_quantity(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -733,8 +695,7 @@ def parse_burn_quantity(self, transaction_on_network: TransactionOnNetwork) -> l return self.parser.parse_burn_quantity(transaction_on_network) def await_completed_burn_quantity(self, transaction_hash: Union[str, bytes]) -> list[BurnQuantityOutcome]: - transaction = self.network_provider.await_transaction_completed( - transaction_hash) + transaction = self.network_provider.await_transaction_completed(transaction_hash) return self.parse_burn_quantity(transaction) def create_transaction_for_transferring_ownership(self, @@ -753,8 +714,7 @@ def create_transaction_for_transferring_ownership(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -776,8 +736,7 @@ def create_transaction_for_freezing_single_nft(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -799,8 +758,7 @@ def create_transaction_for_unfreezing_single_nft(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -820,8 +778,7 @@ def create_transaction_for_changing_sft_to_meta_esdt(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -841,8 +798,7 @@ def create_transaction_for_transferring_nft_create_role(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -860,8 +816,7 @@ def create_transaction_for_stopping_nft_creation(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -883,8 +838,7 @@ def create_transaction_for_wiping_single_nft(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) return transaction @@ -904,7 +858,6 @@ def create_transction_for_adding_uris(self, transaction.guardian = guardian transaction.relayer = relayer transaction.nonce = nonce - transaction.signature = sender.sign( - self.tx_computer.compute_bytes_for_signing(transaction)) + transaction.signature = sender.sign(self.tx_computer.compute_bytes_for_signing(transaction)) - return transaction + return transaction \ No newline at end of file