Skip to content

Commit c1fd895

Browse files
committed
fix gasPrice for smart contract interactions
1 parent 995d0ee commit c1fd895

2 files changed

Lines changed: 9 additions & 0 deletions

File tree

multiversx_sdk_cli/cli_contracts.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -373,6 +373,7 @@ def deploy(args: Any):
373373
payable=args.metadata_payable,
374374
payable_by_sc=args.metadata_payable_by_sc,
375375
gas_limit=int(args.gas_limit),
376+
gas_price=int(args.gas_price),
376377
value=int(args.value),
377378
nonce=sender.nonce,
378379
version=int(args.version),
@@ -419,6 +420,7 @@ def call(args: Any):
419420
arguments=arguments,
420421
should_prepare_args=should_prepare_args,
421422
gas_limit=int(args.gas_limit),
423+
gas_price=int(args.gas_price),
422424
value=int(args.value),
423425
transfers=args.token_transfers,
424426
nonce=sender.nonce,
@@ -464,6 +466,7 @@ def upgrade(args: Any):
464466
payable=args.metadata_payable,
465467
payable_by_sc=args.metadata_payable_by_sc,
466468
gas_limit=int(args.gas_limit),
469+
gas_price=int(args.gas_price),
467470
value=int(args.value),
468471
nonce=sender.nonce,
469472
version=int(args.version),

multiversx_sdk_cli/contracts.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ def prepare_deploy_transaction(
7070
payable: bool,
7171
payable_by_sc: bool,
7272
gas_limit: int,
73+
gas_price: int,
7374
value: int,
7475
nonce: int,
7576
version: int,
@@ -94,6 +95,7 @@ def prepare_deploy_transaction(
9495
tx.nonce = nonce
9596
tx.version = version
9697
tx.options = options
98+
tx.gas_price = gas_price
9799
tx.guardian = guardian_and_relayer_data.guardian_address
98100
tx.relayer = guardian_and_relayer_data.relayer_address
99101

@@ -116,6 +118,7 @@ def prepare_execute_transaction(
116118
arguments: Union[list[Any], None],
117119
should_prepare_args: bool,
118120
gas_limit: int,
121+
gas_price: int,
119122
value: int,
120123
transfers: Union[list[str], None],
121124
nonce: int,
@@ -141,6 +144,7 @@ def prepare_execute_transaction(
141144
tx.nonce = nonce
142145
tx.version = version
143146
tx.options = options
147+
tx.gas_price = gas_price
144148
tx.guardian = guardian_and_relayer_data.guardian_address
145149
tx.relayer = guardian_and_relayer_data.relayer_address
146150

@@ -167,6 +171,7 @@ def prepare_upgrade_transaction(
167171
payable: bool,
168172
payable_by_sc: bool,
169173
gas_limit: int,
174+
gas_price: int,
170175
value: int,
171176
nonce: int,
172177
version: int,
@@ -192,6 +197,7 @@ def prepare_upgrade_transaction(
192197
tx.nonce = nonce
193198
tx.version = version
194199
tx.options = options
200+
tx.gas_price = gas_price
195201
tx.guardian = guardian_and_relayer_data.guardian_address
196202
tx.relayer = guardian_and_relayer_data.relayer_address
197203

0 commit comments

Comments
 (0)