Skip to content

Commit e7a7e67

Browse files
committed
change type of poll interval from int to float
1 parent c9a4c6c commit e7a7e67

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/gradient/_exceptions.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,9 +127,9 @@ class IndexingJobTimeoutError(GradientError):
127127

128128
uuid: str
129129
phase: str
130-
timeout: int
130+
timeout: float
131131

132-
def __init__(self, message: str, *, uuid: str, phase: str, timeout: int) -> None:
132+
def __init__(self, message: str, *, uuid: str, phase: str, timeout: float) -> None:
133133
super().__init__(message)
134134
self.uuid = uuid
135135
self.phase = phase

src/gradient/resources/knowledge_bases/indexing_jobs.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -266,8 +266,8 @@ def wait_for_completion(
266266
self,
267267
uuid: str,
268268
*,
269-
poll_interval: int = 5,
270-
timeout: int | None = None,
269+
poll_interval: float = 5,
270+
timeout: float | None = None,
271271
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
272272
# The extra values given here take precedence over values defined on the client or passed to this method.
273273
extra_headers: Headers | None = None,
@@ -601,8 +601,8 @@ async def wait_for_completion(
601601
self,
602602
uuid: str,
603603
*,
604-
poll_interval: int = 5,
605-
timeout: int | None = None,
604+
poll_interval: float = 5,
605+
timeout: float | None = None,
606606
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
607607
# The extra values given here take precedence over values defined on the client or passed to this method.
608608
extra_headers: Headers | None = None,

0 commit comments

Comments
 (0)