@dreamlake/dreamlake-cli 0.111.2 → 0.112.0
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/api/skills.js +1 -1
- package/dist/cli/agents/index.js +20 -20
- package/dist/cli/agents/manage.js +1 -1
- package/dist/cli/artifact/index.js +5 -5
- package/dist/cli/artifact/meta.js +1 -1
- package/dist/cli/auth/commands.d.ts +2 -2
- package/dist/cli/auth/commands.js +9 -9
- package/dist/cli/auth/device-flow.js +2 -2
- package/dist/cli/auth/materialized.d.ts +1 -1
- package/dist/cli/auth/materialized.js +1 -1
- package/dist/cli/compat/http.js +2 -2
- package/dist/cli/compat/presignedTransfer.js +2 -2
- package/dist/cli/config.js +2 -2
- package/dist/cli/connection/index.js +8 -8
- package/dist/cli/connection/oauth.js +3 -3
- package/dist/cli/connection/write.js +6 -6
- package/dist/cli/create/index.js +2 -2
- package/dist/cli/declare/index.js +14 -14
- package/dist/cli/delete/index.js +4 -4
- package/dist/cli/download/index.js +3 -3
- package/dist/cli/env/compose.js +1 -1
- package/dist/cli/env/index.js +9 -9
- package/dist/cli/experiments/index.js +2 -2
- package/dist/cli/experiments/native-commands.js +1 -1
- package/dist/cli/experiments/native-run-data.js +1 -1
- package/dist/cli/graphql.js +1 -1
- package/dist/cli/help-examples.generated.js +253 -253
- package/dist/cli/hosts/bootstrap-source.d.ts +1 -1
- package/dist/cli/hosts/bootstrap-source.js +1 -1
- package/dist/cli/hosts/inventory.js +2 -2
- package/dist/cli/hosts/picker.js +2 -2
- package/dist/cli/hosts/ssh.js +1 -1
- package/dist/cli/hosts/upgrade.d.ts +2 -2
- package/dist/cli/hosts/upgrade.js +3 -3
- package/dist/cli/index.js +7 -3
- package/dist/cli/lakeshore/connections.js +1 -1
- package/dist/cli/lakeshore/index.d.ts +1 -1
- package/dist/cli/lakeshore/index.js +4 -4
- package/dist/cli/launch/index.js +10 -10
- package/dist/cli/library/add.js +4 -4
- package/dist/cli/library/cache.js +1 -1
- package/dist/cli/library/discover.js +1 -1
- package/dist/cli/library/freshness.js +1 -1
- package/dist/cli/library/index.js +1 -1
- package/dist/cli/library/info.js +1 -1
- package/dist/cli/library/manifest.js +1 -1
- package/dist/cli/library/pull.js +1 -1
- package/dist/cli/library/push.js +2 -2
- package/dist/cli/library/rm.js +2 -2
- package/dist/cli/library/search.js +2 -2
- package/dist/cli/library/stat.js +1 -1
- package/dist/cli/library/tools.js +1 -1
- package/dist/cli/library/wire.js +1 -1
- package/dist/cli/list/index.js +4 -4
- package/dist/cli/memos/document.d.ts +1 -1
- package/dist/cli/memos/document.js +1 -1
- package/dist/cli/memos/edit-commands.d.ts +2 -2
- package/dist/cli/memos/edit-commands.js +2 -2
- package/dist/cli/memos/files-commands.d.ts +1 -1
- package/dist/cli/memos/files-commands.js +2 -2
- package/dist/cli/memos/index.js +7 -7
- package/dist/cli/memos/media-commands.js +1 -1
- package/dist/cli/memos/move-command.js +2 -2
- package/dist/cli/memos/rm-command.d.ts +1 -1
- package/dist/cli/memos/rm-command.js +2 -2
- package/dist/cli/namespace.js +2 -2
- package/dist/cli/nymph/index.js +4 -4
- package/dist/cli/ownership/index.js +1 -1
- package/dist/cli/ownership/metadata-transfer.js +2 -2
- package/dist/cli/page/index.js +5 -5
- package/dist/cli/pipeline/index.js +5 -5
- package/dist/cli/project/attachments.js +1 -1
- package/dist/cli/project/grants.js +1 -1
- package/dist/cli/project/index.js +1 -1
- package/dist/cli/project/move.js +3 -3
- package/dist/cli/project/stream.js +2 -2
- package/dist/cli/provider/dreamdir.js +2 -2
- package/dist/cli/provider/index.js +18 -18
- package/dist/cli/provider/lifecycle.js +14 -14
- package/dist/cli/python.js +4 -4
- package/dist/cli/queues/index.js +4 -4
- package/dist/cli/queues/slurm.js +2 -2
- package/dist/cli/resources.js +2 -2
- package/dist/cli/run/index.js +1 -1
- package/dist/cli/runconfig/index.js +3 -3
- package/dist/cli/runnable/bound.js +3 -3
- package/dist/cli/runnable/index.js +14 -14
- package/dist/cli/runnable/path.d.ts +1 -1
- package/dist/cli/runnable/path.js +1 -1
- package/dist/cli/self-update/alias-migration.d.ts +11 -0
- package/dist/cli/self-update/alias-migration.js +56 -0
- package/dist/cli/self-update/index.d.ts +1 -1
- package/dist/cli/self-update/index.js +5 -5
- package/dist/cli/self-update/install.js +2 -2
- package/dist/cli/self-update/update.d.ts +1 -1
- package/dist/cli/self-update/update.js +7 -7
- package/dist/cli/session-affiliation.js +1 -1
- package/dist/cli/sessions/control.d.ts +1 -1
- package/dist/cli/sessions/control.js +2 -2
- package/dist/cli/sessions/index.js +5 -5
- package/dist/cli/sessions/live.js +1 -1
- package/dist/cli/sessions/runner/serve.js +1 -1
- package/dist/cli/sessions/wrap.d.ts +2 -2
- package/dist/cli/sessions/wrap.js +8 -8
- package/dist/cli/skill/index.js +22 -22
- package/dist/cli/skill/prefs.js +1 -1
- package/dist/cli/skill/read.js +3 -3
- package/dist/cli/skill/registry.js +2 -2
- package/dist/cli/snapshot/index.js +9 -9
- package/dist/cli/source/access.js +3 -3
- package/dist/cli/source/control.js +8 -8
- package/dist/cli/source/delete.js +6 -6
- package/dist/cli/source/index.js +14 -14
- package/dist/cli/source/share.js +8 -8
- package/dist/cli/source/upload.d.ts +1 -1
- package/dist/cli/source/upload.js +2 -2
- package/dist/cli/source/write.js +2 -2
- package/dist/cli/spawn.js +1 -1
- package/dist/cli/tasks/index.js +1 -1
- package/dist/cli/update/index.js +2 -2
- package/dist/cli/upload/index.js +3 -3
- package/dist/cli/upload/multipart.js +1 -1
- package/dist/cli/vault/index.js +1 -1
- package/dist/cli/vault/sshSync.js +1 -1
- package/dist/cli/version.d.ts +1 -1
- package/dist/cli/version.js +1 -1
- package/dist/cli/workflow/index.d.ts +1 -1
- package/dist/cli/workflow/index.js +6 -6
- package/package.json +10 -10
|
@@ -415,7 +415,7 @@ export async function runSourceDelete(opts) {
|
|
|
415
415
|
` Its Project and Bindr references were removed in the same transaction.\n` +
|
|
416
416
|
` The name stays taken until the cleanup succeeds.\n` +
|
|
417
417
|
` Check it with:\n` +
|
|
418
|
-
`
|
|
418
|
+
` dl source delete-source-status ${created.operationId}\n`);
|
|
419
419
|
}
|
|
420
420
|
return 0;
|
|
421
421
|
}
|
|
@@ -474,7 +474,7 @@ export async function runSourceDeleteRetry(operationId, opts) {
|
|
|
474
474
|
fail(`${explainWrite(err)}\n` +
|
|
475
475
|
` The server may or may not have rescheduled it, and this endpoint has no\n` +
|
|
476
476
|
` idempotency key. Read the state instead:\n` +
|
|
477
|
-
`
|
|
477
|
+
` dl source delete-source-status ${operationId}`);
|
|
478
478
|
return 1;
|
|
479
479
|
}
|
|
480
480
|
fail(explainWrite(err));
|
|
@@ -485,7 +485,7 @@ export async function runSourceDeleteRetry(operationId, opts) {
|
|
|
485
485
|
export function registerSourceControlCommands(source) {
|
|
486
486
|
strictArgs(source.command("external-set"))
|
|
487
487
|
.description("attach or replace a source's external layer")
|
|
488
|
-
.requiredOption("--source <name>", "source name (see '
|
|
488
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
489
489
|
.requiredOption("--connector <kind>", "connector kind (e.g. s3, huggingface)")
|
|
490
490
|
.requiredOption("--target <json>", "connector target, as JSON")
|
|
491
491
|
.option("--connection <id>", "connection to authenticate with")
|
|
@@ -497,34 +497,34 @@ export function registerSourceControlCommands(source) {
|
|
|
497
497
|
.action(async (opts) => process.exit(await runExternalSet(opts)));
|
|
498
498
|
strictArgs(source.command("external-remove"))
|
|
499
499
|
.description("detach a source's external layer (the provider is untouched)")
|
|
500
|
-
.requiredOption("--source <name>", "source name (see '
|
|
500
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
501
501
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
502
502
|
.option("--idempotency-key <key>", "reuse a key from an attempt that never answered")
|
|
503
503
|
.option("--json", "emit JSON")
|
|
504
504
|
.action(async (opts) => process.exit(await runExternalRemove(opts)));
|
|
505
505
|
strictArgs(source.command("enable"))
|
|
506
506
|
.description("enable a source (its configuration is validated first)")
|
|
507
|
-
.requiredOption("--source <name>", "source name (see '
|
|
507
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
508
508
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
509
509
|
.option("--idempotency-key <key>", "reuse a key from an attempt that never answered")
|
|
510
510
|
.option("--json", "emit JSON")
|
|
511
511
|
.action(async (opts) => process.exit(await runLifecycle("enable", opts)));
|
|
512
512
|
strictArgs(source.command("disable"))
|
|
513
513
|
.description("disable a source")
|
|
514
|
-
.requiredOption("--source <name>", "source name (see '
|
|
514
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
515
515
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
516
516
|
.option("--idempotency-key <key>", "reuse a key from an attempt that never answered")
|
|
517
517
|
.option("--json", "emit JSON")
|
|
518
518
|
.action(async (opts) => process.exit(await runLifecycle("disable", opts)));
|
|
519
519
|
strictArgs(source.command("check-access"))
|
|
520
520
|
.description("probe a source's upstream (changes nothing)")
|
|
521
|
-
.requiredOption("--source <name>", "source name (see '
|
|
521
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
522
522
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
523
523
|
.option("--json", "emit JSON")
|
|
524
524
|
.action(async (opts) => process.exit(await runCheckAccess(opts)));
|
|
525
525
|
strictArgs(source.command("delete-source"))
|
|
526
526
|
.description("queue deletion of a whole source")
|
|
527
|
-
.requiredOption("--source <name>", "source name (see '
|
|
527
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
528
528
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
529
529
|
.option("--idempotency-key <key>", "reuse a key from an attempt that never answered")
|
|
530
530
|
.option("--json", "emit JSON")
|
|
@@ -299,7 +299,7 @@ export async function runDeletePrefix(path, opts) {
|
|
|
299
299
|
else {
|
|
300
300
|
process.stdout.write(` state ${created.state}\n` +
|
|
301
301
|
` Check it with:\n` +
|
|
302
|
-
`
|
|
302
|
+
` dl source delete-status ${created.operationId}\n${UNCOVER_NOTE}\n`);
|
|
303
303
|
}
|
|
304
304
|
return 0;
|
|
305
305
|
}
|
|
@@ -326,7 +326,7 @@ export async function runDeletePrefix(path, opts) {
|
|
|
326
326
|
}
|
|
327
327
|
else {
|
|
328
328
|
process.stdout.write(` still ${state} after ${Math.round(WAIT_TIMEOUT_MS / 1000)}s — check it with:\n` +
|
|
329
|
-
`
|
|
329
|
+
` dl source delete-status ${created.operationId}\n`);
|
|
330
330
|
}
|
|
331
331
|
return 0;
|
|
332
332
|
}
|
|
@@ -339,7 +339,7 @@ export async function runDeletePrefix(path, opts) {
|
|
|
339
339
|
// The deletion is running regardless of whether this poll worked.
|
|
340
340
|
fail(`${explainWrite(err)}\n` +
|
|
341
341
|
` The deletion is still ${state}. Check it with:\n` +
|
|
342
|
-
`
|
|
342
|
+
` dl source delete-status ${created.operationId}`);
|
|
343
343
|
return 1;
|
|
344
344
|
}
|
|
345
345
|
}
|
|
@@ -353,7 +353,7 @@ export async function runDeletePrefix(path, opts) {
|
|
|
353
353
|
// command does not start a second one.
|
|
354
354
|
if (latest.state === "failed") {
|
|
355
355
|
if (!opts.json) {
|
|
356
|
-
process.stdout.write(` Retry it with:\n
|
|
356
|
+
process.stdout.write(` Retry it with:\n dl source delete-retry ${latest.id}\n`);
|
|
357
357
|
}
|
|
358
358
|
return 1;
|
|
359
359
|
}
|
|
@@ -433,7 +433,7 @@ export function registerSourceDeleteCommands(source) {
|
|
|
433
433
|
strictArgs(source.command("delete-object"))
|
|
434
434
|
.description("delete one managed object (immediate, physical)")
|
|
435
435
|
.argument("<path>", "path within the source")
|
|
436
|
-
.requiredOption("--source <name>", "source name (see '
|
|
436
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
437
437
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
438
438
|
.option("--idempotency-key <key>", "reuse a key from an attempt that never answered")
|
|
439
439
|
.option("--json", "emit JSON")
|
|
@@ -441,7 +441,7 @@ export function registerSourceDeleteCommands(source) {
|
|
|
441
441
|
strictArgs(source.command("delete-prefix"))
|
|
442
442
|
.description("queue a recursive delete of one managed directory")
|
|
443
443
|
.argument("<path>", "directory path within the source")
|
|
444
|
-
.requiredOption("--source <name>", "source name (see '
|
|
444
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
445
445
|
.option("--wait", "watch until the operation finishes")
|
|
446
446
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
447
447
|
.option("--idempotency-key <key>", "reuse a key from an attempt that never answered")
|
package/dist/cli/source/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { collectionList } from "../collection-list.js";
|
|
2
|
-
// `
|
|
2
|
+
// `dl source ...` — read data out of connected sources (S3 and Hugging
|
|
3
3
|
// Face; those are the two connectors Source v1 has).
|
|
4
4
|
//
|
|
5
5
|
// A Source is a *named*, credentialed connection stored server-side; the CLI
|
|
@@ -65,13 +65,13 @@ const CONCURRENCY = 6;
|
|
|
65
65
|
export async function ctx(nsFlag) {
|
|
66
66
|
const token = resolveToken();
|
|
67
67
|
if (!token) {
|
|
68
|
-
fail("not authenticated — run '
|
|
68
|
+
fail("not authenticated — run 'dl login' first");
|
|
69
69
|
return null;
|
|
70
70
|
}
|
|
71
71
|
const remote = resolveRemote();
|
|
72
72
|
const ns = await resolveNamespace(nsFlag, { token, remote });
|
|
73
73
|
if (!ns) {
|
|
74
|
-
fail("could not resolve namespace — run '
|
|
74
|
+
fail("could not resolve namespace — run 'dl login' or pass --namespace");
|
|
75
75
|
return null;
|
|
76
76
|
}
|
|
77
77
|
return { token, remote, ns };
|
|
@@ -102,7 +102,7 @@ export function seg(v) {
|
|
|
102
102
|
export function explain(err) {
|
|
103
103
|
if (err instanceof HttpError) {
|
|
104
104
|
if (err.status === 401)
|
|
105
|
-
return "not authenticated — run '
|
|
105
|
+
return "not authenticated — run 'dl login' first";
|
|
106
106
|
if (err.status === 403)
|
|
107
107
|
return "permission denied — you need read access to this namespace";
|
|
108
108
|
}
|
|
@@ -497,7 +497,7 @@ export async function resolveSource(c, name) {
|
|
|
497
497
|
return hit;
|
|
498
498
|
if (near.length === 0) {
|
|
499
499
|
throw new Error(`source '${name}' not found in namespace '${c.ns}' — no source's name contains it. ` +
|
|
500
|
-
`See what exists:
|
|
500
|
+
`See what exists: dl source list --namespace ${c.ns}`);
|
|
501
501
|
}
|
|
502
502
|
throw new Error(`source '${name}' not found in namespace '${c.ns}'. did you mean: ${near
|
|
503
503
|
.map((s) => s.name)
|
|
@@ -669,7 +669,7 @@ function shellQuote(v) {
|
|
|
669
669
|
* page of what was on screen.
|
|
670
670
|
*/
|
|
671
671
|
function listContinuation(ns, opts, cursor) {
|
|
672
|
-
const parts = ["
|
|
672
|
+
const parts = ["dl source list", `--namespace ${ns}`];
|
|
673
673
|
if (opts.nameContains !== undefined)
|
|
674
674
|
parts.push(`--name-contains ${shellQuote(opts.nameContains)}`);
|
|
675
675
|
if (opts.provider !== undefined)
|
|
@@ -911,7 +911,7 @@ export async function runSourceConnectors(opts) {
|
|
|
911
911
|
process.stdout.write("\n connection: required — import must name one with --connection\n" +
|
|
912
912
|
" optional — it may, and works without\n" +
|
|
913
913
|
" none — it takes none\n" +
|
|
914
|
-
` See what you have:
|
|
914
|
+
` See what you have: dl connection list --namespace ${c.ns}\n`);
|
|
915
915
|
return 0;
|
|
916
916
|
}
|
|
917
917
|
catch (err) {
|
|
@@ -1051,10 +1051,10 @@ export async function runSourceFetch(pathArg, opts) {
|
|
|
1051
1051
|
*/
|
|
1052
1052
|
if (requiresHeaders(cap)) {
|
|
1053
1053
|
fail("this capability requires request headers, so a bare URL cannot be used — " +
|
|
1054
|
-
"run with --json to get the full capability, or use '
|
|
1054
|
+
"run with --json to get the full capability, or use 'dl source download'");
|
|
1055
1055
|
return 1;
|
|
1056
1056
|
}
|
|
1057
|
-
// URL alone on stdout so `$(
|
|
1057
|
+
// URL alone on stdout so `$(dl source fetch …)` is directly usable.
|
|
1058
1058
|
process.stdout.write(`${cap.url}\n`);
|
|
1059
1059
|
process.stderr.write(`→ valid ${expiryNote(cap.expiresAt)}\n`);
|
|
1060
1060
|
return 0;
|
|
@@ -1206,7 +1206,7 @@ export async function runSourceDownload(pathArg, opts) {
|
|
|
1206
1206
|
plan = downloadable.map((e) => ({
|
|
1207
1207
|
remote: e.path,
|
|
1208
1208
|
// Preserve the tree *below* the requested root, matching
|
|
1209
|
-
// `aws s3 cp --recursive` and the existing `
|
|
1209
|
+
// `aws s3 cp --recursive` and the existing `dl download`.
|
|
1210
1210
|
local: path.join(outDir, path.relative(root, e.path) || path.basename(e.path)),
|
|
1211
1211
|
size: e.size,
|
|
1212
1212
|
}));
|
|
@@ -1270,7 +1270,7 @@ export function strictArgs(cmd) {
|
|
|
1270
1270
|
process.stderr.write(str);
|
|
1271
1271
|
if (str.includes("too many arguments")) {
|
|
1272
1272
|
process.stderr.write("\nA path with spaces has to be quoted:\n" +
|
|
1273
|
-
'
|
|
1273
|
+
' dl source fetch --source my-src "folder/my file.mov"\n');
|
|
1274
1274
|
}
|
|
1275
1275
|
},
|
|
1276
1276
|
});
|
|
@@ -1312,7 +1312,7 @@ export function registerSourceCommand(program) {
|
|
|
1312
1312
|
strictArgs(source.command("browse"))
|
|
1313
1313
|
.description("list directories and files inside a source (one level; -r to recurse)")
|
|
1314
1314
|
.argument("[path]", "path within the source (default: root)")
|
|
1315
|
-
.requiredOption("--source <name>", "source name (see '
|
|
1315
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
1316
1316
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
1317
1317
|
.option("--dirs", "list only directories")
|
|
1318
1318
|
.option("--files", "list only files (for piping into fetch/download)")
|
|
@@ -1324,7 +1324,7 @@ export function registerSourceCommand(program) {
|
|
|
1324
1324
|
strictArgs(source.command("fetch"))
|
|
1325
1325
|
.description("mint a short-lived read capability for one file")
|
|
1326
1326
|
.argument("<path>", "file path within the source (quote it if it has spaces)")
|
|
1327
|
-
.requiredOption("--source <name>", "source name (see '
|
|
1327
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
1328
1328
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
1329
1329
|
.option("--json", "emit JSON")
|
|
1330
1330
|
.action(async (pathArg, opts) => process.exit(await runSourceFetch(pathArg, opts)));
|
|
@@ -1332,7 +1332,7 @@ export function registerSourceCommand(program) {
|
|
|
1332
1332
|
strictArgs(source.command("download"))
|
|
1333
1333
|
.description("download a file (or a folder with -r) to local disk")
|
|
1334
1334
|
.argument("<path>", "file or folder path within the source (quote it if it has spaces)")
|
|
1335
|
-
.requiredOption("--source <name>", "source name (see '
|
|
1335
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
1336
1336
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
1337
1337
|
.option("-o, --output <dir>", "output directory (default: current directory)")
|
|
1338
1338
|
.option("-r, --recursive", "download every file under <path>")
|
package/dist/cli/source/share.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// `
|
|
1
|
+
// `dl source share | share-off | shares | shares-remove`
|
|
2
2
|
//
|
|
3
3
|
// The share link: one token per Source that lets a signed-in person who is not
|
|
4
4
|
// a member of the owning namespace read — or, at `--role write`, also write the
|
|
@@ -198,7 +198,7 @@ export async function runSourceShare(opts) {
|
|
|
198
198
|
*/
|
|
199
199
|
process.stdout.write("\n Nothing here stores it — re-run this command to print the same link again.\n");
|
|
200
200
|
process.stdout.write(` Changing the role later reuses this same token, so links already handed out keep working.\n`);
|
|
201
|
-
process.stdout.write(` Turn it off for everyone:
|
|
201
|
+
process.stdout.write(` Turn it off for everyone: dl source share-off --source ${source.name} --namespace ${c.ns}\n`);
|
|
202
202
|
return 0;
|
|
203
203
|
}
|
|
204
204
|
catch (err) {
|
|
@@ -265,7 +265,7 @@ export async function runSourceShareOff(opts) {
|
|
|
265
265
|
* `--help`, not in every invocation.
|
|
266
266
|
*/
|
|
267
267
|
process.stdout.write(" New access stops now. A read or write URL already issued keeps working until it expires\n" +
|
|
268
|
-
" (up to 1 hour for a write) — `
|
|
268
|
+
" (up to 1 hour for a write) — `dl source share-off --help` has the per-connector bounds.\n");
|
|
269
269
|
return 0;
|
|
270
270
|
}
|
|
271
271
|
catch (err) {
|
|
@@ -352,7 +352,7 @@ export async function runSourceShares(opts) {
|
|
|
352
352
|
" they open it. To exclude someone, turn the link off for everyone with 'source share-off'.\n");
|
|
353
353
|
}
|
|
354
354
|
if (nextCursor !== null) {
|
|
355
|
-
process.stdout.write(`\n More to come. Next page:\n
|
|
355
|
+
process.stdout.write(`\n More to come. Next page:\n dl source shares --source ${source.name}` +
|
|
356
356
|
` --namespace ${c.ns} --cursor ${nextCursor}\n`);
|
|
357
357
|
}
|
|
358
358
|
return 0;
|
|
@@ -373,7 +373,7 @@ export async function runSourceShares(opts) {
|
|
|
373
373
|
*/
|
|
374
374
|
export async function runSourceSharesRemove(opts) {
|
|
375
375
|
if (opts.user === undefined || opts.user === "") {
|
|
376
|
-
fail("--user <id> is required (the user id from '
|
|
376
|
+
fail("--user <id> is required (the user id from 'dl source shares')");
|
|
377
377
|
return 1;
|
|
378
378
|
}
|
|
379
379
|
const c = await ctx(opts.namespace);
|
|
@@ -396,7 +396,7 @@ export async function runSourceSharesRemove(opts) {
|
|
|
396
396
|
*/
|
|
397
397
|
ok(`${opts.user} is no longer admitted to '${source.name}'`);
|
|
398
398
|
process.stdout.write(" This is not a block. The link they hold re-admits them the next time they open it;\n" +
|
|
399
|
-
` to exclude them, turn the link off for everyone:
|
|
399
|
+
` to exclude them, turn the link off for everyone: dl source share-off --source ${source.name}\n`);
|
|
400
400
|
return 0;
|
|
401
401
|
}
|
|
402
402
|
catch (err) {
|
|
@@ -446,7 +446,7 @@ export function registerSourceShareCommands(source) {
|
|
|
446
446
|
* commands away on `editor-add` and must not be copied here.
|
|
447
447
|
*/
|
|
448
448
|
const addressed = (cmd) => cmd
|
|
449
|
-
.requiredOption("--source <name>", "source name (see '
|
|
449
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
450
450
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
|
451
451
|
.option("--json", "emit JSON");
|
|
452
452
|
addressed(strictArgs(source.command("share")))
|
|
@@ -515,7 +515,7 @@ reach it through their membership — and it does not mean the link is off.
|
|
|
515
515
|
.action(async (opts) => process.exit(await runSourceShares(opts)));
|
|
516
516
|
addressed(strictArgs(source.command("shares-remove")))
|
|
517
517
|
.description("return one admitted person to 'not admitted' (Owner/Admin only)")
|
|
518
|
-
.requiredOption("--user <id>", "user id from '
|
|
518
|
+
.requiredOption("--user <id>", "user id from 'dl source shares'")
|
|
519
519
|
.addHelpText("after", `
|
|
520
520
|
NOT a block. This clears one admission record; the link that person still holds
|
|
521
521
|
re-admits them the next time they open it. Keeping the link open while durably
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*
|
|
8
8
|
* The transfer executor itself — streamed single-puts, positioned multipart
|
|
9
9
|
* reads, Complete via the XML body, whole-batch abandonment on failure — lives
|
|
10
|
-
* in ../compat/presignedTransfer.ts, shared with `
|
|
10
|
+
* in ../compat/presignedTransfer.ts, shared with `dl library push`,
|
|
11
11
|
* whose server answers the same transfer shape. What stays HERE is §9's own
|
|
12
12
|
* envelope: the canonicalPath computation, the positional binding of answer to
|
|
13
13
|
* request, the idempotency key, and the limits.
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*
|
|
8
8
|
* The transfer executor itself — streamed single-puts, positioned multipart
|
|
9
9
|
* reads, Complete via the XML body, whole-batch abandonment on failure — lives
|
|
10
|
-
* in ../compat/presignedTransfer.ts, shared with `
|
|
10
|
+
* in ../compat/presignedTransfer.ts, shared with `dl library push`,
|
|
11
11
|
* whose server answers the same transfer shape. What stays HERE is §9's own
|
|
12
12
|
* envelope: the canonicalPath computation, the positional binding of answer to
|
|
13
13
|
* request, the idempotency key, and the limits.
|
|
@@ -248,7 +248,7 @@ export function registerSourceUploadCommand(source) {
|
|
|
248
248
|
strictArgs(source.command("upload"))
|
|
249
249
|
.description("upload a file or directory into a source's managed layer")
|
|
250
250
|
.argument("<path>", "local file or directory")
|
|
251
|
-
.requiredOption("--source <name>", "source name (see '
|
|
251
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
252
252
|
.option("--to <prefix>", "destination prefix within the source (default: root)")
|
|
253
253
|
.option("-r, --recursive", "upload a directory's contents")
|
|
254
254
|
.option("--namespace <slug>", "namespace slug (default: active login)")
|
package/dist/cli/source/write.js
CHANGED
|
@@ -103,7 +103,7 @@ function idempotencyKey(override) {
|
|
|
103
103
|
*/
|
|
104
104
|
export function explainWrite(err) {
|
|
105
105
|
if (err instanceof HttpError && err.status === 401) {
|
|
106
|
-
return "not authenticated — run '
|
|
106
|
+
return "not authenticated — run 'dl login' first";
|
|
107
107
|
}
|
|
108
108
|
return err.message;
|
|
109
109
|
}
|
|
@@ -325,7 +325,7 @@ export function registerSourceWriteCommands(source) {
|
|
|
325
325
|
.action(async (opts) => process.exit(await runSourceImport(opts)));
|
|
326
326
|
strictArgs(source.command("metadata"))
|
|
327
327
|
.description("rename a source, or change its description")
|
|
328
|
-
.requiredOption("--source <name>", "source name (see '
|
|
328
|
+
.requiredOption("--source <name>", "source name (see 'dl source list')")
|
|
329
329
|
.option("--rename <name>", "new name; the old one is released immediately")
|
|
330
330
|
.option("--description <text>", "replace the description")
|
|
331
331
|
.option("--clear-description", "remove the description entirely")
|
package/dist/cli/spawn.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// WHY IT MOVED OUT OF `python.ts`. There used to be exactly one subprocess
|
|
4
4
|
// family — `python -m dreamlake.lakeshore.bridge` — and the type that describes
|
|
5
5
|
// it lived beside it. There are now two: the Python bridge, and the
|
|
6
|
-
// terraform / ssh runners behind `
|
|
6
|
+
// terraform / ssh runners behind `dl provider`. Neither speaks the
|
|
7
7
|
// other's protocol (terraform emits a JSON *stream*, ssh emits nothing at all),
|
|
8
8
|
// but both are tested the same way, by handing the entry point a fake that
|
|
9
9
|
// records the argv it was given.
|
package/dist/cli/tasks/index.js
CHANGED
|
@@ -60,7 +60,7 @@ export async function runTasks(operation, target, opts = {}, destination) {
|
|
|
60
60
|
throw new Error("--project or DREAMLAKE_PROJECT is required");
|
|
61
61
|
const c = resolveCtx(opts);
|
|
62
62
|
if (!c.token)
|
|
63
|
-
throw new Error("not authenticated — run '
|
|
63
|
+
throw new Error("not authenticated — run 'dl login' first");
|
|
64
64
|
const ns = await requireNamespace(c, namespace);
|
|
65
65
|
if (!ns)
|
|
66
66
|
return 1;
|
package/dist/cli/update/index.js
CHANGED
|
@@ -160,12 +160,12 @@ export async function runUpdateProject(slug, opts) {
|
|
|
160
160
|
const remote = resolveRemote();
|
|
161
161
|
const token = resolveToken();
|
|
162
162
|
if (!token) {
|
|
163
|
-
fail("not authenticated. run '
|
|
163
|
+
fail("not authenticated. run 'dl login' first");
|
|
164
164
|
return 1;
|
|
165
165
|
}
|
|
166
166
|
const namespace = await resolveNamespace(opts.namespace, { token, remote });
|
|
167
167
|
if (!namespace) {
|
|
168
|
-
fail("namespace not specified and no authenticated user found. run '
|
|
168
|
+
fail("namespace not specified and no authenticated user found. run 'dl login'");
|
|
169
169
|
return 1;
|
|
170
170
|
}
|
|
171
171
|
const body = {};
|
package/dist/cli/upload/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// `
|
|
1
|
+
// `dl upload <file|dir> --episode <target> --to <path>`.
|
|
2
2
|
//
|
|
3
3
|
// Single file → one multipart upload. Directory → flat (non-recursive)
|
|
4
4
|
// folder upload with a resume manifest, matching dreamlake-py's
|
|
@@ -60,12 +60,12 @@ async function resolveContext(episode) {
|
|
|
60
60
|
const remote = resolveRemote();
|
|
61
61
|
const token = resolveToken();
|
|
62
62
|
if (!token) {
|
|
63
|
-
fail("not authenticated. run '
|
|
63
|
+
fail("not authenticated. run 'dl login' first");
|
|
64
64
|
return null;
|
|
65
65
|
}
|
|
66
66
|
const namespace = await resolveNamespace(t.namespace, { token, remote });
|
|
67
67
|
if (!namespace) {
|
|
68
|
-
fail("namespace not specified and no authenticated user found. run '
|
|
68
|
+
fail("namespace not specified and no authenticated user found. run 'dl login'");
|
|
69
69
|
return null;
|
|
70
70
|
}
|
|
71
71
|
t.namespace = namespace;
|
package/dist/cli/vault/index.js
CHANGED
|
@@ -61,7 +61,7 @@ export async function request(path, body, method = body ? "POST" : "GET", revisi
|
|
|
61
61
|
throw new Error('Use --scope to select the vault');
|
|
62
62
|
const token = connection?.token ?? resolveToken();
|
|
63
63
|
if (!token)
|
|
64
|
-
throw new Error("Vault authentication required; run
|
|
64
|
+
throw new Error("Vault authentication required; run dl login");
|
|
65
65
|
let response;
|
|
66
66
|
try {
|
|
67
67
|
// Bun can replay PUT/DELETE after a pooled connection drops. A fresh connection keeps recovery under the caller's
|
|
@@ -159,7 +159,7 @@ export async function runSshImport(options, command) {
|
|
|
159
159
|
return;
|
|
160
160
|
}
|
|
161
161
|
if (!token)
|
|
162
|
-
throw new Error('Vault authentication required; run
|
|
162
|
+
throw new Error('Vault authentication required; run dl login');
|
|
163
163
|
if (interactive && !await confirm('Upload these selected items to the reviewed vault destinations?')) {
|
|
164
164
|
process.stdout.write(JSON.stringify({ cancelled: true, entries: transferReport(transfers) }) + '\n');
|
|
165
165
|
return;
|
package/dist/cli/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.112.0";
|
package/dist/cli/version.js
CHANGED
|
@@ -54,7 +54,7 @@ export declare function runWorkflowWatchRun(name: string, filePath: string, opts
|
|
|
54
54
|
* else strip leading api.). */
|
|
55
55
|
export declare function webBase(remote: string): string;
|
|
56
56
|
/** The '.workflow.json' (or '.json') suffix is optional — return the
|
|
57
|
-
* first candidate that reads, so `
|
|
57
|
+
* first candidate that reads, so `dl workflow push <name>` just
|
|
58
58
|
* works. Null when nothing exists. */
|
|
59
59
|
export declare function resolveSpecFile(file: string): {
|
|
60
60
|
path: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { collectionList } from "../collection-list.js";
|
|
2
|
-
// `
|
|
2
|
+
// `dl workflow ...` — workflow management + run-trace push.
|
|
3
3
|
//
|
|
4
4
|
// Covers the workflow API endpoints:
|
|
5
5
|
// workflow list / create / show / update / delete
|
|
@@ -19,13 +19,13 @@ import { backendFrom, realDreamdbIO, WORKFLOW_SCHEMA, } from "../compat/dreamdb.
|
|
|
19
19
|
async function ctx(nsFlag) {
|
|
20
20
|
const token = resolveToken();
|
|
21
21
|
if (!token) {
|
|
22
|
-
fail("not authenticated — run '
|
|
22
|
+
fail("not authenticated — run 'dl login' first");
|
|
23
23
|
return null;
|
|
24
24
|
}
|
|
25
25
|
const remote = resolveRemote();
|
|
26
26
|
const ns = await resolveNamespace(nsFlag, { token, remote });
|
|
27
27
|
if (!ns) {
|
|
28
|
-
fail("could not resolve namespace — run '
|
|
28
|
+
fail("could not resolve namespace — run 'dl login' or pass --namespace");
|
|
29
29
|
return null;
|
|
30
30
|
}
|
|
31
31
|
return { token, remote, ns };
|
|
@@ -597,7 +597,7 @@ export function webBase(remote) {
|
|
|
597
597
|
return remote.replace(/\/+$/, "");
|
|
598
598
|
}
|
|
599
599
|
/** The '.workflow.json' (or '.json') suffix is optional — return the
|
|
600
|
-
* first candidate that reads, so `
|
|
600
|
+
* first candidate that reads, so `dl workflow push <name>` just
|
|
601
601
|
* works. Null when nothing exists. */
|
|
602
602
|
export function resolveSpecFile(file) {
|
|
603
603
|
const candidates = [file];
|
|
@@ -723,7 +723,7 @@ export async function runDreamlakeWorkflowPush(args, deps = {}) {
|
|
|
723
723
|
return 0;
|
|
724
724
|
}
|
|
725
725
|
// ─── append-local (pointer stub) ──────────────────────────────────────────────
|
|
726
|
-
// dreamlake-server's Apply endpoint spawns `
|
|
726
|
+
// dreamlake-server's Apply endpoint spawns `dl workflow
|
|
727
727
|
// append-local` expecting the CANONICAL Python writer. If PATH resolves
|
|
728
728
|
// to this CLI instead, answer on stdout with the same one-line JSON
|
|
729
729
|
// error contract the server parses, so the operator sees a precise fix
|
|
@@ -815,7 +815,7 @@ export function registerWorkflowCommand(program) {
|
|
|
815
815
|
.option("--name <name>", "workflow name (default: the spec's \"name\" field)")
|
|
816
816
|
.option("--namespace <slug>", "namespace slug (default: active login)")).action(async (file, opts) => process.exit(await runDreamlakeWorkflowPush({ ...opts, file })));
|
|
817
817
|
// Internal — the Python CLI stays the canonical DreamDB writer;
|
|
818
|
-
// dreamlake-server spawns `
|
|
818
|
+
// dreamlake-server spawns `dl workflow append-local` for spec
|
|
819
819
|
// applies. If PATH resolves to THIS CLI instead, answer with a
|
|
820
820
|
// machine-readable pointer rather than a confusing generic failure.
|
|
821
821
|
workflow
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dreamlake/dreamlake-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.112.0",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/dreamlake-ai/dreamlake-cli.git"
|
|
7
7
|
},
|
|
8
8
|
"homepage": "https://cli.dreamlake.ai",
|
|
9
|
-
"description": "dreamlake — data-warehouse CLI. The `
|
|
9
|
+
"description": "dreamlake — data-warehouse CLI. The `dl` command uploads/downloads assets, manages episodes, bindrs, datasets, organizations and teams, and versions artifacts, workflow specs and pipelines against a DreamLake server + BSS.",
|
|
10
10
|
"bin": {
|
|
11
11
|
"dreamlake": "bin/dreamlake.js",
|
|
12
12
|
"dl": "bin/dreamlake.js"
|
|
@@ -37,13 +37,13 @@
|
|
|
37
37
|
"node": ">=18"
|
|
38
38
|
},
|
|
39
39
|
"optionalDependencies": {
|
|
40
|
-
"@dreamlake/dreamlake-cli-darwin-arm64": "0.
|
|
41
|
-
"@dreamlake/dreamlake-cli-darwin-x64": "0.
|
|
42
|
-
"@dreamlake/dreamlake-cli-linux-x64": "0.
|
|
43
|
-
"@dreamlake/dreamlake-cli-linux-arm64": "0.
|
|
44
|
-
"@dreamlake/dreamlake-cli-linux-x64-musl": "0.
|
|
45
|
-
"@dreamlake/dreamlake-cli-linux-arm64-musl": "0.
|
|
46
|
-
"@dreamlake/dreamlake-cli-win32-x64": "0.
|
|
47
|
-
"@dreamlake/dreamlake-cli-win32-arm64": "0.
|
|
40
|
+
"@dreamlake/dreamlake-cli-darwin-arm64": "0.112.0",
|
|
41
|
+
"@dreamlake/dreamlake-cli-darwin-x64": "0.112.0",
|
|
42
|
+
"@dreamlake/dreamlake-cli-linux-x64": "0.112.0",
|
|
43
|
+
"@dreamlake/dreamlake-cli-linux-arm64": "0.112.0",
|
|
44
|
+
"@dreamlake/dreamlake-cli-linux-x64-musl": "0.112.0",
|
|
45
|
+
"@dreamlake/dreamlake-cli-linux-arm64-musl": "0.112.0",
|
|
46
|
+
"@dreamlake/dreamlake-cli-win32-x64": "0.112.0",
|
|
47
|
+
"@dreamlake/dreamlake-cli-win32-arm64": "0.112.0"
|
|
48
48
|
}
|
|
49
49
|
}
|