@miller-tech/uap 1.148.16 → 1.148.19
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/.tsbuildinfo +1 -1
- package/dist/cli/deliver.d.ts.map +1 -1
- package/dist/cli/deliver.js +27 -0
- package/dist/cli/deliver.js.map +1 -1
- package/dist/cli/init.d.ts.map +1 -1
- package/dist/cli/init.js +24 -0
- package/dist/cli/init.js.map +1 -1
- package/dist/delivery/project-preflight.d.ts +38 -0
- package/dist/delivery/project-preflight.d.ts.map +1 -0
- package/dist/delivery/project-preflight.js +79 -0
- package/dist/delivery/project-preflight.js.map +1 -0
- package/dist/delivery/run-exit.d.ts +50 -0
- package/dist/delivery/run-exit.d.ts.map +1 -0
- package/dist/delivery/run-exit.js +105 -0
- package/dist/delivery/run-exit.js.map +1 -0
- package/dist/delivery/run-state.d.ts +10 -0
- package/dist/delivery/run-state.d.ts.map +1 -1
- package/dist/delivery/run-state.js.map +1 -1
- package/dist/delivery/self-gate.d.ts +23 -1
- package/dist/delivery/self-gate.d.ts.map +1 -1
- package/dist/delivery/self-gate.js +43 -3
- package/dist/delivery/self-gate.js.map +1 -1
- package/package.json +1 -1
- package/src/policies/enforcers/__pycache__/_common.cpython-312.pyc +0 -0
- package/tools/agents/scripts/__pycache__/toolcall_path_normalizer.cpython-312.pyc +0 -0
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Project preflight — refuse to start a mission in a project that structurally
|
|
3
|
+
* CANNOT deliver, and self-heal the config posture that must always hold.
|
|
4
|
+
*
|
|
5
|
+
* Why this exists: a fresh scaffold silently reproduced two blockers that had
|
|
6
|
+
* already been diagnosed and hand-fixed once. `uap init` did not `git init`, so
|
|
7
|
+
* the project was not a repo — and deliver's candidate workspace is worktree
|
|
8
|
+
* based, so deliver, epics, orchestration and tasks were ALL dead. Nothing said
|
|
9
|
+
* so; the mission just failed to make progress. A hand-patched project is not a
|
|
10
|
+
* fix, because the next scaffold reset recreates the same hole.
|
|
11
|
+
*
|
|
12
|
+
* Two classes of problem, deliberately handled differently:
|
|
13
|
+
* - BLOCKER (not a git repo): deliver cannot function. Fail loudly with the
|
|
14
|
+
* exact command to fix it. Failing closed beats burning a turn budget on a
|
|
15
|
+
* mission that cannot land.
|
|
16
|
+
* - POSTURE (deliver.orchestrate / deliver.epics unset): the desired state is
|
|
17
|
+
* "always on". Refusing to run would punish every project that simply never
|
|
18
|
+
* set the key, so SELF-HEAL: write the intended posture and say so. Explicit
|
|
19
|
+
* `false`/`'off'` is a real operator decision and is never overridden.
|
|
20
|
+
*/
|
|
21
|
+
export interface PreflightResult {
|
|
22
|
+
/** False when a hard blocker means the mission must not start. */
|
|
23
|
+
ok: boolean;
|
|
24
|
+
/** Fatal, actionable reasons the project cannot deliver. */
|
|
25
|
+
blockers: string[];
|
|
26
|
+
/** Config posture repaired in place (reported, not fatal). */
|
|
27
|
+
healed: string[];
|
|
28
|
+
}
|
|
29
|
+
/** True when `dir` is inside a git work tree. */
|
|
30
|
+
export declare function isGitRepo(dir: string): boolean;
|
|
31
|
+
/**
|
|
32
|
+
* Check a project can actually deliver, healing config posture as needed.
|
|
33
|
+
* Pure-ish: only writes `.uap.json`, and only to add absent keys.
|
|
34
|
+
*/
|
|
35
|
+
export declare function preflightProject(dir: string): PreflightResult;
|
|
36
|
+
/** Human-readable preflight failure, with the fix inline. */
|
|
37
|
+
export declare function formatPreflightFailure(result: PreflightResult): string;
|
|
38
|
+
//# sourceMappingURL=project-preflight.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-preflight.d.ts","sourceRoot":"","sources":["../../src/delivery/project-preflight.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAMH,MAAM,WAAW,eAAe;IAC9B,kEAAkE;IAClE,EAAE,EAAE,OAAO,CAAC;IACZ,4DAA4D;IAC5D,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,8DAA8D;IAC9D,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB;AAED,iDAAiD;AACjD,wBAAgB,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAO9C;AAED;;;GAGG;AACH,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,MAAM,GAAG,eAAe,CAsC7D;AAED,6DAA6D;AAC7D,wBAAgB,sBAAsB,CAAC,MAAM,EAAE,eAAe,GAAG,MAAM,CAKtE"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Project preflight — refuse to start a mission in a project that structurally
|
|
3
|
+
* CANNOT deliver, and self-heal the config posture that must always hold.
|
|
4
|
+
*
|
|
5
|
+
* Why this exists: a fresh scaffold silently reproduced two blockers that had
|
|
6
|
+
* already been diagnosed and hand-fixed once. `uap init` did not `git init`, so
|
|
7
|
+
* the project was not a repo — and deliver's candidate workspace is worktree
|
|
8
|
+
* based, so deliver, epics, orchestration and tasks were ALL dead. Nothing said
|
|
9
|
+
* so; the mission just failed to make progress. A hand-patched project is not a
|
|
10
|
+
* fix, because the next scaffold reset recreates the same hole.
|
|
11
|
+
*
|
|
12
|
+
* Two classes of problem, deliberately handled differently:
|
|
13
|
+
* - BLOCKER (not a git repo): deliver cannot function. Fail loudly with the
|
|
14
|
+
* exact command to fix it. Failing closed beats burning a turn budget on a
|
|
15
|
+
* mission that cannot land.
|
|
16
|
+
* - POSTURE (deliver.orchestrate / deliver.epics unset): the desired state is
|
|
17
|
+
* "always on". Refusing to run would punish every project that simply never
|
|
18
|
+
* set the key, so SELF-HEAL: write the intended posture and say so. Explicit
|
|
19
|
+
* `false`/`'off'` is a real operator decision and is never overridden.
|
|
20
|
+
*/
|
|
21
|
+
import { spawnSync } from 'child_process';
|
|
22
|
+
import { existsSync, readFileSync, writeFileSync } from 'fs';
|
|
23
|
+
import { join } from 'path';
|
|
24
|
+
/** True when `dir` is inside a git work tree. */
|
|
25
|
+
export function isGitRepo(dir) {
|
|
26
|
+
const r = spawnSync('git', ['rev-parse', '--is-inside-work-tree'], {
|
|
27
|
+
cwd: dir,
|
|
28
|
+
encoding: 'utf-8',
|
|
29
|
+
stdio: ['ignore', 'pipe', 'ignore'],
|
|
30
|
+
});
|
|
31
|
+
return r.status === 0 && String(r.stdout).trim() === 'true';
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Check a project can actually deliver, healing config posture as needed.
|
|
35
|
+
* Pure-ish: only writes `.uap.json`, and only to add absent keys.
|
|
36
|
+
*/
|
|
37
|
+
export function preflightProject(dir) {
|
|
38
|
+
const blockers = [];
|
|
39
|
+
const healed = [];
|
|
40
|
+
if (!isGitRepo(dir)) {
|
|
41
|
+
blockers.push('not a git repository — deliver runs each candidate in a git worktree, so ' +
|
|
42
|
+
'deliver, epics, orchestration and tasks cannot run at all here.\n' +
|
|
43
|
+
` fix: git -C ${dir} init && git -C ${dir} add -A && git -C ${dir} commit -m "baseline"`);
|
|
44
|
+
}
|
|
45
|
+
const configPath = join(dir, '.uap.json');
|
|
46
|
+
if (existsSync(configPath)) {
|
|
47
|
+
try {
|
|
48
|
+
const cfg = JSON.parse(readFileSync(configPath, 'utf-8'));
|
|
49
|
+
const deliver = cfg.deliver ?? {};
|
|
50
|
+
let changed = false;
|
|
51
|
+
// Absent => the intended always-on posture. An explicit false/'off' is an
|
|
52
|
+
// operator decision and must survive.
|
|
53
|
+
for (const key of ['orchestrate', 'epics']) {
|
|
54
|
+
if (deliver[key] === undefined) {
|
|
55
|
+
deliver[key] = 'on';
|
|
56
|
+
healed.push(`deliver.${key} was unset — defaulted to "on"`);
|
|
57
|
+
changed = true;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
if (changed) {
|
|
61
|
+
cfg.deliver = deliver;
|
|
62
|
+
writeFileSync(configPath, JSON.stringify(cfg, null, 2));
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
catch {
|
|
66
|
+
// A malformed .uap.json is the config layer's problem to report, not ours;
|
|
67
|
+
// never let preflight throw out of a mission start.
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
return { ok: blockers.length === 0, blockers, healed };
|
|
71
|
+
}
|
|
72
|
+
/** Human-readable preflight failure, with the fix inline. */
|
|
73
|
+
export function formatPreflightFailure(result) {
|
|
74
|
+
return [
|
|
75
|
+
'This project cannot deliver:',
|
|
76
|
+
...result.blockers.map((b) => ` ✗ ${b}`),
|
|
77
|
+
].join('\n');
|
|
78
|
+
}
|
|
79
|
+
//# sourceMappingURL=project-preflight.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"project-preflight.js","sourceRoot":"","sources":["../../src/delivery/project-preflight.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,IAAI,CAAC;AAC7D,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAW5B,iDAAiD;AACjD,MAAM,UAAU,SAAS,CAAC,GAAW;IACnC,MAAM,CAAC,GAAG,SAAS,CAAC,KAAK,EAAE,CAAC,WAAW,EAAE,uBAAuB,CAAC,EAAE;QACjE,GAAG,EAAE,GAAG;QACR,QAAQ,EAAE,OAAO;QACjB,KAAK,EAAE,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,CAAC;KACpC,CAAC,CAAC;IACH,OAAO,CAAC,CAAC,MAAM,KAAK,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,IAAI,EAAE,KAAK,MAAM,CAAC;AAC9D,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,gBAAgB,CAAC,GAAW;IAC1C,MAAM,QAAQ,GAAa,EAAE,CAAC;IAC9B,MAAM,MAAM,GAAa,EAAE,CAAC;IAE5B,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,EAAE,CAAC;Q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AC5D,OAAO;QACL,8BAA8B;QAC9B,GAAG,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,OAAO,CAAC,EAAE,CAAC;KAC1C,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACf,CAAC"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Record HOW a deliver run's process ended.
|
|
3
|
+
*
|
|
4
|
+
* A run that dies leaves `status: 'running'` behind — deliberately, because that
|
|
5
|
+
* is what `--resume` looks for. But nothing recorded *how* it died, so a mission
|
|
6
|
+
* killed by its parent was indistinguishable from one still working: monitoring
|
|
7
|
+
* could not tell a live run from a corpse, and there was no way to find out who
|
|
8
|
+
* killed it or with what signal.
|
|
9
|
+
*
|
|
10
|
+
* That gap is not academic. Client-spawned deliver runs were dying within
|
|
11
|
+
* seconds while the identical binary run from a shell worked fine — and with no
|
|
12
|
+
* exit record anywhere, the cause could only be guessed at. This makes the
|
|
13
|
+
* process state its own witness:
|
|
14
|
+
*
|
|
15
|
+
* - SIGHUP → the parent (client) tore down our process group
|
|
16
|
+
* - SIGTERM → something deliberately killed us (a timeout, a supervisor)
|
|
17
|
+
* - SIGINT → an interactive interrupt
|
|
18
|
+
* - clean → we exited on our own, with a code
|
|
19
|
+
* - NO record at all, but a dead pid → SIGKILL (no handler can run for it)
|
|
20
|
+
*
|
|
21
|
+
* The recorder is best-effort and must never itself break a run: every write is
|
|
22
|
+
* wrapped, and the process is not prevented from exiting.
|
|
23
|
+
*/
|
|
24
|
+
/** How a deliver process ended. */
|
|
25
|
+
export interface RunExit {
|
|
26
|
+
at: string;
|
|
27
|
+
/** Signal name when killed (SIGHUP/SIGTERM/…), absent on a normal exit. */
|
|
28
|
+
signal?: string;
|
|
29
|
+
/** Exit code on a normal exit. */
|
|
30
|
+
code?: number;
|
|
31
|
+
/** pid of whoever spawned us — names the killer when the parent tears us down. */
|
|
32
|
+
ppid?: number;
|
|
33
|
+
reason: string;
|
|
34
|
+
}
|
|
35
|
+
/** Human-readable exit line for `.uap/deliver-exits.log`. */
|
|
36
|
+
export declare function formatExitLine(runId: string, exit: RunExit): string;
|
|
37
|
+
/** Append an exit record to the project's deliver-exits log (best-effort). */
|
|
38
|
+
export declare function appendExitLog(projectRoot: string, runId: string, exit: RunExit): void;
|
|
39
|
+
/**
|
|
40
|
+
* Persist the exit onto the run's state (keeping `status` untouched, so a killed
|
|
41
|
+
* run stays resumable) and append it to the log.
|
|
42
|
+
*/
|
|
43
|
+
export declare function recordExit(projectRoot: string, runId: string, exit: RunExit): void;
|
|
44
|
+
/**
|
|
45
|
+
* Install handlers so this process records its own death. Returns a disposer
|
|
46
|
+
* that removes them (so a long-lived parent process — tests, the MCP server —
|
|
47
|
+
* does not accumulate listeners).
|
|
48
|
+
*/
|
|
49
|
+
export declare function installRunExitRecorder(projectRoot: string, runId: string): () => void;
|
|
50
|
+
//# sourceMappingURL=run-exit.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run-exit.d.ts","sourceRoot":"","sources":["../../src/delivery/run-exit.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAMH,mCAAmC;AACnC,MAAM,WAAW,OAAO;IACtB,EAAE,EAAE,MAAM,CAAC;IACX,2EAA2E;IAC3E,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,kCAAkC;IAClC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,kFAAkF;IAClF,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB;AAID,6DAA6D;AAC7D,wBAAgB,cAAc,CAAC,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,GAAG,MAAM,CAGnE;AAED,8EAA8E;AAC9E,wBAAgB,aAAa,CAAC,WAAW,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,GAAG,IAAI,CAQrF;AAED;;;GAGG;AACH,wBAAgB,UAAU,CAAC,WAAW,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,OAAO,GAAG,IAAI,CAQlF;AAED;;;;GAIG;AACH,wBAAgB,sBAAsB,CAAC,WAAW,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,IAAI,CA2CrF"}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Record HOW a deliver run's process ended.
|
|
3
|
+
*
|
|
4
|
+
* A run that dies leaves `status: 'running'` behind — deliberately, because that
|
|
5
|
+
* is what `--resume` looks for. But nothing recorded *how* it died, so a mission
|
|
6
|
+
* killed by its parent was indistinguishable from one still working: monitoring
|
|
7
|
+
* could not tell a live run from a corpse, and there was no way to find out who
|
|
8
|
+
* killed it or with what signal.
|
|
9
|
+
*
|
|
10
|
+
* That gap is not academic. Client-spawned deliver runs were dying within
|
|
11
|
+
* seconds while the identical binary run from a shell worked fine — and with no
|
|
12
|
+
* exit record anywhere, the cause could only be guessed at. This makes the
|
|
13
|
+
* process state its own witness:
|
|
14
|
+
*
|
|
15
|
+
* - SIGHUP → the parent (client) tore down our process group
|
|
16
|
+
* - SIGTERM → something deliberately killed us (a timeout, a supervisor)
|
|
17
|
+
* - SIGINT → an interactive interrupt
|
|
18
|
+
* - clean → we exited on our own, with a code
|
|
19
|
+
* - NO record at all, but a dead pid → SIGKILL (no handler can run for it)
|
|
20
|
+
*
|
|
21
|
+
* The recorder is best-effort and must never itself break a run: every write is
|
|
22
|
+
* wrapped, and the process is not prevented from exiting.
|
|
23
|
+
*/
|
|
24
|
+
import { appendFileSync, mkdirSync } from 'fs';
|
|
25
|
+
import { dirname, join } from 'path';
|
|
26
|
+
import { loadRunState, saveRunState } from './run-state.js';
|
|
27
|
+
const SIGNALS = ['SIGHUP', 'SIGTERM', 'SIGINT', 'SIGQUIT'];
|
|
28
|
+
/** Human-readable exit line for `.uap/deliver-exits.log`. */
|
|
29
|
+
export function formatExitLine(runId, exit) {
|
|
30
|
+
const how = exit.signal ? `signal=${exit.signal}` : `code=${exit.code ?? '?'}`;
|
|
31
|
+
return `${exit.at} run=${runId} ${how} ppid=${exit.ppid ?? '?'} reason=${exit.reason}\n`;
|
|
32
|
+
}
|
|
33
|
+
/** Append an exit record to the project's deliver-exits log (best-effort). */
|
|
34
|
+
export function appendExitLog(projectRoot, runId, exit) {
|
|
35
|
+
try {
|
|
36
|
+
const p = join(projectRoot, '.uap', 'deliver-exits.log');
|
|
37
|
+
mkdirSync(dirname(p), { recursive: true });
|
|
38
|
+
appendFileSync(p, formatExitLine(runId, exit), 'utf-8');
|
|
39
|
+
}
|
|
40
|
+
catch {
|
|
41
|
+
/* never let logging break a run */
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* Persist the exit onto the run's state (keeping `status` untouched, so a killed
|
|
46
|
+
* run stays resumable) and append it to the log.
|
|
47
|
+
*/
|
|
48
|
+
export function recordExit(projectRoot, runId, exit) {
|
|
49
|
+
try {
|
|
50
|
+
const state = loadRunState(projectRoot, runId);
|
|
51
|
+
if (state)
|
|
52
|
+
saveRunState({ ...state, exit });
|
|
53
|
+
}
|
|
54
|
+
catch {
|
|
55
|
+
/* best-effort */
|
|
56
|
+
}
|
|
57
|
+
appendExitLog(projectRoot, runId, exit);
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Install handlers so this process records its own death. Returns a disposer
|
|
61
|
+
* that removes them (so a long-lived parent process — tests, the MCP server —
|
|
62
|
+
* does not accumulate listeners).
|
|
63
|
+
*/
|
|
64
|
+
export function installRunExitRecorder(projectRoot, runId) {
|
|
65
|
+
let recorded = false;
|
|
66
|
+
const once = (exit) => {
|
|
67
|
+
if (recorded)
|
|
68
|
+
return;
|
|
69
|
+
recorded = true;
|
|
70
|
+
recordExit(projectRoot, runId, exit);
|
|
71
|
+
};
|
|
72
|
+
const onSignal = (signal) => {
|
|
73
|
+
once({
|
|
74
|
+
at: new Date().toISOString(),
|
|
75
|
+
signal,
|
|
76
|
+
ppid: process.ppid,
|
|
77
|
+
reason: signal === 'SIGHUP'
|
|
78
|
+
? 'parent closed our process group (client tore down the spawn)'
|
|
79
|
+
: `killed by ${signal}`,
|
|
80
|
+
});
|
|
81
|
+
// Preserve normal semantics: die from the signal we were sent.
|
|
82
|
+
process.exit(signal === 'SIGINT' ? 130 : 143);
|
|
83
|
+
};
|
|
84
|
+
const handlers = new Map();
|
|
85
|
+
for (const s of SIGNALS) {
|
|
86
|
+
const h = () => onSignal(s);
|
|
87
|
+
handlers.set(s, h);
|
|
88
|
+
process.on(s, h);
|
|
89
|
+
}
|
|
90
|
+
const onExit = (code) => {
|
|
91
|
+
once({
|
|
92
|
+
at: new Date().toISOString(),
|
|
93
|
+
code,
|
|
94
|
+
ppid: process.ppid,
|
|
95
|
+
reason: code === 0 ? 'exited normally' : `exited with code ${code}`,
|
|
96
|
+
});
|
|
97
|
+
};
|
|
98
|
+
process.on('exit', onExit);
|
|
99
|
+
return () => {
|
|
100
|
+
for (const [s, h] of handlers)
|
|
101
|
+
process.off(s, h);
|
|
102
|
+
process.off('exit', onExit);
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
//# sourceMappingURL=run-exit.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run-exit.js","sourceRoot":"","sources":["../../src/delivery/run-exit.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAEH,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,IAAI,CAAC;AAC/C,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AACrC,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAc5D,MAAM,OAAO,GAAqB,CAAC,QAAQ,EAAE,SAAS,EAAE,QAAQ,EAAE,SAAS,CAAC,CAAC;AAE7E,6DAA6D;A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AAC;IACL,CAAC,CAAC;IACF,OAAO,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAE3B,OAAO,GAAG,EAAE;QACV,KAAK,MAAM,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,QAAQ;YAAE,OAAO,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;QACjD,OAAO,CAAC,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC9B,CAAC,CAAC;AACJ,CAAC"}
|
|
@@ -30,6 +30,16 @@ export interface DeliverRunState {
|
|
|
30
30
|
taskId?: string;
|
|
31
31
|
/** OS pid of the deliver process that owns this run (operator cancel target). */
|
|
32
32
|
pid?: number;
|
|
33
|
+
/** pid of whoever SPAWNED the deliver process — names the killer when a parent tears it down. */
|
|
34
|
+
ppid?: number;
|
|
35
|
+
/** How the process ended (signal/code). Absent while genuinely alive; see run-exit.ts. */
|
|
36
|
+
exit?: {
|
|
37
|
+
at: string;
|
|
38
|
+
signal?: string;
|
|
39
|
+
code?: number;
|
|
40
|
+
ppid?: number;
|
|
41
|
+
reason: string;
|
|
42
|
+
};
|
|
33
43
|
}
|
|
34
44
|
export declare function deliverRunsDir(projectRoot: string): string;
|
|
35
45
|
export declare function newRunId(): string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"run-state.d.ts","sourceRoot":"","sources":["../../src/delivery/run-state.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAKH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAEpD,MAAM,MAAM,gBAAgB,GAAG,SAAS,GAAG,WAAW,GAAG,QAAQ,GAAG,aAAa,CAAC;AAElF,MAAM,WAAW,eAAe;IAC9B,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;I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oot":"","sources":["../../src/delivery/run-state.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,IAAI,CAAC;AAC7G,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAC;
|
|
1
|
+
{"version":3,"file":"run-state.js","sourceRoot":"","sources":["../../src/delivery/run-state.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,IAAI,CAAC;AAC7G,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAC;AAqCrC,MAAM,UAAU,cAAc,CAAC,WAAmB;IAChD,OAAO,IAAI,CAAC,WAAW,EAAE,MAAM,EAAE,cAAc,CAAC,CAAC;AACnD,CAAC;AAED,MAAM,UAAU,QAAQ;IACtB,MAAM,KAAK,GAAG,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC;IAChF,OAAO,OAAO,KAAK,IAAI,WAAW,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,CAAC;AAC1D,CAAC;AAED,6EAA6E;AAC7E,MAAM,UAAU,YAAY,CAAC,EAAU;IACrC,OAAO,mCAAmC,CAAC,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;AAC5E,CAAC;AAED,2EAA2E;AAC3E,MAAM,UAAU,YAAY,CAAC,KAAsB;IAC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W,EAAE,KAAK,CAAC,CAAC,CAAC;IAAC,CAAC;IAAC,MAAM,CAAC;QAAC,OAAO,KAAK,CAAC;IAAC,CAAC;AAC7G,CAAC;AAED,0FAA0F;AAC1F,MAAM,UAAU,WAAW,CAAC,WAAmB,EAAE,KAAa;IAC5D,IAAI,CAAC;QACH,MAAM,GAAG,GAAG,IAAI,CAAC,cAAc,CAAC,WAAW,CAAC,EAAE,KAAK,CAAC,CAAC;QACrD,SAAS,CAAC,GAAG,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;QACpC,aAAa,CAAC,IAAI,CAAC,GAAG,EAAE,MAAM,CAAC,EAAE,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,EAAE,OAAO,CAAC,CAAC;QACpE,OAAO,IAAI,CAAC;IACd,CAAC;IAAC,MAAM,CAAC;QAAC,OAAO,KAAK,CAAC;IAAC,CAAC;AAC3B,CAAC;AAED,mFAAmF;AACnF,MAAM,UAAU,SAAS,CAAC,WAAmB,EAAE,KAAa;IAC1D,IAAI,CAAC;QAAC,MAAM,CAAC,GAAG,YAAY,CAAC,WAAW,EAAE,KAAK,CAAC,CAAC;QAAC,IAAI,UAAU,CAAC,CAAC,CAAC;YAAE,UAAU,CAAC,CAAC,CAAC,CAAC;IAAC,CAAC;IAAC,MAAM,CAAC,CAAC,YAAY,CAAC,CAAC;AAC9G,CAAC"}
|
|
@@ -37,8 +37,30 @@ export interface SelfGateResult {
|
|
|
37
37
|
attempts: number;
|
|
38
38
|
notes: string[];
|
|
39
39
|
}
|
|
40
|
-
/**
|
|
40
|
+
/**
|
|
41
|
+
* Pull a shell script out of a model response (fenced block preferred).
|
|
42
|
+
*
|
|
43
|
+
* The closing fence is OPTIONAL. It used to be mandatory, and that was a live
|
|
44
|
+
* bug: when the model's response was truncated mid-script there was no closing
|
|
45
|
+
* ```, the regex did not match, and the whole raw response — opening ```bash
|
|
46
|
+
* line included — was written out as the gate. bash then hit an unterminated
|
|
47
|
+
* backtick on line 2 and every single turn failed with `unexpected EOF`, a
|
|
48
|
+
* phantom failure the model could not see or fix.
|
|
49
|
+
*/
|
|
41
50
|
export declare function extractScript(modelOutput: string): string;
|
|
51
|
+
/**
|
|
52
|
+
* Does this script even PARSE? `bash -n` reads without executing.
|
|
53
|
+
*
|
|
54
|
+
* A gate that cannot run is not a gate. Without this check the self-gate could
|
|
55
|
+
* not tell "the gate correctly failed on the unsolved repo" from "the gate is
|
|
56
|
+
* broken" — a syntax error exits non-zero, which the loop below read as proof
|
|
57
|
+
* of a strict gate and happily installed. The mission then failed on that
|
|
58
|
+
* script forever, for a reason that had nothing to do with the code.
|
|
59
|
+
*/
|
|
60
|
+
export declare function scriptParses(script: string): {
|
|
61
|
+
ok: boolean;
|
|
62
|
+
error?: string;
|
|
63
|
+
};
|
|
42
64
|
/**
|
|
43
65
|
* Author and validate a task-specific acceptance gate. Retries until the
|
|
44
66
|
* generated script fails on the current (unsolved) repo — the non-vacuity
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"self-gate.d.ts","sourceRoot":"","sources":["../../src/delivery/self-gate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAKH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAQ1D,MAAM,WAAW,eAAe;IAC9B,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,YAAY,CAAC;IACvB,iFAAiF;IACjF,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,8DAA8D;IAC9D,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,cAAc;IAC7B,0EAA0E;IAC1E,IAAI,EAAE,QAAQ,GAAG,IAAI,CAAC;IACtB,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,+EAA+E;IAC/E,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,EAAE,CAAC;CACjB;AAED
|
|
1
|
+
{"version":3,"file":"self-gate.d.ts","sourceRoot":"","sources":["../../src/delivery/self-gate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAKH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAQ1D,MAAM,WAAW,eAAe;IAC9B,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,YAAY,CAAC;IACvB,iFAAiF;IACjF,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,8DAA8D;IAC9D,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,cAAc;IAC7B,0EAA0E;IAC1E,IAAI,EAAE,QAAQ,GAAG,IAAI,CAAC;IACtB,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,+EAA+E;IAC/E,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,EAAE,CAAC;CACjB;AAED;;;;;;;;;GASG;AACH,wBAAgB,aAAa,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAQzD;AAED;;;;;;;;GAQG;AACH,wBAAgB,YAAY,CAAC,MAAM,EAAE,MAAM,GAAG;IAAE,EAAE,EAAE,OAAO,CAAC;IAAC,KAAK,CAAC,EAAE,MAAM,CAAA;CAAE,CAK5E;AAuDD;;;;GAIG;AACH,wBAAsB,oBAAoB,CAAC,IAAI,EAAE,eAAe,GAAG,OAAO,CAAC,cAAc,CAAC,CAgFzF"}
|
|
@@ -25,15 +25,42 @@ const GATE_DIR = '.uap-deliver';
|
|
|
25
25
|
const GATE_FILE = 'verify.sh';
|
|
26
26
|
const DEFAULT_ATTEMPTS = 3;
|
|
27
27
|
const DEFAULT_TIMEOUT_MS = 120_000;
|
|
28
|
-
/**
|
|
28
|
+
/**
|
|
29
|
+
* Pull a shell script out of a model response (fenced block preferred).
|
|
30
|
+
*
|
|
31
|
+
* The closing fence is OPTIONAL. It used to be mandatory, and that was a live
|
|
32
|
+
* bug: when the model's response was truncated mid-script there was no closing
|
|
33
|
+
* ```, the regex did not match, and the whole raw response — opening ```bash
|
|
34
|
+
* line included — was written out as the gate. bash then hit an unterminated
|
|
35
|
+
* backtick on line 2 and every single turn failed with `unexpected EOF`, a
|
|
36
|
+
* phantom failure the model could not see or fix.
|
|
37
|
+
*/
|
|
29
38
|
export function extractScript(modelOutput) {
|
|
30
|
-
const
|
|
31
|
-
|
|
39
|
+
const closed = modelOutput.match(/```(?:bash|sh|shell)?[^\n]*\n([\s\S]*?)```/);
|
|
40
|
+
// Truncated response: an opening fence with nothing closing it.
|
|
41
|
+
const open = modelOutput.match(/```(?:bash|sh|shell)?[^\n]*\n([\s\S]*)$/);
|
|
42
|
+
const body = (closed?.[1] ?? open?.[1] ?? modelOutput).trim();
|
|
32
43
|
// Guarantee a shebang so `bash <file>` and direct exec both behave.
|
|
33
44
|
if (/^#!/.test(body))
|
|
34
45
|
return body;
|
|
35
46
|
return `#!/usr/bin/env bash\n${body}`;
|
|
36
47
|
}
|
|
48
|
+
/**
|
|
49
|
+
* Does this script even PARSE? `bash -n` reads without executing.
|
|
50
|
+
*
|
|
51
|
+
* A gate that cannot run is not a gate. Without this check the self-gate could
|
|
52
|
+
* not tell "the gate correctly failed on the unsolved repo" from "the gate is
|
|
53
|
+
* broken" — a syntax error exits non-zero, which the loop below read as proof
|
|
54
|
+
* of a strict gate and happily installed. The mission then failed on that
|
|
55
|
+
* script forever, for a reason that had nothing to do with the code.
|
|
56
|
+
*/
|
|
57
|
+
export function scriptParses(script) {
|
|
58
|
+
const r = spawnSync('bash', ['-n'], { input: script, encoding: 'utf-8', timeout: 10_000 });
|
|
59
|
+
if (r.status === 0)
|
|
60
|
+
return { ok: true };
|
|
61
|
+
const error = String(r.stderr || r.stdout || 'script does not parse').trim().split('\n')[0];
|
|
62
|
+
return { ok: false, error: error.slice(0, 200) };
|
|
63
|
+
}
|
|
37
64
|
function buildAuthorPrompt(instruction, projectRoot, priorFeedback) {
|
|
38
65
|
const retry = priorFeedback
|
|
39
66
|
? `\n\nYour previous script was rejected because: ${priorFeedback}\nWrite a stricter script that genuinely verifies the required outcome.`
|
|
@@ -104,6 +131,19 @@ export async function authorAcceptanceGate(opts) {
|
|
|
104
131
|
continue;
|
|
105
132
|
}
|
|
106
133
|
const script = extractScript(response);
|
|
134
|
+
// A script that does not PARSE must never be installed. bash exits non-zero
|
|
135
|
+
// on a syntax error, which the "fails on the unsolved repo" check below
|
|
136
|
+
// would otherwise accept as proof of a strict gate — wiring in a gate that
|
|
137
|
+
// fails every turn for a reason the model cannot see. Reject it, hand the
|
|
138
|
+
// parse error back, and let the next attempt fix it.
|
|
139
|
+
const parse = scriptParses(script);
|
|
140
|
+
if (!parse.ok) {
|
|
141
|
+
notes.push(`attempt ${attempt}: gate script does not parse (${parse.error ?? 'syntax error'}) — regenerating`);
|
|
142
|
+
priorFeedback =
|
|
143
|
+
`the script was not valid bash: ${parse.error ?? 'syntax error'}. ` +
|
|
144
|
+
'Output ONLY the raw script — no markdown code fences, no prose — and make sure it is complete (not cut off).';
|
|
145
|
+
continue;
|
|
146
|
+
}
|
|
107
147
|
writeFileSync(scriptPath, script, 'utf-8');
|
|
108
148
|
try {
|
|
109
149
|
chmodSync(scriptPath, 0o755);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"self-gate.js","sourceRoot":"","sources":["../../src/delivery/self-gate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,aAA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