hte-cli 0.2.1__tar.gz → 0.2.3__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.
- {hte_cli-0.2.1 → hte_cli-0.2.3}/PKG-INFO +1 -1
- {hte_cli-0.2.1 → hte_cli-0.2.3}/pyproject.toml +1 -1
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/cli.py +54 -17
- {hte_cli-0.2.1 → hte_cli-0.2.3}/.gitignore +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/README.md +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/__init__.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/__main__.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/api_client.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/config.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/errors.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/events.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/image_utils.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/runner.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/scorers.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/src/hte_cli/version_check.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/__init__.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/e2e/__init__.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/e2e/automated_runner.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/e2e/conftest.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/e2e/e2e_test.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/e2e/test_benchmark_flows.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/e2e/test_eval_logs.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/e2e/test_infrastructure.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/e2e/test_runtime_imports.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/e2e/test_session_lifecycle.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/tests/e2e/verify_docker_deps.py +0 -0
- {hte_cli-0.2.1 → hte_cli-0.2.3}/uv.lock +0 -0
|
@@ -281,26 +281,63 @@ def session_join(ctx, session_id: str, force_setup: bool):
|
|
|
281
281
|
|
|
282
282
|
# Step 3: Run setup (skip if reconnecting without force)
|
|
283
283
|
setup_start_time = time.monotonic()
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
284
|
+
images = []
|
|
285
|
+
pulled_images = []
|
|
286
|
+
cached_images = []
|
|
287
|
+
failed_images = []
|
|
287
288
|
|
|
288
|
-
|
|
289
|
+
if not is_reconnect or force_setup:
|
|
290
|
+
# Extract images from compose
|
|
289
291
|
if compose_yaml:
|
|
290
292
|
images = extract_images_from_compose(compose_yaml)
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
293
|
+
|
|
294
|
+
# Send setup_started event
|
|
295
|
+
events.setup_started(images=images)
|
|
296
|
+
|
|
297
|
+
# Pull images if we have any
|
|
298
|
+
if images:
|
|
299
|
+
from hte_cli.image_utils import check_image_exists_locally
|
|
300
|
+
|
|
301
|
+
console.print(f"[bold]Pulling {len(images)} Docker image(s)...[/bold]")
|
|
302
|
+
pull_start = time.monotonic()
|
|
303
|
+
|
|
304
|
+
for img in images:
|
|
305
|
+
short_name = img.split("/")[-1][:40]
|
|
306
|
+
|
|
307
|
+
# Check if already cached
|
|
308
|
+
if check_image_exists_locally(img):
|
|
309
|
+
console.print(f" [green]✓[/green] {short_name} [dim](cached)[/dim]")
|
|
310
|
+
cached_images.append(img)
|
|
311
|
+
continue
|
|
312
|
+
|
|
313
|
+
# Need to pull - show progress
|
|
314
|
+
with console.status(f"[yellow]↓[/yellow] {short_name} [dim]connecting...[/dim]") as status:
|
|
315
|
+
def show_progress(image: str, line: str):
|
|
316
|
+
# Parse docker pull output for layer progress
|
|
317
|
+
# Lines look like: "abc123: Downloading [====> ] 10MB/50MB"
|
|
318
|
+
if ": " in line:
|
|
319
|
+
parts = line.split(": ", 1)
|
|
320
|
+
if len(parts) == 2:
|
|
321
|
+
layer_status = parts[1][:50] # Truncate
|
|
322
|
+
status.update(f"[yellow]↓[/yellow] {short_name} [dim]{layer_status}[/dim]")
|
|
323
|
+
|
|
324
|
+
success = pull_image_with_progress(img, on_progress=show_progress)
|
|
325
|
+
|
|
326
|
+
if success:
|
|
327
|
+
console.print(f" [green]✓[/green] {short_name} [dim](downloaded)[/dim]")
|
|
328
|
+
pulled_images.append(img)
|
|
329
|
+
else:
|
|
330
|
+
console.print(f" [red]✗[/red] {short_name} [dim](failed)[/dim]")
|
|
331
|
+
failed_images.append(img)
|
|
332
|
+
|
|
333
|
+
pull_duration = time.monotonic() - pull_start
|
|
334
|
+
events.image_pull_completed(
|
|
335
|
+
duration_seconds=pull_duration,
|
|
336
|
+
pulled=pulled_images,
|
|
337
|
+
cached=cached_images,
|
|
338
|
+
failed=failed_images,
|
|
339
|
+
)
|
|
340
|
+
console.print()
|
|
304
341
|
|
|
305
342
|
# Send setup_completed - THIS STARTS THE TIMER ON SERVER
|
|
306
343
|
total_setup = time.monotonic() - setup_start_time
|
|
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
|