smooth-py 0.2.1.dev20250911__py3-none-any.whl → 0.2.1.post0.dev20250911__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of smooth-py might be problematic. Click here for more details.
- smooth/__init__.py +17 -13
- {smooth_py-0.2.1.dev20250911.dist-info → smooth_py-0.2.1.post0.dev20250911.dist-info}/METADATA +1 -1
- smooth_py-0.2.1.post0.dev20250911.dist-info/RECORD +6 -0
- smooth_py-0.2.1.dev20250911.dist-info/RECORD +0 -6
- {smooth_py-0.2.1.dev20250911.dist-info → smooth_py-0.2.1.post0.dev20250911.dist-info}/WHEEL +0 -0
smooth/__init__.py
CHANGED
|
@@ -210,12 +210,12 @@ class TaskHandle:
|
|
|
210
210
|
|
|
211
211
|
start_time = time.time()
|
|
212
212
|
while timeout is None or (time.time() - start_time) < timeout:
|
|
213
|
-
task_response = self._client._get_task(self.id)
|
|
213
|
+
task_response = self._client._get_task(self.id())
|
|
214
214
|
self._task_response = task_response
|
|
215
215
|
if task_response.status not in ["running", "waiting"]:
|
|
216
216
|
return task_response
|
|
217
217
|
time.sleep(poll_interval)
|
|
218
|
-
raise TimeoutError(f"Task {self.id} did not complete within {timeout} seconds.")
|
|
218
|
+
raise TimeoutError(f"Task {self.id()} did not complete within {timeout} seconds.")
|
|
219
219
|
|
|
220
220
|
def live_url(self, interactive: bool = True, embed: bool = False, timeout: int | None = None):
|
|
221
221
|
"""Returns the live URL for the task."""
|
|
@@ -224,13 +224,13 @@ class TaskHandle:
|
|
|
224
224
|
|
|
225
225
|
start_time = time.time()
|
|
226
226
|
while timeout is None or (time.time() - start_time) < timeout:
|
|
227
|
-
task_response = self._client._get_task(self.id)
|
|
227
|
+
task_response = self._client._get_task(self.id())
|
|
228
228
|
self._task_response = task_response
|
|
229
229
|
if self._task_response.live_url:
|
|
230
230
|
return _encode_url(self._task_response.live_url, interactive=interactive, embed=embed)
|
|
231
231
|
time.sleep(1)
|
|
232
232
|
|
|
233
|
-
raise TimeoutError(f"Live URL not available for task {self.id}.")
|
|
233
|
+
raise TimeoutError(f"Live URL not available for task {self.id()}.")
|
|
234
234
|
|
|
235
235
|
def recording_url(self, timeout: int | None = None) -> str:
|
|
236
236
|
"""Returns the recording URL for the task."""
|
|
@@ -239,12 +239,12 @@ class TaskHandle:
|
|
|
239
239
|
|
|
240
240
|
start_time = time.time()
|
|
241
241
|
while timeout is None or (time.time() - start_time) < timeout:
|
|
242
|
-
task_response = self._client._get_task(self.id)
|
|
242
|
+
task_response = self._client._get_task(self.id())
|
|
243
243
|
self._task_response = task_response
|
|
244
244
|
if task_response.recording_url is not None:
|
|
245
245
|
return task_response.recording_url
|
|
246
246
|
time.sleep(1)
|
|
247
|
-
raise TimeoutError(f"Recording URL not available for task {self.id}.")
|
|
247
|
+
raise TimeoutError(f"Recording URL not available for task {self.id()}.")
|
|
248
248
|
|
|
249
249
|
|
|
250
250
|
class SmoothClient(BaseClient):
|
|
@@ -415,7 +415,11 @@ class AsyncTaskHandle:
|
|
|
415
415
|
self._client = client
|
|
416
416
|
self._task_response: TaskResponse | None = None
|
|
417
417
|
|
|
418
|
-
self.
|
|
418
|
+
self._id = task_id
|
|
419
|
+
|
|
420
|
+
def id(self):
|
|
421
|
+
"""Returns the task ID."""
|
|
422
|
+
return self._id
|
|
419
423
|
|
|
420
424
|
async def result(self, timeout: int | None = None, poll_interval: float = 1) -> TaskResponse:
|
|
421
425
|
"""Waits for the task to complete and returns the result."""
|
|
@@ -429,12 +433,12 @@ class AsyncTaskHandle:
|
|
|
429
433
|
|
|
430
434
|
start_time = time.time()
|
|
431
435
|
while timeout is None or (time.time() - start_time) < timeout:
|
|
432
|
-
task_response = await self._client._get_task(self.id)
|
|
436
|
+
task_response = await self._client._get_task(self.id())
|
|
433
437
|
self._task_response = task_response
|
|
434
438
|
if task_response.status not in ["running", "waiting"]:
|
|
435
439
|
return task_response
|
|
436
440
|
await asyncio.sleep(poll_interval)
|
|
437
|
-
raise TimeoutError(f"Task {self.id} did not complete within {timeout} seconds.")
|
|
441
|
+
raise TimeoutError(f"Task {self.id()} did not complete within {timeout} seconds.")
|
|
438
442
|
|
|
439
443
|
async def live_url(self, interactive: bool = True, embed: bool = False, timeout: int | None = None):
|
|
440
444
|
"""Returns the live URL for the task."""
|
|
@@ -443,13 +447,13 @@ class AsyncTaskHandle:
|
|
|
443
447
|
|
|
444
448
|
start_time = time.time()
|
|
445
449
|
while timeout is None or (time.time() - start_time) < timeout:
|
|
446
|
-
task_response = await self._client._get_task(self.id)
|
|
450
|
+
task_response = await self._client._get_task(self.id())
|
|
447
451
|
self._task_response = task_response
|
|
448
452
|
if task_response.live_url is not None:
|
|
449
453
|
return _encode_url(self._task_response.live_url, interactive=interactive, embed=embed)
|
|
450
454
|
await asyncio.sleep(1)
|
|
451
455
|
|
|
452
|
-
raise TimeoutError(f"Live URL not available for task {self.id}.")
|
|
456
|
+
raise TimeoutError(f"Live URL not available for task {self.id()}.")
|
|
453
457
|
|
|
454
458
|
async def recording_url(self, timeout: int | None = None):
|
|
455
459
|
"""Returns the recording URL for the task."""
|
|
@@ -458,13 +462,13 @@ class AsyncTaskHandle:
|
|
|
458
462
|
|
|
459
463
|
start_time = time.time()
|
|
460
464
|
while timeout is None or (time.time() - start_time) < timeout:
|
|
461
|
-
task_response = await self._client._get_task(self.id)
|
|
465
|
+
task_response = await self._client._get_task(self.id())
|
|
462
466
|
self._task_response = task_response
|
|
463
467
|
if task_response.recording_url is not None:
|
|
464
468
|
return task_response.recording_url
|
|
465
469
|
await asyncio.sleep(1)
|
|
466
470
|
|
|
467
|
-
raise TimeoutError(f"Recording URL not available for task {self.id}.")
|
|
471
|
+
raise TimeoutError(f"Recording URL not available for task {self.id()}.")
|
|
468
472
|
|
|
469
473
|
|
|
470
474
|
class SmoothAsyncClient(BaseClient):
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
smooth/__init__.py,sha256=ONEEpCPFOF9caI1IddSxP_v_MPPs8ovFLyQ6oFCERJE,24412
|
|
2
|
+
smooth/mcp/__init__.py,sha256=0aJVFi2a8Ah3-5xtgyZ5UMbaaJsBWu2T8QLWoFQITk8,219
|
|
3
|
+
smooth/mcp/server.py,sha256=9SymTD4NOGTMN8P-LNGlvYNvv81yCIZfZeeuhEcAc6s,20068
|
|
4
|
+
smooth_py-0.2.1.post0.dev20250911.dist-info/METADATA,sha256=xfoJG8Y7ovk0JDA3IcZW1DZpKWvExzSXcQ8nksFqZxA,7443
|
|
5
|
+
smooth_py-0.2.1.post0.dev20250911.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
|
|
6
|
+
smooth_py-0.2.1.post0.dev20250911.dist-info/RECORD,,
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
smooth/__init__.py,sha256=L-qnxbgkS40esgcEo9-laRGAzsCoK8W6-5EyS0lFRDU,24559
|
|
2
|
-
smooth/mcp/__init__.py,sha256=0aJVFi2a8Ah3-5xtgyZ5UMbaaJsBWu2T8QLWoFQITk8,219
|
|
3
|
-
smooth/mcp/server.py,sha256=9SymTD4NOGTMN8P-LNGlvYNvv81yCIZfZeeuhEcAc6s,20068
|
|
4
|
-
smooth_py-0.2.1.dev20250911.dist-info/METADATA,sha256=ApjDoqXRckaSUQPYrpfNzJcp17QZ5dbzCnkPsNqwfHY,7437
|
|
5
|
-
smooth_py-0.2.1.dev20250911.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
|
|
6
|
-
smooth_py-0.2.1.dev20250911.dist-info/RECORD,,
|
|
File without changes
|