From b4f8d2f0c7ca647f6769de0ec5d53d468c3ca2f2 Mon Sep 17 00:00:00 2001 From: Tejas Polakam Date: Wed, 30 Sep 2026 16:05:13 -0400 Subject: [PATCH] refactor(explorer): drop the trajectory-manifest download, which only the hosted hub serves The runs table's "Downloads" column held one button that fetched GET /tasks/{id}/runs/{run_group_id}/trajectory-manifest, a JSON of presigned S3 URLs that only Scale's hosted hub serves. The explorer has no such route, so the button always failed. The column, the button and its icon import are removed, and its width goes to Model, Status and Score. Co-Authored-By: Claude Opus 5.5 --- .../ui/src/components/task-detail-page.tsx | 120 +----------------- 1 file changed, 7 insertions(+), 113 deletions(-) diff --git a/src/agent_env/explorer/ui/src/components/task-detail-page.tsx b/src/agent_env/explorer/ui/src/components/task-detail-page.tsx index c3becde0..b64f43e1 100644 --- a/src/agent_env/explorer/ui/src/components/task-detail-page.tsx +++ b/src/agent_env/explorer/ui/src/components/task-detail-page.tsx @@ -11,7 +11,6 @@ import { ChevronDown, CheckCircle2, XCircle, - Download, Loader2, RefreshCw, X, @@ -241,91 +240,6 @@ interface RunGroupSummary { }>; } -/** Per-row button: fetches a run group's trajectory manifest (JSON of presigned URLs, 24h TTL) and - * downloads it. Accepts a runGroupId or an instance_id. */ -function ManifestDownloadButton({ - taskId, - runGroupId, - className, -}: { - taskId: string; - runGroupId: string; - className?: string; -}) { - const [loading, setLoading] = useState(false); - const [error, setError] = useState(null); - const onClick = useCallback(async () => { - setLoading(true); - setError(null); - try { - const res = await apiFetch( - `${BACKEND_URL}/api/v1/tasks/${encodeURIComponent( - taskId, - )}/runs/${encodeURIComponent(runGroupId)}/trajectory-manifest`, - ); - if (!res.ok) { - const detail = await res.text().catch(() => ''); - throw new Error( - `manifest request failed: ${res.status} ${res.statusText}${ - detail ? ` — ${detail.slice(0, 200)}` : '' - }`, - ); - } - const manifest = await res.json(); - const blob = new Blob([JSON.stringify(manifest, null, 2)], { - type: 'application/json', - }); - const blobUrl = URL.createObjectURL(blob); - const a = document.createElement('a'); - a.href = blobUrl; - a.download = `${runGroupId}.trajectory-manifest.json`; - document.body.appendChild(a); - a.click(); - a.remove(); - // Defer revoke so Safari has a chance to fire the download. - setTimeout(() => URL.revokeObjectURL(blobUrl), 1000); - } catch (err) { - console.error(err); - setError(err instanceof Error ? err.message : String(err)); - } finally { - setLoading(false); - } - }, [taskId, runGroupId]); - - return ( - - ); -} - interface InstanceRowProps { taskId: string; inst: Record; @@ -619,16 +533,6 @@ function InstanceRow({ -- )} - - {!isPending && !nested ? ( -
- -
- ) : null} - {!isPending && (