Skip to content

Commit

Permalink
gas_budget optional on SuiTransaction.get_transaction_data
Browse files Browse the repository at this point in the history
  • Loading branch information
FrankC01 committed Sep 15, 2023
1 parent e2ae437 commit 2e910c1
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ pure vectors (i.e. vector<u8>, etc.)
### Changed

- Bumped dataclasses-json to 0.6.0
- `gas_budget` now optional on `SuiTransaction.get_transaction_data`

### Removed

Expand Down
8 changes: 7 additions & 1 deletion pysui/sui/sui_txn/async_transaction.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,7 +246,13 @@ async def _build_for_execute(
@versionadded(
version="0.17.0", reason="Convenience for serializing and dry-running."
)
async def get_transaction_data(self, *, gas_budget) -> bcs.TransactionData:
@versionchanged(
version="0.35.1",
reason="gas_budget is optional.",
)
async def get_transaction_data(
self, *, gas_budget: Optional[str] = None
) -> bcs.TransactionData:
"""Returns the BCS TransactionKind."""
return await self._build_for_execute(gas_budget)

Expand Down
8 changes: 7 additions & 1 deletion pysui/sui/sui_txn/sync_transaction.py
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,13 @@ def _build_for_execute(
@versionadded(
version="0.17.0", reason="Convenience for serializing and dry-running."
)
def get_transaction_data(self, *, gas_budget) -> bcs.TransactionData:
@versionchanged(
version="0.35.1",
reason="gas_budget is optional.",
)
def get_transaction_data(
self, *, gas_budget: Optional[str] = None
) -> bcs.TransactionData:
"""Returns the BCS TransactionKind."""
return self._build_for_execute(gas_budget)

Expand Down

0 comments on commit 2e910c1

Please sign in to comment.