tensorlake 0.5.142 → 0.5.143
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/dist/applications/index.cjs +16 -7
- package/dist/applications/index.cjs.map +1 -1
- package/dist/applications/index.d.cts +2 -2
- package/dist/applications/index.d.ts +2 -2
- package/dist/applications/index.js +16 -7
- package/dist/applications/index.js.map +1 -1
- package/dist/function-agent/main.cjs +1 -1
- package/dist/function-agent/main.js +1 -1
- package/dist/function-executor/main.cjs +2 -2
- package/dist/function-executor/main.js +2 -2
- package/dist/index.cjs +18 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +9 -5
- package/dist/index.d.ts +9 -5
- package/dist/index.js +18 -9
- package/dist/index.js.map +1 -1
- package/dist/{remote-D95Y6Czr.d.cts → remote-CNJ9TmcQ.d.cts} +2 -1
- package/dist/{remote-omwTzbfj.d.ts → remote-dblFxKug.d.ts} +2 -1
- package/dist/sandbox-image.cjs +2 -2
- package/dist/sandbox-image.cjs.map +1 -1
- package/dist/sandbox-image.js +2 -2
- package/dist/sandbox-image.js.map +1 -1
- package/package.json +7 -7
- package/runtime/function-executor/manifest.json +5 -5
- package/runtime/function-executor/package/dist/function-executor/main.js +2 -2
- package/runtime/function-executor/package/npm-shrinkwrap.json +2 -2
- package/runtime/function-executor/package/package.json +1 -1
- package/runtime/typescript-function-runner/manifest.json +5 -5
- package/runtime/typescript-function-runner/package/dist/function-agent/main.js +1 -1
- package/runtime/typescript-function-runner/package/npm-shrinkwrap.json +20 -20
- package/runtime/typescript-function-runner/package/package.json +7 -7
package/dist/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { C as CloudClientOptions, A as ApplicationManifest, B as BinaryPayload, S as SandboxTemplate, a as ApplicationSummary, R as RequestInput, c as RequestMetadata, b as RequestOutput, d as SecretsList, e as Secret, N as NewSecret, U as UpsertSecretResponse, f as StartImageBuildRequest, g as BuildInfo, h as CreateApplicationBuildRequest, i as ApplicationBuildContext, j as ApplicationBuildResponse, k as BuildLogEntry, F as FileSystem } from './sandbox-image-ChzWDeZy.cjs';
|
|
2
2
|
export { l as ApplicationBuildImageResult, m as CreateApplicationBuildImageRequest, n as CreateSandboxImageOptions, I as Image, o as ImageBuildOperation, p as ImageBuildOperationType, p as ImageBuildOperationTypeValue, q as ImageOptions, r as ImportSandboxImageOptions, s as RequestErrorInfo, t as SandboxImageSource, u as SecretsPagination, v as createSandboxImage, w as deleteSandboxImage, x as dockerfileContent, y as findSandboxImageByName, z as importSandboxImage, D as listSandboxImages } from './sandbox-image-ChzWDeZy.cjs';
|
|
3
|
-
export { v as APIClient, A as ApplicationCapability, a as ApplicationOptions, F as File, b as FunctionOptions, c as Future, H as Headers, d as HeadersInit, e as HttpBody, P as Parameter, g as RegisteredFunction, h as RemoteOptions, j as RequestContext, S as Schema, l as SimpleApplicationOptions, m as SimpleFunctionOptions, T as TailCall, r as registerApplication, o as registerFunction, p as remoteOptions, q as retries, s as runLocal, t as runRemote, u as schema } from './remote-
|
|
3
|
+
export { v as APIClient, A as ApplicationCapability, a as ApplicationOptions, F as File, b as FunctionOptions, c as Future, H as Headers, d as HeadersInit, e as HttpBody, P as Parameter, g as RegisteredFunction, h as RemoteOptions, j as RequestContext, S as Schema, l as SimpleApplicationOptions, m as SimpleFunctionOptions, T as TailCall, r as registerApplication, o as registerFunction, p as remoteOptions, q as retries, s as runLocal, t as runRemote, u as schema } from './remote-CNJ9TmcQ.cjs';
|
|
4
4
|
|
|
5
5
|
/** An SDK result paired with its server-side W3C trace ID. */
|
|
6
6
|
type Traced<T> = T & {
|
|
@@ -116,7 +116,7 @@ interface NativeRepositoryClient {
|
|
|
116
116
|
pushWorktree(repo: string, root: string, branch: string, message: string, expectOid?: string | null): Promise<TracedJson>;
|
|
117
117
|
mergeRepo(repo: string, ours: string, theirs: string, preflight: boolean, deep: boolean, materialize: boolean, message?: string | null, base?: string | null): Promise<TracedJson>;
|
|
118
118
|
commitConflicts(repo: string, commit: string): Promise<TracedJson>;
|
|
119
|
-
createFilesystem(name: string): Promise<string>;
|
|
119
|
+
createFilesystem(name: string, region?: string): Promise<string>;
|
|
120
120
|
forkFilesystem(name: string, base: string, snapshot?: string | null): Promise<TracedJson>;
|
|
121
121
|
listFilesystems(): Promise<TracedJson>;
|
|
122
122
|
filesystemMeta(name: string): Promise<TracedJson>;
|
|
@@ -1996,7 +1996,9 @@ declare class RepositoryClient {
|
|
|
1996
1996
|
* running sandbox.
|
|
1997
1997
|
*/
|
|
1998
1998
|
/** Register a new file system for the current project. */
|
|
1999
|
-
declare function createFileSystem(name: string, description?: string
|
|
1999
|
+
declare function createFileSystem(name: string, description?: string, options?: {
|
|
2000
|
+
region?: string;
|
|
2001
|
+
}): Promise<FileSystem>;
|
|
2000
2002
|
/** List all registered file systems for the current project. */
|
|
2001
2003
|
declare function listFileSystems(): Promise<FileSystem[]>;
|
|
2002
2004
|
/** Delete a registered file system by its id (e.g. `file_system_...`). */
|
|
@@ -2177,8 +2179,10 @@ declare class FilesystemClient {
|
|
|
2177
2179
|
* options are retained only for the separately installed `tl` CLI used by local mounts.
|
|
2178
2180
|
*/
|
|
2179
2181
|
constructor(options?: FilesystemClientOptions);
|
|
2180
|
-
/** Create a
|
|
2181
|
-
create(name: string
|
|
2182
|
+
/** Create a filesystem; region fixes its storage placement. Forks inherit placement. */
|
|
2183
|
+
create(name: string, options?: {
|
|
2184
|
+
region?: string;
|
|
2185
|
+
}): Promise<Filesystem>;
|
|
2182
2186
|
/**
|
|
2183
2187
|
* Fork a filesystem at its live head or an explicit retained snapshot.
|
|
2184
2188
|
* The server shares immutable content and publishes only metadata.
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { C as CloudClientOptions, A as ApplicationManifest, B as BinaryPayload, S as SandboxTemplate, a as ApplicationSummary, R as RequestInput, c as RequestMetadata, b as RequestOutput, d as SecretsList, e as Secret, N as NewSecret, U as UpsertSecretResponse, f as StartImageBuildRequest, g as BuildInfo, h as CreateApplicationBuildRequest, i as ApplicationBuildContext, j as ApplicationBuildResponse, k as BuildLogEntry, F as FileSystem } from './sandbox-image-ChzWDeZy.js';
|
|
2
2
|
export { l as ApplicationBuildImageResult, m as CreateApplicationBuildImageRequest, n as CreateSandboxImageOptions, I as Image, o as ImageBuildOperation, p as ImageBuildOperationType, p as ImageBuildOperationTypeValue, q as ImageOptions, r as ImportSandboxImageOptions, s as RequestErrorInfo, t as SandboxImageSource, u as SecretsPagination, v as createSandboxImage, w as deleteSandboxImage, x as dockerfileContent, y as findSandboxImageByName, z as importSandboxImage, D as listSandboxImages } from './sandbox-image-ChzWDeZy.js';
|
|
3
|
-
export { v as APIClient, A as ApplicationCapability, a as ApplicationOptions, F as File, b as FunctionOptions, c as Future, H as Headers, d as HeadersInit, e as HttpBody, P as Parameter, g as RegisteredFunction, h as RemoteOptions, j as RequestContext, S as Schema, l as SimpleApplicationOptions, m as SimpleFunctionOptions, T as TailCall, r as registerApplication, o as registerFunction, p as remoteOptions, q as retries, s as runLocal, t as runRemote, u as schema } from './remote-
|
|
3
|
+
export { v as APIClient, A as ApplicationCapability, a as ApplicationOptions, F as File, b as FunctionOptions, c as Future, H as Headers, d as HeadersInit, e as HttpBody, P as Parameter, g as RegisteredFunction, h as RemoteOptions, j as RequestContext, S as Schema, l as SimpleApplicationOptions, m as SimpleFunctionOptions, T as TailCall, r as registerApplication, o as registerFunction, p as remoteOptions, q as retries, s as runLocal, t as runRemote, u as schema } from './remote-dblFxKug.js';
|
|
4
4
|
|
|
5
5
|
/** An SDK result paired with its server-side W3C trace ID. */
|
|
6
6
|
type Traced<T> = T & {
|
|
@@ -116,7 +116,7 @@ interface NativeRepositoryClient {
|
|
|
116
116
|
pushWorktree(repo: string, root: string, branch: string, message: string, expectOid?: string | null): Promise<TracedJson>;
|
|
117
117
|
mergeRepo(repo: string, ours: string, theirs: string, preflight: boolean, deep: boolean, materialize: boolean, message?: string | null, base?: string | null): Promise<TracedJson>;
|
|
118
118
|
commitConflicts(repo: string, commit: string): Promise<TracedJson>;
|
|
119
|
-
createFilesystem(name: string): Promise<string>;
|
|
119
|
+
createFilesystem(name: string, region?: string): Promise<string>;
|
|
120
120
|
forkFilesystem(name: string, base: string, snapshot?: string | null): Promise<TracedJson>;
|
|
121
121
|
listFilesystems(): Promise<TracedJson>;
|
|
122
122
|
filesystemMeta(name: string): Promise<TracedJson>;
|
|
@@ -1996,7 +1996,9 @@ declare class RepositoryClient {
|
|
|
1996
1996
|
* running sandbox.
|
|
1997
1997
|
*/
|
|
1998
1998
|
/** Register a new file system for the current project. */
|
|
1999
|
-
declare function createFileSystem(name: string, description?: string
|
|
1999
|
+
declare function createFileSystem(name: string, description?: string, options?: {
|
|
2000
|
+
region?: string;
|
|
2001
|
+
}): Promise<FileSystem>;
|
|
2000
2002
|
/** List all registered file systems for the current project. */
|
|
2001
2003
|
declare function listFileSystems(): Promise<FileSystem[]>;
|
|
2002
2004
|
/** Delete a registered file system by its id (e.g. `file_system_...`). */
|
|
@@ -2177,8 +2179,10 @@ declare class FilesystemClient {
|
|
|
2177
2179
|
* options are retained only for the separately installed `tl` CLI used by local mounts.
|
|
2178
2180
|
*/
|
|
2179
2181
|
constructor(options?: FilesystemClientOptions);
|
|
2180
|
-
/** Create a
|
|
2181
|
-
create(name: string
|
|
2182
|
+
/** Create a filesystem; region fixes its storage placement. Forks inherit placement. */
|
|
2183
|
+
create(name: string, options?: {
|
|
2184
|
+
region?: string;
|
|
2185
|
+
}): Promise<Filesystem>;
|
|
2182
2186
|
/**
|
|
2183
2187
|
* Fork a filesystem at its live head or an explicit retained snapshot.
|
|
2184
2188
|
* The server shares immutable content and publishes only metadata.
|
package/dist/index.js
CHANGED
|
@@ -46,7 +46,7 @@ var init_defaults = __esm({
|
|
|
46
46
|
"src/defaults.ts"() {
|
|
47
47
|
"use strict";
|
|
48
48
|
init_esm_shims();
|
|
49
|
-
SDK_VERSION = "0.5.
|
|
49
|
+
SDK_VERSION = "0.5.143";
|
|
50
50
|
API_URL = process.env.TENSORLAKE_API_URL ?? "https://api.tensorlake.ai";
|
|
51
51
|
API_KEY = process.env.TENSORLAKE_API_KEY ?? void 0;
|
|
52
52
|
NAMESPACE = process.env.INDEXIFY_NAMESPACE ?? "default";
|
|
@@ -490,7 +490,7 @@ var init_native_worker_client = __esm({
|
|
|
490
490
|
}
|
|
491
491
|
};
|
|
492
492
|
runtimeKey = /* @__PURE__ */ Symbol.for(
|
|
493
|
-
`tensorlake.native.worker.${false ? "source" : "0.5.
|
|
493
|
+
`tensorlake.native.worker.${false ? "source" : "0.5.143"}.v1`
|
|
494
494
|
);
|
|
495
495
|
runtimes = globalThis;
|
|
496
496
|
}
|
|
@@ -7319,15 +7319,21 @@ var FilesystemClient = class {
|
|
|
7319
7319
|
this.cli = new FsCli(envOverrides);
|
|
7320
7320
|
}
|
|
7321
7321
|
// -- lifecycle --------------------------------------------------------------
|
|
7322
|
-
/** Create a
|
|
7323
|
-
async create(name) {
|
|
7322
|
+
/** Create a filesystem; region fixes its storage placement. Forks inherit placement. */
|
|
7323
|
+
async create(name, options = {}) {
|
|
7324
7324
|
if (typeof name !== "string") {
|
|
7325
7325
|
throw new TypeError("name must be a string");
|
|
7326
7326
|
}
|
|
7327
7327
|
if (name.length === 0) {
|
|
7328
7328
|
throw new FilesystemError("filesystem name must not be empty");
|
|
7329
7329
|
}
|
|
7330
|
-
const
|
|
7330
|
+
const { region } = options;
|
|
7331
|
+
if (region !== void 0 && (typeof region !== "string" || region.length === 0 || region.trim() !== region)) {
|
|
7332
|
+
throw new FilesystemError(
|
|
7333
|
+
"region must be a nonempty string without surrounding whitespace"
|
|
7334
|
+
);
|
|
7335
|
+
}
|
|
7336
|
+
const raw = await callNative2(() => region === void 0 ? this.native.createFilesystem(name) : this.native.createFilesystem(name, region));
|
|
7331
7337
|
const created = JSON.parse(raw);
|
|
7332
7338
|
return new Filesystem(
|
|
7333
7339
|
this,
|
|
@@ -7783,8 +7789,11 @@ var APIClient = class {
|
|
|
7783
7789
|
async deleteSandboxImage(imageName) {
|
|
7784
7790
|
await this.cloudClient.deleteSandboxImage(imageName);
|
|
7785
7791
|
}
|
|
7786
|
-
async createFileSystem(name, description,
|
|
7787
|
-
const filesystem = await new FilesystemClient(this.filesystemOptions).create(
|
|
7792
|
+
async createFileSystem(name, description, options) {
|
|
7793
|
+
const filesystem = await new FilesystemClient(this.filesystemOptions).create(
|
|
7794
|
+
name,
|
|
7795
|
+
{ region: options?.region }
|
|
7796
|
+
);
|
|
7788
7797
|
return {
|
|
7789
7798
|
id: filesystem.name,
|
|
7790
7799
|
name: filesystem.name,
|
|
@@ -8185,11 +8194,11 @@ init_sandbox_image();
|
|
|
8185
8194
|
|
|
8186
8195
|
// src/file-system.ts
|
|
8187
8196
|
init_esm_shims();
|
|
8188
|
-
async function createFileSystem(name, description) {
|
|
8197
|
+
async function createFileSystem(name, description, options = {}) {
|
|
8189
8198
|
if (typeof name !== "string" || name.length === 0) {
|
|
8190
8199
|
throw new TypeError("name must be a non-empty string");
|
|
8191
8200
|
}
|
|
8192
|
-
const filesystem = await new FilesystemClient().create(name);
|
|
8201
|
+
const filesystem = await new FilesystemClient().create(name, options);
|
|
8193
8202
|
return {
|
|
8194
8203
|
id: filesystem.name,
|
|
8195
8204
|
name: filesystem.name,
|