@indigoai-us/hq-cli 5.188.1 → 5.190.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/CHANGELOG.md +31 -0
- package/dist/command-catalog.generated.d.ts +31 -1
- package/dist/command-catalog.generated.js +40 -1
- package/dist/commands/lanes.d.ts +3 -1
- package/dist/commands/lanes.js +269 -50
- package/dist/lib/bot/promotion-upload.js +17 -2
- package/dist/lib/lanes/index.d.ts +2 -0
- package/dist/lib/lanes/index.js +1 -0
- package/dist/lib/lanes/outpost-dispatch.d.ts +4 -0
- package/dist/lib/lanes/outpost-dispatch.js +8 -0
- package/dist/lib/lanes/spawn.d.ts +3 -0
- package/dist/lib/lanes/spawn.js +8 -2
- package/dist/lib/lanes/store.js +129 -6
- package/dist/lib/lanes/stories.js +3 -0
- package/dist/lib/lanes/story-ledger.d.ts +78 -0
- package/dist/lib/lanes/story-ledger.js +762 -0
- package/dist/lib/lanes/types.d.ts +10 -1
- package/dist/lib/lanes/types.js +3 -3
- package/dist/lib/lanes/watcher.js +2 -0
- package/dist/utils/vault-api.js +1 -1
- package/package.json +1 -1
|
@@ -293,6 +293,9 @@ export interface LastEnvelopeRef {
|
|
|
293
293
|
ref: string;
|
|
294
294
|
decision: EnvelopeDecision;
|
|
295
295
|
at: string;
|
|
296
|
+
/** PR and merge references carried by the worker envelope. */
|
|
297
|
+
artifacts?: unknown[];
|
|
298
|
+
blocked_reason?: string;
|
|
296
299
|
}
|
|
297
300
|
export interface LaneStory {
|
|
298
301
|
project_id: string;
|
|
@@ -313,6 +316,12 @@ export interface LaneRecord {
|
|
|
313
316
|
mesh_company?: LaneCompanyRef;
|
|
314
317
|
project_id: string;
|
|
315
318
|
story_id: string;
|
|
319
|
+
/** Explicit reason a lane was created without a project story. */
|
|
320
|
+
no_story_reason?: string;
|
|
321
|
+
/** Last failed story-ledger synchronization, cleared after a successful retry. */
|
|
322
|
+
ledger_sync_error?: string;
|
|
323
|
+
/** Pending question ids owned by this lane. */
|
|
324
|
+
pending_question_ids?: string[];
|
|
316
325
|
/**
|
|
317
326
|
* Stories currently carried by this lane. Old records omit this field and
|
|
318
327
|
* are migrated in memory from project_id/story_id on read.
|
|
@@ -469,7 +478,7 @@ export interface LaneRecord {
|
|
|
469
478
|
}
|
|
470
479
|
/** The v1 fields that must exist on every durable lane record (spec §3). */
|
|
471
480
|
export declare const REQUIRED_LANE_RECORD_FIELDS: readonly ["schema_version", "lane_id", "company", "project_id", "story_id", "depth", "senior", "senior_history", "state", "priority", "provider", "host", "version", "created_at", "updated_at", "attribution_history"];
|
|
472
|
-
export declare const LANE_WRITERS: readonly ["creator", "command", "watcher", "reconcile", "spawn"];
|
|
481
|
+
export declare const LANE_WRITERS: readonly ["creator", "command", "watcher", "reconcile", "spawn", "story-ledger"];
|
|
473
482
|
export type LaneWriter = (typeof LANE_WRITERS)[number];
|
|
474
483
|
/** Field ownership at the durable-record mutation boundary (spec §10.1). */
|
|
475
484
|
export declare const LANE_FIELD_WRITERS: Readonly<Record<keyof LaneRecord, readonly LaneWriter[]>>;
|
package/dist/lib/lanes/types.js
CHANGED
|
@@ -213,11 +213,11 @@ export const REQUIRED_LANE_RECORD_FIELDS = [
|
|
|
213
213
|
"senior", "senior_history", "state", "priority", "provider", "host",
|
|
214
214
|
"version", "created_at", "updated_at", "attribution_history",
|
|
215
215
|
];
|
|
216
|
-
export const LANE_WRITERS = ["creator", "command", "watcher", "reconcile", "spawn"];
|
|
216
|
+
export const LANE_WRITERS = ["creator", "command", "watcher", "reconcile", "spawn", "story-ledger"];
|
|
217
217
|
/** Field ownership at the durable-record mutation boundary (spec §10.1). */
|
|
218
218
|
export const LANE_FIELD_WRITERS = {
|
|
219
219
|
schema_version: ["creator"], lane_id: ["creator"], company: ["creator"],
|
|
220
|
-
project_id: ["command"], story_id: ["command"], stories: ["creator", "command", "watcher", "reconcile", "spawn"], thread_id: ["creator", "command", "spawn"], mesh_company: ["creator", "command"],
|
|
220
|
+
project_id: ["command"], story_id: ["command"], no_story_reason: ["creator", "command"], ledger_sync_error: ["story-ledger"], pending_question_ids: ["story-ledger"], stories: ["creator", "command", "watcher", "reconcile", "spawn"], thread_id: ["creator", "command", "spawn"], mesh_company: ["creator", "command"],
|
|
221
221
|
depth: ["command"], senior: ["command"], senior_history: ["command"],
|
|
222
222
|
hire_grant: ["creator", "command"],
|
|
223
223
|
state: ["creator", "command", "watcher", "reconcile", "spawn"], queued_reason: ["creator", "command", "spawn", "watcher", "reconcile"], queued_at: ["creator", "command", "spawn", "watcher", "reconcile"], admission_reserved_at: ["creator", "command", "reconcile", "spawn", "watcher"],
|
|
@@ -226,7 +226,7 @@ export const LANE_FIELD_WRITERS = {
|
|
|
226
226
|
priority: ["command"], worker: ["creator", "command"], worker_path: ["creator", "command"], worker_pack: ["creator", "command"], worker_profile: ["creator", "command"], worker_profile_hash: ["creator", "command", "spawn"], worker_profile_ignored: ["creator", "command", "spawn"], worker_policy_delivery: ["command", "spawn"],
|
|
227
227
|
provider: ["creator"], account: ["creator", "spawn", "command", "watcher", "reconcile"], account_selection: ["creator", "command"], admission_accounts: ["creator", "command"], account_history: ["command", "spawn", "watcher", "reconcile"], pending_resume: ["command", "spawn", "watcher", "reconcile"], placement_default: ["creator"], host: ["creator", "command"], origin_host: ["creator"], origin_host_source: ["creator"],
|
|
228
228
|
version: ["creator"], created_at: ["creator"], updated_at: ["creator"], attribution_history: ["command"],
|
|
229
|
-
last_envelope: ["watcher", "reconcile"], model: ["creator", "spawn", "command"], model_source: ["creator", "spawn", "command"], effort: ["creator", "spawn"], effort_source: ["creator", "spawn"], fast_mode: ["spawn"],
|
|
229
|
+
last_envelope: ["watcher", "reconcile"], model: ["creator", "spawn", "command"], model_source: ["creator", "spawn", "command"], effort: ["creator", "spawn", "command"], effort_source: ["creator", "spawn", "command"], fast_mode: ["spawn"],
|
|
230
230
|
last_message_at: ["command"], last_compaction: ["spawn"], story_complete: ["watcher", "reconcile"], story_complete_reason: ["watcher", "reconcile"], story_status: ["watcher", "reconcile"],
|
|
231
231
|
overdue: ["reconcile"], overdue_at: ["reconcile"], last_host_report_at: ["watcher", "spawn", "reconcile"], stalled: ["watcher"], stalled_at: ["watcher"], stalled_reason: ["watcher"],
|
|
232
232
|
admitted_reason: ["command", "reconcile"], terminal_reason: ["command", "watcher", "spawn", "reconcile"], terminal_details: ["command", "spawn", "watcher", "reconcile"],
|
|
@@ -357,6 +357,8 @@ export function applyTerminalToLaneWithResult(hqRoot, laneId, classification, op
|
|
|
357
357
|
ref: opts.envelopeRef,
|
|
358
358
|
decision: envelope.decision,
|
|
359
359
|
at,
|
|
360
|
+
artifacts: envelope.artifacts,
|
|
361
|
+
...(envelope.blocked_reason !== undefined ? { blocked_reason: envelope.blocked_reason } : {}),
|
|
360
362
|
};
|
|
361
363
|
next.story_status = envelope.story_status;
|
|
362
364
|
if (envelope.story_complete !== undefined) {
|
package/dist/utils/vault-api.js
CHANGED
|
@@ -484,7 +484,7 @@ async function resolveCompanyUid(token, ref, baseUrl) {
|
|
|
484
484
|
// failure — treating it as not-found sent owners to check a slug that
|
|
485
485
|
// was fine (Shepherd #2306).
|
|
486
486
|
if (res.status === 404 && mine.kind === "miss") {
|
|
487
|
-
throw Object.assign(new Error(redactedSlugLookupMessage(`Company slug '${ref}' was not found. Check the slug or run \`hq
|
|
487
|
+
throw Object.assign(new Error(redactedSlugLookupMessage(`Company slug '${ref}' was not found. Check the slug or run \`hq sources entities\`.`)), { expected: true });
|
|
488
488
|
}
|
|
489
489
|
const reason = formatSlugLookupReason(res, body);
|
|
490
490
|
const retryable = mine.kind === "transient" || isTransientSlugLookupStatus(res.status);
|