overlord-cli 0.2610071655.0 → 0.2610130851.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/index.js +44 -13
- package/dist/index.js.map +2 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -8185,7 +8185,6 @@ var init_search = __esm({
|
|
|
8185
8185
|
});
|
|
8186
8186
|
|
|
8187
8187
|
// ../packages/contract/dist/index.js
|
|
8188
|
-
var MY_MISSIONS_COLUMNS, MY_MISSIONS_COLUMN_TYPES;
|
|
8189
8188
|
var init_dist2 = __esm({
|
|
8190
8189
|
"../packages/contract/dist/index.js"() {
|
|
8191
8190
|
"use strict";
|
|
@@ -8198,13 +8197,6 @@ var init_dist2 = __esm({
|
|
|
8198
8197
|
init_objective_ref();
|
|
8199
8198
|
init_resource_paths();
|
|
8200
8199
|
init_search();
|
|
8201
|
-
MY_MISSIONS_COLUMNS = [
|
|
8202
|
-
{ type: "next", label: "Next" },
|
|
8203
|
-
{ type: "execute", label: "Executing" },
|
|
8204
|
-
{ type: "review", label: "Review" },
|
|
8205
|
-
{ type: "complete", label: "Completed" }
|
|
8206
|
-
];
|
|
8207
|
-
MY_MISSIONS_COLUMN_TYPES = MY_MISSIONS_COLUMNS.map((column) => column.type);
|
|
8208
8200
|
}
|
|
8209
8201
|
});
|
|
8210
8202
|
|
|
@@ -39268,6 +39260,8 @@ Environment fallback:
|
|
|
39268
39260
|
--session-key <- SESSION_KEY printed on stderr after attach/connect/prompt/resume-follow-up
|
|
39269
39261
|
--mission-id <- mission display id (e.g. coo:8) or UUID
|
|
39270
39262
|
--objective-id <- OVERLORD_OBJECTIVE_ID (objective display id, e.g. coo:8.k7xm)
|
|
39263
|
+
Read commands inherit it only with no explicit mission or a matching
|
|
39264
|
+
parent mission display id; explicit objective flags are always validated.
|
|
39271
39265
|
backend URL <- overlord.toml backend_url, OVERLORD_BACKEND_URL, or dev OVERLORD_BACKEND_URL_DEV
|
|
39272
39266
|
auth token <- OVERLORD_USER_TOKEN, OVLD_USER_TOKEN, or USER_TOKEN
|
|
39273
39267
|
|
|
@@ -39362,6 +39356,11 @@ connect:
|
|
|
39362
39356
|
load-context:
|
|
39363
39357
|
Purpose:
|
|
39364
39358
|
Read mission details without creating a session.
|
|
39359
|
+
An explicit mission (flag or positional) ignores an inherited objective unless
|
|
39360
|
+
its parent mission display id matches. This also applies to read-context and
|
|
39361
|
+
attachment reads, including bootstrap fallback. For UUID selectors, explicitly
|
|
39362
|
+
pass the objective to pin the read. Explicit objective/mission pairs retain
|
|
39363
|
+
validation. Reads never change the active execution binding or update/delivery target.
|
|
39365
39364
|
Required:
|
|
39366
39365
|
--mission-id <id> Or --objective-id with a display id
|
|
39367
39366
|
Optional:
|
|
@@ -39939,6 +39938,7 @@ hook-event:
|
|
|
39939
39938
|
read-context:
|
|
39940
39939
|
Purpose:
|
|
39941
39940
|
Read persistent shared context written by earlier sessions.
|
|
39941
|
+
Explicit mission selection ignores a different inherited objective (see load-context).
|
|
39942
39942
|
Required:
|
|
39943
39943
|
--mission-id <id>
|
|
39944
39944
|
Optional:
|
|
@@ -39997,6 +39997,7 @@ attachment-list:
|
|
|
39997
39997
|
with --objective-id).
|
|
39998
39998
|
Each entry includes id, filename, mimeType, sizeBytes, status, storageKey, and url.
|
|
39999
39999
|
The url field is a server-relative path; prepend the backend base URL to download.
|
|
40000
|
+
Explicit mission selection ignores a different inherited objective (see load-context).
|
|
40000
40001
|
Required:
|
|
40001
40002
|
--mission-id <id>
|
|
40002
40003
|
Optional:
|
|
@@ -40006,6 +40007,7 @@ attachment-download-url:
|
|
|
40006
40007
|
Purpose:
|
|
40007
40008
|
Return the authenticated download URL for a specific attachment, or save it
|
|
40008
40009
|
to a new file using the CLI's existing authentication.
|
|
40010
|
+
Explicit mission selection ignores a different inherited objective (see load-context).
|
|
40009
40011
|
Required:
|
|
40010
40012
|
--mission-id <id>
|
|
40011
40013
|
--attachment-id <id> (use the id from attachment-list output)
|
|
@@ -41172,6 +41174,25 @@ function missionDisplayId(mission) {
|
|
|
41172
41174
|
const record2 = asRecord5(mission);
|
|
41173
41175
|
return typeof record2.displayId === "string" ? record2.displayId : typeof record2.id === "string" ? record2.id : "unknown";
|
|
41174
41176
|
}
|
|
41177
|
+
function createdObjectiveLines(mission) {
|
|
41178
|
+
const objectives = asRecord5(mission).objectives;
|
|
41179
|
+
if (!Array.isArray(objectives)) return [];
|
|
41180
|
+
return objectives.map((entry, index) => {
|
|
41181
|
+
const objective = asRecord5(entry);
|
|
41182
|
+
const identifier = typeof objective.displayId === "string" && objective.displayId || typeof objective.id === "string" && objective.id || `#${index + 1}`;
|
|
41183
|
+
const assignedAgent = typeof objective.assignedAgent === "string" ? objective.assignedAgent : "project default";
|
|
41184
|
+
const model = typeof objective.model === "string" ? objective.model : "project default";
|
|
41185
|
+
const resource = typeof objective.resourceKey === "string" ? objective.resourceKey : "project default";
|
|
41186
|
+
const fields = [
|
|
41187
|
+
`agent=${assignedAgent}`,
|
|
41188
|
+
`model=${model}`,
|
|
41189
|
+
`resource=${resource}`,
|
|
41190
|
+
`autoAdvance=${objective.autoAdvance === true}`
|
|
41191
|
+
];
|
|
41192
|
+
const title = typeof objective.title === "string" && objective.title.trim();
|
|
41193
|
+
return ` Objective ${identifier}${title ? ` (${title})` : ""}: ${fields.join(", ")}`;
|
|
41194
|
+
});
|
|
41195
|
+
}
|
|
41175
41196
|
function appendDeclaredOutputPaths({
|
|
41176
41197
|
flags,
|
|
41177
41198
|
active,
|
|
@@ -41280,6 +41301,8 @@ Run \`${primaryCommand} protocol help\` for usage.`
|
|
|
41280
41301
|
rejectOversizedInlineJson({ flags: parsed.flags });
|
|
41281
41302
|
const workingDirectory = process.cwd();
|
|
41282
41303
|
const flags = Object.fromEntries(parsed.flags);
|
|
41304
|
+
const explicitMissionId = flagValue(parsed.flags, "--mission-id") ?? parsed.positional[0];
|
|
41305
|
+
const mayInheritObjective = (objectiveId) => !READ_ONLY_MISSION_SUBCOMMANDS.has(subcommand) || explicitMissionId === void 0 || missionDisplayIdFromObjectiveRef(objectiveId) === explicitMissionId.trim();
|
|
41283
41306
|
const retiredFlags = RETIRED_CHANGE_TRACKING_FLAGS[subcommand] ?? [];
|
|
41284
41307
|
const suppliedRetiredFlags = retiredFlags.filter((flag) => flag in flags);
|
|
41285
41308
|
if (suppliedRetiredFlags.length > 0) {
|
|
@@ -41290,10 +41313,9 @@ Run \`${primaryCommand} protocol help\` for usage.`
|
|
|
41290
41313
|
if (subcommand === "attach" && typeof flags["--execution-request-id"] !== "string" && process.env.OVERLORD_EXECUTION_REQUEST_ID) {
|
|
41291
41314
|
flags["--execution-request-id"] = process.env.OVERLORD_EXECUTION_REQUEST_ID;
|
|
41292
41315
|
}
|
|
41293
|
-
if (OBJECTIVE_SCOPED_SUBCOMMANDS.has(subcommand) && typeof flags["--objective-id"] !== "string" && process.env.OVERLORD_OBJECTIVE_ID) {
|
|
41316
|
+
if (OBJECTIVE_SCOPED_SUBCOMMANDS.has(subcommand) && typeof flags["--objective-id"] !== "string" && process.env.OVERLORD_OBJECTIVE_ID && mayInheritObjective(process.env.OVERLORD_OBJECTIVE_ID)) {
|
|
41294
41317
|
flags["--objective-id"] = process.env.OVERLORD_OBJECTIVE_ID;
|
|
41295
41318
|
}
|
|
41296
|
-
const explicitMissionId = flagValue(parsed.flags, "--mission-id") ?? parsed.positional[0];
|
|
41297
41319
|
if (subcommand === "attach" || OBJECTIVE_SCOPED_SUBCOMMANDS.has(subcommand)) {
|
|
41298
41320
|
const needsChannelId = subcommand === "attach" && typeof flags["--session-channel-id"] !== "string";
|
|
41299
41321
|
const needsExecutionRequestId = subcommand === "attach" && typeof flags["--execution-request-id"] !== "string";
|
|
@@ -41314,7 +41336,7 @@ Run \`${primaryCommand} protocol help\` for usage.`
|
|
|
41314
41336
|
if (needsExecutionRequestId && recovered.executionRequestId) {
|
|
41315
41337
|
flags["--execution-request-id"] = recovered.executionRequestId;
|
|
41316
41338
|
}
|
|
41317
|
-
if (needsObjectiveId && recovered.objectiveId) {
|
|
41339
|
+
if (needsObjectiveId && recovered.objectiveId && mayInheritObjective(recovered.objectiveId)) {
|
|
41318
41340
|
flags["--objective-id"] = recovered.objectiveId;
|
|
41319
41341
|
}
|
|
41320
41342
|
}
|
|
@@ -41872,7 +41894,10 @@ async function runManagementCommand({
|
|
|
41872
41894
|
}
|
|
41873
41895
|
}
|
|
41874
41896
|
if (json2) printJson(mission);
|
|
41875
|
-
else
|
|
41897
|
+
else {
|
|
41898
|
+
console.log(`Created mission ${missionDisplayId(mission)}`);
|
|
41899
|
+
for (const line of createdObjectiveLines(mission)) console.log(line);
|
|
41900
|
+
}
|
|
41876
41901
|
return;
|
|
41877
41902
|
}
|
|
41878
41903
|
case "attach":
|
|
@@ -42663,7 +42688,7 @@ Note: ${reinstallHint}`);
|
|
|
42663
42688
|
message: "Usage: ovld runner service <install|start|stop|restart|status|uninstall> [--no-start] [--json]"
|
|
42664
42689
|
});
|
|
42665
42690
|
}
|
|
42666
|
-
var SYNC_CHANGE_EVIDENCE_KEYS, OBJECTIVE_DISPLAY_ID_RE, PROTOCOL_FILE_FLAGS, SESSION_KEY_SUBCOMMANDS, OBJECTIVE_SCOPED_SUBCOMMANDS, RETIRED_CHANGE_TRACKING_FLAGS, MAX_CHANGES_HEALTH_ENTRIES, MAX_DECLARED_OUTPUT_PATHS, MAX_RUNNER_FAILURE_MESSAGE_LENGTH;
|
|
42691
|
+
var SYNC_CHANGE_EVIDENCE_KEYS, OBJECTIVE_DISPLAY_ID_RE, PROTOCOL_FILE_FLAGS, SESSION_KEY_SUBCOMMANDS, OBJECTIVE_SCOPED_SUBCOMMANDS, READ_ONLY_MISSION_SUBCOMMANDS, RETIRED_CHANGE_TRACKING_FLAGS, MAX_CHANGES_HEALTH_ENTRIES, MAX_DECLARED_OUTPUT_PATHS, MAX_RUNNER_FAILURE_MESSAGE_LENGTH;
|
|
42667
42692
|
var init_commands = __esm({
|
|
42668
42693
|
"src/commands.ts"() {
|
|
42669
42694
|
"use strict";
|
|
@@ -42756,6 +42781,12 @@ var init_commands = __esm({
|
|
|
42756
42781
|
"update-artifact",
|
|
42757
42782
|
"write-context"
|
|
42758
42783
|
]);
|
|
42784
|
+
READ_ONLY_MISSION_SUBCOMMANDS = /* @__PURE__ */ new Set([
|
|
42785
|
+
"load-context",
|
|
42786
|
+
"read-context",
|
|
42787
|
+
"attachment-list",
|
|
42788
|
+
"attachment-download-url"
|
|
42789
|
+
]);
|
|
42759
42790
|
RETIRED_CHANGE_TRACKING_FLAGS = {
|
|
42760
42791
|
update: ["--track-changed-files", "--changed-files-json", "--changed-files-file"],
|
|
42761
42792
|
deliver: [
|