@skrr-ai/cli 0.1.97 → 0.1.99

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.
Files changed (62) hide show
  1. package/dist/base-command.d.ts +7 -0
  2. package/dist/base-command.js +10 -1
  3. package/dist/commands/agents/create.js +3 -3
  4. package/dist/commands/agents/update.js +22 -3
  5. package/dist/commands/commitments/create.js +29 -8
  6. package/dist/commands/commitments/observations.js +3 -1
  7. package/dist/commands/commitments/update.js +69 -14
  8. package/dist/commands/machines/dedicated/show.js +1 -0
  9. package/dist/commands/machines/show.js +13 -4
  10. package/dist/commands/signals/monitors/create.d.ts +2 -2
  11. package/dist/commands/signals/monitors/create.js +2 -2
  12. package/dist/commands/signals/monitors/list.d.ts +2 -2
  13. package/dist/commands/signals/monitors/list.js +2 -2
  14. package/dist/commands/signals/monitors/pause.d.ts +2 -2
  15. package/dist/commands/signals/monitors/pause.js +2 -2
  16. package/dist/commands/signals/monitors/resume.d.ts +2 -2
  17. package/dist/commands/signals/monitors/resume.js +2 -2
  18. package/dist/commands/signals/monitors/revise.d.ts +2 -2
  19. package/dist/commands/signals/monitors/revise.js +2 -2
  20. package/dist/commands/signals/monitors/show.d.ts +2 -2
  21. package/dist/commands/signals/monitors/show.js +2 -2
  22. package/dist/commands/signals/monitors/test.d.ts +2 -2
  23. package/dist/commands/signals/monitors/test.js +2 -2
  24. package/dist/commands/signals/monitors/transitions.d.ts +2 -2
  25. package/dist/commands/signals/monitors/transitions.js +2 -2
  26. package/dist/commands/signals/monitors/validate.d.ts +2 -2
  27. package/dist/commands/signals/monitors/validate.js +2 -2
  28. package/dist/commands/signals/schemas/list.d.ts +2 -2
  29. package/dist/commands/signals/schemas/list.js +2 -2
  30. package/dist/commands/signals/schemas/show.d.ts +2 -2
  31. package/dist/commands/signals/schemas/show.js +2 -2
  32. package/dist/commands/signals/sources/list.d.ts +2 -2
  33. package/dist/commands/signals/sources/list.js +2 -2
  34. package/dist/commands/signals/sources/receipts.d.ts +2 -2
  35. package/dist/commands/signals/sources/receipts.js +2 -2
  36. package/dist/commands/signals/sources/show.d.ts +2 -2
  37. package/dist/commands/signals/sources/show.js +2 -2
  38. package/dist/commands/tasks/assign.js +3 -4
  39. package/dist/commands/tasks/complete.d.ts +1 -0
  40. package/dist/commands/tasks/complete.js +1 -0
  41. package/dist/commands/tasks/create.js +4 -2
  42. package/dist/commands/tasks/deliverable/add.d.ts +1 -0
  43. package/dist/commands/tasks/deliverable/add.js +1 -0
  44. package/dist/commands/tasks/result/submit.d.ts +1 -0
  45. package/dist/commands/tasks/result/submit.js +1 -0
  46. package/dist/commands/tasks/resume/save.d.ts +1 -0
  47. package/dist/commands/tasks/resume/save.js +1 -0
  48. package/dist/commands/tasks/retry.js +38 -6
  49. package/dist/commands/tasks/show.js +3 -1
  50. package/dist/commands/tasks/update.js +31 -4
  51. package/dist/commands/tasks/updates/add.d.ts +1 -0
  52. package/dist/commands/tasks/updates/add.js +1 -0
  53. package/dist/lib/commitments.js +34 -2
  54. package/dist/lib/dedicated-machines.d.ts +5 -7
  55. package/dist/lib/dedicated-machines.js +19 -10
  56. package/dist/lib/signals.js +22 -13
  57. package/dist/lib/space-usage.js +1 -1
  58. package/dist/node_modules/@skrr-ai/data-provider/index.js +35 -19
  59. package/dist/signal-command.d.ts +11 -0
  60. package/dist/signal-command.js +15 -0
  61. package/oclif.manifest.json +1273 -24
  62. package/package.json +1 -1
