@skrr-ai/cli 0.1.127 → 0.1.129
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/base-command.d.ts +35 -0
- package/dist/base-command.js +107 -0
- package/dist/commands/agenda/trigger/list.d.ts +2 -1
- package/dist/commands/agenda/trigger/list.js +55 -6
- package/dist/commands/agents/chat.js +7 -0
- package/dist/commands/agents/create.js +3 -1
- package/dist/commands/browser/persistent-profile.d.ts +22 -0
- package/dist/commands/browser/persistent-profile.js +46 -0
- package/dist/commands/commitments/action-history.js +1 -1
- package/dist/commands/commitments/cases.js +3 -3
- package/dist/commands/commitments/check-now.d.ts +10 -2
- package/dist/commands/commitments/check-now.js +53 -3
- package/dist/commands/commitments/create.d.ts +6 -14
- package/dist/commands/commitments/create.js +64 -7
- package/dist/commands/commitments/doctor.js +3 -1
- package/dist/commands/commitments/effective-policy.d.ts +11 -1
- package/dist/commands/commitments/effective-policy.js +90 -4
- package/dist/commands/commitments/explain.js +10 -1
- package/dist/commands/commitments/hypotheses.js +12 -12
- package/dist/commands/commitments/next-tick.js +5 -0
- package/dist/commands/commitments/observations.js +18 -17
- package/dist/commands/commitments/pack/list.js +2 -1
- package/dist/commands/commitments/pack/plan.d.ts +6 -0
- package/dist/commands/commitments/pack/plan.js +19 -0
- package/dist/commands/commitments/plan.d.ts +14 -0
- package/dist/commands/commitments/plan.js +32 -0
- package/dist/commands/commitments/preflight.d.ts +20 -1
- package/dist/commands/commitments/preflight.js +118 -12
- package/dist/commands/commitments/show.d.ts +9 -0
- package/dist/commands/commitments/show.js +14 -1
- package/dist/commands/commitments/trigger-status.js +8 -0
- package/dist/commands/commitments/update.d.ts +1 -0
- package/dist/commands/commitments/update.js +45 -4
- package/dist/commands/commitments/wake-capabilities.js +13 -0
- package/dist/commands/compass/archive.js +4 -0
- package/dist/commands/compass/commitments.js +15 -1
- package/dist/commands/compass/create.js +11 -3
- package/dist/commands/compass/effective-policy.d.ts +1 -0
- package/dist/commands/compass/effective-policy.js +8 -7
- package/dist/commands/compass/revert.d.ts +8 -0
- package/dist/commands/compass/revert.js +25 -1
- package/dist/commands/compass/revisions.d.ts +6 -0
- package/dist/commands/compass/revisions.js +26 -2
- package/dist/commands/compass/tactic.d.ts +10 -3
- package/dist/commands/compass/tactic.js +22 -7
- package/dist/commands/compass/update.js +19 -3
- package/dist/commands/followups/act.js +1 -1
- package/dist/commands/followups/cancel.js +13 -0
- package/dist/commands/followups/observability.js +20 -1
- package/dist/commands/followups/plans/create.js +12 -1
- package/dist/commands/followups/show.js +13 -0
- package/dist/commands/followups/watch.js +1 -1
- package/dist/commands/goals/planner-config.d.ts +11 -0
- package/dist/commands/goals/planner-config.js +16 -0
- package/dist/commands/harnesses/list.js +1 -1
- package/dist/commands/machines/update.d.ts +5 -3
- package/dist/commands/machines/update.js +70 -9
- package/dist/commands/northstars/create.js +3 -1
- package/dist/commands/northstars/governance/configure.d.ts +4 -0
- package/dist/commands/northstars/governance/configure.js +76 -10
- package/dist/commands/northstars/intents/decide.d.ts +6 -0
- package/dist/commands/northstars/intents/decide.js +68 -15
- package/dist/commands/northstars/intents/list.d.ts +2 -1
- package/dist/commands/northstars/intents/list.js +15 -5
- package/dist/commands/northstars/intents.d.ts +26 -0
- package/dist/commands/northstars/intents.js +49 -0
- package/dist/commands/northstars/list.d.ts +1 -0
- package/dist/commands/northstars/list.js +24 -3
- package/dist/commands/northstars/recommendations/list.d.ts +1 -1
- package/dist/commands/northstars/recommendations/list.js +3 -3
- package/dist/commands/northstars/recommendations.d.ts +19 -0
- package/dist/commands/northstars/recommendations.js +42 -0
- package/dist/commands/northstars/review-now.d.ts +1 -0
- package/dist/commands/northstars/review-now.js +15 -4
- package/dist/commands/northstars/reviews.d.ts +1 -0
- package/dist/commands/northstars/reviews.js +34 -6
- package/dist/commands/northstars/update.js +8 -1
- package/dist/commands/proposals/list.js +11 -2
- package/dist/commands/proposals/show.js +9 -1
- package/dist/commands/spaces/auto-executor/preview.d.ts +14 -1
- package/dist/commands/spaces/auto-executor/preview.js +35 -1
- package/dist/commands/spaces/auto-executor/run.d.ts +17 -0
- package/dist/commands/spaces/auto-executor/run.js +60 -2
- package/dist/commands/spaces/auto-executor/runs.d.ts +9 -1
- package/dist/commands/spaces/auto-executor/runs.js +18 -1
- package/dist/commands/spaces/files/upload.js +1 -2
- package/dist/commands/spaces/heartbeats/create.js +7 -5
- package/dist/commands/spaces/heartbeats/update.js +5 -3
- package/dist/commands/spaces/index.js +23 -0
- package/dist/commands/store/artifacts/releases.d.ts +20 -0
- package/dist/commands/store/artifacts/releases.js +85 -0
- package/dist/commands/store/library.d.ts +14 -0
- package/dist/commands/store/library.js +71 -0
- package/dist/commands/tasks/list.d.ts +48 -0
- package/dist/commands/tasks/list.js +141 -9
- package/dist/commands/tasks/remind.js +23 -11
- package/dist/commands/tasks/retry-schedule.js +6 -3
- package/dist/commands/tasks/schedule.js +29 -7
- package/dist/commands/tasks/show.js +4 -0
- package/dist/generated/agent-guides.json +69 -69
- package/dist/lib/agent-trigger-listing.d.ts +26 -0
- package/dist/lib/agent-trigger-listing.js +63 -0
- package/dist/lib/agentic-stream.d.ts +9 -0
- package/dist/lib/agentic-stream.js +152 -41
- package/dist/lib/command-miss.js +11 -2
- package/dist/lib/commitment-attention-copy.d.ts +96 -0
- package/dist/lib/commitment-attention-copy.js +209 -0
- package/dist/lib/commitment-ledgers.js +3 -1
- package/dist/lib/commitment-loop-status.d.ts +6 -0
- package/dist/lib/commitment-loop-status.js +16 -6
- package/dist/lib/commitments.d.ts +112 -0
- package/dist/lib/commitments.js +250 -2
- package/dist/lib/compass-body-help.d.ts +20 -0
- package/dist/lib/compass-body-help.js +61 -0
- package/dist/lib/compass-refusals.d.ts +35 -0
- package/dist/lib/compass-refusals.js +50 -0
- package/dist/lib/compasses.d.ts +82 -4
- package/dist/lib/compasses.js +232 -12
- package/dist/lib/followups.d.ts +22 -1
- package/dist/lib/followups.js +21 -1
- package/dist/lib/format.d.ts +11 -0
- package/dist/lib/format.js +29 -0
- package/dist/lib/initiatives.d.ts +9 -2
- package/dist/lib/initiatives.js +13 -2
- package/dist/lib/iso-instant.d.ts +52 -0
- package/dist/lib/iso-instant.js +162 -0
- package/dist/lib/machines.d.ts +14 -1
- package/dist/lib/machines.js +24 -0
- package/dist/lib/northstars.d.ts +201 -24
- package/dist/lib/northstars.js +655 -27
- package/dist/lib/proposal-decision-command.js +21 -1
- package/dist/lib/proposals.d.ts +26 -1
- package/dist/lib/proposals.js +167 -0
- package/dist/lib/rate-limit-retry.d.ts +5 -0
- package/dist/lib/rate-limit-retry.js +19 -0
- package/dist/lib/roles.d.ts +1 -1
- package/dist/lib/space-charter.js +9 -0
- package/dist/lib/store-artifact-releases.d.ts +39 -0
- package/dist/lib/store-artifact-releases.js +12 -0
- package/dist/lib/store-library.d.ts +37 -0
- package/dist/lib/store-library.js +12 -0
- package/dist/lib/task-asset-upload.js +1 -2
- package/dist/lib/task-calendar.d.ts +19 -0
- package/dist/lib/task-calendar.js +72 -0
- package/dist/lib/task-recurrence-outcome.js +3 -1
- package/dist/lib/task-recurrence-summary.d.ts +15 -0
- package/dist/lib/task-recurrence-summary.js +228 -0
- package/dist/lib/task-reminder.d.ts +28 -0
- package/dist/lib/task-reminder.js +50 -0
- package/dist/lib/triggers.d.ts +13 -2
- package/dist/lib/triggers.js +31 -13
- package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/daemonWire.js +11 -1
- package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/executorStopReceipt.d.ts +123 -0
- package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/executorStopReceipt.js +160 -0
- package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/index.d.ts +1 -0
- package/dist/node_modules/@skrr-ai/auth-core/dist/cjs/index.js +17 -0
- package/dist/node_modules/@skrr-ai/auth-core/dist/esm/daemonWire.js +11 -1
- package/dist/node_modules/@skrr-ai/auth-core/dist/esm/executorStopReceipt.d.ts +123 -0
- package/dist/node_modules/@skrr-ai/auth-core/dist/esm/executorStopReceipt.js +173 -0
- package/dist/node_modules/@skrr-ai/auth-core/dist/esm/index.d.ts +1 -0
- package/dist/node_modules/@skrr-ai/auth-core/dist/esm/index.js +2 -0
- package/dist/node_modules/@skrr-ai/auth-core/package.json +1 -1
- package/dist/node_modules/@skrr-ai/data-provider/index.js +6922 -6828
- package/oclif.manifest.json +612 -62
- package/package.json +4 -4
package/dist/base-command.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Command, Flags, type Interfaces } from '@oclif/core';
|
|
2
2
|
import { type CliOperationOptions } from './lib/json-output';
|
|
3
|
+
import { type CompassRefusalContext } from './lib/compass-refusals';
|
|
3
4
|
export { resolveProfileFromArgv } from './lib/keychain';
|
|
4
5
|
import { dataService } from '@skrr-ai/data-provider';
|
|
5
6
|
import { type WriteTarget } from './lib/write-target';
|
|
@@ -413,6 +414,12 @@ export declare abstract class BaseCommand extends Command {
|
|
|
413
414
|
* path the person never typed. See `lib/request-field-flags.ts`.
|
|
414
415
|
*/
|
|
415
416
|
protected requestFieldFlags?: Readonly<Record<string, string>>;
|
|
417
|
+
/**
|
|
418
|
+
* The Compass (and Agent) this invocation is about, set by a `compass` command before it sends.
|
|
419
|
+
* A stale version or a missing revision is answered with the command to run next, and that
|
|
420
|
+
* command names these. Unset, the hint carries placeholders. See `lib/compass-refusals.ts`.
|
|
421
|
+
*/
|
|
422
|
+
protected compassRef?: CompassRefusalContext;
|
|
416
423
|
protected handleApiError(err: unknown, { subject }?: {
|
|
417
424
|
subject?: string;
|
|
418
425
|
}): never;
|
|
@@ -515,6 +522,22 @@ export declare function apiRefusal(err: unknown): {
|
|
|
515
522
|
/** The parsed JSON body, for a refusal that carries structured context. */
|
|
516
523
|
body?: Record<string, unknown>;
|
|
517
524
|
};
|
|
525
|
+
/**
|
|
526
|
+
* The remedy a refused Commitment activation carries.
|
|
527
|
+
*
|
|
528
|
+
* The refusal's message names the blocking Preflight gate by its QUESTION and a reason token
|
|
529
|
+
* ("Can the runtime enforce this Run? (runtime_commitment_contract_unavailable)"). The gate's own
|
|
530
|
+
* `hint` — the sentence that says what to run — travels beside it at
|
|
531
|
+
* `diagnostic.firstBlocker.detail`, and the web client already shows it
|
|
532
|
+
* (`activationFailureMessage`). The CLI dropped it, so `commitments resume` and
|
|
533
|
+
* `commitments create --activate` told a person to "fix the gate the reason names" while
|
|
534
|
+
* `commitments preflight` knew the exact command (OSK-21126).
|
|
535
|
+
*
|
|
536
|
+
* Undefined when the gate offered none, so a caller keeps its generic wording.
|
|
537
|
+
*
|
|
538
|
+
* Exported for tests.
|
|
539
|
+
*/
|
|
540
|
+
export declare function commitmentActivationHint(body: Record<string, unknown> | null | undefined): string | undefined;
|
|
518
541
|
/**
|
|
519
542
|
* Prefix a failure message with the resource it is about.
|
|
520
543
|
*
|
|
@@ -557,6 +580,18 @@ export declare function describeHarnessUnavailable(body: Record<string, unknown>
|
|
|
557
580
|
* Exported for tests.
|
|
558
581
|
*/
|
|
559
582
|
export declare function describeGitHubUnavailable(): string;
|
|
583
|
+
/**
|
|
584
|
+
* Frame a typed `TASK_LIST_TIMEOUT` failure as what it is — a list too broad for the database's
|
|
585
|
+
* time limit — rather than a control-plane outage.
|
|
586
|
+
*
|
|
587
|
+
* `GET /api/tasks` answers 503 with this code when its one aggregate is cut off at `maxTimeMS`,
|
|
588
|
+
* which an unscoped list over every accessible Space reaches because no index serves its sort
|
|
589
|
+
* across the access filter. Lead with the server's `cause`/`remedy`, falling back to the CLI's
|
|
590
|
+
* own sentence: the 5xx redaction boundary generalizes a bare message in production.
|
|
591
|
+
*
|
|
592
|
+
* Exported for tests.
|
|
593
|
+
*/
|
|
594
|
+
export declare function describeTaskListTimeout(body: Record<string, unknown> | null, bin?: string): string;
|
|
560
595
|
/**
|
|
561
596
|
* Frame a typed `LABEL_SUGGESTION_UNAVAILABLE` failure as what it is — the
|
|
562
597
|
* suggestion's hosted-inference call found no billing payer — rather than a
|
package/dist/base-command.js
CHANGED
|
@@ -5,9 +5,11 @@ exports.assigneePayloadNeedsResolution = assigneePayloadNeedsResolution;
|
|
|
5
5
|
exports.parseGlobalFlags = parseGlobalFlags;
|
|
6
6
|
exports.refusalCodeOf = refusalCodeOf;
|
|
7
7
|
exports.apiRefusal = apiRefusal;
|
|
8
|
+
exports.commitmentActivationHint = commitmentActivationHint;
|
|
8
9
|
exports.withSubject = withSubject;
|
|
9
10
|
exports.describeHarnessUnavailable = describeHarnessUnavailable;
|
|
10
11
|
exports.describeGitHubUnavailable = describeGitHubUnavailable;
|
|
12
|
+
exports.describeTaskListTimeout = describeTaskListTimeout;
|
|
11
13
|
exports.describeLabelSuggestionUnavailable = describeLabelSuggestionUnavailable;
|
|
12
14
|
exports.describeGitHubAppNotConfigured = describeGitHubAppNotConfigured;
|
|
13
15
|
exports.describeResourceNotFound = describeResourceNotFound;
|
|
@@ -34,6 +36,7 @@ const failed_lookup_1 = require("./lib/failed-lookup");
|
|
|
34
36
|
const internal_id_1 = require("./lib/internal-id");
|
|
35
37
|
const http_error_1 = require("./lib/http-error");
|
|
36
38
|
const api_error_reason_1 = require("./lib/api-error-reason");
|
|
39
|
+
const compass_refusals_1 = require("./lib/compass-refusals");
|
|
37
40
|
const guide_pointer_1 = require("./lib/guide-pointer");
|
|
38
41
|
// Re-exported from its home in `lib/keychain`, beside the other profile
|
|
39
42
|
// functions. It lived here while `init()` was its only caller; a lib module
|
|
@@ -1467,6 +1470,12 @@ class BaseCommand extends core_1.Command {
|
|
|
1467
1470
|
* path the person never typed. See `lib/request-field-flags.ts`.
|
|
1468
1471
|
*/
|
|
1469
1472
|
requestFieldFlags;
|
|
1473
|
+
/**
|
|
1474
|
+
* The Compass (and Agent) this invocation is about, set by a `compass` command before it sends.
|
|
1475
|
+
* A stale version or a missing revision is answered with the command to run next, and that
|
|
1476
|
+
* command names these. Unset, the hint carries placeholders. See `lib/compass-refusals.ts`.
|
|
1477
|
+
*/
|
|
1478
|
+
compassRef;
|
|
1470
1479
|
handleApiError(err, { subject } = {}) {
|
|
1471
1480
|
// An error this command already raised for the user is not an API failure
|
|
1472
1481
|
// to translate. `this.error()` throws a CLIError carrying `oclif.exit`, and
|
|
@@ -1565,6 +1574,20 @@ class BaseCommand extends core_1.Command {
|
|
|
1565
1574
|
details: envelopeDetails(body),
|
|
1566
1575
|
});
|
|
1567
1576
|
}
|
|
1577
|
+
else if (bodyCode === 'TASK_LIST_TIMEOUT') {
|
|
1578
|
+
// The list was too broad for the database's time limit — a 503 the API sent on purpose,
|
|
1579
|
+
// with the narrower question to ask. The outage branch below would say skrr is down,
|
|
1580
|
+
// record an incident, and tell an agent to retry the very query that cannot finish
|
|
1581
|
+
// (OSK-21284).
|
|
1582
|
+
this.failWithCliError({
|
|
1583
|
+
message: say(describeTaskListTimeout(body, this.config.bin)),
|
|
1584
|
+
code: bodyCode,
|
|
1585
|
+
status: e.status,
|
|
1586
|
+
exit: 1,
|
|
1587
|
+
retryable: false,
|
|
1588
|
+
details: envelopeDetails(body),
|
|
1589
|
+
});
|
|
1590
|
+
}
|
|
1568
1591
|
else if (bodyCode === 'LABEL_SUGGESTION_UNAVAILABLE') {
|
|
1569
1592
|
// The label-suggestion route found no inference payer — a per-call
|
|
1570
1593
|
// condition the API deliberately reported, not a platform outage,
|
|
@@ -1579,6 +1602,36 @@ class BaseCommand extends core_1.Command {
|
|
|
1579
1602
|
details: envelopeDetails(body),
|
|
1580
1603
|
});
|
|
1581
1604
|
}
|
|
1605
|
+
else if ((bodyCode === COMMITMENT_ACTIVATION_BLOCKED ||
|
|
1606
|
+
stringProp(body, 'error') === COMMITMENT_ACTIVATION_BLOCKED) &&
|
|
1607
|
+
commitmentActivationHint(body)) {
|
|
1608
|
+
// The route puts the code in `error`, in upper case, which `refusalCodeOf` does not read
|
|
1609
|
+
// as a code — so this refusal arrived as `HTTP_409` with the gate's QUESTION as its only
|
|
1610
|
+
// explanation. Name the code, and say what to do (OSK-21126).
|
|
1611
|
+
this.failWithCliError({
|
|
1612
|
+
message: say(`${bodyMessage || e.message}\n → ${commitmentActivationHint(body)}`),
|
|
1613
|
+
code: COMMITMENT_ACTIVATION_BLOCKED,
|
|
1614
|
+
status: e.status,
|
|
1615
|
+
exit: 1,
|
|
1616
|
+
retryable: false,
|
|
1617
|
+
details: envelopeDetails(body),
|
|
1618
|
+
});
|
|
1619
|
+
}
|
|
1620
|
+
else if ((e.status === 409 || e.status === 404) && (0, compass_refusals_1.compassRefusalCode)(body)) {
|
|
1621
|
+
// The Compass routes sent the code in upper-case `error`, which `refusalCodeOf` does not
|
|
1622
|
+
// read as a code, so a stale writer saw `HTTP_409` and a mistyped version `NOT_FOUND`,
|
|
1623
|
+
// both without the versions that say what to do (OSK-21162, OSK-21152). Read these two
|
|
1624
|
+
// codes by name here rather than widening `refusalCodeOf` for every route.
|
|
1625
|
+
const compassCode = (0, compass_refusals_1.compassRefusalCode)(body);
|
|
1626
|
+
this.failWithCliError({
|
|
1627
|
+
message: say((0, compass_refusals_1.describeCompassRefusal)(compassCode, body, this.compassRef ?? {}, this.config.bin)),
|
|
1628
|
+
code: compassCode,
|
|
1629
|
+
status: e.status,
|
|
1630
|
+
exit: compassCode === compass_refusals_1.COMPASS_REVISION_NOT_FOUND ? 4 : 1,
|
|
1631
|
+
retryable: false,
|
|
1632
|
+
details: envelopeDetails(body),
|
|
1633
|
+
});
|
|
1634
|
+
}
|
|
1582
1635
|
else if (bodyCode === 'ASSIGNEE_NOT_IN_SPACE') {
|
|
1583
1636
|
// Code-specific enrichment takes precedence over the status heuristic:
|
|
1584
1637
|
// the server rejects a non-member assignee by id with no next step, so
|
|
@@ -2254,6 +2307,40 @@ function apiRefusal(err) {
|
|
|
2254
2307
|
...(body ? { body } : {}),
|
|
2255
2308
|
};
|
|
2256
2309
|
}
|
|
2310
|
+
/** The typed code the server refuses a Commitment activation with. */
|
|
2311
|
+
const COMMITMENT_ACTIVATION_BLOCKED = 'COMMITMENT_ACTIVATION_BLOCKED';
|
|
2312
|
+
/**
|
|
2313
|
+
* The remedy a refused Commitment activation carries.
|
|
2314
|
+
*
|
|
2315
|
+
* The refusal's message names the blocking Preflight gate by its QUESTION and a reason token
|
|
2316
|
+
* ("Can the runtime enforce this Run? (runtime_commitment_contract_unavailable)"). The gate's own
|
|
2317
|
+
* `hint` — the sentence that says what to run — travels beside it at
|
|
2318
|
+
* `diagnostic.firstBlocker.detail`, and the web client already shows it
|
|
2319
|
+
* (`activationFailureMessage`). The CLI dropped it, so `commitments resume` and
|
|
2320
|
+
* `commitments create --activate` told a person to "fix the gate the reason names" while
|
|
2321
|
+
* `commitments preflight` knew the exact command (OSK-21126).
|
|
2322
|
+
*
|
|
2323
|
+
* Undefined when the gate offered none, so a caller keeps its generic wording.
|
|
2324
|
+
*
|
|
2325
|
+
* Exported for tests.
|
|
2326
|
+
*/
|
|
2327
|
+
function commitmentActivationHint(body) {
|
|
2328
|
+
const diagnostic = body?.diagnostic;
|
|
2329
|
+
if (!diagnostic || typeof diagnostic !== 'object')
|
|
2330
|
+
return undefined;
|
|
2331
|
+
const blocker = diagnostic.firstBlocker;
|
|
2332
|
+
if (!blocker || typeof blocker !== 'object')
|
|
2333
|
+
return undefined;
|
|
2334
|
+
const detail = blocker.detail;
|
|
2335
|
+
if (!detail || typeof detail !== 'object')
|
|
2336
|
+
return undefined;
|
|
2337
|
+
const { hint, note } = detail;
|
|
2338
|
+
for (const candidate of [hint, note]) {
|
|
2339
|
+
if (typeof candidate === 'string' && candidate.trim())
|
|
2340
|
+
return candidate.trim();
|
|
2341
|
+
}
|
|
2342
|
+
return undefined;
|
|
2343
|
+
}
|
|
2257
2344
|
/**
|
|
2258
2345
|
* Prefix a failure message with the resource it is about.
|
|
2259
2346
|
*
|
|
@@ -2316,6 +2403,26 @@ function describeGitHubUnavailable() {
|
|
|
2316
2403
|
return ('GitHub is temporarily unreachable, so this request could not be completed. ' +
|
|
2317
2404
|
'skrr itself answered, so this is not a skrr outage — try again shortly.');
|
|
2318
2405
|
}
|
|
2406
|
+
/**
|
|
2407
|
+
* Frame a typed `TASK_LIST_TIMEOUT` failure as what it is — a list too broad for the database's
|
|
2408
|
+
* time limit — rather than a control-plane outage.
|
|
2409
|
+
*
|
|
2410
|
+
* `GET /api/tasks` answers 503 with this code when its one aggregate is cut off at `maxTimeMS`,
|
|
2411
|
+
* which an unscoped list over every accessible Space reaches because no index serves its sort
|
|
2412
|
+
* across the access filter. Lead with the server's `cause`/`remedy`, falling back to the CLI's
|
|
2413
|
+
* own sentence: the 5xx redaction boundary generalizes a bare message in production.
|
|
2414
|
+
*
|
|
2415
|
+
* Exported for tests.
|
|
2416
|
+
*/
|
|
2417
|
+
function describeTaskListTimeout(body, bin = 'skrr') {
|
|
2418
|
+
const cause = stringProp(body, 'cause') ||
|
|
2419
|
+
'The task list took too long: it spans every task you can see across all your workspaces and ' +
|
|
2420
|
+
'Spaces, and the database could not return the newest page within its time limit.';
|
|
2421
|
+
const remedy = stringProp(body, 'remedy') ||
|
|
2422
|
+
`Name where to look: a workspace (\`${bin} workspaces use <workspace-id>\`, or \`--workspace <workspace-id>\`) ` +
|
|
2423
|
+
`or a Space (\`${bin} tasks list --space <space-id>\`).`;
|
|
2424
|
+
return `${cause}\n → ${remedy}`;
|
|
2425
|
+
}
|
|
2319
2426
|
/**
|
|
2320
2427
|
* Frame a typed `LABEL_SUGGESTION_UNAVAILABLE` failure as what it is — the
|
|
2321
2428
|
* suggestion's hosted-inference call found no billing payer — rather than a
|
|
@@ -12,7 +12,8 @@ import { BaseCommand } from '../../../base-command';
|
|
|
12
12
|
export declare function isUnconfirmedTurnCapture(trigger: Record<string, unknown>): boolean;
|
|
13
13
|
/**
|
|
14
14
|
* `skrr agenda trigger list <agent-id>` — show all triggers registered for
|
|
15
|
-
* an agent (any kind, not just agenda-created ones)
|
|
15
|
+
* an agent (any kind, not just agenda-created ones), including the ones the
|
|
16
|
+
* platform manages for its Commitments (the daily self-reflection check).
|
|
16
17
|
*/
|
|
17
18
|
export default class AgendaTriggerList extends BaseCommand {
|
|
18
19
|
static description: string;
|
|
@@ -7,6 +7,7 @@ const data_provider_1 = require("@skrr-ai/data-provider");
|
|
|
7
7
|
const base_command_1 = require("../../../base-command");
|
|
8
8
|
const format_1 = require("../../../lib/format");
|
|
9
9
|
const triggers_1 = require("../../../lib/triggers");
|
|
10
|
+
const agent_trigger_listing_1 = require("../../../lib/agent-trigger-listing");
|
|
10
11
|
/**
|
|
11
12
|
* A schedule persisted while handling a conversation turn, for which no explicit
|
|
12
13
|
* confirmation was recorded.
|
|
@@ -27,10 +28,11 @@ function isUnconfirmedTurnCapture(trigger) {
|
|
|
27
28
|
}
|
|
28
29
|
/**
|
|
29
30
|
* `skrr agenda trigger list <agent-id>` — show all triggers registered for
|
|
30
|
-
* an agent (any kind, not just agenda-created ones)
|
|
31
|
+
* an agent (any kind, not just agenda-created ones), including the ones the
|
|
32
|
+
* platform manages for its Commitments (the daily self-reflection check).
|
|
31
33
|
*/
|
|
32
34
|
class AgendaTriggerList extends base_command_1.BaseCommand {
|
|
33
|
-
static description =
|
|
35
|
+
static description = "List every trigger registered against an agent, including the ones the platform manages for its Commitments (SOURCE 'system'). A passive agent (--initial-always-on off) still has a daily self-reflection check.";
|
|
34
36
|
static examples = [
|
|
35
37
|
'<%= config.bin %> agenda trigger list <agent-id>',
|
|
36
38
|
'<%= config.bin %> agenda trigger list <agent-id> --unconfirmed',
|
|
@@ -55,17 +57,50 @@ class AgendaTriggerList extends base_command_1.BaseCommand {
|
|
|
55
57
|
catch (err) {
|
|
56
58
|
this.handleApiError(err);
|
|
57
59
|
}
|
|
60
|
+
const r = response;
|
|
61
|
+
const listed = r?.data ?? [];
|
|
62
|
+
// The per-agent route lists `scope: 'agent'` rows only; the Commitment triggers a passive agent still owns
|
|
63
|
+
// live under `commitment_watcher`. `--unconfirmed` is about turn captures, which are agent-scoped, so it
|
|
64
|
+
// skips the extra read.
|
|
65
|
+
let extra = [];
|
|
66
|
+
let extraUnreadable = null;
|
|
67
|
+
if (!flags.unconfirmed) {
|
|
68
|
+
try {
|
|
69
|
+
const universal = await triggers_1.triggerApi.list((0, triggers_1.withQuery)('/api/triggers', { refEntity: [`agent:${args.agentId}`], limit: 200 }));
|
|
70
|
+
extra = (0, agent_trigger_listing_1.triggersMissingFromAgentList)(listed, (universal?.triggers ?? []));
|
|
71
|
+
}
|
|
72
|
+
catch (err) {
|
|
73
|
+
extraUnreadable = err instanceof Error ? err.message : String(err);
|
|
74
|
+
}
|
|
75
|
+
}
|
|
58
76
|
if (flags.json) {
|
|
59
|
-
this.printJsonResult((0, list_output_1.listResult)(
|
|
77
|
+
this.printJsonResult((0, list_output_1.listResult)(r && typeof r === 'object'
|
|
78
|
+
? {
|
|
79
|
+
...r,
|
|
80
|
+
data: [...listed, ...extra],
|
|
81
|
+
...(extraUnreadable
|
|
82
|
+
? {
|
|
83
|
+
warnings: [
|
|
84
|
+
{
|
|
85
|
+
code: 'system_triggers_unreadable',
|
|
86
|
+
value: extraUnreadable,
|
|
87
|
+
hint: systemTriggersUnreadable(args.agentId, extraUnreadable),
|
|
88
|
+
},
|
|
89
|
+
],
|
|
90
|
+
}
|
|
91
|
+
: {}),
|
|
92
|
+
}
|
|
93
|
+
: response));
|
|
60
94
|
return;
|
|
61
95
|
}
|
|
62
|
-
|
|
63
|
-
let items = r?.data ?? [];
|
|
96
|
+
let items = [...listed, ...extra];
|
|
64
97
|
if (flags.unconfirmed) {
|
|
65
98
|
items = items.filter((t) => isUnconfirmedTurnCapture(t));
|
|
66
99
|
}
|
|
67
100
|
if (items.length === 0) {
|
|
68
101
|
this.log(flags.unconfirmed ? 'No unconfirmed turn-captured schedules.' : 'No triggers.');
|
|
102
|
+
if (extraUnreadable)
|
|
103
|
+
this.log(systemTriggersUnreadable(args.agentId, extraUnreadable));
|
|
69
104
|
return;
|
|
70
105
|
}
|
|
71
106
|
const rows = items.map((t) => {
|
|
@@ -81,7 +116,7 @@ class AgendaTriggerList extends base_command_1.BaseCommand {
|
|
|
81
116
|
label: String(t.label ?? '-').slice(0, 40),
|
|
82
117
|
next: String(next).slice(0, 25),
|
|
83
118
|
fires: String(fires),
|
|
84
|
-
source: isUnconfirmedTurnCapture(t)
|
|
119
|
+
source: (0, agent_trigger_listing_1.sourceLabel)(t, isUnconfirmedTurnCapture(t)),
|
|
85
120
|
};
|
|
86
121
|
});
|
|
87
122
|
(0, format_1.renderTable)(rows, [
|
|
@@ -93,6 +128,15 @@ class AgendaTriggerList extends base_command_1.BaseCommand {
|
|
|
93
128
|
{ key: 'fires', header: 'FIRES' },
|
|
94
129
|
{ key: 'source', header: 'SOURCE' },
|
|
95
130
|
], (line) => this.log(line));
|
|
131
|
+
if (rows.some((row) => row.source.startsWith('system'))) {
|
|
132
|
+
this.log('');
|
|
133
|
+
for (const line of (0, agent_trigger_listing_1.systemManagedLegend)(args.agentId, this.config.bin))
|
|
134
|
+
this.log(line);
|
|
135
|
+
}
|
|
136
|
+
if (extraUnreadable) {
|
|
137
|
+
this.log('');
|
|
138
|
+
this.log(systemTriggersUnreadable(args.agentId, extraUnreadable));
|
|
139
|
+
}
|
|
96
140
|
if (rows.some((row) => row.source === 'turn*')) {
|
|
97
141
|
// Deliberately not "the agent scheduled this by itself". The capture layer
|
|
98
142
|
// cannot tell "remind me at 9" from a nudge the agent invented, so the
|
|
@@ -105,3 +149,8 @@ class AgendaTriggerList extends base_command_1.BaseCommand {
|
|
|
105
149
|
}
|
|
106
150
|
}
|
|
107
151
|
exports.default = AgendaTriggerList;
|
|
152
|
+
/** Said, not skipped: a missing read must not look like an agent with no Commitment triggers. */
|
|
153
|
+
function systemTriggersUnreadable(agentId, reason) {
|
|
154
|
+
return (`Platform-managed (Commitment) triggers could not be read (${reason}); this list may be incomplete. ` +
|
|
155
|
+
`Try: skrr triggers list --ref-entity agent:${agentId}`);
|
|
156
|
+
}
|
|
@@ -336,6 +336,13 @@ function noStreamJsonPayload(input) {
|
|
|
336
336
|
// The run first failed as handed over and the machine's reply was then
|
|
337
337
|
// repaired onto the record (OSK-13543).
|
|
338
338
|
...(result.repaired ? { repaired: true } : {}),
|
|
339
|
+
// Tool calls refused for want of `--approve-tools`: the turn completed, and these did not run.
|
|
340
|
+
...(result.permissionDenials?.length
|
|
341
|
+
? {
|
|
342
|
+
permissionDenials: result.permissionDenials,
|
|
343
|
+
permissionDenialHint: 'Re-run with --approve-tools to allow these tool calls.',
|
|
344
|
+
}
|
|
345
|
+
: {}),
|
|
339
346
|
response: result.text,
|
|
340
347
|
// The model a local harness reported running (OSK-12111). Absent on a
|
|
341
348
|
// cloud turn and on a harness that reports none.
|
|
@@ -245,7 +245,9 @@ class AgentsCreate extends base_command_1.BaseCommand {
|
|
|
245
245
|
description: 'Default working directory for local Harness sessions',
|
|
246
246
|
}),
|
|
247
247
|
'initial-always-on': core_1.Flags.string({
|
|
248
|
-
description: 'Start autonomous work after creation (default: on). Use off for a passive agent; explicit chat still works.
|
|
248
|
+
description: 'Start autonomous work after creation (default: on). Use off for a passive agent; explicit chat still works. ' +
|
|
249
|
+
'A passive agent is still seeded with the system-managed daily self-reflection Commitment: `agenda trigger list <agent>` shows its trigger (SOURCE "system", marked "suspended" while the platform holds it for Always-On being off) ' +
|
|
250
|
+
'and `commitments list --agent <agent> --include-system` finds the Commitment to pause. Relationship-loop seeding is configured separately.',
|
|
249
251
|
options: ['on', 'off'],
|
|
250
252
|
}),
|
|
251
253
|
'no-relationship-loops': core_1.Flags.boolean({
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { Command } from '@oclif/core';
|
|
2
|
+
/**
|
|
3
|
+
* Whether browser sessions on THIS computer share one profile that keeps its
|
|
4
|
+
* logins and cache, instead of a fresh one each.
|
|
5
|
+
*
|
|
6
|
+
* The setting lives in the daemon's own config on this computer, so it is
|
|
7
|
+
* forwarded to the daemon rather than sent to the API: a browser that stays
|
|
8
|
+
* signed in is the person at the machine's decision, and a request from the
|
|
9
|
+
* cloud must not be able to make it (the same boundary as `browser
|
|
10
|
+
* cloud-agents`). The profile is the daemon's own, never the everyday Chrome.
|
|
11
|
+
*/
|
|
12
|
+
export default class BrowserPersistentProfile extends Command {
|
|
13
|
+
static description: string;
|
|
14
|
+
static examples: string[];
|
|
15
|
+
static args: {
|
|
16
|
+
action: import("@oclif/core/interfaces").Arg<string, Record<string, unknown>>;
|
|
17
|
+
};
|
|
18
|
+
static flags: {
|
|
19
|
+
json: import("@oclif/core/interfaces").BooleanFlag<boolean>;
|
|
20
|
+
};
|
|
21
|
+
run(): Promise<void>;
|
|
22
|
+
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const core_1 = require("@oclif/core");
|
|
4
|
+
const browser_1 = require("../browser");
|
|
5
|
+
/**
|
|
6
|
+
* Whether browser sessions on THIS computer share one profile that keeps its
|
|
7
|
+
* logins and cache, instead of a fresh one each.
|
|
8
|
+
*
|
|
9
|
+
* The setting lives in the daemon's own config on this computer, so it is
|
|
10
|
+
* forwarded to the daemon rather than sent to the API: a browser that stays
|
|
11
|
+
* signed in is the person at the machine's decision, and a request from the
|
|
12
|
+
* cloud must not be able to make it (the same boundary as `browser
|
|
13
|
+
* cloud-agents`). The profile is the daemon's own, never the everyday Chrome.
|
|
14
|
+
*/
|
|
15
|
+
class BrowserPersistentProfile extends core_1.Command {
|
|
16
|
+
static description = 'Keep one browser profile (logins, cookies, cache) across browser sessions on this computer (off by default)';
|
|
17
|
+
static examples = [
|
|
18
|
+
'<%= config.bin %> browser persistent-profile status',
|
|
19
|
+
'<%= config.bin %> browser persistent-profile on',
|
|
20
|
+
'<%= config.bin %> browser persistent-profile off',
|
|
21
|
+
'<%= config.bin %> browser persistent-profile reset',
|
|
22
|
+
];
|
|
23
|
+
static args = {
|
|
24
|
+
action: core_1.Args.string({
|
|
25
|
+
description: 'on, off, status, or reset (sign out of everything and delete the profile)',
|
|
26
|
+
required: true,
|
|
27
|
+
options: ['on', 'off', 'status', 'reset'],
|
|
28
|
+
// Without this oclif reads stdin for a missing positional, so the command
|
|
29
|
+
// hangs when run from a pipe or a non-tty instead of refusing. Enforced
|
|
30
|
+
// by ARG_IMPLICIT_STDIN_ENABLED in the command-hygiene audit.
|
|
31
|
+
ignoreStdin: true,
|
|
32
|
+
}),
|
|
33
|
+
};
|
|
34
|
+
static flags = {
|
|
35
|
+
json: core_1.Flags.boolean({ description: 'Output JSON' }),
|
|
36
|
+
};
|
|
37
|
+
async run() {
|
|
38
|
+
const { args, flags } = await this.parse(BrowserPersistentProfile);
|
|
39
|
+
await (0, browser_1.forwardBrowserCommand)(this, [
|
|
40
|
+
'persistent-profile',
|
|
41
|
+
args.action,
|
|
42
|
+
...(flags.json ? ['--json'] : []),
|
|
43
|
+
]);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
exports.default = BrowserPersistentProfile;
|
|
@@ -42,8 +42,8 @@ class CommitmentsActionHistory extends base_command_1.BaseCommand {
|
|
|
42
42
|
this.handleApiError(err);
|
|
43
43
|
}
|
|
44
44
|
if (flags.json) {
|
|
45
|
+
// One JSON document and nothing else: has_more / next_cursor are in it.
|
|
45
46
|
this.log(JSON.stringify(response, null, 2));
|
|
46
|
-
(0, commitments_1.renderListPageHint)(response, (line) => this.log(line));
|
|
47
47
|
return;
|
|
48
48
|
}
|
|
49
49
|
(0, commitment_ledgers_1.renderActionHistory)(response, (line) => this.log(line));
|
|
@@ -31,11 +31,11 @@ class CommitmentsCases extends base_command_1.BaseCommand {
|
|
|
31
31
|
this.handleApiError(error);
|
|
32
32
|
}
|
|
33
33
|
if (flags.json) {
|
|
34
|
+
// One JSON document and nothing else: has_more / next_cursor are in it.
|
|
34
35
|
this.log(JSON.stringify(result, null, 2));
|
|
36
|
+
return;
|
|
35
37
|
}
|
|
36
|
-
|
|
37
|
-
(0, commitments_1.renderCommitmentCases)(result, (line) => this.log(line));
|
|
38
|
-
}
|
|
38
|
+
(0, commitments_1.renderCommitmentCases)(result, (line) => this.log(line));
|
|
39
39
|
(0, commitments_1.renderListPageHint)(result, (line) => this.log(line));
|
|
40
40
|
}
|
|
41
41
|
}
|
|
@@ -1,6 +1,14 @@
|
|
|
1
1
|
import { BaseCommand } from '../../base-command';
|
|
2
|
-
/** Render runtime/Always-On blockers returned alongside
|
|
3
|
-
export declare function manualCheckBlockerLines(result: Record<string, unknown
|
|
2
|
+
/** Render runtime/Always-On blockers returned alongside a Check (accepted, or skipped). */
|
|
3
|
+
export declare function manualCheckBlockerLines(result: Record<string, unknown>, heading?: string): string[];
|
|
4
|
+
/**
|
|
5
|
+
* Why a Check was not queued, in words, and what to do. The server answers with a reason code
|
|
6
|
+
* (`commitment_draft`, `commitment_paused`, ...) and the CLI used to print only that, so "Check
|
|
7
|
+
* skipped / Reason: commitment_draft" gave no hint that the Commitment simply was not turned on
|
|
8
|
+
* (dogfood df-261031-commitment-authoring, F11). The code stays in parentheses so it can be
|
|
9
|
+
* searched for and quoted. `null` for a reason this does not know: the caller prints it as it came.
|
|
10
|
+
*/
|
|
11
|
+
export declare function describeNotQueuedReason(reason: unknown, id: string, bin?: string): string | null;
|
|
4
12
|
/**
|
|
5
13
|
* `skrr commitments check-now <id>` — run one control-loop iteration immediately.
|
|
6
14
|
*
|
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.manualCheckBlockerLines = manualCheckBlockerLines;
|
|
4
|
+
exports.describeNotQueuedReason = describeNotQueuedReason;
|
|
4
5
|
const core_1 = require("@oclif/core");
|
|
5
6
|
const base_command_1 = require("../../base-command");
|
|
6
7
|
const web_url_1 = require("../../lib/web-url");
|
|
7
8
|
const commitments_1 = require("../../lib/commitments");
|
|
8
|
-
|
|
9
|
-
|
|
9
|
+
const ACCEPTED_CHECK_BLOCKER_HEADING = 'Warning: this check can record state, but autonomous agent work is blocked:';
|
|
10
|
+
/** Render runtime/Always-On blockers returned alongside a Check (accepted, or skipped). */
|
|
11
|
+
function manualCheckBlockerLines(result, heading = ACCEPTED_CHECK_BLOCKER_HEADING) {
|
|
10
12
|
const blockers = Array.isArray(result.executionBlockers)
|
|
11
13
|
? result.executionBlockers
|
|
12
14
|
: [];
|
|
13
15
|
if (!blockers.length)
|
|
14
16
|
return [];
|
|
15
|
-
const lines = [
|
|
17
|
+
const lines = [heading];
|
|
16
18
|
for (const blocker of blockers) {
|
|
17
19
|
const label = typeof blocker.label === 'string' && blocker.label ? blocker.label : 'Execution';
|
|
18
20
|
const reason = typeof blocker.reason === 'string' && blocker.reason ? ` — ${blocker.reason}` : '';
|
|
@@ -23,6 +25,40 @@ function manualCheckBlockerLines(result) {
|
|
|
23
25
|
}
|
|
24
26
|
return lines;
|
|
25
27
|
}
|
|
28
|
+
/**
|
|
29
|
+
* Why a Check was not queued, in words, and what to do. The server answers with a reason code
|
|
30
|
+
* (`commitment_draft`, `commitment_paused`, ...) and the CLI used to print only that, so "Check
|
|
31
|
+
* skipped / Reason: commitment_draft" gave no hint that the Commitment simply was not turned on
|
|
32
|
+
* (dogfood df-261031-commitment-authoring, F11). The code stays in parentheses so it can be
|
|
33
|
+
* searched for and quoted. `null` for a reason this does not know: the caller prints it as it came.
|
|
34
|
+
*/
|
|
35
|
+
function describeNotQueuedReason(reason, id, bin = 'skrr') {
|
|
36
|
+
if (typeof reason !== 'string' || !reason)
|
|
37
|
+
return null;
|
|
38
|
+
const resume = `Turn it on with \`${bin} commitments resume ${id}\`.`;
|
|
39
|
+
const sentence = (text) => `${text} (${reason})`;
|
|
40
|
+
switch (reason) {
|
|
41
|
+
case 'commitment_draft':
|
|
42
|
+
return sentence(`Nothing was queued: this Commitment is a draft, so it never runs. ${resume}`);
|
|
43
|
+
case 'commitment_paused':
|
|
44
|
+
return sentence(`Nothing was queued: this Commitment is paused. ${resume}`);
|
|
45
|
+
case 'commitment_archived':
|
|
46
|
+
case 'commitment_completed':
|
|
47
|
+
case 'commitment_cancelled':
|
|
48
|
+
return sentence(`Nothing was queued: this Commitment is ${reason.slice('commitment_'.length)}, so it no longer runs.`);
|
|
49
|
+
case 'commitment_deleted':
|
|
50
|
+
return sentence('Nothing was queued: this Commitment was deleted.');
|
|
51
|
+
case 'commitment_check_not_reserved':
|
|
52
|
+
return sentence('Nothing was queued: the platform did not reserve a new check for it just now. Try again shortly.');
|
|
53
|
+
case 'reservation_exists':
|
|
54
|
+
// Two requests at once: one reserves the check, the other meets that reservation.
|
|
55
|
+
return sentence(`Nothing new was queued: a check for this Commitment is already queued or running. See it with \`${bin} commitments checks ${id}\`.`);
|
|
56
|
+
case 'queue_unavailable':
|
|
57
|
+
return sentence('Nothing was queued: the check queue is unavailable right now. Try again shortly.');
|
|
58
|
+
default:
|
|
59
|
+
return null;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
26
62
|
/**
|
|
27
63
|
* `skrr commitments check-now <id>` — run one control-loop iteration immediately.
|
|
28
64
|
*
|
|
@@ -60,6 +96,20 @@ class CommitmentsCheckNow extends base_command_1.BaseCommand {
|
|
|
60
96
|
const status = String(result.status ?? 'unknown');
|
|
61
97
|
const checkId = result.checkId ? String(result.checkId) : null;
|
|
62
98
|
this.log(`Check ${status}${checkId ? ` — ${checkId}` : ''}`);
|
|
99
|
+
if (status !== 'queued') {
|
|
100
|
+
const sentence = describeNotQueuedReason(result.reason, args.id, this.config.bin);
|
|
101
|
+
if (sentence)
|
|
102
|
+
this.log(sentence);
|
|
103
|
+
else if (result.reason)
|
|
104
|
+
this.log(`Reason: ${String(result.reason)}`);
|
|
105
|
+
// What would stop it from running once it is on, so the fix is not discovered one try at a time.
|
|
106
|
+
const blockerLines = manualCheckBlockerLines(result, 'When it is on, these will also keep agent work from running:');
|
|
107
|
+
if (blockerLines.length)
|
|
108
|
+
this.log('');
|
|
109
|
+
for (const line of blockerLines)
|
|
110
|
+
this.log(line);
|
|
111
|
+
return;
|
|
112
|
+
}
|
|
63
113
|
if (result.reason)
|
|
64
114
|
this.log(`Reason: ${String(result.reason)}`);
|
|
65
115
|
if (status === 'queued') {
|
|
@@ -20,19 +20,10 @@ export declare function createCadenceFromFlags({ eventDriven, cadence: cadenceIn
|
|
|
20
20
|
cadenceMode?: string;
|
|
21
21
|
timezone?: string;
|
|
22
22
|
}): Record<string, unknown> | undefined;
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
* be said out loud at the CLI boundary; otherwise a successful create response
|
|
28
|
-
* reads like the requested autonomy is live when something else is running.
|
|
29
|
-
*/
|
|
30
|
-
/**
|
|
31
|
-
* A refused `--activate` leaves a draft, and the draft's id is the answer the
|
|
32
|
-
* caller needs — so the refusal is reported on the result, never thrown over
|
|
33
|
-
* it. `{code, reason, fix}` mirrors the MCP surface's refusal; `guide` points
|
|
34
|
-
* at the section that explains the code when one does (resolved offline).
|
|
35
|
-
*/
|
|
23
|
+
export type ActivationBlocker = {
|
|
24
|
+
gate: string;
|
|
25
|
+
reason: string;
|
|
26
|
+
};
|
|
36
27
|
export declare function commitmentActivationRefusal(err: unknown, { id, bin }: {
|
|
37
28
|
id: string;
|
|
38
29
|
bin: string;
|
|
@@ -41,6 +32,7 @@ export declare function commitmentActivationRefusal(err: unknown, { id, bin }: {
|
|
|
41
32
|
reason: string;
|
|
42
33
|
fix: string;
|
|
43
34
|
guide?: AgentGuidePointer;
|
|
35
|
+
blockers?: ActivationBlocker[];
|
|
44
36
|
};
|
|
45
37
|
/**
|
|
46
38
|
* `skrr commitments create` — author a durable commitment contract.
|
|
@@ -89,7 +81,7 @@ export default class CommitmentsCreate extends BaseCommand {
|
|
|
89
81
|
repo: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
90
82
|
base: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
91
83
|
isolation: import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
92
|
-
'max-nudges': import("@oclif/core/interfaces").OptionFlag<
|
|
84
|
+
'max-nudges': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
93
85
|
'max-concurrent-runs': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
94
86
|
'concurrency-reason': import("@oclif/core/interfaces").OptionFlag<string | undefined, import("@oclif/core/interfaces").CustomOptions>;
|
|
95
87
|
};
|