Skip to content

Commit 03a6250

Browse files
committed
fix: Add Latest Change
Signed-off-by: aceppaluni <aceppaluni@gmail.com>
1 parent e32346b commit 03a6250

2 files changed

Lines changed: 4 additions & 0 deletions

File tree

src/hiero_sdk_python/query/fee_estimate_query.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,8 @@ def __init__(self) -> None:
5656

5757
def set_mode(self, mode: FeeEstimateMode) -> FeeEstimateQuery:
5858
"""Set the estimation mode (STATE or INTRINSIC)."""
59+
if not isinstance(mode, FeeEstimateMode):
60+
raise TypeError("mode must be a FeeEstimateMode")
5961
self._mode = mode
6062
return self
6163

tests/unit/fee_estimate_query_test.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,8 @@ def test_invalid_argument_error(mock_post):
178178
with pytest.raises(RuntimeError):
179179
FeeEstimateQuery().set_transaction(tx).execute(mock_client())
180180

181+
assert mock_post.call_count == 1, "HTTP 400 (INVALID_ARGUMENT) must not be retried"
182+
181183

182184
@patch("hiero_sdk_python.query.fee_estimate_query.requests.post")
183185
def test_retry_on_timeout(mock_post):

0 commit comments

Comments
 (0)