podstack 1.3.5__tar.gz → 1.3.7__tar.gz
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.
- {podstack-1.3.5 → podstack-1.3.7}/PKG-INFO +1 -1
- {podstack-1.3.5 → podstack-1.3.7}/podstack/gpu_runner.py +18 -7
- {podstack-1.3.5 → podstack-1.3.7}/podstack.egg-info/PKG-INFO +1 -1
- {podstack-1.3.5 → podstack-1.3.7}/pyproject.toml +1 -1
- {podstack-1.3.5 → podstack-1.3.7}/LICENSE +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/README.md +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/__init__.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/annotations.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/client.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/exceptions.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/execution.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/models.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/notebook.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/registry/__init__.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/registry/client.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/registry/exceptions.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/registry/experiment.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/registry/model.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack/registry/model_utils.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack.egg-info/SOURCES.txt +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack.egg-info/dependency_links.txt +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack.egg-info/requires.txt +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack.egg-info/top_level.txt +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack_gpu/__init__.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack_gpu/app.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack_gpu/exceptions.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack_gpu/image.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack_gpu/runner.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack_gpu/secret.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack_gpu/utils.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/podstack_gpu/volume.py +0 -0
- {podstack-1.3.5 → podstack-1.3.7}/setup.cfg +0 -0
|
@@ -205,10 +205,17 @@ class GPUExecutionResult:
|
|
|
205
205
|
|
|
206
206
|
@classmethod
|
|
207
207
|
def from_dict(cls, data: Dict[str, Any]) -> "GPUExecutionResult":
|
|
208
|
+
# The result API returns output as []ExecutionOutputResponse objects.
|
|
209
|
+
# Join their content fields into a single string.
|
|
210
|
+
raw_output = data.get("output", "")
|
|
211
|
+
if isinstance(raw_output, list):
|
|
212
|
+
output = "".join(item.get("content", "") for item in raw_output if item.get("content"))
|
|
213
|
+
else:
|
|
214
|
+
output = raw_output or ""
|
|
208
215
|
return cls(
|
|
209
216
|
execution_id=data.get("execution_id", ""),
|
|
210
217
|
status=data.get("status", "unknown"),
|
|
211
|
-
output=
|
|
218
|
+
output=output,
|
|
212
219
|
error=data.get("error"),
|
|
213
220
|
gpu_seconds=data.get("gpu_seconds", 0.0),
|
|
214
221
|
cost_paise=data.get("cost_cents", data.get("cost_paise", data.get("actual_cost_paise", 0))),
|
|
@@ -437,7 +444,8 @@ def _stream_install(cmd, description):
|
|
|
437
444
|
# Install pip packages using uv (faster)
|
|
438
445
|
_pip_packages = {repr(pip_list)}
|
|
439
446
|
_stream_install(
|
|
440
|
-
["uv", "pip", "install", "--system", "--progress"
|
|
447
|
+
["uv", "pip", "install", "--system", "--progress",
|
|
448
|
+
"--extra-index-url", "https://pypi.org/simple/"] + _pip_packages,
|
|
441
449
|
f"Installing pip packages with uv: {{' '.join(_pip_packages)}}"
|
|
442
450
|
)
|
|
443
451
|
''')
|
|
@@ -446,7 +454,8 @@ _stream_install(
|
|
|
446
454
|
# Install pip packages
|
|
447
455
|
_pip_packages = {repr(pip_list)}
|
|
448
456
|
_stream_install(
|
|
449
|
-
[sys.executable, "-m", "pip", "install", "--progress-bar", "on"
|
|
457
|
+
[sys.executable, "-m", "pip", "install", "--progress-bar", "on",
|
|
458
|
+
"--extra-index-url", "https://pypi.org/simple/"] + _pip_packages,
|
|
450
459
|
f"Installing pip packages: {{' '.join(_pip_packages)}}"
|
|
451
460
|
)
|
|
452
461
|
''')
|
|
@@ -812,10 +821,12 @@ _stream_install(
|
|
|
812
821
|
raise ConnectionError(f"Failed to get result after {max_retries} attempts: {e}")
|
|
813
822
|
time.sleep(2 * (attempt + 1))
|
|
814
823
|
|
|
815
|
-
#
|
|
816
|
-
#
|
|
817
|
-
|
|
818
|
-
|
|
824
|
+
# If the API result's output doesn't have the result marker but the
|
|
825
|
+
# streaming buffer does (e.g. race between completed status and last
|
|
826
|
+
# stdout event), use the streaming buffer instead.
|
|
827
|
+
streamed = "".join(output_buffer)
|
|
828
|
+
if "__PODSTACK_RESULT__" not in result.output and "__PODSTACK_RESULT__" in streamed:
|
|
829
|
+
result.output = streamed
|
|
819
830
|
|
|
820
831
|
if result.success:
|
|
821
832
|
print(f"\n[Podstack] Completed in {result.gpu_seconds:.1f}s (cost: ₹{result.cost_paise/100:.2f})")
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|