@sensigo/realm-cli 0.39.0 → 0.41.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/agent/drive-failure.d.ts +62 -0
- package/dist/agent/drive-failure.d.ts.map +1 -0
- package/dist/agent/drive-failure.js +241 -0
- package/dist/agent/drive-failure.js.map +1 -0
- package/dist/agent/providers/agent-utils.d.ts +156 -0
- package/dist/agent/providers/agent-utils.d.ts.map +1 -1
- package/dist/agent/providers/agent-utils.js +423 -1
- package/dist/agent/providers/agent-utils.js.map +1 -1
- package/dist/agent/providers/anthropic-provider.d.ts +51 -1
- package/dist/agent/providers/anthropic-provider.d.ts.map +1 -1
- package/dist/agent/providers/anthropic-provider.js +109 -30
- package/dist/agent/providers/anthropic-provider.js.map +1 -1
- package/dist/agent/providers/llm-provider.d.ts +13 -1
- package/dist/agent/providers/llm-provider.d.ts.map +1 -1
- package/dist/agent/providers/llm-provider.js +8 -4
- package/dist/agent/providers/llm-provider.js.map +1 -1
- package/dist/agent/providers/openai-provider.d.ts +6 -1
- package/dist/agent/providers/openai-provider.d.ts.map +1 -1
- package/dist/agent/providers/openai-provider.js +75 -20
- package/dist/agent/providers/openai-provider.js.map +1 -1
- package/dist/agent/providers/openai-reasoning-provider.d.ts +4 -1
- package/dist/agent/providers/openai-reasoning-provider.d.ts.map +1 -1
- package/dist/agent/providers/openai-reasoning-provider.js +21 -6
- package/dist/agent/providers/openai-reasoning-provider.js.map +1 -1
- package/dist/agent/run-agent.d.ts +9 -0
- package/dist/agent/run-agent.d.ts.map +1 -1
- package/dist/agent/run-agent.js +775 -680
- package/dist/agent/run-agent.js.map +1 -1
- package/dist/agent/run-attach.d.ts.map +1 -1
- package/dist/agent/run-attach.js +26 -2
- package/dist/agent/run-attach.js.map +1 -1
- package/dist/agent/test-support/anthropic-stub.d.ts +45 -0
- package/dist/agent/test-support/anthropic-stub.d.ts.map +1 -0
- package/dist/agent/test-support/anthropic-stub.js +146 -0
- package/dist/agent/test-support/anthropic-stub.js.map +1 -0
- package/dist/agent/test-support/composed-journey.d.ts +40 -0
- package/dist/agent/test-support/composed-journey.d.ts.map +1 -0
- package/dist/agent/test-support/composed-journey.js +104 -0
- package/dist/agent/test-support/composed-journey.js.map +1 -0
- package/dist/agent/test-support/mcp-server-entry.d.ts +20 -0
- package/dist/agent/test-support/mcp-server-entry.d.ts.map +1 -0
- package/dist/agent/test-support/mcp-server-entry.js +39 -0
- package/dist/agent/test-support/mcp-server-entry.js.map +1 -0
- package/dist/agent/test-support/openai-stub.d.ts +47 -0
- package/dist/agent/test-support/openai-stub.d.ts.map +1 -0
- package/dist/agent/test-support/openai-stub.js +115 -0
- package/dist/agent/test-support/openai-stub.js.map +1 -0
- package/dist/commands/agent.d.ts +6 -0
- package/dist/commands/agent.d.ts.map +1 -1
- package/dist/commands/agent.js +44 -3
- package/dist/commands/agent.js.map +1 -1
- package/dist/commands/drain.d.ts.map +1 -1
- package/dist/commands/drain.js +37 -3
- package/dist/commands/drain.js.map +1 -1
- package/dist/commands/gc.d.ts.map +1 -1
- package/dist/commands/gc.js.map +1 -1
- package/dist/commands/inspect.d.ts.map +1 -1
- package/dist/commands/inspect.js +61 -2
- package/dist/commands/inspect.js.map +1 -1
- package/dist/commands/list.d.ts.map +1 -1
- package/dist/commands/list.js +86 -0
- package/dist/commands/list.js.map +1 -1
- package/dist/commands/listen.d.ts +13 -0
- package/dist/commands/listen.d.ts.map +1 -1
- package/dist/commands/listen.js +36 -4
- package/dist/commands/listen.js.map +1 -1
- package/dist/commands/purge.d.ts +22 -1
- package/dist/commands/purge.d.ts.map +1 -1
- package/dist/commands/purge.js +70 -42
- package/dist/commands/purge.js.map +1 -1
- package/dist/commands/register.d.ts +25 -0
- package/dist/commands/register.d.ts.map +1 -1
- package/dist/commands/register.js +91 -21
- package/dist/commands/register.js.map +1 -1
- package/dist/commands/respond.d.ts.map +1 -1
- package/dist/commands/respond.js +23 -1
- package/dist/commands/respond.js.map +1 -1
- package/dist/commands/run.d.ts +34 -0
- package/dist/commands/run.d.ts.map +1 -1
- package/dist/commands/run.js +225 -11
- package/dist/commands/run.js.map +1 -1
- package/dist/commands/test.d.ts.map +1 -1
- package/dist/commands/test.js +48 -8
- package/dist/commands/test.js.map +1 -1
- package/dist/commands/validate.d.ts +19 -0
- package/dist/commands/validate.d.ts.map +1 -1
- package/dist/commands/validate.js +358 -84
- package/dist/commands/validate.js.map +1 -1
- package/dist/commands/watch.d.ts +30 -0
- package/dist/commands/watch.d.ts.map +1 -1
- package/dist/commands/watch.js +159 -23
- package/dist/commands/watch.js.map +1 -1
- package/dist/commands/workflow-list.d.ts +16 -0
- package/dist/commands/workflow-list.d.ts.map +1 -0
- package/dist/commands/workflow-list.js +96 -0
- package/dist/commands/workflow-list.js.map +1 -0
- package/dist/commands-registry.d.ts.map +1 -1
- package/dist/commands-registry.js +2 -0
- package/dist/commands-registry.js.map +1 -1
- package/dist/extensions/load-project-extensions.d.ts.map +1 -1
- package/dist/extensions/load-project-extensions.js +9 -3
- package/dist/extensions/load-project-extensions.js.map +1 -1
- package/dist/index.js +22 -1
- package/dist/index.js.map +1 -1
- package/dist/lib/loader-warnings.d.ts +45 -3
- package/dist/lib/loader-warnings.d.ts.map +1 -1
- package/dist/lib/loader-warnings.js +106 -5
- package/dist/lib/loader-warnings.js.map +1 -1
- package/package.json +5 -4
|
@@ -9,9 +9,9 @@ import { Command } from 'commander';
|
|
|
9
9
|
import { dirname, join, resolve } from 'node:path';
|
|
10
10
|
import { readFileSync } from 'node:fs';
|
|
11
11
|
import { load } from 'js-yaml';
|
|
12
|
-
import { loadWorkflowFromStringWithDiagnostics, loadWorkflowFromFileWithDiagnostics, findTrustRoot, WorkflowError, shouldEnforceTimeout, DEFAULT_EXECUTION_TIMEOUT_SECONDS, resolveSeverity, assessStructuredOutputEligibility, renderIneligibleMessage, } from '@sensigo/realm';
|
|
12
|
+
import { loadWorkflowFromStringWithDiagnostics, loadWorkflowFromFileWithDiagnostics, findTrustRoot, WorkflowError, shouldEnforceTimeout, DEFAULT_EXECUTION_TIMEOUT_SECONDS, resolveSeverity, renderLoaderWarning, assessStructuredOutputEligibility, renderIneligibleMessage, JsonWorkflowStore, RUNTIME_ONLY_WORKFLOW_KEYS, VERSION, } from '@sensigo/realm';
|
|
13
13
|
import { loadProjectExtensions, checkForOrphanedManifests, } from '../extensions/load-project-extensions.js';
|
|
14
|
-
import { printLoaderWarnings, rejectOnErrorSeverity, failsStrict } from '../lib/loader-warnings.js';
|
|
14
|
+
import { renderLoadFailure, renderEscalationLine, printLoaderWarnings, rejectOnErrorSeverity, failsStrict, wrapSentinelWarnings, } from '../lib/loader-warnings.js';
|
|
15
15
|
/**
|
|
16
16
|
* Advisory (issue A3, never rejects): an auto step declaring `retry:` but no `timeout_seconds`
|
|
17
17
|
* has EVERY attempt bounded by the generous DEFAULT_EXECUTION_TIMEOUT_SECONDS default — a hung
|
|
@@ -27,7 +27,8 @@ import { printLoaderWarnings, rejectOnErrorSeverity, failsStrict } from '../lib/
|
|
|
27
27
|
* fires). The message is worded to cover both axes without requiring the reader to already know
|
|
28
28
|
* about the cap.
|
|
29
29
|
*/
|
|
30
|
-
|
|
30
|
+
/** @internal Exported for testing only. */
|
|
31
|
+
export function findRetryWithoutExplicitTimeout(definition) {
|
|
31
32
|
const warnings = [];
|
|
32
33
|
for (const [stepName, step] of Object.entries(definition.steps)) {
|
|
33
34
|
if (shouldEnforceTimeout(step) &&
|
|
@@ -38,7 +39,7 @@ function findRetryWithoutExplicitTimeout(definition) {
|
|
|
38
39
|
severity: resolveSeverity('RETRY_NO_TIMEOUT'),
|
|
39
40
|
scope: 'step',
|
|
40
41
|
step: stepName,
|
|
41
|
-
message:
|
|
42
|
+
message: `Step '${stepName}': declares 'retry' but no 'timeout_seconds' — each attempt is ` +
|
|
42
43
|
`bounded by the default execution timeout (${DEFAULT_EXECUTION_TIMEOUT_SECONDS}s), and ` +
|
|
43
44
|
`(absent an explicit 'retry.total_timeout_seconds') the step's overall retry budget ` +
|
|
44
45
|
`defaults to that same per-attempt bound compounded across every attempt plus backoffs. ` +
|
|
@@ -49,15 +50,6 @@ function findRetryWithoutExplicitTimeout(definition) {
|
|
|
49
50
|
}
|
|
50
51
|
return warnings;
|
|
51
52
|
}
|
|
52
|
-
/** Wraps loadProjectExtensions' sentinel-credential warnings as LoaderWarning (issue #169). */
|
|
53
|
-
function wrapSentinelWarnings(sentinelWarnings) {
|
|
54
|
-
return (sentinelWarnings ?? []).map((message) => ({
|
|
55
|
-
code: 'EXTENSION_SENTINEL',
|
|
56
|
-
severity: resolveSeverity('EXTENSION_SENTINEL'),
|
|
57
|
-
scope: 'workflow',
|
|
58
|
-
message: `⚠ ${message}`,
|
|
59
|
-
}));
|
|
60
|
-
}
|
|
61
53
|
/**
|
|
62
54
|
* The single success-path printer BOTH validation branches (extension-free and file-based)
|
|
63
55
|
* share: prints every accumulated warning, then the summary line. Under `--strict`, a non-empty
|
|
@@ -67,9 +59,10 @@ function wrapSentinelWarnings(sentinelWarnings) {
|
|
|
67
59
|
*/
|
|
68
60
|
function printValidationOutcome(definition, warnings, strict) {
|
|
69
61
|
printLoaderWarnings(warnings);
|
|
70
|
-
const
|
|
62
|
+
const stepCount = Object.keys(definition.steps).length;
|
|
63
|
+
const base = `Valid: ${definition.id} v${definition.version} (${stepCount} ${stepCount === 1 ? 'step' : 'steps'})`;
|
|
71
64
|
if (strict && failsStrict(warnings)) {
|
|
72
|
-
console.log(`${base} — ${warnings.length} warning
|
|
65
|
+
console.log(`${base} — ${warnings.length} ${warnings.length === 1 ? 'warning' : 'warnings'}; failing due to --strict`);
|
|
73
66
|
return true;
|
|
74
67
|
}
|
|
75
68
|
console.log(base);
|
|
@@ -90,16 +83,34 @@ function findReasoningLikeTopLevelProperty(schema) {
|
|
|
90
83
|
return Object.keys(properties).find((name) => REASONING_LIKE_PROPERTY.test(name));
|
|
91
84
|
}
|
|
92
85
|
/**
|
|
93
|
-
* issue #236 (Deliverable 7) — the adoption
|
|
94
|
-
*
|
|
95
|
-
*
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
*
|
|
99
|
-
*
|
|
100
|
-
*
|
|
86
|
+
* issue #236 (Deliverable 7) — the adoption nudge, on validate's own INFO channel. Structurally
|
|
87
|
+
* NOT a LoaderWarning (plain `console.log`, never routed through `printLoaderWarnings`/the
|
|
88
|
+
* warnings accumulator/`--strict` — that stays a hard zero-diff rail on `loader-warnings.ts`,
|
|
89
|
+
* since ANY new WarningCode there would auto-fail `validate --strict`).
|
|
90
|
+
*
|
|
91
|
+
* issue #422 reshaped the FORM, not the purpose. It used to print one line per caveat per step,
|
|
92
|
+
* which on a green validate of a file that never mentions structured_output meant fourteen lines
|
|
93
|
+
* (examples/06) or nine (examples/02) of advice nobody asked for. The field's converged answer for
|
|
94
|
+
* adoption discovery on a clean run is one aggregate line plus a named detail command plus a
|
|
95
|
+
* durable silencer — npm fund, cargo's future-incompat report, npm audit; no surveyed tool prints
|
|
96
|
+
* per-item adoption advice on a green run, and npm's RFC 0017 explicitly rejected demoting the
|
|
97
|
+
* class behind a flag instead. So: a summary by default, the full per-step detail behind
|
|
98
|
+
* `--explain`, and `REALM_NO_NUDGE=1` to silence.
|
|
99
|
+
*
|
|
100
|
+
* THE POLICY THAT DECIDES WHICH STEPS ARE LOUD (rustc's attach-to-the-diagnostic rule, made
|
|
101
|
+
* written policy here): advice about config the author DECLARED is a diagnostic and always prints;
|
|
102
|
+
* advice about config they COULD adopt is one line. So an opted-in step's caveats print
|
|
103
|
+
* unconditionally — `--explain` does not gate them and `REALM_NO_NUDGE` does not silence them —
|
|
104
|
+
* while a not-opted-in step's detail is exactly what moves behind the flag.
|
|
105
|
+
*
|
|
106
|
+
* Never printed for an ineligible-and-opted-in step: the LOADER already rejected that combination
|
|
107
|
+
* at load time, so this function structurally never observes it.
|
|
101
108
|
*/
|
|
102
|
-
function printStructuredOutputNudge(definition) {
|
|
109
|
+
function printStructuredOutputNudge(definition, opts) {
|
|
110
|
+
// Not-opted-in steps whose detail either renders (--explain) or feeds the summary counts.
|
|
111
|
+
const ready = []; // eligible | eligible_with_caveats
|
|
112
|
+
const withCaveats = []; // the subset of `ready` carrying >=1 caveat
|
|
113
|
+
const oneAway = []; // ineligible
|
|
103
114
|
for (const [stepName, step] of Object.entries(definition.steps)) {
|
|
104
115
|
if (step.execution !== 'agent')
|
|
105
116
|
continue;
|
|
@@ -113,45 +124,141 @@ function printStructuredOutputNudge(definition) {
|
|
|
113
124
|
...(step.tools !== undefined ? { tools: step.tools } : {}),
|
|
114
125
|
});
|
|
115
126
|
const reasoningProp = findReasoningLikeTopLevelProperty(effectiveSchema);
|
|
127
|
+
// An opted-in step's advice is about DECLARED config: a diagnostic, printed here and now
|
|
128
|
+
// whatever the flags say. It is also EXCLUDED from the summary's census entirely — its
|
|
129
|
+
// surface is this branch, never the aggregate line.
|
|
130
|
+
if (optedIn) {
|
|
131
|
+
if (verdict.verdict !== 'eligible_with_caveats')
|
|
132
|
+
continue;
|
|
133
|
+
for (const caveat of verdict.caveats) {
|
|
134
|
+
console.log(`ℹ Step '${stepName}': structured_output caveat — ${caveat.remediation}`);
|
|
135
|
+
}
|
|
136
|
+
printReasoningAnnotation(stepName, reasoningProp);
|
|
137
|
+
continue;
|
|
138
|
+
}
|
|
116
139
|
if (verdict.verdict === 'ineligible') {
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
140
|
+
oneAway.push(stepName);
|
|
141
|
+
if (opts.explain) {
|
|
142
|
+
console.log(`ℹ Step '${stepName}': structured_output: strict — one line short: ` +
|
|
143
|
+
`${renderIneligibleMessage(verdict.reasons)}`);
|
|
144
|
+
}
|
|
121
145
|
continue;
|
|
122
146
|
}
|
|
147
|
+
ready.push(stepName);
|
|
123
148
|
if (verdict.verdict === 'eligible_with_caveats') {
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
`default thinking there is no regression; on non-thinking configurations prefer ` +
|
|
134
|
-
`'required' + first property order — see docs/reference/yaml-schema.md).`);
|
|
149
|
+
// `eligible_with_caveats` with zero caveats is unconstructible — the assessor mints that
|
|
150
|
+
// verdict only when it has at least one — so the verdict IS the caveated subset.
|
|
151
|
+
withCaveats.push(stepName);
|
|
152
|
+
if (opts.explain) {
|
|
153
|
+
for (const caveat of verdict.caveats) {
|
|
154
|
+
console.log(`ℹ Step '${stepName}': eligible for structured_output: strict, with caveat — ` +
|
|
155
|
+
`${caveat.remediation}`);
|
|
156
|
+
}
|
|
157
|
+
printReasoningAnnotation(stepName, reasoningProp);
|
|
135
158
|
}
|
|
136
159
|
continue;
|
|
137
160
|
}
|
|
138
161
|
// eligible, zero caveats — NEVER printed bare (census: this is a rare, fully-required
|
|
139
162
|
// schema). Always paired with the concrete next step.
|
|
140
|
-
if (
|
|
163
|
+
if (opts.explain) {
|
|
141
164
|
console.log(`ℹ Step '${stepName}': eligible for structured_output: strict — add ` +
|
|
142
165
|
`'structured_output: strict' to opt in.`);
|
|
143
166
|
}
|
|
144
167
|
}
|
|
168
|
+
// `--explain` REPLACES the summary with the detail above — an explicit ask for detail should
|
|
169
|
+
// not also get the pointer telling you how to ask for it.
|
|
170
|
+
if (opts.explain)
|
|
171
|
+
return;
|
|
172
|
+
// Read at call time, never captured at module scope (the #285 class). An explicit `--explain`
|
|
173
|
+
// beats a standing preference, which is why this check sits below the return above.
|
|
174
|
+
if (process.env['REALM_NO_NUDGE'] === '1')
|
|
175
|
+
return;
|
|
176
|
+
const line = renderNudgeSummary(ready.length, withCaveats.length, oneAway.length);
|
|
177
|
+
if (line !== undefined)
|
|
178
|
+
console.log(line);
|
|
179
|
+
}
|
|
180
|
+
/** The reasoning-position annotation, printed beside a caveat list wherever one renders. */
|
|
181
|
+
function printReasoningAnnotation(stepName, reasoningProp) {
|
|
182
|
+
if (reasoningProp === undefined)
|
|
183
|
+
return;
|
|
184
|
+
console.log(`ℹ Step '${stepName}': the optional '${reasoningProp}' property looks like a ` +
|
|
185
|
+
`reasoning field — see the optional_emission caveat above (position matters: with ` +
|
|
186
|
+
`default thinking there is no regression; on non-thinking configurations prefer ` +
|
|
187
|
+
`'required' + first property order — see docs/reference/yaml-schema.md).`);
|
|
188
|
+
}
|
|
189
|
+
/**
|
|
190
|
+
* The one graded summary line (issue #422), or `undefined` when there is nothing to say.
|
|
191
|
+
*
|
|
192
|
+
* The tail teaches BOTH escape routes in the one line it gets — the detail command (npm's
|
|
193
|
+
* "Run `npm fund` for details", cargo's named report command) fused with the silencer (git's
|
|
194
|
+
* squelch-teaching advice hints). A reader who wants more and a reader who wants less are both
|
|
195
|
+
* served without a second line.
|
|
196
|
+
*
|
|
197
|
+
* Each clause pluralizes on its OWN count, and a zero-valued clause is omitted rather than
|
|
198
|
+
* rendered as a zero. The caveats parenthetical and the one-change-away clause are independent:
|
|
199
|
+
* gating the second on the first would silently drop it for a file whose ready steps are all
|
|
200
|
+
* caveat-free.
|
|
201
|
+
*/
|
|
202
|
+
function renderNudgeSummary(ready, withCaveats, oneAway) {
|
|
203
|
+
if (ready === 0 && oneAway === 0)
|
|
204
|
+
return undefined;
|
|
205
|
+
const steps = (n) => (n === 1 ? 'step' : 'steps');
|
|
206
|
+
const tail = ` — run 'realm workflow validate --explain' for detail (REALM_NO_NUDGE=1 to silence).`;
|
|
207
|
+
if (ready === 0) {
|
|
208
|
+
return `ℹ ${oneAway} ${steps(oneAway)} one change away from structured_output: strict${tail}`;
|
|
209
|
+
}
|
|
210
|
+
let line = `ℹ ${ready} ${steps(ready)} ready for structured_output: strict`;
|
|
211
|
+
if (withCaveats > 0)
|
|
212
|
+
line += ` (${withCaveats} with caveats)`;
|
|
213
|
+
if (oneAway > 0)
|
|
214
|
+
line += `, ${oneAway} ${steps(oneAway)} one change away`;
|
|
215
|
+
return line + tail;
|
|
145
216
|
}
|
|
146
217
|
/**
|
|
147
|
-
* The
|
|
148
|
-
*
|
|
218
|
+
* The ONE place a load failure is rendered on this command (issue #445).
|
|
219
|
+
*
|
|
220
|
+
* WorkflowError means the workflow is invalid: print the warnings it carried (#424), render the
|
|
221
|
+
* message, exit 1. Anything else is an internal bug and is RETHROWN — the #123 doctrine, pinned
|
|
222
|
+
* by validate-internal-error.test.ts's "genuine-bug-still-loud" cell: a real crash must never be
|
|
223
|
+
* relabelled `Invalid:`, because that tells an author their file is wrong when realm is.
|
|
224
|
+
*
|
|
225
|
+
* The extensions arm used to render ANY error as `Invalid:`, so it violated that doctrine in two
|
|
226
|
+
* directions at once — an internal bug was swallowed, and a user's broken extension module was
|
|
227
|
+
* blamed on their workflow. Both arms route here now, and extension loading has its own catch
|
|
228
|
+
* with its own sentence, so the two populations stay separate.
|
|
229
|
+
*
|
|
230
|
+
* SCOPE, deliberate: watch/register/test/agent keep their own catches (#425's recorded
|
|
231
|
+
* exclusion). If a second surface ever adopts this, move it to lib/loader-warnings.ts — one
|
|
232
|
+
* caller does not earn a shared home.
|
|
233
|
+
*/
|
|
234
|
+
function exitOnLoadFailure(err) {
|
|
235
|
+
if (err instanceof WorkflowError) {
|
|
236
|
+
if (err.warnings !== undefined)
|
|
237
|
+
printLoaderWarnings(err.warnings);
|
|
238
|
+
console.error(renderLoadFailure(err));
|
|
239
|
+
process.exit(1);
|
|
240
|
+
}
|
|
241
|
+
throw err;
|
|
242
|
+
}
|
|
243
|
+
/**
|
|
244
|
+
* The issue #170 boundary-reject, LIVE since the flip: a workflow carrying an unrecognised
|
|
245
|
+
* workflow-level or step-level key is refused here, before `--strict` is even consulted (which is
|
|
246
|
+
* why `--strict` and the default now agree on this class). run/agent/listen are unaffected — they
|
|
247
|
+
* load leniently, so a deployed workflow with an unknown key keeps running.
|
|
149
248
|
*/
|
|
150
249
|
function rejectIfPolicyEscalates(warnings) {
|
|
151
250
|
if (!rejectOnErrorSeverity(warnings))
|
|
152
251
|
return false;
|
|
153
252
|
printLoaderWarnings(warnings);
|
|
154
|
-
|
|
253
|
+
// issue #425: name WHICH warnings escalated. "at least one is escalated" left an author with
|
|
254
|
+
// three warnings above and no way to tell which of them was the refusal — the counts are the
|
|
255
|
+
// aggregate this line adds, so it is the line that has to say.
|
|
256
|
+
//
|
|
257
|
+
// register and watch print the same line since issue #451 (watch adds its timestamp and a
|
|
258
|
+
// `— refusing to register.` tail, because it does not exit); it lives in lib/loader-warnings.ts
|
|
259
|
+
// for that reason. On all three surfaces printLoaderWarnings' `— REFUSED below` substitution
|
|
260
|
+
// already marks each refused warning one line above.
|
|
261
|
+
console.error(renderEscalationLine(warnings));
|
|
155
262
|
return true;
|
|
156
263
|
}
|
|
157
264
|
/** Pre-scan: does the YAML carry a top-level `extensions` key? (Parse errors → false; the
|
|
@@ -168,16 +275,121 @@ function hasTopLevelExtensions(content) {
|
|
|
168
275
|
return false;
|
|
169
276
|
}
|
|
170
277
|
}
|
|
278
|
+
/**
|
|
279
|
+
* `validate --registered <id>` — audit the STORED copy of a workflow (issue #427).
|
|
280
|
+
*
|
|
281
|
+
* The mechanism is kubectl's server-side dry-run shape: strip the keys the loader stamps, feed
|
|
282
|
+
* the rest back through the REAL loader, report what it says. Zero rules are duplicated here, so
|
|
283
|
+
* this surface cannot drift from what `register` would accept tomorrow.
|
|
284
|
+
*
|
|
285
|
+
* What it audits is the INSTALLED loader — the same limitation kubectl documents. The
|
|
286
|
+
* pre-upgrade journey is therefore: upgrade the CLI first, THEN audit. That is safe precisely
|
|
287
|
+
* because grandfathering holds for the copies it applies to: a CURRENT-SCHEMA registered copy
|
|
288
|
+
* keeps running under the rules it was registered with, so upgrading the CLI to look does not
|
|
289
|
+
* change what your runs do. A legacy (schema_version-less or older) copy is a different case
|
|
290
|
+
* entirely — see the legacy arm below: it is not grandfathered, it is already unreachable.
|
|
291
|
+
*/
|
|
292
|
+
async function validateRegistered(id, strict) {
|
|
293
|
+
const store = new JsonWorkflowStore();
|
|
294
|
+
let stored;
|
|
295
|
+
try {
|
|
296
|
+
stored = await store.get(id);
|
|
297
|
+
}
|
|
298
|
+
catch (err) {
|
|
299
|
+
if (err instanceof WorkflowError && err.code === 'STATE_WORKFLOW_NOT_FOUND') {
|
|
300
|
+
console.error(`Error: ${err.message}`);
|
|
301
|
+
console.error('Registered workflows: realm workflow list');
|
|
302
|
+
process.exit(1);
|
|
303
|
+
}
|
|
304
|
+
if (err instanceof WorkflowError && err.code === 'STATE_LEGACY_FORMAT') {
|
|
305
|
+
// ONE clause only. There is no schema_version to name — nothing parsed far enough to read
|
|
306
|
+
// one — and the grandfathering sentence would be FALSE for this cohort: every runtime
|
|
307
|
+
// consumer resolves through this same get() gate (start_run, execute_step, append_trace,
|
|
308
|
+
// get_workflow_protocol, submit_human_response, replay), so a legacy entry cannot run at
|
|
309
|
+
// all. It is not grandfathered; it is unreachable.
|
|
310
|
+
console.log(`Auditing the registered copy of '${id}' with realm ${VERSION}'s loader.`);
|
|
311
|
+
// The store's own message carries the remedy; the loader would say `Missing required
|
|
312
|
+
// field: 'steps'` here, which is true of the shape and useless about the cause.
|
|
313
|
+
console.error(renderLoadFailure(err));
|
|
314
|
+
process.exit(1);
|
|
315
|
+
}
|
|
316
|
+
if (!(err instanceof WorkflowError)) {
|
|
317
|
+
// get()'s try wraps ONLY the read — JSON.parse sits outside it, so a corrupt stored file
|
|
318
|
+
// arrives here as a bare SyntaxError with no code (executed).
|
|
319
|
+
console.error(`Error: the registered copy of '${id}' is not parseable JSON: ${err instanceof Error ? err.message : String(err)}`);
|
|
320
|
+
console.error('Registered workflows: realm workflow list');
|
|
321
|
+
process.exit(1);
|
|
322
|
+
}
|
|
323
|
+
throw err; // #123: an unexpected WorkflowError is a bug, and bugs stay loud.
|
|
324
|
+
}
|
|
325
|
+
console.log(`Auditing the registered copy of '${id}' (schema_version ${String(stored.schema_version)}) ` +
|
|
326
|
+
`with realm ${VERSION}'s loader.`);
|
|
327
|
+
console.log('Registered copies stay grandfathered at runtime — this reports what re-registration today would say.');
|
|
328
|
+
const clone = { ...stored };
|
|
329
|
+
for (const key of RUNTIME_ONLY_WORKFLOW_KEYS)
|
|
330
|
+
delete clone[key];
|
|
331
|
+
const declaresProfile = Object.values(stored.steps ?? {}).some((step) => step.agent_profile !== undefined);
|
|
332
|
+
if (clone['extensions'] !== undefined || declaresProfile) {
|
|
333
|
+
console.log('Extensions/profiles declared — module resolution, config_schema checks, and agent-profile ' +
|
|
334
|
+
'file resolution need the source tree and are not audited here; structural rules only.');
|
|
335
|
+
}
|
|
336
|
+
// MUST delete: the from-string loader hard-throws on an `extensions` key (allowExtensions:
|
|
337
|
+
// false) with "Register this workflow from its YAML file" — maximally misleading here, where
|
|
338
|
+
// the workflow IS registered and the operator asked about the stored copy. The honesty line
|
|
339
|
+
// above is what carries the real limitation.
|
|
340
|
+
delete clone['extensions'];
|
|
341
|
+
let definition;
|
|
342
|
+
let loaderWarnings;
|
|
343
|
+
try {
|
|
344
|
+
({ definition, warnings: loaderWarnings } = loadWorkflowFromStringWithDiagnostics(JSON.stringify(clone)));
|
|
345
|
+
}
|
|
346
|
+
catch (err) {
|
|
347
|
+
exitOnLoadFailure(err);
|
|
348
|
+
}
|
|
349
|
+
// The extension-free arm's tail, minus the orphan-manifest check (there is no source tree to
|
|
350
|
+
// have one) and minus the adoption nudge (a stored copy is not where you edit; `--explain` is
|
|
351
|
+
// therefore inert in this mode, deliberately — no machinery for it).
|
|
352
|
+
const accumulated = [...loaderWarnings, ...findRetryWithoutExplicitTimeout(definition)];
|
|
353
|
+
if (rejectIfPolicyEscalates(accumulated)) {
|
|
354
|
+
process.exit(1);
|
|
355
|
+
}
|
|
356
|
+
const strictFailed = printValidationOutcome(definition, accumulated, strict);
|
|
357
|
+
if (strictFailed) {
|
|
358
|
+
process.exit(1);
|
|
359
|
+
}
|
|
360
|
+
}
|
|
171
361
|
export const validateCommand = new Command('validate')
|
|
172
|
-
.argument('
|
|
362
|
+
.argument('[path]', 'Path to workflow directory or workflow.yaml file')
|
|
363
|
+
.option('--registered <id>', 'Audit the STORED copy of a registered workflow instead of a file (issue #427)')
|
|
173
364
|
.option('--extensions-module <path>', "Extensions module that REPLACES the workflow's declared 'extensions' modules (repair/override)")
|
|
174
365
|
.option('--strict', 'Exit non-zero if any loader warning is present (unknown keys, retry-without-timeout, sentinel credentials — issue #169)')
|
|
366
|
+
.option('--explain', 'Print the full per-step structured_output adoption detail instead of the one-line summary the default run prints (issue #422)')
|
|
175
367
|
.description('Validate a workflow YAML file')
|
|
176
368
|
.action(async (inputPath, opts) => {
|
|
369
|
+
const strict = opts.strict === true;
|
|
370
|
+
const explain = opts.explain === true;
|
|
371
|
+
// Exactly-one, checked FIRST and load-bearing: commander parses a `[path]` positional and
|
|
372
|
+
// a `--registered <id>` option happily together and enforces nothing between them
|
|
373
|
+
// (executed — both arrive). The flag is `--registered <id>` rather than an auto-detecting
|
|
374
|
+
// positional deliberately: nothing can reliably tell an id from a path, and guessing wrong
|
|
375
|
+
// means auditing something the operator did not name.
|
|
376
|
+
if (inputPath === undefined && opts.registered === undefined) {
|
|
377
|
+
console.error('Error: provide a workflow path, or --registered <id> to audit a stored definition.');
|
|
378
|
+
process.exit(1);
|
|
379
|
+
return;
|
|
380
|
+
}
|
|
381
|
+
if (inputPath !== undefined && opts.registered !== undefined) {
|
|
382
|
+
console.error('Error: --registered audits the stored copy — it cannot be combined with a path.');
|
|
383
|
+
process.exit(1);
|
|
384
|
+
return;
|
|
385
|
+
}
|
|
386
|
+
if (opts.registered !== undefined) {
|
|
387
|
+
await validateRegistered(opts.registered, strict);
|
|
388
|
+
return;
|
|
389
|
+
}
|
|
177
390
|
const filePath = inputPath.endsWith('.yaml') || inputPath.endsWith('.yml')
|
|
178
391
|
? inputPath
|
|
179
392
|
: join(inputPath, 'workflow.yaml');
|
|
180
|
-
const strict = opts.strict === true;
|
|
181
393
|
let content;
|
|
182
394
|
try {
|
|
183
395
|
content = readFileSync(filePath, 'utf8');
|
|
@@ -194,68 +406,130 @@ export const validateCommand = new Command('validate')
|
|
|
194
406
|
// source_dir/trust_root, so resolve the same trust root the file-based path would
|
|
195
407
|
// (findTrustRoot walks package.json/.git from the workflow dir) and run the guard
|
|
196
408
|
// structural-first — after the workflow parses, before the `Valid:` print. It throws
|
|
197
|
-
// WorkflowError, which
|
|
409
|
+
// WorkflowError, which exitOnLoadFailure renders as `Invalid:` + exit(1) — this arm's
|
|
410
|
+
// guard call is DIRECT, which is why it keeps that sentence while an extensions-declaring
|
|
411
|
+
// load surfaces the same guard as `Error loading extensions:` (issue #445). resolve()
|
|
198
412
|
// before dirname so a relative `workflow.yaml` doesn't collapse the walk to '.'.
|
|
413
|
+
let definition;
|
|
414
|
+
let loaderWarnings;
|
|
415
|
+
try {
|
|
416
|
+
({ definition, warnings: loaderWarnings } =
|
|
417
|
+
loadWorkflowFromStringWithDiagnostics(content));
|
|
418
|
+
}
|
|
419
|
+
catch (err) {
|
|
420
|
+
exitOnLoadFailure(err);
|
|
421
|
+
}
|
|
422
|
+
// Its own try (issue #463): each try owns one failure population — the #445 doctrine. A
|
|
423
|
+
// load failure above has nothing to print but itself; the guard below fails AFTER the
|
|
424
|
+
// workflow parsed, with its warnings in hand.
|
|
199
425
|
try {
|
|
200
|
-
const { definition, warnings: loaderWarnings } = loadWorkflowFromStringWithDiagnostics(content);
|
|
201
426
|
const workflowDir = dirname(resolve(filePath));
|
|
202
427
|
checkForOrphanedManifests(workflowDir, findTrustRoot(workflowDir));
|
|
203
|
-
const accumulated = [...loaderWarnings, ...findRetryWithoutExplicitTimeout(definition)];
|
|
204
|
-
if (rejectIfPolicyEscalates(accumulated)) {
|
|
205
|
-
process.exit(1);
|
|
206
|
-
}
|
|
207
|
-
const strictFailed = printValidationOutcome(definition, accumulated, strict);
|
|
208
|
-
// issue #236: the nudge's own INFO channel — never affects the exit code below.
|
|
209
|
-
printStructuredOutputNudge(definition);
|
|
210
|
-
if (strictFailed) {
|
|
211
|
-
process.exit(1);
|
|
212
|
-
}
|
|
213
428
|
}
|
|
214
429
|
catch (err) {
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
430
|
+
// The workflow's own warnings before the refusal — the same set the success path counts,
|
|
431
|
+
// so nothing the author would otherwise see only on the NEXT run is withheld. Plain
|
|
432
|
+
// render: the escalation gate has not run, so printLoaderWarnings' `— REFUSED below`
|
|
433
|
+
// would name the wrong cause (test.ts's render comment, #450's reasoning). Unconditional:
|
|
434
|
+
// on the #123 non-WorkflowError rethrow population the warnings print before the loud
|
|
435
|
+
// crash — true statements either way. exitOnLoadFailure cannot print them twice: the
|
|
436
|
+
// orphan WorkflowError is minted bare in the CLI (load-project-extensions.ts), and the
|
|
437
|
+
// core `warnings` slot is set only by attachLoaderWarnings inside the core loader, which
|
|
438
|
+
// this throw never transits — which is exactly why this arm swallowed them until now.
|
|
439
|
+
for (const w of [...loaderWarnings, ...findRetryWithoutExplicitTimeout(definition)]) {
|
|
440
|
+
console.warn(renderLoaderWarning(w));
|
|
218
441
|
}
|
|
219
|
-
|
|
442
|
+
exitOnLoadFailure(err);
|
|
443
|
+
}
|
|
444
|
+
// Reporting, deliberately OUTSIDE the try (issue #445): these lines only run once the
|
|
445
|
+
// load succeeded, and their own `process.exit` calls have no business passing through a
|
|
446
|
+
// catch that exists to classify LOAD failures. Production-neutral — the exits still exit.
|
|
447
|
+
const accumulated = [...loaderWarnings, ...findRetryWithoutExplicitTimeout(definition)];
|
|
448
|
+
if (rejectIfPolicyEscalates(accumulated)) {
|
|
449
|
+
process.exit(1);
|
|
450
|
+
}
|
|
451
|
+
const strictFailed = printValidationOutcome(definition, accumulated, strict);
|
|
452
|
+
// issue #236: the nudge's own INFO channel — never affects the exit code below.
|
|
453
|
+
printStructuredOutputNudge(definition, { explain });
|
|
454
|
+
if (strictFailed) {
|
|
455
|
+
process.exit(1);
|
|
220
456
|
}
|
|
221
457
|
return;
|
|
222
458
|
}
|
|
223
459
|
// Extensions declared (or an override supplied): file-based two-pass validation.
|
|
460
|
+
//
|
|
461
|
+
// THREE tries, not one (issue #445). The old single catch spanned five concerns and
|
|
462
|
+
// rendered every one of them `Invalid: …` — including a user's unresolvable extension
|
|
463
|
+
// module, and including internal bugs. Each try now owns one failure population, and the
|
|
464
|
+
// reporting tail sits outside all of them.
|
|
465
|
+
let definition;
|
|
466
|
+
let pass1Warnings;
|
|
224
467
|
try {
|
|
225
468
|
// Pass 1: structural validation + extension resolution metadata (source_dir/trust_root).
|
|
226
469
|
// The universal, registry-independent structural load — its warnings are what we count.
|
|
227
|
-
|
|
228
|
-
|
|
470
|
+
({ definition, warnings: pass1Warnings } = loadWorkflowFromFileWithDiagnostics(filePath));
|
|
471
|
+
}
|
|
472
|
+
catch (err) {
|
|
473
|
+
exitOnLoadFailure(err);
|
|
474
|
+
}
|
|
475
|
+
let registry;
|
|
476
|
+
let manifest;
|
|
477
|
+
let sentinelWarnings;
|
|
478
|
+
try {
|
|
479
|
+
({ registry, manifest, sentinelWarnings } = await loadProjectExtensions(definition, {
|
|
229
480
|
...(opts.extensionsModule !== undefined ? { overrideModule: opts.extensionsModule } : {}),
|
|
230
481
|
secretMode: 'sentinel',
|
|
231
|
-
});
|
|
482
|
+
}));
|
|
483
|
+
}
|
|
484
|
+
catch (err) {
|
|
485
|
+
// issue #445 — a DIFFERENT population, and it gets its own sentence. Everything
|
|
486
|
+
// loadProjectExtensions throws is extension or deployment territory: an unresolvable
|
|
487
|
+
// module path, a failed import, a module whose default export is the wrong shape, a
|
|
488
|
+
// malformed `realm.yaml`, and the #123 orphaned-manifest refusal. None of those makes
|
|
489
|
+
// the WORKFLOW invalid, and calling them `Invalid:` sent an author to the wrong file.
|
|
490
|
+
// The sentence is `realm run`'s, verbatim (run.ts) — the sibling surface renders this
|
|
491
|
+
// identical failure class exactly so.
|
|
492
|
+
//
|
|
493
|
+
// issue #463 — the workflow's own warnings first: pass-1's plus the retry advisory, the
|
|
494
|
+
// same set the success path counts minus the sentinel wraps, which come from the load that
|
|
495
|
+
// just failed — there is nothing to wrap. Plain render (test.ts's render comment, #450's
|
|
496
|
+
// reasoning): the escalation gate has not run, so printLoaderWarnings' `— REFUSED below`
|
|
497
|
+
// would name the wrong cause.
|
|
498
|
+
for (const w of [...pass1Warnings, ...findRetryWithoutExplicitTimeout(definition)]) {
|
|
499
|
+
console.warn(renderLoaderWarning(w));
|
|
500
|
+
}
|
|
501
|
+
console.error(`Error loading extensions: ${err instanceof Error ? err.message : String(err)}`);
|
|
502
|
+
process.exit(1);
|
|
503
|
+
}
|
|
504
|
+
try {
|
|
232
505
|
// Pass 2: step config validated against each resolved adapter's config_schema. Same
|
|
233
506
|
// content as pass 1, registry only adds config_schema checks — its warnings are proven
|
|
234
507
|
// identical to pass 1's, so they are deliberately discarded here (not collected) to avoid
|
|
235
508
|
// double-counting the same unknown key twice.
|
|
236
509
|
loadWorkflowFromFileWithDiagnostics(filePath, registry);
|
|
237
|
-
const accumulated = [
|
|
238
|
-
...pass1Warnings,
|
|
239
|
-
...findRetryWithoutExplicitTimeout(definition),
|
|
240
|
-
...wrapSentinelWarnings(sentinelWarnings),
|
|
241
|
-
];
|
|
242
|
-
if (rejectIfPolicyEscalates(accumulated)) {
|
|
243
|
-
process.exit(1);
|
|
244
|
-
}
|
|
245
|
-
const strictFailed = printValidationOutcome(definition, accumulated, strict);
|
|
246
|
-
// issue #236: the nudge's own INFO channel — never affects the exit code below.
|
|
247
|
-
printStructuredOutputNudge(definition);
|
|
248
|
-
if (manifest.modules.length > 0) {
|
|
249
|
-
console.log(`Extensions: ${manifest.modules.map((m) => m.declared).join(', ')} ` +
|
|
250
|
-
`(adapters: ${manifest.adapters.length}, handlers: ${manifest.handlers.length}, ` +
|
|
251
|
-
`processors: ${manifest.processors.length})`);
|
|
252
|
-
}
|
|
253
|
-
if (strictFailed) {
|
|
254
|
-
process.exit(1);
|
|
255
|
-
}
|
|
256
510
|
}
|
|
257
511
|
catch (err) {
|
|
258
|
-
|
|
512
|
+
exitOnLoadFailure(err);
|
|
513
|
+
}
|
|
514
|
+
const accumulated = [
|
|
515
|
+
...pass1Warnings,
|
|
516
|
+
...findRetryWithoutExplicitTimeout(definition),
|
|
517
|
+
...wrapSentinelWarnings(sentinelWarnings),
|
|
518
|
+
];
|
|
519
|
+
if (rejectIfPolicyEscalates(accumulated)) {
|
|
520
|
+
process.exit(1);
|
|
521
|
+
}
|
|
522
|
+
const strictFailed = printValidationOutcome(definition, accumulated, strict);
|
|
523
|
+
if (manifest.modules.length > 0) {
|
|
524
|
+
console.log(`Extensions: ${manifest.modules.map((m) => m.declared).join(', ')} ` +
|
|
525
|
+
`(adapters: ${manifest.adapters.length}, handlers: ${manifest.handlers.length}, ` +
|
|
526
|
+
`processors: ${manifest.processors.length})`);
|
|
527
|
+
}
|
|
528
|
+
// issue #236: the nudge's own INFO channel — never affects the exit code below.
|
|
529
|
+
// issue #422: genuinely end-of-report, BELOW the Extensions block — the summary is a
|
|
530
|
+
// pointer at what you could do next, not part of what was just validated.
|
|
531
|
+
printStructuredOutputNudge(definition, { explain });
|
|
532
|
+
if (strictFailed) {
|
|
259
533
|
process.exit(1);
|
|
260
534
|
}
|
|
261
535
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validate.js","sourceRoot":"","sources":["../../src/commands/validate.ts"],"names":[],"mappings":"AAAA,iFAAiF;AACjF,EAAE;AACF,yFAAyF;AACzF,qFAAqF;AACrF,uFAAuF;AACvF,wFAAwF;AACxF,4EAA4E;AAC5E,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAC/B,OAAO,EACL,qCAAqC,EACrC,mCAAmC,EACnC,aAAa,EACb,aAAa,EACb,oBAAoB,EACpB,iCAAiC,EACjC,eAAe,EACf,iCAAiC,EACjC,uBAAuB,GAExB,MAAM,gBAAgB,CAAC;AAExB,O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