@tangle-network/sandbox 1.0.208 → 1.0.210
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.
- package/README.md +1 -1
- package/dist/abort-signal-BbJTt2QJ.js +31 -0
- package/dist/agent/index.d.ts +4 -4
- package/dist/agent/index.js +4 -4
- package/dist/agent/preview.d.ts +1 -1
- package/dist/agent/preview.js +1 -1
- package/dist/{agent-run-outcome-1NHcTtoo.d.ts → agent-run-outcome-CP2N40aT.d.ts} +1 -1
- package/dist/api-request-CUIrVFhJ.js +173 -0
- package/dist/{browser-interactive-control-controller-BYbNLahH.js → browser-interactive-control-controller-BiP6TJFP.js} +1 -1
- package/dist/{chunked-upload-BTdDxWFj.js → chunked-upload-D6ZCQ-iN.js} +15 -11
- package/dist/{chunked-upload-file-5GlXGjhY.js → chunked-upload-file-D3YxQdAl.js} +2 -2
- package/dist/{client-Bp3Gqf0e.d.ts → client-DiLd0XGB.d.ts} +4 -4
- package/dist/{client-DN4Ug-ub.js → client-DyKdtYDZ.js} +24 -29
- package/dist/{core-7rGEb0lF.js → core-DDgUWBS7.js} +2 -2
- package/dist/core.d.ts +5 -5
- package/dist/core.js +3 -3
- package/dist/{direct-http2-Bqtn2jg3.js → direct-http2-DU2SK2Wo.js} +1 -1
- package/dist/{index-BVEpMspL.d.ts → index-DyFU9hy7.d.ts} +5 -6
- package/dist/index.d.ts +7 -7
- package/dist/index.js +7 -7
- package/dist/intelligence/index.js +1 -1
- package/dist/interactive-control.js +1 -1
- package/dist/{interactive-controller-DuyS5n9z.d.ts → interactive-controller-BzObb8aT.d.ts} +1 -1
- package/dist/{interactive-controller-B09YfFqP.js → interactive-controller-C-CuPVMA.js} +8 -6
- package/dist/lib/prepared-evidence.js +1 -1
- package/dist/lib/prepared-process.js +1 -1
- package/dist/{lines-DGke3URt.d.ts → lines-D0dHQ3X5.d.ts} +1 -1
- package/dist/lines.d.ts +1 -1
- package/dist/{mcp-local-BHCdMtdh.js → mcp-local-BW6W0Vh8.js} +3 -3
- package/dist/{prepared-evidence-4prvV0YK.js → prepared-evidence--rjwnXGD.js} +2 -12
- package/dist/{prepared-process-BSpZXDDw.js → prepared-process-N-y0xr9S.js} +2 -14
- package/dist/{preview-Din4zRB-.d.ts → preview-CrXG9Y8a.d.ts} +3 -3
- package/dist/{public-templates-k5rHh7Up.d.ts → public-templates-Ba-DTf2O.d.ts} +1 -1
- package/dist/public-templates.d.ts +1 -1
- package/dist/{raw-evidence-archive-C5H8BaHr.js → raw-evidence-archive-DrgeV9_0.js} +1 -1
- package/dist/retry-policy-0_NCh5OB.js +88 -0
- package/dist/runtime.d.ts +3 -3
- package/dist/runtime.js +4 -4
- package/dist/{sandbox-BQ_u_Fjy.js → sandbox-DRZ1nTd3.js} +123 -156
- package/dist/select-seat-command.d.ts +1 -1
- package/dist/session-gateway/index.js +3 -3
- package/dist/tangle/index.d.ts +1 -1
- package/dist/tangle/index.js +1 -1
- package/dist/{tangle-B-Sv_5XW.js → tangle-BPDYjDpX.js} +1 -1
- package/dist/{types-BVcWpKvF.d.ts → types-BE70nj5h.d.ts} +2 -2
- package/package.json +5 -5
- package/dist/abort-signal-Cu4F2VVz.js +0 -62
- package/dist/api-request-BBNFh7Zx.js +0 -92
- package/dist/response-rewrap-Cjoxh2wZ.js +0 -28
- /package/dist/{file-transfer-Cr9Ossea.js → file-transfer-BSe4ayU9.js} +0 -0
- /package/dist/{keep-alive-fetch-C2lFwrMA.js → keep-alive-fetch-BIaDMUtu.js} +0 -0
- /package/dist/{sidecar-proxy-error-DTJbOAWL.js → sidecar-proxy-error-DpBLxIof.js} +0 -0
- /package/dist/{sse-parser-DXRUx6gh.js → sse-parser-DOCszo1K.js} +0 -0
package/README.md
CHANGED
|
@@ -429,7 +429,7 @@ It says nothing about whether this call admitted a sandbox, and it is not a retr
|
|
|
429
429
|
An absent value means the cell published no estimate, not that the wait is short.
|
|
430
430
|
|
|
431
431
|
`TimeoutError.timeoutMs` is the configured budget; `elapsedMs` is the actual duration. A `create()` ends early when `Retry-After` exceeds its remaining budget.
|
|
432
|
-
The [shared raw transport](src/lib/api-request.mjs) owns authentication, cancellation
|
|
432
|
+
The [shared raw transport](src/lib/api-request.mjs) owns authentication, cancellation, response deadlines and the one transient retry for SDK clients and standalone probes: a request safe to send twice (idempotent method or `Idempotency-Key`, no `x-no-retry`) is resent after a lost connection, a 502-504, or a 429 with `Retry-After`, within its timeout.
|
|
433
433
|
|
|
434
434
|
## One sandbox per customer
|
|
435
435
|
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
//#region src/lib/abort-signal.ts
|
|
2
|
+
function combineAbortSignals(signals) {
|
|
3
|
+
return AbortSignal.any(signals);
|
|
4
|
+
}
|
|
5
|
+
function awaitWithAbort(work, signal) {
|
|
6
|
+
if (!signal) return work;
|
|
7
|
+
signal.throwIfAborted();
|
|
8
|
+
return new Promise((resolve, reject) => {
|
|
9
|
+
let settled = false;
|
|
10
|
+
const onAbort = () => {
|
|
11
|
+
if (settled) return;
|
|
12
|
+
settled = true;
|
|
13
|
+
signal.removeEventListener("abort", onAbort);
|
|
14
|
+
reject(signal.reason ?? new DOMException("The request was aborted", "AbortError"));
|
|
15
|
+
};
|
|
16
|
+
signal.addEventListener("abort", onAbort, { once: true });
|
|
17
|
+
work.then((value) => {
|
|
18
|
+
if (settled) return;
|
|
19
|
+
settled = true;
|
|
20
|
+
signal.removeEventListener("abort", onAbort);
|
|
21
|
+
resolve(value);
|
|
22
|
+
}, (cause) => {
|
|
23
|
+
if (settled) return;
|
|
24
|
+
settled = true;
|
|
25
|
+
signal.removeEventListener("abort", onAbort);
|
|
26
|
+
reject(cause);
|
|
27
|
+
});
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
//#endregion
|
|
31
|
+
export { combineAbortSignals as n, awaitWithAbort as t };
|
package/dist/agent/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { I as SandboxTaskSession, O as SandboxInstance, R as SandboxSession } from "../index-
|
|
2
|
-
import { Bt as SandboxFleetParent, Ha as CodeExecutionResult, Ua as CodeLanguage, Ur as CodeExecutionOptions, Wa as CodeResultPart, ga as BackendConfig, ia as SessionListOptions, na as SessionInfo, wo as BackendType } from "../types-
|
|
3
|
-
import { t as Sandbox } from "../client-
|
|
4
|
-
import { u as PreviewAuthorizer } from "../preview-
|
|
1
|
+
import { I as SandboxTaskSession, O as SandboxInstance, R as SandboxSession } from "../index-DyFU9hy7.js";
|
|
2
|
+
import { Bt as SandboxFleetParent, Ha as CodeExecutionResult, Ua as CodeLanguage, Ur as CodeExecutionOptions, Wa as CodeResultPart, ga as BackendConfig, ia as SessionListOptions, na as SessionInfo, wo as BackendType } from "../types-BE70nj5h.js";
|
|
3
|
+
import { t as Sandbox } from "../client-DiLd0XGB.js";
|
|
4
|
+
import { u as PreviewAuthorizer } from "../preview-CrXG9Y8a.js";
|
|
5
5
|
import * as _$_modelcontextprotocol_sdk_server_index_js0 from "@modelcontextprotocol/sdk/server/index.js";
|
|
6
6
|
import { JSONSchema } from "zod/v4/core";
|
|
7
7
|
import { ToolSet } from "ai";
|
package/dist/agent/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { a as TOOL_SPECS, i as ALL_TOOL_SPECS, o as serializeToolResult, r as bindToolSpecs, t as createMcpServer } from "../mcp-local-
|
|
2
|
-
import { O as assertCurrentBackendType } from "../interactive-controller-
|
|
3
|
-
import { t as SandboxInstance } from "../sandbox-
|
|
1
|
+
import { a as TOOL_SPECS, i as ALL_TOOL_SPECS, o as serializeToolResult, r as bindToolSpecs, t as createMcpServer } from "../mcp-local-BW6W0Vh8.js";
|
|
2
|
+
import { O as assertCurrentBackendType } from "../interactive-controller-C-CuPVMA.js";
|
|
3
|
+
import { t as SandboxInstance } from "../sandbox-DRZ1nTd3.js";
|
|
4
4
|
import { D as ValidationError, _ as NotFoundError, w as StateError } from "../errors-CNszZUZ2.js";
|
|
5
|
-
import { t as Sandbox } from "../client-
|
|
5
|
+
import { t as Sandbox } from "../client-DyKdtYDZ.js";
|
|
6
6
|
import { z } from "zod";
|
|
7
7
|
//#region src/agent/instances.ts
|
|
8
8
|
const managers = /* @__PURE__ */ new WeakMap();
|
package/dist/agent/preview.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { _ as publishAgentPreview, a as previewOperationTool, c as AgentPreviewOptions, d as PreviewExecutionContext, f as PublishAgentPreviewOptions, g as listAgentPreviews, h as getAgentPreview, i as PreviewTool, l as PreviewAuthorizationRequest, m as ensureAgentPreview, n as PREVIEW_MCP_ALIAS, o as previewToolsForProfile, p as assertPreviewId, r as PREVIEW_TOOLS, s as AgentPreviewError, t as servePreviewMcp, u as PreviewAuthorizer, v as removeAgentPreview, y as resolveSelfSandbox } from "../preview-
|
|
1
|
+
import { _ as publishAgentPreview, a as previewOperationTool, c as AgentPreviewOptions, d as PreviewExecutionContext, f as PublishAgentPreviewOptions, g as listAgentPreviews, h as getAgentPreview, i as PreviewTool, l as PreviewAuthorizationRequest, m as ensureAgentPreview, n as PREVIEW_MCP_ALIAS, o as previewToolsForProfile, p as assertPreviewId, r as PREVIEW_TOOLS, s as AgentPreviewError, t as servePreviewMcp, u as PreviewAuthorizer, v as removeAgentPreview, y as resolveSelfSandbox } from "../preview-CrXG9Y8a.js";
|
|
2
2
|
export { AgentPreviewError, AgentPreviewOptions, PREVIEW_MCP_ALIAS, PREVIEW_TOOLS, PreviewAuthorizationRequest, PreviewAuthorizer, PreviewExecutionContext, PreviewTool, PublishAgentPreviewOptions, assertPreviewId, ensureAgentPreview, getAgentPreview, listAgentPreviews, previewOperationTool, previewToolsForProfile, publishAgentPreview, removeAgentPreview, resolveSelfSandbox, servePreviewMcp };
|
package/dist/agent/preview.js
CHANGED
|
@@ -66,7 +66,7 @@ async function servePreviewMcp(request, config) {
|
|
|
66
66
|
if (typeof config.authorize !== "function") throw new Error("Preview MCP requires a host authorization callback");
|
|
67
67
|
const tools = config.tools ?? PREVIEW_TOOLS;
|
|
68
68
|
if (!tools.length || tools.some((tool) => !PREVIEW_TOOLS.includes(tool))) throw new Error("Preview MCP requires an explicit nonempty preview-only tool grant");
|
|
69
|
-
const [{ createMcpServer }, { WebStandardStreamableHTTPServerTransport }] = await Promise.all([import("../mcp-local-
|
|
69
|
+
const [{ createMcpServer }, { WebStandardStreamableHTTPServerTransport }] = await Promise.all([import("../mcp-local-BW6W0Vh8.js").then((n) => n.n), import("@modelcontextprotocol/sdk/server/webStandardStreamableHttp.js")]);
|
|
70
70
|
const handle = await createMcpServer(config.box, {
|
|
71
71
|
name: "tangle-previews",
|
|
72
72
|
sessionId: config.sessionId,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { V as InteractionRequest } from "./terminal-stream-types-DeH8FF0d.js";
|
|
2
|
-
import { Di as SandboxEvent, _i as DurablePlanSnapshot, ci as AgentApprovalRequirement, di as AgentToolInvocation, li as AgentQuestionRequest, ui as AgentRunStatus } from "./types-
|
|
2
|
+
import { Di as SandboxEvent, _i as DurablePlanSnapshot, ci as AgentApprovalRequirement, di as AgentToolInvocation, li as AgentQuestionRequest, ui as AgentRunStatus } from "./types-BE70nj5h.js";
|
|
3
3
|
|
|
4
4
|
//#region src/agent-run-outcome.d.ts
|
|
5
5
|
interface AgentRunOutcome {
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
import { t as parseSandboxRetryAfterHeader } from "./retry-after-header-DUdCC0KJ.js";
|
|
2
|
+
import { n as SANDBOX_API_RETRY_SCOPE, o as planResend, r as abortableSleep, s as retryBudget } from "./retry-policy-0_NCh5OB.js";
|
|
3
|
+
//#region src/lib/response-rewrap.mjs
|
|
4
|
+
/**
|
|
5
|
+
* Response wrappers that must outlive the fetch Response they wrap.
|
|
6
|
+
*
|
|
7
|
+
* Node's fetch (undici) cancels a response body when the Response object that
|
|
8
|
+
* fetch returned is garbage collected while its body is still unread. A
|
|
9
|
+
* wrapper built with `new Response(original.body, …)` shares that body stream
|
|
10
|
+
* but not that lifetime: once the original is collected, the wrapper's body is
|
|
11
|
+
* already cancelled and every read throws `TypeError: Body is unusable: Body
|
|
12
|
+
* has already been read`. It depends on when the collector runs, so it shows
|
|
13
|
+
* up as a rare failure on any call whose body is read after a longer await.
|
|
14
|
+
*
|
|
15
|
+
* The map holds each original for as long as its wrapper is reachable, so the
|
|
16
|
+
* body stays readable. When both are unreachable, undici's own cleanup runs.
|
|
17
|
+
*/
|
|
18
|
+
const originals = /* @__PURE__ */ new WeakMap();
|
|
19
|
+
/** A Response retaining `original`'s lifetime, with optional body decoration. */
|
|
20
|
+
function rewrapResponse(original, headers, body = original.body) {
|
|
21
|
+
const wrapper = new Response(body, {
|
|
22
|
+
status: original.status,
|
|
23
|
+
statusText: original.statusText,
|
|
24
|
+
headers
|
|
25
|
+
});
|
|
26
|
+
originals.set(wrapper, original);
|
|
27
|
+
return wrapper;
|
|
28
|
+
}
|
|
29
|
+
//#endregion
|
|
30
|
+
//#region src/lib/api-request.mjs
|
|
31
|
+
/** The package version tsdown.config.ts defines; unbuilt source reports 0.0.0. */
|
|
32
|
+
const SDK_VERSION = "1.0.210";
|
|
33
|
+
function withRequestContextHeaders(response, path, method, body = response.body) {
|
|
34
|
+
const headers = new Headers(response.headers);
|
|
35
|
+
headers.set("x-tangle-request-path", path);
|
|
36
|
+
if (method) headers.set("x-tangle-request-method", method);
|
|
37
|
+
return rewrapResponse(response, headers, body);
|
|
38
|
+
}
|
|
39
|
+
/** RFC 9110 idempotent methods: applying one twice leaves what once did. */
|
|
40
|
+
const IDEMPOTENT_METHODS = new Set([
|
|
41
|
+
"GET",
|
|
42
|
+
"HEAD",
|
|
43
|
+
"OPTIONS",
|
|
44
|
+
"PUT",
|
|
45
|
+
"DELETE"
|
|
46
|
+
]);
|
|
47
|
+
/** Whether fetch can send this body twice. A stream is read once. */
|
|
48
|
+
function isReplayableBody(body) {
|
|
49
|
+
if (body === void 0 || body === null || typeof body === "string") return true;
|
|
50
|
+
if (typeof ReadableStream !== "undefined" && body instanceof ReadableStream) return false;
|
|
51
|
+
return !(Symbol.asyncIterator in body);
|
|
52
|
+
}
|
|
53
|
+
/** The wait before resending after `response` (none: connection lost) on the shared pacing, or undefined when it is final or cannot go before `deadline`. */
|
|
54
|
+
function retryDelayMs(response, attempt, deadline) {
|
|
55
|
+
const after = parseSandboxRetryAfterHeader(response?.headers.get("retry-after"));
|
|
56
|
+
const status = response?.status ?? 503;
|
|
57
|
+
if (!(status >= 502 && status <= 504 || status === 429 && after !== void 0)) return void 0;
|
|
58
|
+
return planResend(SANDBOX_API_RETRY_SCOPE, attempt, {
|
|
59
|
+
retryAfterMs: after,
|
|
60
|
+
deadlineAt: deadline,
|
|
61
|
+
capMs: 4e3
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* The SDK's authenticated raw transport, also shipped with standalone probes;
|
|
66
|
+
* the one place a transient failure is resent. A request safe to send twice
|
|
67
|
+
* (an idempotent method or an `Idempotency-Key`, a replayable body, no
|
|
68
|
+
* `x-no-retry`) goes again after a connection lost before any response, a
|
|
69
|
+
* 502-504, or a 429 with `Retry-After`: four attempts at most, inside the
|
|
70
|
+
* caller's one timeout. A response is final once its headers arrive.
|
|
71
|
+
*/
|
|
72
|
+
async function fetchSandboxApi({ baseUrl, apiKey, timeoutMs = 3e4, signal, fetchImpl = fetch, networkError = (error) => error, timeoutError = () => new DOMException("The operation was aborted due to timeout", "TimeoutError") }, path, options, fetchOptions) {
|
|
73
|
+
const url = `${baseUrl.replace(/\/+$/, "")}${path}`;
|
|
74
|
+
const requestTimeoutMs = typeof fetchOptions?.timeoutMs === "number" && fetchOptions.timeoutMs > 0 ? fetchOptions.timeoutMs : timeoutMs;
|
|
75
|
+
const deadline = Date.now() + requestTimeoutMs;
|
|
76
|
+
const controller = new AbortController();
|
|
77
|
+
const timeoutId = setTimeout(() => controller.abort(), requestTimeoutMs);
|
|
78
|
+
timeoutId.unref?.();
|
|
79
|
+
const requestSignal = AbortSignal.any([
|
|
80
|
+
controller.signal,
|
|
81
|
+
...options?.signal ? [options.signal] : [],
|
|
82
|
+
...signal ? [signal] : []
|
|
83
|
+
]);
|
|
84
|
+
let bodyOwnsTimeout = false;
|
|
85
|
+
let reading = false;
|
|
86
|
+
const failure = (error, network = false) => {
|
|
87
|
+
if (!requestSignal.aborted) return network ? networkError(error) : error;
|
|
88
|
+
return requestSignal.reason === controller.signal.reason ? timeoutError(requestTimeoutMs) : requestSignal.reason ?? error;
|
|
89
|
+
};
|
|
90
|
+
try {
|
|
91
|
+
const headers = new Headers(options?.headers);
|
|
92
|
+
headers.set("Authorization", `Bearer ${apiKey}`);
|
|
93
|
+
headers.set("x-sdk-version", SDK_VERSION);
|
|
94
|
+
const isFormDataBody = typeof FormData !== "undefined" && options?.body instanceof FormData;
|
|
95
|
+
if (!headers.has("Content-Type") && !isFormDataBody) headers.set("Content-Type", "application/json");
|
|
96
|
+
const method = (options?.method ?? "GET").toUpperCase();
|
|
97
|
+
const retryable = !headers.has("x-no-retry") && isReplayableBody(options?.body) && (IDEMPOTENT_METHODS.has(method) || headers.has("Idempotency-Key"));
|
|
98
|
+
let response;
|
|
99
|
+
let lost;
|
|
100
|
+
for (let attempt = 1;; attempt++) {
|
|
101
|
+
retryBudget(SANDBOX_API_RETRY_SCOPE).sent();
|
|
102
|
+
try {
|
|
103
|
+
response = await fetchImpl(url, {
|
|
104
|
+
...options,
|
|
105
|
+
headers,
|
|
106
|
+
signal: requestSignal
|
|
107
|
+
});
|
|
108
|
+
} catch (error) {
|
|
109
|
+
if (requestSignal.aborted) throw error;
|
|
110
|
+
response = void 0;
|
|
111
|
+
lost = error;
|
|
112
|
+
}
|
|
113
|
+
const delayMs = retryable && attempt < 4 ? retryDelayMs(response, attempt, deadline) : void 0;
|
|
114
|
+
if (delayMs === void 0) {
|
|
115
|
+
if (!response) throw lost;
|
|
116
|
+
break;
|
|
117
|
+
}
|
|
118
|
+
await response?.body?.cancel().catch(() => {});
|
|
119
|
+
await abortableSleep(delayMs, requestSignal);
|
|
120
|
+
}
|
|
121
|
+
if (fetchOptions?.read) {
|
|
122
|
+
reading = true;
|
|
123
|
+
return await fetchOptions.read(withRequestContextHeaders(response, path, options?.method));
|
|
124
|
+
}
|
|
125
|
+
const mediaType = response.headers.get("content-type")?.split(";", 1)[0]?.trim().toLowerCase();
|
|
126
|
+
if (fetchOptions?.bodyDeadline !== false && response.body !== null && (!response.ok || mediaType === "application/json" || mediaType?.endsWith("+json") === true)) {
|
|
127
|
+
const reader = response.body.getReader();
|
|
128
|
+
let settled = false;
|
|
129
|
+
const body = new ReadableStream({
|
|
130
|
+
type: "bytes",
|
|
131
|
+
async pull(stream) {
|
|
132
|
+
try {
|
|
133
|
+
const chunk = await reader.read();
|
|
134
|
+
if (settled) return;
|
|
135
|
+
if (chunk.done) {
|
|
136
|
+
settled = true;
|
|
137
|
+
clearTimeout(timeoutId);
|
|
138
|
+
reader.releaseLock();
|
|
139
|
+
stream.close();
|
|
140
|
+
stream.byobRequest?.respond(0);
|
|
141
|
+
} else stream.enqueue(chunk.value);
|
|
142
|
+
} catch (error) {
|
|
143
|
+
if (settled) return;
|
|
144
|
+
settled = true;
|
|
145
|
+
clearTimeout(timeoutId);
|
|
146
|
+
reader.releaseLock();
|
|
147
|
+
stream.error(failure(error));
|
|
148
|
+
}
|
|
149
|
+
},
|
|
150
|
+
async cancel(reason) {
|
|
151
|
+
if (settled) return;
|
|
152
|
+
settled = true;
|
|
153
|
+
clearTimeout(timeoutId);
|
|
154
|
+
try {
|
|
155
|
+
await reader.cancel(reason);
|
|
156
|
+
} finally {
|
|
157
|
+
reader.releaseLock();
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
});
|
|
161
|
+
const wrapped = withRequestContextHeaders(response, path, options?.method, body);
|
|
162
|
+
bodyOwnsTimeout = true;
|
|
163
|
+
return wrapped;
|
|
164
|
+
}
|
|
165
|
+
return withRequestContextHeaders(response, path, options?.method);
|
|
166
|
+
} catch (err) {
|
|
167
|
+
throw failure(err, !reading);
|
|
168
|
+
} finally {
|
|
169
|
+
if (!bodyOwnsTimeout) clearTimeout(timeoutId);
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
//#endregion
|
|
173
|
+
export { rewrapResponse as a, isReplayableBody as i, SDK_VERSION as n, fetchSandboxApi as r, IDEMPOTENT_METHODS as t };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { C as boundedIdentifierSchema, D as isBoundedEventContentJson, E as boundedStringSchema, S as boundedEventContentStringSchema, T as boundedJsonSchema, _ as CONTRACT_MAX_ARRAY_LENGTH, b as boundedEventContentJsonSchema, g as sha256DigestSchema, h as omitTopLevelDigest, m as looksLikeCredential, n as REASONING_EFFORTS, o as canonicalCandidateDigest, p as isWellFormedUnicode, s as canonicalCandidateJson, t as harnessTypeSchema, u as isCanonicalJsonValue, w as boundedJsonRecordSchema, x as boundedEventContentRecordSchema, y as CONTRACT_MAX_STRING_LENGTH } from "./harness-DMaNgn0S.js";
|
|
2
|
-
import {
|
|
2
|
+
import { t as awaitWithAbort } from "./abort-signal-BbJTt2QJ.js";
|
|
3
3
|
import { z } from "zod";
|
|
4
4
|
//#region ../../../node_modules/.pnpm/@tangle-network+agent-interface@5.10.13/node_modules/@tangle-network/agent-interface/dist/native-session-event.js
|
|
5
5
|
/**
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
import { S as SandboxError, n as isTransientWrite, r as parseErrorResponse } from "./errors-CNszZUZ2.js";
|
|
2
|
-
import {
|
|
3
|
-
import { i as FILE_UPLOAD_SESSION_MAX_BYTES, n as isFileTooLargeErrorBody, r as isPayloadTooLargeErrorBody } from "./file-transfer-
|
|
2
|
+
import { i as awaitResend, n as SANDBOX_API_RETRY_SCOPE, r as abortableSleep, s as retryBudget } from "./retry-policy-0_NCh5OB.js";
|
|
3
|
+
import { i as FILE_UPLOAD_SESSION_MAX_BYTES, n as isFileTooLargeErrorBody, r as isPayloadTooLargeErrorBody } from "./file-transfer-BSe4ayU9.js";
|
|
4
|
+
//#region src/lib/sdk-retry.ts
|
|
5
|
+
const countSdkRequest = () => retryBudget(SANDBOX_API_RETRY_SCOPE).sent();
|
|
6
|
+
const takeSdkTurn = (maxWaitMs) => retryBudget(SANDBOX_API_RETRY_SCOPE).take(maxWaitMs);
|
|
7
|
+
const awaitSdkResend = (resend, o) => awaitResend(SANDBOX_API_RETRY_SCOPE, resend, o);
|
|
8
|
+
//#endregion
|
|
4
9
|
//#region src/generated/sandbox-upload-operations.ts
|
|
5
10
|
function uploadSessionInit(transport, input, init = {}) {
|
|
6
11
|
return transport.fetch(`/fs/upload-session`, {
|
|
@@ -42,8 +47,7 @@ function uploadSessionDelete(transport, params, init = {}) {
|
|
|
42
47
|
* browsers, Workers, and Node 18+ — the same environments this module must
|
|
43
48
|
* run in unmodified.
|
|
44
49
|
*/
|
|
45
|
-
const DEFAULT_MAX_RETRIES =
|
|
46
|
-
const RETRY_BASE_MS = 250;
|
|
50
|
+
const DEFAULT_MAX_RETRIES = 6;
|
|
47
51
|
const RETRY_MAX_MS = 2e3;
|
|
48
52
|
/** Concurrent part PUTs — indexed parts + commit-time assembly make out-of-
|
|
49
53
|
* order completion safe; the cap keeps one session polite to the sidecar's
|
|
@@ -208,6 +212,7 @@ async function putPart(transport, uploadId, index, options, wire) {
|
|
|
208
212
|
}, {
|
|
209
213
|
headers: {
|
|
210
214
|
"Content-Type": "application/octet-stream",
|
|
215
|
+
"x-no-retry": "1",
|
|
211
216
|
...wire.encoding ? { "Content-Encoding": wire.encoding } : {}
|
|
212
217
|
},
|
|
213
218
|
body: wire.body,
|
|
@@ -216,12 +221,11 @@ async function putPart(transport, uploadId, index, options, wire) {
|
|
|
216
221
|
if (!response.ok) throw await parseUploadError(response);
|
|
217
222
|
return;
|
|
218
223
|
} catch (err) {
|
|
219
|
-
if (isTransientWrite(err) && attempt < maxRetries
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
}
|
|
224
|
+
if (isTransientWrite(err) && attempt < maxRetries && await awaitSdkResend(attempt + 1, {
|
|
225
|
+
retryAfterMs: err instanceof SandboxError ? err.retryAfterMs : void 0,
|
|
226
|
+
signal: options.signal,
|
|
227
|
+
capMs: RETRY_MAX_MS
|
|
228
|
+
})) continue;
|
|
225
229
|
throw err;
|
|
226
230
|
}
|
|
227
231
|
}
|
|
@@ -383,4 +387,4 @@ var ChunkedUploadInterruptedError = class extends Error {
|
|
|
383
387
|
}
|
|
384
388
|
};
|
|
385
389
|
//#endregion
|
|
386
|
-
export { planCompression as a, partCount as i, commitSession as n, putPart as o, initUploadSession as r, uploadChunked as s, abortSession as t };
|
|
390
|
+
export { planCompression as a, awaitSdkResend as c, partCount as i, countSdkRequest as l, commitSession as n, putPart as o, initUploadSession as r, uploadChunked as s, abortSession as t, takeSdkTurn as u };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { i as FILE_UPLOAD_SESSION_MAX_BYTES } from "./file-transfer-
|
|
2
|
-
import { a as planCompression, i as partCount, n as commitSession, o as putPart, r as initUploadSession, t as abortSession } from "./chunked-upload-
|
|
1
|
+
import { i as FILE_UPLOAD_SESSION_MAX_BYTES } from "./file-transfer-BSe4ayU9.js";
|
|
2
|
+
import { a as planCompression, i as partCount, n as commitSession, o as putPart, r as initUploadSession, t as abortSession } from "./chunked-upload-D6ZCQ-iN.js";
|
|
3
3
|
import { createHash } from "node:crypto";
|
|
4
4
|
import { open } from "node:fs/promises";
|
|
5
5
|
//#region src/lib/chunked-upload-file.ts
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { A as TraceExportResult, H as MaterializeProfileFileMountsOptions, O as SandboxInstance, U as MaterializeProfileFileMountsResult, W as ProfileFileMountBox, j as TraceExportSink } from "./index-
|
|
1
|
+
import { A as TraceExportResult, H as MaterializeProfileFileMountsOptions, O as SandboxInstance, U as MaterializeProfileFileMountsResult, W as ProfileFileMountBox, j as TraceExportSink } from "./index-DyFU9hy7.js";
|
|
2
2
|
import { G as AgentProfileConfidential, J as AgentProfileMcpServer, K as AgentProfileConfigValue, U as AgentProfile, X as AgentProfileSeat, Y as AgentProfileMetadata, b as SandboxSizePreset, bt as SandboxError, c as MintInteractiveSessionTokenOptions, k as AgentInteractiveSessionRef, q as AgentProfileFileMount, u as ScopedToken } from "./terminal-stream-types-DeH8FF0d.js";
|
|
3
|
-
import { $ as CreateSandboxFleetOptions, $t as SandboxFleetWorkspaceRestoreResult, A as SandboxIdentity, Bt as SandboxFleetParent, Ci as IntelligenceReportWindow, Di as SandboxEvent, Dn as SandboxResources, Ei as PromptResult, En as SandboxConfig, Et as SandboxFleetCostEstimate, Ft as SandboxFleetMachineRecord, Ga as ExecResult, Gr as ManagedProcessOptions, Gt as SandboxFleetToken, Ht as SandboxFleetPolicy, It as SandboxFleetMachineSpec, Jr as ManagedProcessRecord, Kr as ManagedProcessResumeOptions, Kt as SandboxFleetTraceBundle, Lt as SandboxFleetManifest, M as UsageInfo, Ma as GpuLeaseProviderName, Nt as SandboxFleetMachine, On as SandboxShapesInfo, Ot as SandboxFleetDispatchResponse, Pi as TurnBackendConfig, Q as AttachSandboxFleetMachineOptions, Qt as SandboxFleetWorkspaceReconcileResult, Ri as ConversationTurnOptions, St as SandboxFleetAgent, T as SshKeysManager, Ti as PromptOptions, Tn as CreateSandboxOptions, Tt as SandboxFleetArtifactSpec, Wr as ManagedProcessJobs, Wt as SandboxFleetSpend, X as FleetDriveTurnRequest, Xr as HttpClient, Xt as SandboxFleetUsage, Y as FleetDriveTurnOutcome, Yn as DownloadResult, Yr as ManagedProcessSpec, Yt as SandboxFleetTraceOptions, Z as TokenRefreshHandler, Zr as SdkTimingHook, _o as PublicBatchRunRequestInput, _t as ListSandboxFleetOptions, a as DeleteMatchingSandboxesResult, an as SandboxInfo, bi as IntelligenceReportBudget, bn as TeeAttestationResponse, bt as ReconcileSandboxFleetsOptions, cn as SandboxRunGeneration, ct as FleetDispatchResultBufferOptions, dt as FleetExecDispatchResult, en as SandboxFleetWorkspaceSnapshotResult, et as CreateSandboxFleetTokenOptions, fi as CreateIntelligenceReportOptions, ft as FleetMachineId, ga as BackendConfig, go as PublicBatchRunRequest, gt as FleetRunOptions, ht as FleetRunEvent, i as DeleteMatchingSandboxesOptions, it as FleetAgentResult, j as SubscriptionInfo, jn as SandboxShapePreset, jt as SandboxFleetInfo, kt as SandboxFleetDriverCapability, lt as FleetDispatchStreamOptions, mt as FleetPromptDispatchResult, nt as FleetAgentId, ot as FleetDispatchCancelResult, po as BatchResult, pt as FleetPromptDispatchOptions, qn as DownloadOptions, r as DeleteMatchingSandboxesFilter, si as BatchRunOptions, st as FleetDispatchResultBuffer, tn as ListSandboxOptions, tt as CreateSandboxFleetWithCoordinatorOptions, ut as FleetExecDispatchOptions, vt as ReapExpiredSandboxFleetsOptions, w as SecretsManager, wa as SecretBindingOptions, wi as PromptInputPart, wn as CreateRequestOptions, wr as SandboxEnvironment, wt as SandboxFleetArtifact, xi as IntelligenceReportCompareTo, xt as ReconcileSandboxFleetsResult, yi as IntelligenceReport, yn as TeeAttestationReport, yo as BatchEvent, yr as ExecOptions, yt as ReapExpiredSandboxFleetsResult, zi as ConversationTurnResult, zt as SandboxFleetOperationsSummary } from "./types-
|
|
4
|
-
import { t as LinesClient } from "./lines-
|
|
5
|
-
import { a as PublicTemplatesClient } from "./public-templates-
|
|
3
|
+
import { $ as CreateSandboxFleetOptions, $t as SandboxFleetWorkspaceRestoreResult, A as SandboxIdentity, Bt as SandboxFleetParent, Ci as IntelligenceReportWindow, Di as SandboxEvent, Dn as SandboxResources, Ei as PromptResult, En as SandboxConfig, Et as SandboxFleetCostEstimate, Ft as SandboxFleetMachineRecord, Ga as ExecResult, Gr as ManagedProcessOptions, Gt as SandboxFleetToken, Ht as SandboxFleetPolicy, It as SandboxFleetMachineSpec, Jr as ManagedProcessRecord, Kr as ManagedProcessResumeOptions, Kt as SandboxFleetTraceBundle, Lt as SandboxFleetManifest, M as UsageInfo, Ma as GpuLeaseProviderName, Nt as SandboxFleetMachine, On as SandboxShapesInfo, Ot as SandboxFleetDispatchResponse, Pi as TurnBackendConfig, Q as AttachSandboxFleetMachineOptions, Qt as SandboxFleetWorkspaceReconcileResult, Ri as ConversationTurnOptions, St as SandboxFleetAgent, T as SshKeysManager, Ti as PromptOptions, Tn as CreateSandboxOptions, Tt as SandboxFleetArtifactSpec, Wr as ManagedProcessJobs, Wt as SandboxFleetSpend, X as FleetDriveTurnRequest, Xr as HttpClient, Xt as SandboxFleetUsage, Y as FleetDriveTurnOutcome, Yn as DownloadResult, Yr as ManagedProcessSpec, Yt as SandboxFleetTraceOptions, Z as TokenRefreshHandler, Zr as SdkTimingHook, _o as PublicBatchRunRequestInput, _t as ListSandboxFleetOptions, a as DeleteMatchingSandboxesResult, an as SandboxInfo, bi as IntelligenceReportBudget, bn as TeeAttestationResponse, bt as ReconcileSandboxFleetsOptions, cn as SandboxRunGeneration, ct as FleetDispatchResultBufferOptions, dt as FleetExecDispatchResult, en as SandboxFleetWorkspaceSnapshotResult, et as CreateSandboxFleetTokenOptions, fi as CreateIntelligenceReportOptions, ft as FleetMachineId, ga as BackendConfig, go as PublicBatchRunRequest, gt as FleetRunOptions, ht as FleetRunEvent, i as DeleteMatchingSandboxesOptions, it as FleetAgentResult, j as SubscriptionInfo, jn as SandboxShapePreset, jt as SandboxFleetInfo, kt as SandboxFleetDriverCapability, lt as FleetDispatchStreamOptions, mt as FleetPromptDispatchResult, nt as FleetAgentId, ot as FleetDispatchCancelResult, po as BatchResult, pt as FleetPromptDispatchOptions, qn as DownloadOptions, r as DeleteMatchingSandboxesFilter, si as BatchRunOptions, st as FleetDispatchResultBuffer, tn as ListSandboxOptions, tt as CreateSandboxFleetWithCoordinatorOptions, ut as FleetExecDispatchOptions, vt as ReapExpiredSandboxFleetsOptions, w as SecretsManager, wa as SecretBindingOptions, wi as PromptInputPart, wn as CreateRequestOptions, wr as SandboxEnvironment, wt as SandboxFleetArtifact, xi as IntelligenceReportCompareTo, xt as ReconcileSandboxFleetsResult, yi as IntelligenceReport, yn as TeeAttestationReport, yo as BatchEvent, yr as ExecOptions, yt as ReapExpiredSandboxFleetsResult, zi as ConversationTurnResult, zt as SandboxFleetOperationsSummary } from "./types-BE70nj5h.js";
|
|
4
|
+
import { t as LinesClient } from "./lines-D0dHQ3X5.js";
|
|
5
|
+
import { a as PublicTemplatesClient } from "./public-templates-Ba-DTf2O.js";
|
|
6
6
|
import { z } from "zod";
|
|
7
7
|
|
|
8
8
|
//#region src/backend-registry.d.ts
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import { A as normalizeRuntimeBackendConfig, D as applyRequestedModel, E as isBrowserRuntime, H as backendTypeSchema, N as withProfileHarness, O as assertCurrentBackendType, P as withoutCreateOnlyModelFields, S as encodePromptForWire, o as requestInteractiveSessionToken } from "./interactive-controller-
|
|
1
|
+
import { A as normalizeRuntimeBackendConfig, D as applyRequestedModel, E as isBrowserRuntime, H as backendTypeSchema, N as withProfileHarness, O as assertCurrentBackendType, P as withoutCreateOnlyModelFields, S as encodePromptForWire, o as requestInteractiveSessionToken } from "./interactive-controller-C-CuPVMA.js";
|
|
2
2
|
import { r as agentProfileSchema } from "./profile-schema-C1KpT-wS.js";
|
|
3
|
-
import { A as normalizeSandboxCreateReceipt, B as CAPACITY_ETA_WAIT_MAX_MS, D as validateDeferredProfileFileMounts, E as splitInlineProfileSkills, F as normalizeConnection, G as
|
|
4
|
-
import { C as ServerError, D as ValidationError, E as TimeoutError, S as SandboxError, _ as NotFoundError, a as readResponseJson, g as NetworkError, i as parseResponseError,
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import { t as
|
|
3
|
+
import { A as normalizeSandboxCreateReceipt, B as CAPACITY_ETA_WAIT_MAX_MS, D as validateDeferredProfileFileMounts, E as splitInlineProfileSkills, F as normalizeConnection, G as createRetryDelayMs, I as normalizeEgressPolicyFields, J as isCapacityShortageCreateError, K as extendableDeadline, L as normalizeProxySecretReceipt, N as dateOf, O as isRetryableProfileFileMaterializeFailure, P as parseLifecycleTimes, R as normalizeSandboxShape, T as splitInlineProfileFileMounts, U as DEPLOY_WINDOW_RETRY_MS, W as awaitCreateResend, X as isRateLimitCreateError, Y as isDeployWindowCreateError, Z as isRetryableCreateError, d as sandboxLedgerUsd, j as normalizeStartupDiagnostics, k as normalizeCaptureProof, n as createSandboxInstanceFromResponse, o as exportTraceBundle, q as generateIdempotencyKey, z as CAPACITY_ETA_MARGIN_MS } from "./sandbox-DRZ1nTd3.js";
|
|
4
|
+
import { C as ServerError, D as ValidationError, E as TimeoutError, S as SandboxError, _ as NotFoundError, a as readResponseJson, g as NetworkError, i as parseResponseError, r as parseErrorResponse, s as AuthError, v as PartialFailureError } from "./errors-CNszZUZ2.js";
|
|
5
|
+
import { n as combineAbortSignals } from "./abort-signal-BbJTt2QJ.js";
|
|
6
|
+
import { r as abortableSleep, t as RETRY_POLICY } from "./retry-policy-0_NCh5OB.js";
|
|
7
|
+
import { l as SANDBOX_AGENT_HOME, t as isInsideReservedDir } from "./file-transfer-BSe4ayU9.js";
|
|
8
|
+
import { r as fetchSandboxApi } from "./api-request-CUIrVFhJ.js";
|
|
9
|
+
import { n as fetchWithKeepAlive, t as emitTiming } from "./keep-alive-fetch-BIaDMUtu.js";
|
|
10
|
+
import { t as parseSSEStream } from "./sse-parser-DOCszo1K.js";
|
|
10
11
|
import { t as LinesClient } from "./lines-DHOIUO-t.js";
|
|
11
12
|
import { PublicTemplatesClient } from "./public-templates.js";
|
|
12
13
|
import { z } from "zod";
|
|
@@ -1909,9 +1910,9 @@ var SandboxCreation = class extends SandboxManagement {
|
|
|
1909
1910
|
cause: lastServerError
|
|
1910
1911
|
});
|
|
1911
1912
|
};
|
|
1912
|
-
const sleepBeforeRetry = async (delayMs) => {
|
|
1913
|
+
const sleepBeforeRetry = async (delayMs, cause) => {
|
|
1913
1914
|
try {
|
|
1914
|
-
await
|
|
1915
|
+
await awaitCreateResend(delayMs, deadline, postSignal, cause);
|
|
1915
1916
|
} catch (waitError) {
|
|
1916
1917
|
if (requestOptions?.signal?.aborted) throw waitError;
|
|
1917
1918
|
throw createTimeoutError();
|
|
@@ -1926,9 +1927,9 @@ var SandboxCreation = class extends SandboxManagement {
|
|
|
1926
1927
|
status: cause.status
|
|
1927
1928
|
});
|
|
1928
1929
|
if (isPacedCreateError(cause)) {
|
|
1929
|
-
const delayMs = Math.max(createRetryDelayMs(cause, failedAttempt),
|
|
1930
|
+
const delayMs = Math.max(createRetryDelayMs(cause, failedAttempt), RETRY_POLICY.baseMs);
|
|
1930
1931
|
if (delayMs >= deployWindowDeadline - Date.now()) throw deployWindowDeadline === deadline ? createTimeoutError() : cause;
|
|
1931
|
-
await sleepBeforeRetry(delayMs);
|
|
1932
|
+
await sleepBeforeRetry(delayMs, cause);
|
|
1932
1933
|
return;
|
|
1933
1934
|
}
|
|
1934
1935
|
const delayMs = createRetryDelayMs(cause, failedAttempt);
|
|
@@ -1936,7 +1937,7 @@ var SandboxCreation = class extends SandboxManagement {
|
|
|
1936
1937
|
if (proxyTimedOutCreate && cause.code === "IDEMPOTENT_CREATE_IN_PROGRESS") throw createTimeoutError();
|
|
1937
1938
|
throw cause;
|
|
1938
1939
|
}
|
|
1939
|
-
await sleepBeforeRetry(delayMs);
|
|
1940
|
+
await sleepBeforeRetry(delayMs, cause);
|
|
1940
1941
|
};
|
|
1941
1942
|
let response;
|
|
1942
1943
|
let shortBudgetFailures = 0;
|
|
@@ -1946,13 +1947,16 @@ var SandboxCreation = class extends SandboxManagement {
|
|
|
1946
1947
|
if (isPacedCreateError(error)) return false;
|
|
1947
1948
|
if (proxyTimedOutCreate && error instanceof SandboxError && error.code === "IDEMPOTENT_CREATE_IN_PROGRESS") return false;
|
|
1948
1949
|
shortBudgetFailures += 1;
|
|
1949
|
-
return shortBudgetFailures >=
|
|
1950
|
+
return shortBudgetFailures >= 6;
|
|
1950
1951
|
};
|
|
1951
1952
|
for (let attempt = 1;; attempt++) {
|
|
1952
1953
|
try {
|
|
1953
1954
|
response = await this.fetch("/v1/sandboxes", {
|
|
1954
1955
|
method: "POST",
|
|
1955
|
-
headers: {
|
|
1956
|
+
headers: {
|
|
1957
|
+
"Idempotency-Key": idempotencyKey,
|
|
1958
|
+
"x-no-retry": "1"
|
|
1959
|
+
},
|
|
1956
1960
|
signal: postSignal,
|
|
1957
1961
|
body: createRequestBody
|
|
1958
1962
|
}, { timeoutMs: Math.max(1, deadline - Date.now()) });
|
|
@@ -2429,7 +2433,6 @@ const MODEL_META = "tangle.fleet.model";
|
|
|
2429
2433
|
/** Id of the budgeted Platform key a capped fleet's sandboxes charge. */
|
|
2430
2434
|
const KEY_ID_META = "tangle.fleet.key_id";
|
|
2431
2435
|
const RESERVED_METADATA_PREFIX = "tangle.";
|
|
2432
|
-
const DELETE_RETRY_DELAYS_MS = [1e3, 3e3];
|
|
2433
2436
|
const FLEET_KEY_GRACE_MS = 3600 * 1e3;
|
|
2434
2437
|
const machineIdPattern = /^[a-zA-Z0-9][a-zA-Z0-9._-]*$/;
|
|
2435
2438
|
//#endregion
|
|
@@ -2855,20 +2858,12 @@ var FleetClientTransport = class {
|
|
|
2855
2858
|
return keyIds;
|
|
2856
2859
|
}
|
|
2857
2860
|
async deleteTreeOnce(fleetId, machines) {
|
|
2858
|
-
|
|
2859
|
-
|
|
2860
|
-
|
|
2861
|
-
|
|
2862
|
-
}
|
|
2863
|
-
if (response.status === 404) {
|
|
2864
|
-
await this.deleteMachines(machines);
|
|
2865
|
-
return;
|
|
2866
|
-
}
|
|
2867
|
-
const body = await response.text().catch(() => "");
|
|
2868
|
-
const error = parseErrorResponse(response.status, body, void 0, response.headers);
|
|
2869
|
-
if (!(retryWhen(error) && (error.status >= 500 || error.status === 429)) || attempt >= DELETE_RETRY_DELAYS_MS.length) throw error;
|
|
2870
|
-
await new Promise((resolve) => setTimeout(resolve, DELETE_RETRY_DELAYS_MS[attempt]));
|
|
2861
|
+
const response = await this.client.fetch(`/v1/fleets/${fleetId}`, { method: "DELETE" });
|
|
2862
|
+
if (response.status === 404) return this.deleteMachines(machines);
|
|
2863
|
+
if (response.ok) {
|
|
2864
|
+
if ((await response.clone().json().catch(() => ({}))).success !== false) return;
|
|
2871
2865
|
}
|
|
2866
|
+
throw await parseResponseError(response);
|
|
2872
2867
|
}
|
|
2873
2868
|
async deleteMachines(machines) {
|
|
2874
2869
|
const failures = [];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as agentProfileSchema } from "./profile-schema-C1KpT-wS.js";
|
|
2
|
-
import {
|
|
2
|
+
import { Q as canonicalAgentProfileDigest } from "./sandbox-DRZ1nTd3.js";
|
|
3
3
|
import { D as ValidationError, S as SandboxError, l as CapabilityError } from "./errors-CNszZUZ2.js";
|
|
4
|
-
import {
|
|
4
|
+
import { t as awaitWithAbort } from "./abort-signal-BbJTt2QJ.js";
|
|
5
5
|
import { r as cliAuthReferenceSchema } from "./cli-auth-bundle-C6DtK7GX-BbbiAn-Z.js";
|
|
6
6
|
import "./cli-auth-bundle-CMJWI99l.js";
|
|
7
7
|
import { z } from "zod";
|
package/dist/core.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { B as WorkspaceImages, O as SandboxInstance, V as ProfileFileDeliveryReport, z as WorkspaceImagePublishRequestOptions } from "./index-
|
|
1
|
+
import { B as WorkspaceImages, O as SandboxInstance, V as ProfileFileDeliveryReport, z as WorkspaceImagePublishRequestOptions } from "./index-DyFU9hy7.js";
|
|
2
2
|
import { Ct as ServerError, Dt as TimeoutError, Ot as ValidationError, St as SandboxFailureDetail, _t as ProfileFileMountPathError, bt as SandboxError, gt as PartialFailureError, ht as NotFoundError, it as AuthError, mt as NetworkError, ot as CapabilityError, rt as parseErrorResponse, ut as FileWriteConflictError, vt as QuotaError, wt as StateError, xt as SandboxErrorJson } from "./terminal-stream-types-DeH8FF0d.js";
|
|
3
|
-
import { En as SandboxConfig, Ga as ExecResult, Gr as ManagedProcessOptions, H as PreviewLinkInfo, Ia as WorkspaceImagePublishInput, In as NetworkConfig, Ja as SandboxEnvRecoveryView, Jr as ManagedProcessRecord, Kr as ManagedProcessResumeOptions, La as WorkspaceImagePublishResult, Ri as ConversationTurnOptions, Tn as CreateSandboxOptions, U as PreviewLinkManager, W as PreviewLinkWaitOptions, Wr as ManagedProcessJobs, Yr as ManagedProcessSpec, an as SandboxInfo, kn as SandboxStatus, oa as SessionMessageAdmission, qa as SandboxEnvRecovery, qr as ManagedProcessState, wi as PromptInputPart, yr as ExecOptions, zi as ConversationTurnResult } from "./types-
|
|
4
|
-
import { D as LineReplyCode, E as LineReminderPreferences, F as LineSenderVerification, G as LineApplicationRequest, H as LINE_APPLICATION_REPLY_MAX_CHARS, I as LineSenderVerificationStart, J as LineApplicationView, K as LineApplicationResult, N as LineSendInput, O as LineReplyCodeInput, P as LineSendReceipt, T as LineProvider, U as LINE_APPLICATION_REQUEST_MAX_BYTES, W as LineApplication, X as parseLineApplicationResult, Y as parseLineApplicationRequest, _ as LineInstanceCreate, a as Line, b as LineMemberInstance, d as LineAttachment, f as LineAttachmentReauthorization, g as LineInstanceAttachOptions, h as LineImage, i as profileChannelReference, l as LineApplicationAttachOptions, o as LineAgentRolePolicy, p as LineExecutionKey, q as LineApplicationState, r as lineInstanceKey, t as LinesClient, w as LineNumberInventory, y as LineMember } from "./lines-
|
|
5
|
-
import { Ct as InstanceRestartingError, Dt as sandboxFailureKind, Et as SandboxFailureKind, St as InstanceRecord, Tt as InstancesClient, _t as gatewaySeatTransport, an as backendRegistryEntrySchema, bt as HostedInstance, cn as isBackendRegistryInteractionKind, ct as SandboxResolvedSeat, dt as SeatOwnerReply, en as BackendRegistryCapabilities, ft as SeatOwnerTransport, gt as createSelectSeat, ht as SeatSelectionRequest, in as backendRegistryCapabilitiesSchema, ln as parseBackendRegistryResponse, lt as SandboxSeatCredentials, mt as SeatSelectionError, nn as BackendRegistryInteractionKind, on as backendRegistryInteractionKindSchema, ot as ISOLATED_CREATION_ATTESTATION_VERSION, pt as SeatResolutionObservation, rn as BackendRegistryResponse, sn as backendRegistryResponseSchema, st as CreateSelectSeatOptions, t as Sandbox, tn as BackendRegistryEntry, un as parseBackendRegistryResponseBody, ut as SandboxSeatSelectionInput, vt as ManagedProcessClient, xt as InstanceProfile, yt as EnsureInstanceOptions } from "./client-
|
|
6
|
-
import { a as PublicTemplatesClient, i as PublicTemplatePublishRequestOptions, n as PublicTemplatePublishError, r as PublicTemplatePublishJob, t as PublicTemplatePublishArtifact } from "./public-templates-
|
|
3
|
+
import { En as SandboxConfig, Ga as ExecResult, Gr as ManagedProcessOptions, H as PreviewLinkInfo, Ia as WorkspaceImagePublishInput, In as NetworkConfig, Ja as SandboxEnvRecoveryView, Jr as ManagedProcessRecord, Kr as ManagedProcessResumeOptions, La as WorkspaceImagePublishResult, Ri as ConversationTurnOptions, Tn as CreateSandboxOptions, U as PreviewLinkManager, W as PreviewLinkWaitOptions, Wr as ManagedProcessJobs, Yr as ManagedProcessSpec, an as SandboxInfo, kn as SandboxStatus, oa as SessionMessageAdmission, qa as SandboxEnvRecovery, qr as ManagedProcessState, wi as PromptInputPart, yr as ExecOptions, zi as ConversationTurnResult } from "./types-BE70nj5h.js";
|
|
4
|
+
import { D as LineReplyCode, E as LineReminderPreferences, F as LineSenderVerification, G as LineApplicationRequest, H as LINE_APPLICATION_REPLY_MAX_CHARS, I as LineSenderVerificationStart, J as LineApplicationView, K as LineApplicationResult, N as LineSendInput, O as LineReplyCodeInput, P as LineSendReceipt, T as LineProvider, U as LINE_APPLICATION_REQUEST_MAX_BYTES, W as LineApplication, X as parseLineApplicationResult, Y as parseLineApplicationRequest, _ as LineInstanceCreate, a as Line, b as LineMemberInstance, d as LineAttachment, f as LineAttachmentReauthorization, g as LineInstanceAttachOptions, h as LineImage, i as profileChannelReference, l as LineApplicationAttachOptions, o as LineAgentRolePolicy, p as LineExecutionKey, q as LineApplicationState, r as lineInstanceKey, t as LinesClient, w as LineNumberInventory, y as LineMember } from "./lines-D0dHQ3X5.js";
|
|
5
|
+
import { Ct as InstanceRestartingError, Dt as sandboxFailureKind, Et as SandboxFailureKind, St as InstanceRecord, Tt as InstancesClient, _t as gatewaySeatTransport, an as backendRegistryEntrySchema, bt as HostedInstance, cn as isBackendRegistryInteractionKind, ct as SandboxResolvedSeat, dt as SeatOwnerReply, en as BackendRegistryCapabilities, ft as SeatOwnerTransport, gt as createSelectSeat, ht as SeatSelectionRequest, in as backendRegistryCapabilitiesSchema, ln as parseBackendRegistryResponse, lt as SandboxSeatCredentials, mt as SeatSelectionError, nn as BackendRegistryInteractionKind, on as backendRegistryInteractionKindSchema, ot as ISOLATED_CREATION_ATTESTATION_VERSION, pt as SeatResolutionObservation, rn as BackendRegistryResponse, sn as backendRegistryResponseSchema, st as CreateSelectSeatOptions, t as Sandbox, tn as BackendRegistryEntry, un as parseBackendRegistryResponseBody, ut as SandboxSeatSelectionInput, vt as ManagedProcessClient, xt as InstanceProfile, yt as EnsureInstanceOptions } from "./client-DiLd0XGB.js";
|
|
6
|
+
import { a as PublicTemplatesClient, i as PublicTemplatePublishRequestOptions, n as PublicTemplatePublishError, r as PublicTemplatePublishJob, t as PublicTemplatePublishArtifact } from "./public-templates-Ba-DTf2O.js";
|
|
7
7
|
export { AuthError, BackendRegistryCapabilities, BackendRegistryEntry, BackendRegistryInteractionKind, BackendRegistryResponse, CapabilityError, ConversationTurnOptions, ConversationTurnResult, CreateSandboxOptions, CreateSelectSeatOptions, EnsureInstanceOptions, ExecOptions, ExecResult, FileWriteConflictError, HostedInstance, ISOLATED_CREATION_ATTESTATION_VERSION, InstanceProfile, InstanceRecord, InstanceRestartingError, InstancesClient, LINE_APPLICATION_REPLY_MAX_CHARS, LINE_APPLICATION_REQUEST_MAX_BYTES, Line, LineAgentRolePolicy, LineApplication, LineApplicationAttachOptions, LineApplicationRequest, LineApplicationResult, LineApplicationState, LineApplicationView, LineAttachment, LineAttachmentReauthorization, LineExecutionKey, LineImage, LineInstanceAttachOptions, LineInstanceCreate, LineMember, LineMemberInstance, LineNumberInventory, LineProvider, LineReminderPreferences, LineReplyCode, LineReplyCodeInput, LineSendInput, LineSendReceipt, LineSenderVerification, LineSenderVerificationStart, LinesClient, ManagedProcessClient, ManagedProcessJobs, ManagedProcessOptions, ManagedProcessRecord, ManagedProcessResumeOptions, ManagedProcessSpec, ManagedProcessState, NetworkConfig, NetworkError, NotFoundError, PartialFailureError, PreviewLinkInfo, PreviewLinkManager, PreviewLinkWaitOptions, ProfileFileDeliveryReport, ProfileFileMountPathError, PromptInputPart, PublicTemplatePublishArtifact, PublicTemplatePublishError, PublicTemplatePublishJob, PublicTemplatePublishRequestOptions, PublicTemplatesClient, QuotaError, Sandbox, SandboxConfig, SandboxEnvRecovery, SandboxEnvRecoveryView, SandboxError, SandboxErrorJson, SandboxFailureDetail, SandboxFailureKind, SandboxInfo, SandboxInstance, SandboxResolvedSeat, SandboxSeatCredentials, SandboxSeatSelectionInput, SandboxStatus, SeatOwnerReply, SeatOwnerTransport, SeatResolutionObservation, SeatSelectionError, SeatSelectionRequest, ServerError, SessionMessageAdmission, StateError, TimeoutError, ValidationError, WorkspaceImagePublishInput, WorkspaceImagePublishRequestOptions, WorkspaceImagePublishResult, WorkspaceImages, backendRegistryCapabilitiesSchema, backendRegistryEntrySchema, backendRegistryInteractionKindSchema, backendRegistryResponseSchema, createSelectSeat, gatewaySeatTransport, isBackendRegistryInteractionKind, lineInstanceKey, parseBackendRegistryResponse, parseBackendRegistryResponseBody, parseErrorResponse, parseLineApplicationRequest, parseLineApplicationResult, profileChannelReference, sandboxFailureKind };
|
package/dist/core.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { r as WorkspaceImages, t as SandboxInstance, x as ManagedProcessClient } from "./sandbox-
|
|
1
|
+
import { r as WorkspaceImages, t as SandboxInstance, x as ManagedProcessClient } from "./sandbox-DRZ1nTd3.js";
|
|
2
2
|
import { C as ServerError, D as ValidationError, E as TimeoutError, S as SandboxError, _ as NotFoundError, b as QuotaError, g as NetworkError, l as CapabilityError, p as FileWriteConflictError, r as parseErrorResponse, s as AuthError, v as PartialFailureError, w as StateError, y as ProfileFileMountPathError } from "./errors-CNszZUZ2.js";
|
|
3
|
-
import { a as InstancesClient, d as backendRegistryInteractionKindSchema, f as backendRegistryResponseSchema, h as parseBackendRegistryResponseBody, i as InstanceRestartingError, l as backendRegistryCapabilitiesSchema, m as parseBackendRegistryResponse, p as isBackendRegistryInteractionKind, r as HostedInstance, t as Sandbox, u as backendRegistryEntrySchema } from "./client-
|
|
3
|
+
import { a as InstancesClient, d as backendRegistryInteractionKindSchema, f as backendRegistryResponseSchema, h as parseBackendRegistryResponseBody, i as InstanceRestartingError, l as backendRegistryCapabilitiesSchema, m as parseBackendRegistryResponse, p as isBackendRegistryInteractionKind, r as HostedInstance, t as Sandbox, u as backendRegistryEntrySchema } from "./client-DyKdtYDZ.js";
|
|
4
4
|
import { i as profileChannelReference, r as lineInstanceKey, t as LinesClient } from "./lines-DHOIUO-t.js";
|
|
5
5
|
import { PublicTemplatePublishError, PublicTemplatesClient } from "./public-templates.js";
|
|
6
|
-
import { a as LINE_APPLICATION_REPLY_MAX_CHARS, c as parseLineApplicationResult, i as gatewaySeatTransport, l as sandboxFailureKind, n as SeatSelectionError, o as LINE_APPLICATION_REQUEST_MAX_BYTES, r as createSelectSeat, s as parseLineApplicationRequest, t as ISOLATED_CREATION_ATTESTATION_VERSION } from "./core-
|
|
6
|
+
import { a as LINE_APPLICATION_REPLY_MAX_CHARS, c as parseLineApplicationResult, i as gatewaySeatTransport, l as sandboxFailureKind, n as SeatSelectionError, o as LINE_APPLICATION_REQUEST_MAX_BYTES, r as createSelectSeat, s as parseLineApplicationRequest, t as ISOLATED_CREATION_ATTESTATION_VERSION } from "./core-DDgUWBS7.js";
|
|
7
7
|
export { AuthError, CapabilityError, FileWriteConflictError, HostedInstance, ISOLATED_CREATION_ATTESTATION_VERSION, InstanceRestartingError, InstancesClient, LINE_APPLICATION_REPLY_MAX_CHARS, LINE_APPLICATION_REQUEST_MAX_BYTES, LinesClient, ManagedProcessClient, NetworkError, NotFoundError, PartialFailureError, ProfileFileMountPathError, PublicTemplatePublishError, PublicTemplatesClient, QuotaError, Sandbox, SandboxError, SandboxInstance, SeatSelectionError, ServerError, StateError, TimeoutError, ValidationError, WorkspaceImages, backendRegistryCapabilitiesSchema, backendRegistryEntrySchema, backendRegistryInteractionKindSchema, backendRegistryResponseSchema, createSelectSeat, gatewaySeatTransport, isBackendRegistryInteractionKind, lineInstanceKey, parseBackendRegistryResponse, parseBackendRegistryResponseBody, parseErrorResponse, parseLineApplicationRequest, parseLineApplicationResult, profileChannelReference, sandboxFailureKind };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { $ as ProxySecretReceipt, At as SandboxCreateReceipt, B as InteractionAcknowledgement, C as AgentInteractiveSessionAttach, D as AgentInteractiveSessionPromptAcknowledgement, E as AgentInteractiveSessionControlClaimRequest, F as TerminalOutputEvent, H as InteractionResponseCommand, I as TerminalReplayWindow, M as AgentInteractiveSessionStopCommand, N as AgentInteractiveTerminalSession, O as AgentInteractiveSessionPromptCommand, R as AgentRunCancellationAcknowledgement, S as AgentInteractiveSessionStart, T as AgentInteractiveSessionControlClaimAcknowledgement, U as AgentProfile, V as InteractionRequest, bt as SandboxError, et as InteractionData, g as TerminalReadyInfo, i as TerminalStreamHandlers, j as AgentInteractiveSessionStopAcknowledgement, k as AgentInteractiveSessionRef, l as MintScopedTokenOptions, o as TerminalStreamReconnectAuthority, q as AgentProfileFileMount, u as ScopedToken, w as AgentInteractiveSessionControlClaim, z as AgentRunCancellationRequest } from "./terminal-stream-types-DeH8FF0d.js";
|
|
2
|
-
import { $a as RawEvidenceBoxDirectoryExport, $r as ForkCounts, An as SandboxShape, Ar as DriverInfo, Bi as CreateSessionOptions, C as WorkspaceOperationLookup, Ci as IntelligenceReportWindow, Cn as TerminalStream, D as ProvisionResult, Di as SandboxEvent, E as ProvisionEvent, Ei as PromptResult, Fi as CommitTaskSessionOptions, Fn as EgressManager, G as GitBranch, Ga as ExecResult, Gi as ListMessagesOptions, Ha as CodeExecutionResult, Hi as DispatchPromptOptions, Ia as WorkspaceImagePublishInput, J as GitStatus, Ja as SandboxEnvRecoveryView, Ji as SendSessionMessageRequest, K as GitCommit, Ka as WriteFileRequest, Ki as PublicProfileConflict, Kt as SandboxFleetTraceBundle, La as WorkspaceImagePublishResult, Li as CompletedTurnResult, Ln as NetworkManager, Lr as GpuLeaseManager, Mi as SandboxTraceOptions, Mn as SandboxResourceUsage, Mr as GpuLease, N as WaitForOptions, Nn as SandboxRuntimeCapabilities, Pi as TurnBackendConfig, Qi as SessionExecutionInfo, Qr as BranchOptions, Ri as ConversationTurnOptions, S as StopOptions, Sn as TeePublicKeyResponse, Ti as PromptOptions, Tn as CreateSandboxOptions, U as PreviewLinkManager, Ua as CodeLanguage, Ui as DispatchedSession, Ur as CodeExecutionOptions, Vi as CreateTaskSessionOptions, Wi as DriveTurnOptions, Xa as RawEvidenceArchiveManifest, Xr as HttpClient, Yi as SentSessionMessage, Zi as SessionEventStreamOptions, _ as SnapshotInfo, _r as SearchMatch, aa as SessionMessage, ai as WaitForRolloutOptions, an as SandboxInfo, bi as IntelligenceReportBudget, bn as TeeAttestationResponse, c as SandboxDeleteOptions, ca as SessionResultOptions, co as InteractionResolutionAcknowledgement, cr as FileWriteResult, d as SandboxOperationKind, ei as ForkIdempotency, eo as RawEvidenceBoxExportOptions, f as SandboxOperationState, fa as TaskSessionInfo, ga as BackendConfig, gn as StartupDiagnostics, gr as WriteManyOptions, hi as DurablePlanDecisionResult, hn as SandboxTerminals, hr as WriteManyFile, ia as SessionListOptions, ii as RolloutStartResult, in as SandboxConnection, k as ResumeOptions, ki as SandboxTraceBundle, kn as SandboxStatus, la as TaskSessionChanges, ln as SandboxRuntimeHealth, m as SnapshotDeleteAcknowledgement, ma as TurnDriveResult, mi as DurablePlanDecisionOptions, mr as WriteFileOptions, na as SessionInfo, ni as Rollout, nn as SSHCommandDescriptor, no as RawEvidenceExportOptions, nr as FileSystem, o as RestoreSnapshotOptions, oa as SessionMessageAdmission, on as SandboxPortBinding, oo as RawEvidenceUnavailable, pi as DurablePlan, q as GitDiff, qa as SandboxEnvRecovery, qi as SendSessionMessageOptions, ra as SessionInterruptOptions, ri as RolloutOptions, rn as SSHCredentials, s as SandboxDeleteAcknowledgement, ta as SessionForkOptions, ti as ForkLookupOptions, to as RawEvidenceDirectoryExport, u as SandboxOperationInfo, ua as TaskSessionCommitResult, un as SandboxTerminalAttachOptions, v as SnapshotOptions, va as BackendManager, vi as EventStreamOptions, vn as TeeAttestationOptions, vr as SearchOptions, wi as PromptInputPart, x as SnapshotResult, xi as IntelligenceReportCompareTo, y as SnapshotProvenance, yi as IntelligenceReport, yr as ExecOptions, z as ProcessManager, zi as ConversationTurnResult } from "./types-
|
|
2
|
+
import { $a as RawEvidenceBoxDirectoryExport, $r as ForkCounts, An as SandboxShape, Ar as DriverInfo, Bi as CreateSessionOptions, C as WorkspaceOperationLookup, Ci as IntelligenceReportWindow, Cn as TerminalStream, D as ProvisionResult, Di as SandboxEvent, E as ProvisionEvent, Ei as PromptResult, Fi as CommitTaskSessionOptions, Fn as EgressManager, G as GitBranch, Ga as ExecResult, Gi as ListMessagesOptions, Ha as CodeExecutionResult, Hi as DispatchPromptOptions, Ia as WorkspaceImagePublishInput, J as GitStatus, Ja as SandboxEnvRecoveryView, Ji as SendSessionMessageRequest, K as GitCommit, Ka as WriteFileRequest, Ki as PublicProfileConflict, Kt as SandboxFleetTraceBundle, La as WorkspaceImagePublishResult, Li as CompletedTurnResult, Ln as NetworkManager, Lr as GpuLeaseManager, Mi as SandboxTraceOptions, Mn as SandboxResourceUsage, Mr as GpuLease, N as WaitForOptions, Nn as SandboxRuntimeCapabilities, Pi as TurnBackendConfig, Qi as SessionExecutionInfo, Qr as BranchOptions, Ri as ConversationTurnOptions, S as StopOptions, Sn as TeePublicKeyResponse, Ti as PromptOptions, Tn as CreateSandboxOptions, U as PreviewLinkManager, Ua as CodeLanguage, Ui as DispatchedSession, Ur as CodeExecutionOptions, Vi as CreateTaskSessionOptions, Wi as DriveTurnOptions, Xa as RawEvidenceArchiveManifest, Xr as HttpClient, Yi as SentSessionMessage, Zi as SessionEventStreamOptions, _ as SnapshotInfo, _r as SearchMatch, aa as SessionMessage, ai as WaitForRolloutOptions, an as SandboxInfo, bi as IntelligenceReportBudget, bn as TeeAttestationResponse, c as SandboxDeleteOptions, ca as SessionResultOptions, co as InteractionResolutionAcknowledgement, cr as FileWriteResult, d as SandboxOperationKind, ei as ForkIdempotency, eo as RawEvidenceBoxExportOptions, f as SandboxOperationState, fa as TaskSessionInfo, ga as BackendConfig, gn as StartupDiagnostics, gr as WriteManyOptions, hi as DurablePlanDecisionResult, hn as SandboxTerminals, hr as WriteManyFile, ia as SessionListOptions, ii as RolloutStartResult, in as SandboxConnection, k as ResumeOptions, ki as SandboxTraceBundle, kn as SandboxStatus, la as TaskSessionChanges, ln as SandboxRuntimeHealth, m as SnapshotDeleteAcknowledgement, ma as TurnDriveResult, mi as DurablePlanDecisionOptions, mr as WriteFileOptions, na as SessionInfo, ni as Rollout, nn as SSHCommandDescriptor, no as RawEvidenceExportOptions, nr as FileSystem, o as RestoreSnapshotOptions, oa as SessionMessageAdmission, on as SandboxPortBinding, oo as RawEvidenceUnavailable, pi as DurablePlan, q as GitDiff, qa as SandboxEnvRecovery, qi as SendSessionMessageOptions, ra as SessionInterruptOptions, ri as RolloutOptions, rn as SSHCredentials, s as SandboxDeleteAcknowledgement, ta as SessionForkOptions, ti as ForkLookupOptions, to as RawEvidenceDirectoryExport, u as SandboxOperationInfo, ua as TaskSessionCommitResult, un as SandboxTerminalAttachOptions, v as SnapshotOptions, va as BackendManager, vi as EventStreamOptions, vn as TeeAttestationOptions, vr as SearchOptions, wi as PromptInputPart, x as SnapshotResult, xi as IntelligenceReportCompareTo, y as SnapshotProvenance, yi as IntelligenceReport, yr as ExecOptions, z as ProcessManager, zi as ConversationTurnResult } from "./types-BE70nj5h.js";
|
|
3
3
|
import { t as CliAuthReference } from "./cli-auth-bundle-Wg3x2hd2.js";
|
|
4
|
-
import { n as SandboxLines } from "./lines-
|
|
4
|
+
import { n as SandboxLines } from "./lines-D0dHQ3X5.js";
|
|
5
5
|
import { _ as InteractiveSessionStatus, f as InteractiveAttachOptions, g as InteractiveRequestOptions, h as InteractiveObserveOptions, m as InteractiveControlClaimOptions, p as InteractiveControlClaimAcknowledgement } from "./browser-interactive-control-controller-7wyaNSvi.js";
|
|
6
|
-
import { r as InteractiveAttachRequest } from "./interactive-controller-
|
|
6
|
+
import { r as InteractiveAttachRequest } from "./interactive-controller-BzObb8aT.js";
|
|
7
7
|
import { z } from "zod";
|
|
8
8
|
import { OtlpTraceExport } from "@tangle-network/agent-trace-contract/otlp";
|
|
9
9
|
|
|
@@ -148,8 +148,8 @@ declare class SandboxOperation {
|
|
|
148
148
|
* with a succeeded operation; throws {@link SandboxOperationFailedError} on
|
|
149
149
|
* a failed one and {@link TimeoutError} past `timeoutMs` (default 10 min).
|
|
150
150
|
* The verb was accepted, so a read that was lost, timed out or refused
|
|
151
|
-
* retryably says nothing about it: read again
|
|
152
|
-
*
|
|
151
|
+
* retryably says nothing about it: read again on the shared retry pacing
|
|
152
|
+
* (the server's Retry-After, else full jitter, and the client's retry budget).
|
|
153
153
|
*/
|
|
154
154
|
wait(options?: {
|
|
155
155
|
timeoutMs?: number;
|
|
@@ -874,7 +874,6 @@ declare abstract class SandboxLifecycleEventsCapabilities extends SandboxPreview
|
|
|
874
874
|
* the same wait and error semantics.
|
|
875
875
|
*/
|
|
876
876
|
protected consumerConnectionReady(): boolean;
|
|
877
|
-
protected sleep(ms: number): Promise<void>;
|
|
878
877
|
}
|
|
879
878
|
//#endregion
|
|
880
879
|
//#region src/sandbox-lifecycle.d.ts
|