@@ -21,6 +21,13 @@ type OclifArgOutput = {
21
21
  [name: string]: unknown;
22
22
  };
23
23
  export declare abstract class BaseCommand extends Command {
24
+ /**
25
+ * Managed commands normally require the daemon's delegated CLI credential.
26
+ * A command whose complete managed path uses the bound-session endpoints
27
+ * declares that policy locally, so its narrower actor does not depend on
28
+ * acquiring unrelated account authority. Human invocations are unaffected.
29
+ */
30
+ static autonomousCredentialPolicy: 'delegated' | 'bound-session';
24
31
  /** Add the owning agent's web detail link without overwriting resource URLs. */
25
32
  protected withAgentContext<T>(agentId: string, value: T): T & {
26
33
  agentUrl: string | null;
@@ -109,6 +109,13 @@ function describeAbsentGuestDaemon(outcome, bin) {
109
109
  return (0, daemonBrokerRefusal_1.describeGuestDaemonUnavailable)(outcome, { bin, onGuest, descriptorPresent });
110
110
  }
111
111
  class BaseCommand extends core_1.Command {
112
+ /**
113
+ * Managed commands normally require the daemon's delegated CLI credential.
114
+ * A command whose complete managed path uses the bound-session endpoints
115
+ * declares that policy locally, so its narrower actor does not depend on
116
+ * acquiring unrelated account authority. Human invocations are unaffected.
117
+ */
118
+ static autonomousCredentialPolicy = 'delegated';
112
119
  /** Add the owning agent's web detail link without overwriting resource URLs. */
113
120
  withAgentContext(agentId, value) {
114
121
  const agentUrl = (0, web_url_1.agentUrlFrom)(this.cliConfig.baseURL, { id: agentId });
@@ -236,7 +243,9 @@ class BaseCommand extends core_1.Command {
236
243
  // state. The restricted session token (or a null credential when it is
237
244
  // missing) is the only adapter authority exposed to the command.
238
245
  let autonomousCredential = (0, credential_resolver_1.resolveTrustedAutonomousCredential)();
239
- if ((0, delegated_cli_1.isDelegatedCliSession)()) {
246
+ const boundSessionCommand = Boolean(autonomousCredential &&
247
+ this.constructor.autonomousCredentialPolicy === 'bound-session');
248
+ if ((0, delegated_cli_1.isDelegatedCliSession)() && !boundSessionCommand) {
240
249
  try {
241
250
  const delegatedCredential = await (0, delegated_cli_1.fetchDelegatedCliCredential)();
242
251
  if (!delegatedCredential) {
@@ -407,9 +407,9 @@ class AgentsCreate extends base_command_1.BaseCommand {
407
407
  // declared a requirement the server does not model has NOT declared it, and
408
408
  // finding that out later — from a run that landed somewhere it should not
409
409
  // have — is the expensive way (OSK-7704).
410
- // relationshipLoops is an input-only provisioning control. The server
411
- // applies it by deciding which system commitments to seed, so it is not an
412
- // Agent document field and is intentionally absent from the response.
410
+ // The server persists relationshipLoops as creation-time provisioning intent.
411
+ // It is a platform control, so it does not participate in the editable
412
+ // definition-field round-trip warning.
413
413
  const unapplied = unappliedPayloadKeys(payload, created, [
414
414
  'relationshipLoops',
415
415
  ...(0, agent_config_1.deprecatedFieldNames)(created),
@@ -243,14 +243,33 @@ exports.default = AgentsUpdate;
243
243
  * Exported for tests.
244
244
  */
245
245
  function agentUpdateWarnings(payload, updated) {
246
+ const isRecord = (value) => value !== null && typeof value === 'object' && !Array.isArray(value);
247
+ const controlReply = isRecord(updated) &&
248
+ typeof updated.agentId === 'string' &&
249
+ isRecord(updated.state) &&
250
+ typeof updated.state.isAlwaysOn === 'boolean';
251
+ let comparison = updated;
252
+ if (controlReply && isRecord(updated) && isRecord(updated.state)) {
253
+ const projection = isRecord(updated.agent) ? { ...updated.agent } : {};
254
+ // The ordinary Agent snapshot can precede the control write. Only the
255
+ // returned control state acknowledges this field, including a false value.
256
+ delete projection.isAlwaysOn;
257
+ delete projection.expectedGeneration;
258
+ if (typeof payload.isAlwaysOn === 'boolean' &&
259
+ updated.state.isAlwaysOn === payload.isAlwaysOn) {
260
+ projection.isAlwaysOn = updated.state.isAlwaysOn;
261
+ }
262
+ comparison = projection;
263
+ }
246
264
  const cleared = Object.keys(payload).filter((key) => payload[key] === null);
247
- const unapplied = (0, create_1.unappliedPayloadKeys)(payload, updated, [
265
+ const unapplied = (0, create_1.unappliedPayloadKeys)(payload, comparison, [
248
266
  'removeProjectIds',
249
267
  ...cleared,
250
- ...(0, agent_config_1.deprecatedFieldNames)(updated),
268
+ ...(0, agent_config_1.deprecatedFieldNames)(comparison),
269
+ ...(controlReply && typeof payload.isAlwaysOn === 'boolean' ? ['expectedGeneration'] : []),
251
270
  ]);
252
271
  return [
253
- ...(0, agent_config_1.deprecatedFieldsWarnings)(updated),
272
+ ...(0, agent_config_1.deprecatedFieldsWarnings)(comparison),
254
273
  ...(unapplied.length > 0 ? [(0, create_1.unappliedPayloadKeysWarning)(unapplied)] : []),
255
274
  ];
256
275
  }
@@ -163,12 +163,36 @@ class CommitmentsCreate extends base_command_1.BaseCommand {
163
163
  '<%= config.bin %> commitments create --agent <agent-id> --title "SLA" --outcome "p95 under 200ms" --criterion "p95 latency confirmed" --evaluator metric --measure <measure-id>',
164
164
  '<%= config.bin %> commitments create --agent <agent-id> --title "AWS cost watch" --outcome "Cost regressions are investigated" --agent-directive-file ./aws-cost-policy.md',
165
165
  '<%= config.bin %> commitments create --from-json commitment.json --json',
166
+ `# Replace <agent-id> with your Agent ID; this creates a draft, not a running loop.
167
+ cat > commitment.json <<'JSON'
168
+ {
169
+ "agentId": "<agent-id>",
170
+ "title": "Daily queue review",
171
+ "status": "draft",
172
+ "target": { "outcome": "Queue changes are reviewed" },
173
+ "cadence": { "mode": "daily", "times": ["09:15", "17:45"], "timezone": "Asia/Shanghai" },
174
+ "watchedSources": [{
175
+ "source": "agent_run",
176
+ "config": { "keys": [
177
+ { "key": "queue.depth", "label": "Queue depth", "requireArtifact": true,
178
+ "changeRule": { "mode": "numeric_delta", "minDelta": 2, "absoluteFloor": 1 } },
179
+ "queue.status"
180
+ ] }
181
+ }],
182
+ "policy": {
183
+ "maxUserNudgesPerDay": 0,
184
+ "executionBudget": { "maxRunsPerDay": 0, "maxObservationRunsPerDay": 0, "maxCostUsdPerDay": 0 }
185
+ }
186
+ }
187
+ JSON
188
+ <%= config.bin %> commitments preflight --from-json commitment.json
189
+ <%= config.bin %> commitments create --from-json commitment.json --json`,
166
190
  '<%= config.bin %> commitments create --agent <agent-id> --title "Keep CI healthy" --outcome "Failed checks are repaired" --watch github --github-event check_run_failed --event-driven --delivery draft-pr --repo owner/repo --base main --status draft',
167
191
  ];
168
192
  static flags = {
169
193
  json: core_1.Flags.boolean({ description: 'Output the created commitment as JSON' }),
170
194
  'from-json': core_1.Flags.string({
171
- description: 'Path to a JSON file (or "-" for stdin) for fields not exposed as flags',
195
+ description: 'JSON file (or "-" for stdin) for fields not exposed as flags. See examples below for daily times, named agent_run keys and zero budgets.',
172
196
  }),
173
197
  agent: core_1.Flags.string({ description: 'Agent that owns and watches this commitment (required)' }),
174
198
  kind: core_1.Flags.string({
@@ -256,13 +280,10 @@ class CommitmentsCreate extends base_command_1.BaseCommand {
256
280
  repo: core_1.Flags.string({ description: 'Delivery repository, owner/repo' }),
257
281
  base: core_1.Flags.string({ description: 'Delivery target branch' }),
258
282
  isolation: core_1.Flags.string({
259
- // Omitting this is not the same as passing `shared`: an omitted value
260
- // leaves the daemon's own isolation heuristic in force, while `shared` is
261
- // an explicit contract that suppresses it. Say so here, because `--help`
262
- // is where someone decides which of the two they mean.
263
- description: 'Where autonomous runs do their work. "ephemeral" cuts a one-shot git worktree per run ' +
264
- 'and destroys it after; "shared" lands them on the daemon working tree, in place. ' +
265
- 'Omit to leave the runtime default. Cannot be combined with a remediation capability.',
283
+ // Keep the CLI optional without declaring a default; the server owns
284
+ // Commitment isolation policy. Describe only its supported vocabulary.
285
+ description: 'Each run uses an "ephemeral" Git worktree. Requires the Agent working directory ' +
286
+ 'to be in a Git repository with an initial commit. Omit to keep the platform default.',
266
287
  options: [...commitments_1.COMMITMENT_EXECUTION_ISOLATION_MODES],
267
288
  hidden: true,
268
289
  }),
@@ -90,7 +90,9 @@ class CommitmentsObservations extends base_command_1.BaseCommand {
90
90
  'changed-only': core_1.Flags.boolean({
91
91
  description: 'Only readings the server judged a material change',
92
92
  }),
93
- since: core_1.Flags.string({ description: 'ISO date — only observations made after it' }),
93
+ since: core_1.Flags.string({
94
+ description: 'ISO date — inclusive lower bound on platform recordedAt; source observedAt is separate.',
95
+ }),
94
96
  cursor: core_1.Flags.string({
95
97
  description: 'Continue from the next_cursor emitted by a previous page',
96
98
  }),
@@ -38,6 +38,15 @@ class CommitmentsUpdate extends base_command_1.BaseCommand {
38
38
  '<%= config.bin %> commitments update <commitment-id> --watch tasks --watch github',
39
39
  '<%= config.bin %> commitments update <commitment-id> --criterion "signups confirmed" --evaluator metric --measure <measure-id>',
40
40
  '<%= config.bin %> commitments update <commitment-id> --agent-directive-file ./review-policy.md',
41
+ `# Read the current contract and use its version for --if-version.
42
+ <%= config.bin %> commitments show <commitment-id> --json
43
+ cat > commitment-patch.json <<'JSON'
44
+ {
45
+ "cadence": { "mode": "daily", "times": ["09:15", "17:45"], "timezone": "Asia/Shanghai" },
46
+ "policy": { "executionBudget": { "maxObservationRunsPerDay": 0 } }
47
+ }
48
+ JSON
49
+ <%= config.bin %> commitments update <commitment-id> --from-json commitment-patch.json --if-version <observed-version> --json`,
41
50
  ];
42
51
  static args = {
43
52
  id: core_1.Args.string({ description: 'Commitment ID', required: true, ignoreStdin: true }),
@@ -49,7 +58,7 @@ class CommitmentsUpdate extends base_command_1.BaseCommand {
49
58
  description: 'Skip the confirmation prompt for an irreversible status change',
50
59
  }),
51
60
  'from-json': core_1.Flags.string({
52
- description: 'Path to a JSON file (or "-" for stdin) for fields not exposed as flags',
61
+ description: 'JSON patch file (or "-" for stdin). See examples below. JSON cadence and watchedSources replace those fields; policy is deep-merged.',
53
62
  }),
54
63
  'if-version': core_1.Flags.integer({
55
64
  description: 'Only update this observed contract version; returns a conflict if it changed',
@@ -89,7 +98,7 @@ class CommitmentsUpdate extends base_command_1.BaseCommand {
89
98
  description: 'Watched source the criterion reads (implies --evaluator source_state), e.g. github',
90
99
  }),
91
100
  watch: core_1.Flags.string({
92
- description: 'Watched source (repeatable). Replaces the existing set. Some sources need companion flags: --watch-space, --watch-monitor.',
101
+ description: 'Watched source (repeatable). Replaces the selected set and retains config for matching bindings. Some sources need companion flags: --watch-space, --watch-monitor.',
93
102
  multiple: true,
94
103
  options: [...commitments_1.COMMITMENT_WATCHED_SOURCES],
95
104
  }),
@@ -112,9 +121,8 @@ class CommitmentsUpdate extends base_command_1.BaseCommand {
112
121
  isolation: core_1.Flags.string({
113
122
  // Sent as a single-key `policy` patch. The API deep-merges it, so this
114
123
  // cannot blank an autonomy mode or an attention budget set elsewhere.
115
- description: 'Where autonomous runs do their work: "ephemeral" (one-shot git worktree per run) or ' +
116
- '"shared" (the daemon working tree, in place). Cannot be combined with a remediation ' +
117
- 'capability.',
124
+ description: 'Each run uses an "ephemeral" Git worktree. Requires the Agent working directory ' +
125
+ 'to be in a Git repository with an initial commit.',
118
126
  options: [...commitments_1.COMMITMENT_EXECUTION_ISOLATION_MODES],
119
127
  }),
120
128
  'max-concurrent-runs': core_1.Flags.string({
@@ -135,6 +143,7 @@ class CommitmentsUpdate extends base_command_1.BaseCommand {
135
143
  this.error('--evaluator and --measure require at least one --criterion.', { exit: 1 });
136
144
  }
137
145
  const watched = (0, triggers_1.splitRepeated)(flags.watch);
146
+ const wantsSources = Boolean(watched?.length || flags['watch-space']?.length || flags['watch-monitor']?.length);
138
147
  const wantsTarget = flags.outcome !== undefined || flags.deadline !== undefined || criteria.length > 0;
139
148
  const wantsCadence = flags.cadence !== undefined ||
140
149
  flags['cadence-mode'] !== undefined ||
@@ -153,6 +162,7 @@ class CommitmentsUpdate extends base_command_1.BaseCommand {
153
162
  let current;
154
163
  if (wantsTarget ||
155
164
  wantsCadence ||
165
+ wantsSources ||
156
166
  authoredDelivery ||
157
167
  flags['task-review-policy'] !== undefined) {
158
168
  try {
@@ -259,17 +269,48 @@ class CommitmentsUpdate extends base_command_1.BaseCommand {
259
269
  spaceIds: resolvedSpaceIds,
260
270
  monitorIds: (0, triggers_1.splitRepeated)(flags['watch-monitor']),
261
271
  });
262
- if (built)
263
- payload.watchedSources = built;
272
+ if (built) {
273
+ // Flags replace the selected source SET, not the declarations of a
274
+ // retained binding. In particular agent_run's named keys are JSON
275
+ // authored; rebuilding a bare source silently erased them (OSK-15110).
276
+ const declarations = Array.isArray(payload.watchedSources)
277
+ ? payload.watchedSources
278
+ : current?.watchedSources ?? [];
279
+ payload.watchedSources = built.map((next) => {
280
+ const scopeKey = next.source === 'space' ? 'spaceId'
281
+ : next.source === 'monitor' ? 'monitorId' : undefined;
282
+ const nextConfig = next.config;
283
+ const prior = declarations.find((binding) => binding?.source === next.source &&
284
+ (!scopeKey || binding.config?.[scopeKey] === nextConfig?.[scopeKey]));
285
+ if (!prior)
286
+ return next;
287
+ return {
288
+ ...prior,
289
+ ...next,
290
+ ...(nextConfig ? { config: { ...prior.config, ...nextConfig } } : {}),
291
+ };
292
+ });
293
+ // Do not overwrite declarations changed after our merge read.
294
+ if (payload.expectedVersion === undefined)
295
+ payload.expectedVersion = current?.version;
296
+ }
264
297
  if (wantsCadence) {
265
298
  const existing = current?.cadence ?? {};
266
- const cadence = {};
267
- if (existing.mode)
268
- cadence.mode = existing.mode;
269
- if (existing.intervalMs)
270
- cadence.intervalMs = existing.intervalMs;
271
- if (existing.timezone)
272
- cadence.timezone = existing.timezone;
299
+ const storedCadence = {};
300
+ for (const key of ['mode', 'intervalMs', 'times', 'jitterRatio', 'timezone']) {
301
+ if (existing[key] !== undefined)
302
+ storedCadence[key] = existing[key];
303
+ }
304
+ if (payload.cadence !== undefined) {
305
+ if (!payload.cadence || typeof payload.cadence !== 'object' || Array.isArray(payload.cadence)) {
306
+ this.error('cadence must be a JSON object when using cadence flags.', { exit: 1 });
307
+ }
308
+ }
309
+ const authoredCadence = payload.cadence;
310
+ const cadence = {
311
+ ...storedCadence,
312
+ ...authoredCadence,
313
+ };
273
314
  if (flags.cadence) {
274
315
  cadence.intervalMs = (0, commitments_1.parseIntervalToMs)(flags.cadence);
275
316
  // Setting an interval on a manual commitment implies interval mode.
@@ -280,7 +321,21 @@ class CommitmentsUpdate extends base_command_1.BaseCommand {
280
321
  cadence.mode = flags['cadence-mode'];
281
322
  if (flags.timezone)
282
323
  cadence.timezone = flags.timezone;
324
+ // A mode change must not carry the previous mode's fields into the
325
+ // replacement. Keep explicitly authored fields so invalid combinations
326
+ // are refused rather than silently discarding what the user requested.
327
+ if (cadence.mode !== existing.mode) {
328
+ if (cadence.mode !== 'daily' && !Object.hasOwn(authoredCadence ?? {}, 'times')) {
329
+ delete cadence.times;
330
+ }
331
+ if (cadence.mode !== 'sampled' && !Object.hasOwn(authoredCadence ?? {}, 'jitterRatio')) {
332
+ delete cadence.jitterRatio;
333
+ }
334
+ }
283
335
  payload.cadence = cadence;
336
+ if (payload.expectedVersion === undefined && current?.version !== undefined) {
337
+ payload.expectedVersion = current.version;
338
+ }
284
339
  }
285
340
  const concurrencyPatch = (0, commitments_1.commitmentConcurrencyEnvelopePatch)({
286
341
  rawValue: flags['max-concurrent-runs'],
@@ -67,6 +67,7 @@ class DedicatedMachinesShow extends dedicated_lease_command_1.DedicatedLeaseComm
67
67
  }));
68
68
  this.log(JSON.stringify({
69
69
  ...response,
70
+ readinessScope: 'runtime-dispatch',
70
71
  harnesses: engines,
71
72
  agentBrowser,
72
73
  ...(latestDaemonRelease ? { latestDaemonRelease } : {}),
@@ -45,9 +45,22 @@ class MachinesShow extends base_command_1.BaseCommand {
45
45
  if (!machine) {
46
46
  this.error('Machine not found.', { exit: 1 });
47
47
  }
48
+ const harnesses = machine.harnesses ?? [];
49
+ const shown = flags.json || flags.all ? harnesses : harnesses.filter((h) => !h.superseded);
50
+ const rowReadiness = await (0, cli_installers_1.readinessForRows)(shown, this.resolvedCredential);
51
+ const readinessFor = rowReadiness.lookup;
48
52
  if (flags.json) {
49
53
  this.log(JSON.stringify({
50
54
  ...machine,
55
+ harnesses: harnesses.map((h) => ({
56
+ ...h,
57
+ authStatusScope: 'daemon-to-skrr',
58
+ readiness: readinessFor(h) ?? null,
59
+ })),
60
+ readinessObservation: {
61
+ asked: rowReadiness.asked,
62
+ answered: rowReadiness.answered,
63
+ },
51
64
  url: this.cliConfig?.baseURL
52
65
  ? (0, web_url_1.webUrl)(this.cliConfig.baseURL, { kind: 'machine', machineId: machine.id })
53
66
  : null,
@@ -86,7 +99,6 @@ class MachinesShow extends base_command_1.BaseCommand {
86
99
  if (machine.preferences?.tags?.length) {
87
100
  this.log(` tags ${machine.preferences.tags.join(', ')}`);
88
101
  }
89
- const harnesses = machine.harnesses ?? [];
90
102
  const live = (0, machines_1.liveHarnessCount)(machine);
91
103
  const superseded = harnesses.length - live;
92
104
  // Superseded registrations are history, not capabilities, and they are not
@@ -95,7 +107,6 @@ class MachinesShow extends base_command_1.BaseCommand {
95
107
  // printed, they were 35 of a machine's 42 rows, back two months, under a
96
108
  // header whose count read like a summary of rows it then printed anyway
97
109
  // (OSK-9389). `--all` shows them, and `--json` always carries every row.
98
- const shown = flags.all ? harnesses : harnesses.filter((h) => !h.superseded);
99
110
  // The daemon's own standing with skrr is ONE fact about the machine, not a
100
111
  // per-provider one: it is written across every row of a daemon at once. It
101
112
  // sat in a per-row column and answered `ok` for a Devin its CLI called
@@ -115,8 +126,6 @@ class MachinesShow extends base_command_1.BaseCommand {
115
126
  .filter((h) => h.status === 'online' && !h.superseded && h.daemonId)
116
127
  .map((h) => h.daemonId)),
117
128
  ];
118
- const rowReadiness = await (0, cli_installers_1.readinessForRows)(shown, this.resolvedCredential);
119
- const readinessFor = rowReadiness.lookup;
120
129
  const readiness = rowReadiness.answered > 0 ? rowReadiness : null;
121
130
  this.log('');
122
131
  this.log(`Harnesses (${machine.onlineHarnessCount}/${live} online` +
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class MonitorsCreate extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class MonitorsCreate extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,10 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
6
  const prompt_1 = require("../../../lib/prompt");
7
- class MonitorsCreate extends base_command_1.BaseCommand {
7
+ class MonitorsCreate extends signal_command_1.SignalCommand {
8
8
  static description = 'Validate, then create, a Signal Monitor (a repeated monitorId answers 409: use revise)';
9
9
  static flags = {
10
10
  json: core_1.Flags.boolean({ description: 'Output as JSON' }),
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class MonitorsList extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class MonitorsList extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
- class MonitorsList extends base_command_1.BaseCommand {
6
+ class MonitorsList extends signal_command_1.SignalCommand {
7
7
  static description = 'List Signal Monitors in the current workspace';
8
8
  static flags = { json: core_1.Flags.boolean({ description: 'Output as JSON' }) };
9
9
  async run() {
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class MonitorsPause extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class MonitorsPause extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
- class MonitorsPause extends base_command_1.BaseCommand {
6
+ class MonitorsPause extends signal_command_1.SignalCommand {
7
7
  static description = 'Pause a Signal Monitor';
8
8
  static flags = { json: core_1.Flags.boolean({ description: 'Output as JSON' }) };
9
9
  static args = { id: core_1.Args.string({ required: true, ignoreStdin: true }) };
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class MonitorsResume extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class MonitorsResume extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
- class MonitorsResume extends base_command_1.BaseCommand {
6
+ class MonitorsResume extends signal_command_1.SignalCommand {
7
7
  static description = 'Resume a paused Signal Monitor';
8
8
  static flags = { json: core_1.Flags.boolean({ description: 'Output as JSON' }) };
9
9
  static args = { id: core_1.Args.string({ required: true, ignoreStdin: true }) };
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class MonitorsRevise extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class MonitorsRevise extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,10 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
6
  const prompt_1 = require("../../../lib/prompt");
7
- class MonitorsRevise extends base_command_1.BaseCommand {
7
+ class MonitorsRevise extends signal_command_1.SignalCommand {
8
8
  static description = 'Create an immutable revision of a Signal Monitor';
9
9
  static flags = {
10
10
  json: core_1.Flags.boolean({ description: 'Output as JSON' }),
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class MonitorsShow extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class MonitorsShow extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
- class MonitorsShow extends base_command_1.BaseCommand {
6
+ class MonitorsShow extends signal_command_1.SignalCommand {
7
7
  static description = 'Show one Signal Monitor';
8
8
  static flags = { json: core_1.Flags.boolean({ description: 'Output as JSON' }) };
9
9
  static args = { id: core_1.Args.string({ required: true, ignoreStdin: true }) };
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class MonitorsTest extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class MonitorsTest extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,10 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
6
  const prompt_1 = require("../../../lib/prompt");
7
- class MonitorsTest extends base_command_1.BaseCommand {
7
+ class MonitorsTest extends signal_command_1.SignalCommand {
8
8
  static description = 'Simulate one CloudEvent against a Monitor; records no receipt, transition, wake or run';
9
9
  static flags = {
10
10
  json: core_1.Flags.boolean({ description: 'Output as JSON' }),
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class MonitorsTransitions extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class MonitorsTransitions extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
- class MonitorsTransitions extends base_command_1.BaseCommand {
6
+ class MonitorsTransitions extends signal_command_1.SignalCommand {
7
7
  static description = 'List the recorded state transitions of a Signal Monitor';
8
8
  static flags = { json: core_1.Flags.boolean({ description: 'Output as JSON' }) };
9
9
  static args = { id: core_1.Args.string({ required: true, ignoreStdin: true }) };
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class MonitorsValidate extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class MonitorsValidate extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,10 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
6
  const prompt_1 = require("../../../lib/prompt");
7
- class MonitorsValidate extends base_command_1.BaseCommand {
7
+ class MonitorsValidate extends signal_command_1.SignalCommand {
8
8
  static description = 'Compile-only check of a Monitor definition; nothing is persisted';
9
9
  static flags = {
10
10
  json: core_1.Flags.boolean({ description: 'Output as JSON' }),
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class SchemasList extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class SchemasList extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
- class SchemasList extends base_command_1.BaseCommand {
6
+ class SchemasList extends signal_command_1.SignalCommand {
7
7
  static description = 'List Signal schemas (read-only)';
8
8
  static flags = { json: core_1.Flags.boolean({ description: 'Output as JSON' }) };
9
9
  async run() {
@@ -1,5 +1,5 @@
1
- import { BaseCommand } from '../../../base-command';
2
- export default class SchemasShow extends BaseCommand {
1
+ import { SignalCommand } from '../../../signal-command';
2
+ export default class SchemasShow extends SignalCommand {
3
3
  static description: string;
4
4
  static flags: {
5
5
  json: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
@@ -1,9 +1,9 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const core_1 = require("@oclif/core");
4
- const base_command_1 = require("../../../base-command");
4
+ const signal_command_1 = require("../../../signal-command");
5
5
  const signals_1 = require("../../../lib/signals");
6
- class SchemasShow extends base_command_1.BaseCommand {
6
+ class SchemasShow extends signal_command_1.SignalCommand {
7
7
  static description = 'Show one Signal schema (read-only)';
8
8
  static flags = { json: core_1.Flags.boolean({ description: 'Output as JSON' }) };
9
9
  static args = { id: core_1.Args.string({ required: true, ignoreStdin: true }) };