@askexenow/exe-os 0.9.216 → 0.9.217
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/deploy/compose/docker-compose.yml +1 -1
- package/dist/{backfill-metadata-PZTWTG35.js → backfill-metadata-I6VR7JZ2.js} +1 -1
- package/dist/{behaviors-KL2G7ZJ7.js → behaviors-YJ3HEQED.js} +3 -1
- package/dist/bin/agentic-ontology-backfill.js +1 -1
- package/dist/bin/agentic-reflection-backfill.js +1 -1
- package/dist/bin/agentic-semantic-label.js +1 -1
- package/dist/bin/backfill-conversations.js +1 -1
- package/dist/bin/backfill-responses.js +1 -1
- package/dist/bin/backfill-vectors.js +2 -2
- package/dist/bin/bulk-sync-postgres.js +1 -1
- package/dist/bin/cleanup-stale-review-tasks.js +2 -2
- package/dist/bin/cli.js +4 -4
- package/dist/bin/exe-assign.js +1 -1
- package/dist/bin/exe-boot.js +3 -3
- package/dist/bin/exe-dispatch.js +2 -2
- package/dist/bin/exe-doctor.js +1 -1
- package/dist/bin/exe-export-behaviors.js +4 -4
- package/dist/bin/exe-forget.js +3 -3
- package/dist/bin/exe-gateway.js +4 -4
- package/dist/bin/exe-heartbeat.js +2 -2
- package/dist/bin/exe-kill.js +3 -3
- package/dist/bin/exe-launch-agent.js +5 -5
- package/dist/bin/exe-pending-messages.js +3 -3
- package/dist/bin/exe-pending-notifications.js +2 -2
- package/dist/bin/exe-pending-reviews.js +2 -2
- package/dist/bin/exe-review.js +3 -3
- package/dist/bin/exe-search.js +2 -2
- package/dist/bin/exe-session-cleanup.js +5 -5
- package/dist/bin/exe-start-codex.js +3 -3
- package/dist/bin/exe-start-opencode.js +3 -3
- package/dist/bin/exe-status.js +3 -3
- package/dist/bin/exe-team.js +1 -1
- package/dist/bin/git-sweep.js +2 -2
- package/dist/bin/graph-backfill.js +1 -1
- package/dist/bin/graph-export.js +2 -2
- package/dist/bin/import-history.js +1 -1
- package/dist/bin/intercom-check.js +4 -4
- package/dist/bin/mcp-sessions.js +2 -2
- package/dist/bin/orchestration-metrics.js +1 -1
- package/dist/bin/scan-tasks.js +2 -2
- package/dist/bin/shard-migrate.js +1 -1
- package/dist/{capacity-monitor-2BQAYPLD.js → capacity-monitor-XFMZSJDB.js} +2 -2
- package/dist/{catchup-brief-WJ7CNOQH.js → catchup-brief-D5IZFZDO.js} +3 -3
- package/dist/{chunk-TBNDW7US.js → chunk-2DRWIXOO.js} +1 -1
- package/dist/{chunk-VNP3SECD.js → chunk-4ANCHFE2.js} +1 -1
- package/dist/{chunk-YWLO73DO.js → chunk-5G643UWZ.js} +14 -4
- package/dist/{chunk-JFH5WWP7.js → chunk-64DYFA5X.js} +2 -2
- package/dist/{chunk-YXYJG5JX.js → chunk-6UY62EGD.js} +4 -4
- package/dist/{chunk-PUGYDZ4H.js → chunk-7X6QKJGM.js} +2 -2
- package/dist/{chunk-NJTIAI5G.js → chunk-BFLBZGPZ.js} +10 -1
- package/dist/{chunk-HZB5RFJI.js → chunk-BN3HRSEU.js} +1 -1
- package/dist/{chunk-NUMRCSLX.js → chunk-CUKIMXQ7.js} +1 -1
- package/dist/{chunk-34QPI5EB.js → chunk-FXD53Q32.js} +2 -2
- package/dist/{chunk-CCKNE7II.js → chunk-GEFZHKEN.js} +1 -1
- package/dist/{chunk-545RHWVW.js → chunk-GKNYEJQ3.js} +1 -1
- package/dist/{chunk-6GSACZON.js → chunk-HW46Q4AR.js} +4 -4
- package/dist/{chunk-IN5UEMCT.js → chunk-IFSAR5IX.js} +3 -3
- package/dist/{chunk-47N7BTNW.js → chunk-NEGJAEZ7.js} +1 -1
- package/dist/{chunk-F6T67NYS.js → chunk-O6LFXATW.js} +1 -1
- package/dist/{chunk-5U6UANGP.js → chunk-PKIOJQ2N.js} +1 -1
- package/dist/{chunk-NWLHYYHG.js → chunk-QOY6CTHV.js} +1 -1
- package/dist/{chunk-J7GQ24E3.js → chunk-R2MZDZTQ.js} +1 -1
- package/dist/{chunk-755ADH4S.js → chunk-RSHVFBKD.js} +4 -4
- package/dist/{chunk-AJJKDHAD.js → chunk-RTGN42GD.js} +1 -1
- package/dist/{chunk-AI4WYA6P.js → chunk-S2T7CE4P.js} +1 -1
- package/dist/{chunk-MUPXVKIR.js → chunk-SDQSOQOE.js} +2 -2
- package/dist/{chunk-XDDBA7QE.js → chunk-T43SC2XX.js} +1 -1
- package/dist/{chunk-47ASPR6R.js → chunk-UO3IEPSY.js} +675 -586
- package/dist/{chunk-GSBNSF67.js → chunk-WEJ45ZFF.js} +1 -1
- package/dist/{chunk-H6IQFGIG.js → chunk-XPKACO5A.js} +3 -3
- package/dist/{chunk-3FBZNRRS.js → chunk-YJNRRQOG.js} +2 -2
- package/dist/{crm-webhook-6EPM6GCJ.js → crm-webhook-WMAW6ZT2.js} +2 -2
- package/dist/{cto-delegation-gate-BU6HH4CY.js → cto-delegation-gate-YNWMQEQB.js} +1 -1
- package/dist/{daemon-orchestration-R2MVQ4CF.js → daemon-orchestration-5KUKQOZ4.js} +3 -3
- package/dist/{exe-export-KEL4ZR25.js → exe-export-RAYK76SO.js} +1 -1
- package/dist/{exe-import-ICJYV22F.js → exe-import-SAJBGUN5.js} +1 -1
- package/dist/{fast-db-init-6D433NQO.js → fast-db-init-5VDTKVKX.js} +1 -1
- package/dist/gateway/index.js +5 -5
- package/dist/{git-task-sweep-VIGVG2RY.js → git-task-sweep-GED54WTZ.js} +2 -2
- package/dist/hooks/bug-report-worker.js +3 -3
- package/dist/hooks/codex-stop-task-finalizer.js +3 -3
- package/dist/hooks/commit-complete.js +4 -4
- package/dist/hooks/error-recall.js +2 -2
- package/dist/hooks/ingest.js +2 -2
- package/dist/hooks/instructions-loaded.js +1 -1
- package/dist/hooks/manifest.json +18 -18
- package/dist/hooks/notification.js +1 -1
- package/dist/hooks/post-compact.js +2 -2
- package/dist/hooks/post-tool-combined.js +2 -2
- package/dist/hooks/pre-compact.js +3 -3
- package/dist/hooks/pre-tool-use.js +6 -6
- package/dist/hooks/prompt-submit.js +10 -10
- package/dist/hooks/session-end.js +152 -20
- package/dist/hooks/session-start.js +4 -4
- package/dist/hooks/stop.js +5 -5
- package/dist/hooks/subagent-stop.js +2 -2
- package/dist/hooks/summary-worker.js +5 -5
- package/dist/index.js +8 -8
- package/dist/lib/consolidation.js +2 -2
- package/dist/lib/exe-daemon.js +24 -14
- package/dist/lib/hybrid-search.js +2 -2
- package/dist/lib/messaging.js +2 -2
- package/dist/lib/schedules.js +2 -2
- package/dist/lib/skill-learning.js +2 -2
- package/dist/lib/store.js +1 -1
- package/dist/lib/tasks.js +2 -2
- package/dist/lib/tmux-routing.js +1 -1
- package/dist/mcp/register-tools.js +24 -24
- package/dist/mcp/server.js +25 -25
- package/dist/mcp/tools/create-task.js +3 -3
- package/dist/mcp/tools/deactivate-behavior.js +2 -2
- package/dist/mcp/tools/list-tasks.js +3 -3
- package/dist/mcp/tools/send-message.js +3 -3
- package/dist/mcp/tools/update-task.js +3 -3
- package/dist/{notifications-TNSU4SCZ.js → notifications-SCHILQCQ.js} +1 -1
- package/dist/{orchestrator-EYAPHOOD.js → orchestrator-NCEFZF32.js} +2 -2
- package/dist/{reranker-UMCHVO3A.js → reranker-QFLVGVRT.js} +1 -1
- package/dist/{review-polling-5ZEWTFQL.js → review-polling-ZKYFETP3.js} +2 -2
- package/dist/runtime/index.js +3 -3
- package/dist/{session-events-ZYNOWIQL.js → session-events-XCNQDXF4.js} +2 -2
- package/dist/{session-scope-UCFA2CJP.js → session-scope-FEZQJMD4.js} +1 -1
- package/dist/{task-enforcement-XYQN7VBA.js → task-enforcement-HVY36QRD.js} +1 -1
- package/dist/{task-scope-52IDTSYX.js → task-scope-ODSOEGTH.js} +1 -1
- package/dist/{tasks-crud-ZRB2UNNB.js → tasks-crud-RIUHZJGR.js} +1 -1
- package/dist/{tasks-review-DZGRPBMN.js → tasks-review-EBUVFQUJ.js} +1 -1
- package/dist/tui/App.js +7 -7
- package/dist/{tui-data-XLI7YZ75.js → tui-data-UM6LR4EQ.js} +1 -1
- package/dist/{worker-gate-ZS6IY5HM.js → worker-gate-K5YTO2H5.js} +1 -1
- package/dist/{workflow-engine-KWRAUF7M.js → workflow-engine-WUU5OZ3N.js} +2 -2
- package/package.json +1 -1
- package/release-notes.json +47 -47
- /package/dist/{chunk-Z3O6UJUX.js → chunk-2IMUAL3X.js} +0 -0
- /package/dist/{chunk-6457MEIK.js → chunk-4AJYZFDE.js} +0 -0
- /package/dist/{chunk-2333X7A7.js → chunk-DXB3CB2O.js} +0 -0
- /package/dist/{chunk-WELKUXEL.js → chunk-KVOTLCAX.js} +0 -0
- /package/dist/{chunk-COGICIAL.js → chunk-MQA6K7DH.js} +0 -0
- /package/dist/{core-memory-LN22LDJA.js → core-memory-NZOLAIOE.js} +0 -0
- /package/dist/{exe-key-ZJMUM57I.js → exe-key-W3CME65M.js} +0 -0
- /package/dist/{skill-refinement-CYK53LCM.js → skill-refinement-QHOS6CGQ.js} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
writeContinuityCheckpoint
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-MQA6K7DH.js";
|
|
4
4
|
import "../chunk-FLLCEGSL.js";
|
|
5
5
|
import "../chunk-X4QO5DXP.js";
|
|
6
6
|
import "../chunk-EF4PA3TY.js";
|
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
} from "../chunk-S4I3UITZ.js";
|
|
17
17
|
import {
|
|
18
18
|
strictSessionScopeFilter
|
|
19
|
-
} from "../chunk-
|
|
19
|
+
} from "../chunk-HW46Q4AR.js";
|
|
20
20
|
import "../chunk-ACOW43IN.js";
|
|
21
21
|
import "../chunk-QI4IXJN7.js";
|
|
22
22
|
import "../chunk-B7NO5U7H.js";
|
|
@@ -47,6 +47,7 @@ import "../chunk-LYH5HE24.js";
|
|
|
47
47
|
import "../chunk-MLKGABMK.js";
|
|
48
48
|
|
|
49
49
|
// src/adapters/claude/hooks/session-end.ts
|
|
50
|
+
import { closeSync, openSync, readSync, statSync } from "fs";
|
|
50
51
|
process.on("uncaughtException", () => process.exit(0));
|
|
51
52
|
process.on("unhandledRejection", () => process.exit(0));
|
|
52
53
|
try {
|
|
@@ -63,6 +64,115 @@ var timeout = setTimeout(() => {
|
|
|
63
64
|
}, 15e3);
|
|
64
65
|
timeout.unref();
|
|
65
66
|
var MAX_INPUT_SIZE = 1e6;
|
|
67
|
+
var TRANSCRIPT_TAIL_BYTES = 2e6;
|
|
68
|
+
function asTimestampMs(value) {
|
|
69
|
+
if (typeof value !== "string") return null;
|
|
70
|
+
const ms = new Date(value).getTime();
|
|
71
|
+
return Number.isFinite(ms) ? ms : null;
|
|
72
|
+
}
|
|
73
|
+
function compactText(value, max = 500) {
|
|
74
|
+
if (typeof value !== "string") return void 0;
|
|
75
|
+
const compact = value.replace(/\s+/g, " ").trim();
|
|
76
|
+
if (!compact) return void 0;
|
|
77
|
+
return compact.length > max ? `${compact.slice(0, max - 1)}\u2026` : compact;
|
|
78
|
+
}
|
|
79
|
+
function extractContentText(content) {
|
|
80
|
+
if (typeof content === "string") return compactText(content);
|
|
81
|
+
if (!Array.isArray(content)) return void 0;
|
|
82
|
+
const parts = [];
|
|
83
|
+
for (const item of content) {
|
|
84
|
+
if (!item || typeof item !== "object") continue;
|
|
85
|
+
const record = item;
|
|
86
|
+
if (record.type === "text") {
|
|
87
|
+
const text = compactText(record.text);
|
|
88
|
+
if (text) parts.push(text);
|
|
89
|
+
} else if (record.type === "tool_result" && record.is_error) {
|
|
90
|
+
const text = compactText(record.content, 300);
|
|
91
|
+
if (text) parts.push(`tool_error: ${text}`);
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
return compactText(parts.join(" | "));
|
|
95
|
+
}
|
|
96
|
+
function readTranscriptTail(transcriptPath) {
|
|
97
|
+
const stats = statSync(transcriptPath);
|
|
98
|
+
const bytesToRead = Math.min(stats.size, TRANSCRIPT_TAIL_BYTES);
|
|
99
|
+
const fd = openSync(transcriptPath, "r");
|
|
100
|
+
try {
|
|
101
|
+
const buffer = Buffer.alloc(bytesToRead);
|
|
102
|
+
readSync(fd, buffer, 0, bytesToRead, Math.max(0, stats.size - bytesToRead));
|
|
103
|
+
return { text: buffer.toString("utf8"), bytes: stats.size };
|
|
104
|
+
} finally {
|
|
105
|
+
closeSync(fd);
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
function readTranscriptExitForensics(transcriptPath) {
|
|
109
|
+
const forensics = {
|
|
110
|
+
transcriptPath,
|
|
111
|
+
transcriptFound: false
|
|
112
|
+
};
|
|
113
|
+
if (!transcriptPath) return forensics;
|
|
114
|
+
try {
|
|
115
|
+
const tail = readTranscriptTail(transcriptPath);
|
|
116
|
+
if (!tail) return forensics;
|
|
117
|
+
forensics.transcriptFound = true;
|
|
118
|
+
forensics.transcriptBytes = tail.bytes;
|
|
119
|
+
const lines = tail.text.split("\n").filter(Boolean);
|
|
120
|
+
let firstTs;
|
|
121
|
+
let lastTs;
|
|
122
|
+
for (const line of lines) {
|
|
123
|
+
try {
|
|
124
|
+
const entry = JSON.parse(line);
|
|
125
|
+
if (entry.timestamp) {
|
|
126
|
+
firstTs ??= entry.timestamp;
|
|
127
|
+
lastTs = entry.timestamp;
|
|
128
|
+
}
|
|
129
|
+
if (entry.version) forensics.claudeVersion = entry.version;
|
|
130
|
+
if (entry.type === "queue-operation" && entry.operation === "enqueue") {
|
|
131
|
+
forensics.queuedPrompt = compactText(entry.content);
|
|
132
|
+
}
|
|
133
|
+
if (entry.type === "user" && entry.message?.role === "user") {
|
|
134
|
+
const text = extractContentText(entry.message.content);
|
|
135
|
+
if (text && !text.startsWith("tool_error:")) forensics.lastUserPrompt = text;
|
|
136
|
+
}
|
|
137
|
+
if (entry.type === "assistant" && entry.message) {
|
|
138
|
+
forensics.lastAssistantStopReason = entry.message.stop_reason;
|
|
139
|
+
forensics.lastAssistantStopDetails = entry.message.stop_details;
|
|
140
|
+
}
|
|
141
|
+
if (entry.type === "system") {
|
|
142
|
+
forensics.lastSystemSubtype = entry.subtype;
|
|
143
|
+
if (entry.subtype === "turn_duration" && typeof entry.durationMs === "number") {
|
|
144
|
+
forensics.lastTurnDurationMs = entry.durationMs;
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
if (typeof entry.toolUseResult === "string" && entry.toolUseResult.startsWith("Error:")) {
|
|
148
|
+
forensics.lastToolError = compactText(entry.toolUseResult, 500);
|
|
149
|
+
}
|
|
150
|
+
} catch {
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
forensics.transcriptStartedAt = firstTs;
|
|
154
|
+
forensics.transcriptEndedAt = lastTs;
|
|
155
|
+
const firstMs = asTimestampMs(firstTs);
|
|
156
|
+
const lastMs = asTimestampMs(lastTs);
|
|
157
|
+
if (firstMs != null && lastMs != null && lastMs >= firstMs) {
|
|
158
|
+
forensics.sessionDurationMs = lastMs - firstMs;
|
|
159
|
+
}
|
|
160
|
+
} catch {
|
|
161
|
+
return forensics;
|
|
162
|
+
}
|
|
163
|
+
return forensics;
|
|
164
|
+
}
|
|
165
|
+
function inferExitReason(daemonAlive, data, transcript) {
|
|
166
|
+
if (!daemonAlive) return "mcp_daemon_dead";
|
|
167
|
+
if (!data.transcript_path || !transcript.transcriptFound) return "abrupt_no_transcript";
|
|
168
|
+
if (transcript.lastAssistantStopReason === "end_turn" && transcript.queuedPrompt) {
|
|
169
|
+
return "ended_after_turn_with_queued_prompt";
|
|
170
|
+
}
|
|
171
|
+
if (transcript.lastAssistantStopReason === "end_turn") return "normal_end_after_turn";
|
|
172
|
+
if (transcript.lastAssistantStopReason === "max_tokens") return "token_limit";
|
|
173
|
+
if (transcript.lastAssistantStopReason === "pause_turn") return "paused";
|
|
174
|
+
return "session_ended_with_transcript";
|
|
175
|
+
}
|
|
66
176
|
var input = "";
|
|
67
177
|
process.stdin.setEncoding("utf8");
|
|
68
178
|
process.stdin.on("data", (chunk) => {
|
|
@@ -76,23 +186,32 @@ process.stdin.on("end", async () => {
|
|
|
76
186
|
const data = JSON.parse(input);
|
|
77
187
|
const agent = getActiveAgent();
|
|
78
188
|
try {
|
|
79
|
-
const { appendFileSync } = await import("fs");
|
|
80
|
-
const { join } = await import("path");
|
|
189
|
+
const { appendFileSync, mkdirSync } = await import("fs");
|
|
190
|
+
const { join, dirname } = await import("path");
|
|
81
191
|
const { homedir } = await import("os");
|
|
82
|
-
const { execSync: execSyncForDeath } = await import("child_process");
|
|
83
192
|
const deathLog = join(homedir(), ".exe-os", "logs", "session-deaths.jsonl");
|
|
193
|
+
mkdirSync(dirname(deathLog), { recursive: true });
|
|
84
194
|
let daemonAlive = false;
|
|
195
|
+
const requestedPort = process.env.EXE_MCP_PORT ?? "";
|
|
196
|
+
const requestedPortNumber = Number(requestedPort);
|
|
197
|
+
const daemonPort = /^\d{1,5}$/.test(requestedPort) && requestedPortNumber > 0 && requestedPortNumber <= 65535 ? String(requestedPortNumber) : "48739";
|
|
198
|
+
const pingController = new AbortController();
|
|
199
|
+
const pingTimeout = setTimeout(() => pingController.abort(), 2e3);
|
|
200
|
+
pingTimeout.unref();
|
|
85
201
|
try {
|
|
86
|
-
|
|
87
|
-
|
|
202
|
+
const response = await fetch(`http://127.0.0.1:${daemonPort}/v1/ping`, {
|
|
203
|
+
method: "GET",
|
|
204
|
+
signal: pingController.signal
|
|
205
|
+
});
|
|
206
|
+
daemonAlive = response.ok;
|
|
88
207
|
} catch {
|
|
208
|
+
} finally {
|
|
209
|
+
clearTimeout(pingTimeout);
|
|
89
210
|
}
|
|
90
|
-
const
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
else if (data.transcript_path) exitReason = "normal_end_or_context_full";
|
|
95
|
-
else exitReason = "abrupt_no_transcript";
|
|
211
|
+
const hookUptimeMs = Math.round(process.uptime() * 1e3);
|
|
212
|
+
const transcript = readTranscriptExitForensics(data.transcript_path);
|
|
213
|
+
const exitReason = inferExitReason(daemonAlive, data, transcript);
|
|
214
|
+
const durationMs = transcript.sessionDurationMs ?? hookUptimeMs;
|
|
96
215
|
const entry = JSON.stringify({
|
|
97
216
|
timestamp: (/* @__PURE__ */ new Date()).toISOString(),
|
|
98
217
|
event: "session_exit",
|
|
@@ -102,15 +221,20 @@ process.stdin.on("end", async () => {
|
|
|
102
221
|
project: process.env.EXE_PROJECT_NAME ?? process.cwd().split("/").pop() ?? "unknown",
|
|
103
222
|
tmuxSession: process.env.EXE_SESSION ?? process.env.TMUX_PANE ?? "unknown",
|
|
104
223
|
tty: process.env.TTY ?? process.env.GPG_TTY ?? "unknown",
|
|
224
|
+
hookPid: process.pid,
|
|
225
|
+
hookPpid: process.ppid,
|
|
226
|
+
// Legacy keys retained for downstream readers; these are hook process IDs.
|
|
105
227
|
pid: process.pid,
|
|
106
228
|
ppid: process.ppid,
|
|
107
|
-
|
|
229
|
+
hookUptimeMs,
|
|
230
|
+
sessionDurationMs: transcript.sessionDurationMs,
|
|
108
231
|
exitReason,
|
|
109
232
|
daemonAlive,
|
|
110
|
-
memoryRssMB: Math.round(process.memoryUsage.rss() / 1024 / 1024)
|
|
233
|
+
memoryRssMB: Math.round(process.memoryUsage.rss() / 1024 / 1024),
|
|
234
|
+
transcript
|
|
111
235
|
});
|
|
112
236
|
appendFileSync(deathLog, entry + "\n");
|
|
113
|
-
process.stderr.write(`[session-end] EXIT: ${agent.agentId}
|
|
237
|
+
process.stderr.write(`[session-end] EXIT: ${agent.agentId} session=${Math.round((transcript.sessionDurationMs ?? 0) / 1e3)}s hook=${Math.round(hookUptimeMs / 1e3)}s \u2014 reason=${exitReason} daemon=${daemonAlive ? "alive" : "DEAD"}
|
|
114
238
|
`);
|
|
115
239
|
try {
|
|
116
240
|
const { recordOrchestrationEvent } = await import("../orchestration-events-RDW7BTCK.js");
|
|
@@ -121,8 +245,16 @@ process.stdin.on("end", async () => {
|
|
|
121
245
|
tmuxSession: process.env.EXE_SESSION ?? process.env.TMUX_PANE ?? "unknown",
|
|
122
246
|
sessionScope: process.env.EXE_SESSION_NAME?.includes("-") ? process.env.EXE_SESSION_NAME.split("-").pop() : process.env.EXE_SESSION_NAME,
|
|
123
247
|
result: exitReason,
|
|
124
|
-
durationMs
|
|
125
|
-
payload: {
|
|
248
|
+
durationMs,
|
|
249
|
+
payload: {
|
|
250
|
+
daemonAlive,
|
|
251
|
+
hookUptimeMs,
|
|
252
|
+
sessionDurationMs: transcript.sessionDurationMs,
|
|
253
|
+
memoryRssMB: Math.round(process.memoryUsage.rss() / 1024 / 1024),
|
|
254
|
+
lastAssistantStopReason: transcript.lastAssistantStopReason,
|
|
255
|
+
lastSystemSubtype: transcript.lastSystemSubtype,
|
|
256
|
+
queuedPrompt: transcript.queuedPrompt
|
|
257
|
+
}
|
|
126
258
|
});
|
|
127
259
|
} catch {
|
|
128
260
|
}
|
|
@@ -130,7 +262,7 @@ process.stdin.on("end", async () => {
|
|
|
130
262
|
}
|
|
131
263
|
if (agent.agentId !== "default") {
|
|
132
264
|
try {
|
|
133
|
-
const { fastDbInit } = await import("../fast-db-init-
|
|
265
|
+
const { fastDbInit } = await import("../fast-db-init-5VDTKVKX.js");
|
|
134
266
|
const client = await fastDbInit();
|
|
135
267
|
const seScope = strictSessionScopeFilter();
|
|
136
268
|
const orphanResult = await client.execute({
|
|
@@ -251,7 +383,7 @@ Orphaned tasks at session end: ${orphanResult.rows.map((r) => `"${String(r.title
|
|
|
251
383
|
parts.push(`Left in_progress (no matching commits, needs triage): ${leftInProgress.join(", ")}`);
|
|
252
384
|
}
|
|
253
385
|
try {
|
|
254
|
-
const { writeNotification } = await import("../notifications-
|
|
386
|
+
const { writeNotification } = await import("../notifications-SCHILQCQ.js");
|
|
255
387
|
await writeNotification({
|
|
256
388
|
agentId: agent.agentId,
|
|
257
389
|
agentRole: agent.agentRole,
|
|
@@ -36,7 +36,7 @@ process.stdin.on("end", async () => {
|
|
|
36
36
|
try {
|
|
37
37
|
const { getActiveAgent } = await import("../active-agent-R7QDYADX.js");
|
|
38
38
|
const { getProjectName } = await import("../project-name-EWG5KAZP.js");
|
|
39
|
-
const { getCurrentSessionScope } = await import("../task-scope-
|
|
39
|
+
const { getCurrentSessionScope } = await import("../task-scope-ODSOEGTH.js");
|
|
40
40
|
const { canCoordinate } = await import("../lib/employees.js");
|
|
41
41
|
const data = JSON.parse(input);
|
|
42
42
|
const projectName = getProjectName(data.cwd || void 0);
|
|
@@ -78,7 +78,7 @@ process.stdin.on("end", async () => {
|
|
|
78
78
|
}
|
|
79
79
|
if (!daemonDegraded) {
|
|
80
80
|
try {
|
|
81
|
-
const { fastDbInit } = await import("../fast-db-init-
|
|
81
|
+
const { fastDbInit } = await import("../fast-db-init-5VDTKVKX.js");
|
|
82
82
|
await fastDbInit();
|
|
83
83
|
} catch {
|
|
84
84
|
daemonDegraded = true;
|
|
@@ -163,7 +163,7 @@ You are **${ag.agentId}** (${ag.agentRole}). Daemon is degraded \u2014 memory un
|
|
|
163
163
|
query = `last actions on ${projectName}`;
|
|
164
164
|
header = "## Resuming Session\nHere's where you left off:";
|
|
165
165
|
try {
|
|
166
|
-
const { buildCatchupBrief } = await import("../catchup-brief-
|
|
166
|
+
const { buildCatchupBrief } = await import("../catchup-brief-D5IZFZDO.js");
|
|
167
167
|
const brief = await buildCatchupBrief(
|
|
168
168
|
agentId,
|
|
169
169
|
projectName,
|
|
@@ -188,7 +188,7 @@ The following files have been modified since you last read them:
|
|
|
188
188
|
query = `recent work on ${projectName}`;
|
|
189
189
|
header = "## Memory Brief\nRecent memories from this project:";
|
|
190
190
|
}
|
|
191
|
-
const { queryTaskRows } = await import("../tasks-crud-
|
|
191
|
+
const { queryTaskRows } = await import("../tasks-crud-RIUHZJGR.js");
|
|
192
192
|
const [memories, taskResult] = await Promise.all([
|
|
193
193
|
lightweightSearch(query, agentId, { projectName, limit: 5 }),
|
|
194
194
|
queryTaskRows({
|
package/dist/hooks/stop.js
CHANGED
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
} from "../chunk-S4I3UITZ.js";
|
|
5
5
|
import {
|
|
6
6
|
sessionScopeFilter
|
|
7
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-HW46Q4AR.js";
|
|
8
8
|
import "../chunk-ACOW43IN.js";
|
|
9
9
|
import "../chunk-QI4IXJN7.js";
|
|
10
10
|
import "../chunk-B7NO5U7H.js";
|
|
@@ -123,8 +123,8 @@ process.stdin.on("end", async () => {
|
|
|
123
123
|
process.exit(0);
|
|
124
124
|
}
|
|
125
125
|
try {
|
|
126
|
-
const { fastDbInit } = await import("../fast-db-init-
|
|
127
|
-
const { recordSessionEvent } = await import("../session-events-
|
|
126
|
+
const { fastDbInit } = await import("../fast-db-init-5VDTKVKX.js");
|
|
127
|
+
const { recordSessionEvent } = await import("../session-events-XCNQDXF4.js");
|
|
128
128
|
const client = await fastDbInit();
|
|
129
129
|
await recordSessionEvent(client, {
|
|
130
130
|
agentId: agent.agentId,
|
|
@@ -160,7 +160,7 @@ process.stdin.on("end", async () => {
|
|
|
160
160
|
}
|
|
161
161
|
const CAPACITY_SIGNALS = /context[- ]?full|hit capacity|conversation is too long|maximum context length|context window.*(?:limit|exceed|full)/i;
|
|
162
162
|
if (!canCoordinate(agent.agentId, agent.agentRole) && CAPACITY_SIGNALS.test(message)) {
|
|
163
|
-
import("../fast-db-init-
|
|
163
|
+
import("../fast-db-init-5VDTKVKX.js").then(({ fastDbInit }) => fastDbInit()).then(async (client) => {
|
|
164
164
|
const stScope = sessionScopeFilter();
|
|
165
165
|
const tasks = await client.execute({
|
|
166
166
|
sql: `SELECT title, status, task_file FROM tasks
|
|
@@ -253,7 +253,7 @@ ${msgs.slice(-15).join("\n")}`;
|
|
|
253
253
|
} catch {
|
|
254
254
|
}
|
|
255
255
|
if (!canCoordinate(agent.agentId, agent.agentRole)) {
|
|
256
|
-
import("../fast-db-init-
|
|
256
|
+
import("../fast-db-init-5VDTKVKX.js").then(({ fastDbInit }) => fastDbInit()).then(async (client) => {
|
|
257
257
|
const orScope = sessionScopeFilter();
|
|
258
258
|
return client.execute({
|
|
259
259
|
sql: `SELECT title, status FROM tasks
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
} from "../chunk-S4I3UITZ.js";
|
|
5
5
|
import {
|
|
6
6
|
sessionScopeFilter
|
|
7
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-HW46Q4AR.js";
|
|
8
8
|
import "../chunk-ACOW43IN.js";
|
|
9
9
|
import "../chunk-QI4IXJN7.js";
|
|
10
10
|
import "../chunk-B7NO5U7H.js";
|
|
@@ -60,7 +60,7 @@ process.stdin.on("end", async () => {
|
|
|
60
60
|
if (canCoordinate(agent.agentId, agent.agentRole)) {
|
|
61
61
|
process.exit(0);
|
|
62
62
|
}
|
|
63
|
-
const { fastDbInit } = await import("../fast-db-init-
|
|
63
|
+
const { fastDbInit } = await import("../fast-db-init-5VDTKVKX.js");
|
|
64
64
|
const client = await fastDbInit();
|
|
65
65
|
const saScope = sessionScopeFilter();
|
|
66
66
|
const pendingResult = await client.execute({
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
writeContinuityCheckpoint
|
|
3
|
-
} from "../chunk-
|
|
3
|
+
} from "../chunk-MQA6K7DH.js";
|
|
4
4
|
import "../chunk-FLLCEGSL.js";
|
|
5
5
|
import "../chunk-X4QO5DXP.js";
|
|
6
6
|
import "../chunk-EF4PA3TY.js";
|
|
@@ -8,14 +8,14 @@ import "../chunk-LMSRF47U.js";
|
|
|
8
8
|
import {
|
|
9
9
|
initStore,
|
|
10
10
|
vectorToBlob
|
|
11
|
-
} from "../chunk-
|
|
11
|
+
} from "../chunk-2IMUAL3X.js";
|
|
12
12
|
import "../chunk-CHCA3ZM2.js";
|
|
13
13
|
import "../chunk-Y2B6MB3J.js";
|
|
14
14
|
import "../chunk-F7LU65PQ.js";
|
|
15
15
|
import {
|
|
16
16
|
sessionScopeFilter,
|
|
17
17
|
writeNotification
|
|
18
|
-
} from "../chunk-
|
|
18
|
+
} from "../chunk-HW46Q4AR.js";
|
|
19
19
|
import "../chunk-ACOW43IN.js";
|
|
20
20
|
import "../chunk-QI4IXJN7.js";
|
|
21
21
|
import "../chunk-B7NO5U7H.js";
|
|
@@ -182,7 +182,7 @@ async function main() {
|
|
|
182
182
|
const { EXE_AI_DIR } = await import("../lib/config.js");
|
|
183
183
|
const flagPath = path.join(EXE_AI_DIR, "session-cache", "needs-backfill");
|
|
184
184
|
if (existsSync(flagPath)) {
|
|
185
|
-
const { tryAcquireWorkerSlot, registerWorkerPid } = await import("../worker-gate-
|
|
185
|
+
const { tryAcquireWorkerSlot, registerWorkerPid } = await import("../worker-gate-K5YTO2H5.js");
|
|
186
186
|
if (!tryAcquireWorkerSlot()) {
|
|
187
187
|
process.stderr.write("[summary-worker] Backfill needed but worker gate full \u2014 skipping\n");
|
|
188
188
|
} else {
|
|
@@ -289,7 +289,7 @@ main().catch((err) => {
|
|
|
289
289
|
process.stderr.write("[summary-worker] FATAL: " + (err instanceof Error ? err.message : String(err)) + "\n");
|
|
290
290
|
}).finally(async () => {
|
|
291
291
|
try {
|
|
292
|
-
const { cleanupWorkerPid } = await import("../worker-gate-
|
|
292
|
+
const { cleanupWorkerPid } = await import("../worker-gate-K5YTO2H5.js");
|
|
293
293
|
cleanupWorkerPid();
|
|
294
294
|
} catch {
|
|
295
295
|
}
|
package/dist/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
runtime_exports
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
3
|
+
} from "./chunk-6UY62EGD.js";
|
|
4
|
+
import "./chunk-O6LFXATW.js";
|
|
5
5
|
import "./chunk-YZFZDJWZ.js";
|
|
6
6
|
import "./chunk-AVE2B4DQ.js";
|
|
7
7
|
import "./chunk-NGVOA6ZQ.js";
|
|
@@ -11,7 +11,7 @@ import "./chunk-PRKVT4KN.js";
|
|
|
11
11
|
import "./chunk-HF25XPZE.js";
|
|
12
12
|
import "./chunk-O377P7GM.js";
|
|
13
13
|
import "./chunk-NUUAYDD6.js";
|
|
14
|
-
import "./chunk-
|
|
14
|
+
import "./chunk-HW46Q4AR.js";
|
|
15
15
|
import "./chunk-ACOW43IN.js";
|
|
16
16
|
import "./chunk-QI4IXJN7.js";
|
|
17
17
|
import "./chunk-B7NO5U7H.js";
|
|
@@ -27,20 +27,20 @@ import "./chunk-OPU3NYOO.js";
|
|
|
27
27
|
import "./chunk-GJV3WDWM.js";
|
|
28
28
|
import {
|
|
29
29
|
gateway_exports
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-7X6QKJGM.js";
|
|
31
31
|
import "./chunk-Q3V7K4ME.js";
|
|
32
32
|
import "./chunk-N5RRQOAC.js";
|
|
33
33
|
import "./chunk-ORCCI2VV.js";
|
|
34
34
|
import "./chunk-FLSASUV3.js";
|
|
35
|
-
import "./chunk-
|
|
35
|
+
import "./chunk-S2T7CE4P.js";
|
|
36
36
|
import "./chunk-ECSNSHZ7.js";
|
|
37
37
|
import "./chunk-RJT7H2KR.js";
|
|
38
38
|
import "./chunk-FWFFZGSC.js";
|
|
39
39
|
import "./chunk-ECGTESAP.js";
|
|
40
|
-
import "./chunk-
|
|
41
|
-
import "./chunk-
|
|
40
|
+
import "./chunk-T43SC2XX.js";
|
|
41
|
+
import "./chunk-CUKIMXQ7.js";
|
|
42
42
|
import "./chunk-YGAAZN3E.js";
|
|
43
|
-
import "./chunk-
|
|
43
|
+
import "./chunk-DXB3CB2O.js";
|
|
44
44
|
import "./chunk-ONKIWA3R.js";
|
|
45
45
|
import "./chunk-MP2AFCGL.js";
|
|
46
46
|
import "./chunk-5QKUR5KS.js";
|
|
@@ -10,8 +10,8 @@ import {
|
|
|
10
10
|
selectUnconsolidated,
|
|
11
11
|
storeConsolidation,
|
|
12
12
|
sweepExpiredTraces
|
|
13
|
-
} from "../chunk-
|
|
14
|
-
import "../chunk-
|
|
13
|
+
} from "../chunk-QOY6CTHV.js";
|
|
14
|
+
import "../chunk-2IMUAL3X.js";
|
|
15
15
|
import "../chunk-CHCA3ZM2.js";
|
|
16
16
|
import "../chunk-Y2B6MB3J.js";
|
|
17
17
|
import "../chunk-F7LU65PQ.js";
|
package/dist/lib/exe-daemon.js
CHANGED
|
@@ -51,6 +51,14 @@ var DAEMON_READ_SQL_RE = /^\s*(SELECT|WITH|EXPLAIN\s+QUERY\s+PLAN|EXPLAIN)\b/i;
|
|
|
51
51
|
var DAEMON_WRITE_SQL_RE = /^\s*(INSERT|UPDATE|DELETE|REPLACE)\b/i;
|
|
52
52
|
var DAEMON_SAFE_PRAGMA_RE = /^\s*PRAGMA\s+(quick_check|integrity_check|table_info|index_list|index_info|foreign_key_check|user_version|schema_version|database_list|journal_mode\b|wal_checkpoint\s*\(\s*PASSIVE\s*\))/i;
|
|
53
53
|
var DAEMON_FORBIDDEN_SQL_RE = /\b(ATTACH|DETACH|DROP|ALTER|VACUUM|REINDEX|CREATE|TRIGGER|LOAD_EXTENSION)\b|^\s*PRAGMA\s+(key|rekey|writable_schema|journal_mode\s*=|foreign_keys\s*=)/i;
|
|
54
|
+
var DAEMON_ALLOWED_SCHEMA_SQL_RE = [
|
|
55
|
+
// Internal telemetry tables are created lazily from hooks and daemon helpers.
|
|
56
|
+
// Keep this allowlist narrow: idempotent CREATEs for known tables/indexes only.
|
|
57
|
+
/^\s*CREATE\s+TABLE\s+IF\s+NOT\s+EXISTS\s+session_events\s*\(/i,
|
|
58
|
+
/^\s*CREATE\s+INDEX\s+IF\s+NOT\s+EXISTS\s+idx_session_events_(?:agent_time|session_index|scope_agent_time)\s+ON\s+session_events\s*\(/i,
|
|
59
|
+
/^\s*CREATE\s+TABLE\s+IF\s+NOT\s+EXISTS\s+orchestration_events\s*\(/i,
|
|
60
|
+
/^\s*CREATE\s+INDEX\s+IF\s+NOT\s+EXISTS\s+idx_orch_events_(?:ts|task|agent|type)\s+ON\s+orchestration_events\s*\(/i
|
|
61
|
+
];
|
|
54
62
|
var UPDATE_DELETE_RE = /^\s*(UPDATE|DELETE)\b/i;
|
|
55
63
|
var TAUTOLOGICAL_WHERE_RE = /\bWHERE\s+(?:\(?\s*)?(?:1\s*=\s*1|TRUE\b|'[^']*'\s*=\s*'[^']*'|"[^"]*"\s*=\s*"[^"]*")/i;
|
|
56
64
|
var OR_TAUTOLOGY_RE = /\bOR\s+(?:\(?\s*)?(?:1\s*=\s*1|TRUE\b|'[^']*'\s*=\s*'[^']*'|"[^"]*"\s*=\s*"[^"]*")/i;
|
|
@@ -144,6 +152,7 @@ function validateDaemonDbSql(sql) {
|
|
|
144
152
|
if (stripTrailingStatementSemicolon(structural).includes(";")) {
|
|
145
153
|
return "multi-statement SQL is not allowed over daemon db-execute";
|
|
146
154
|
}
|
|
155
|
+
if (DAEMON_ALLOWED_SCHEMA_SQL_RE.some((re) => re.test(structural))) return null;
|
|
147
156
|
if (DAEMON_FORBIDDEN_SQL_RE.test(structural)) {
|
|
148
157
|
return "daemon db-execute/db-batch blocks schema, attachment, extension, and destructive maintenance SQL";
|
|
149
158
|
}
|
|
@@ -1965,9 +1974,10 @@ async function startMcpHttpServer() {
|
|
|
1965
1974
|
}
|
|
1966
1975
|
return;
|
|
1967
1976
|
}
|
|
1968
|
-
if (url.pathname === "/v1/ping" && (req.method === "GET" || req.method === "POST")) {
|
|
1977
|
+
if (url.pathname === "/v1/ping" && (req.method === "GET" || req.method === "POST" || req.method === "HEAD")) {
|
|
1969
1978
|
res.writeHead(200, { "Content-Type": "application/json" });
|
|
1970
|
-
|
|
1979
|
+
if (req.method === "HEAD") res.end();
|
|
1980
|
+
else res.end(JSON.stringify({ status: "ok", pid: process.pid, uptime: Math.floor(process.uptime()) }));
|
|
1971
1981
|
return;
|
|
1972
1982
|
}
|
|
1973
1983
|
if (url.pathname === "/v1/heartbeat" && req.method === "POST") {
|
|
@@ -2483,13 +2493,13 @@ async function ensureStoreForPolling() {
|
|
|
2483
2493
|
}
|
|
2484
2494
|
}
|
|
2485
2495
|
async function startReviewPolling() {
|
|
2486
|
-
const polling = await import("../review-polling-
|
|
2496
|
+
const polling = await import("../review-polling-ZKYFETP3.js");
|
|
2487
2497
|
const state = {
|
|
2488
2498
|
lastIntercomSent: /* @__PURE__ */ new Map(),
|
|
2489
2499
|
lastNudgeSent: /* @__PURE__ */ new Map(),
|
|
2490
2500
|
intervalMs: REVIEW_POLL_INTERVAL_MS
|
|
2491
2501
|
};
|
|
2492
|
-
const { pollReviewNudge, createReviewNudgeRealDeps, loadNudgeState } = await import("../daemon-orchestration-
|
|
2502
|
+
const { pollReviewNudge, createReviewNudgeRealDeps, loadNudgeState } = await import("../daemon-orchestration-5KUKQOZ4.js");
|
|
2493
2503
|
const nudgeState = loadNudgeState();
|
|
2494
2504
|
const tick = async () => traceDaemonTimer("review_polling", async () => {
|
|
2495
2505
|
fired("review_polling");
|
|
@@ -2531,7 +2541,7 @@ function startSessionTTL() {
|
|
|
2531
2541
|
if (!await ensureStoreForPolling()) return;
|
|
2532
2542
|
try {
|
|
2533
2543
|
const { getClient } = await import("./database.js");
|
|
2534
|
-
const { checkSessionTTL, createSessionTTLRealDeps } = await import("../daemon-orchestration-
|
|
2544
|
+
const { checkSessionTTL, createSessionTTLRealDeps } = await import("../daemon-orchestration-5KUKQOZ4.js");
|
|
2535
2545
|
const deps = createSessionTTLRealDeps(getClient);
|
|
2536
2546
|
const killed = await checkSessionTTL(deps);
|
|
2537
2547
|
if (killed.length > 0) acted("session_ttl");
|
|
@@ -2580,7 +2590,7 @@ function startIdleKill() {
|
|
|
2580
2590
|
const cfg = await getCachedConfig();
|
|
2581
2591
|
if (!cfg) return;
|
|
2582
2592
|
const { getClient } = await import("./database.js");
|
|
2583
|
-
const { pollIdleKill, createIdleKillRealDeps } = await import("../daemon-orchestration-
|
|
2593
|
+
const { pollIdleKill, createIdleKillRealDeps } = await import("../daemon-orchestration-5KUKQOZ4.js");
|
|
2584
2594
|
const liveSessions = (await getTmuxSessionsAsync()).filter((s) => s.includes("-"));
|
|
2585
2595
|
const [paneCache, aliveSessions] = await Promise.all([
|
|
2586
2596
|
batchCapturePanes(liveSessions, 5),
|
|
@@ -2807,7 +2817,7 @@ function startSkillRefinement() {
|
|
|
2807
2817
|
fired("skill_refinement");
|
|
2808
2818
|
try {
|
|
2809
2819
|
if (!await ensureStoreForPolling()) return;
|
|
2810
|
-
const { runSkillRefinement } = await import("../skill-refinement-
|
|
2820
|
+
const { runSkillRefinement } = await import("../skill-refinement-QHOS6CGQ.js");
|
|
2811
2821
|
const result = await runSkillRefinement();
|
|
2812
2822
|
if (result.reviewed > 0) {
|
|
2813
2823
|
acted("skill_refinement");
|
|
@@ -3195,7 +3205,7 @@ function startOrphanReaper() {
|
|
|
3195
3205
|
const tick = async () => traceDaemonTimer("orphan_reaper", async () => {
|
|
3196
3206
|
fired("orphan_reaper");
|
|
3197
3207
|
try {
|
|
3198
|
-
const { reapOrphanedMcpProcesses, createOrphanReaperRealDeps } = await import("../daemon-orchestration-
|
|
3208
|
+
const { reapOrphanedMcpProcesses, createOrphanReaperRealDeps } = await import("../daemon-orchestration-5KUKQOZ4.js");
|
|
3199
3209
|
const deps = createOrphanReaperRealDeps();
|
|
3200
3210
|
const reaped = await reapOrphanedMcpProcesses(deps);
|
|
3201
3211
|
if (reaped.length > 0) acted("orphan_reaper");
|
|
@@ -3219,7 +3229,7 @@ function startZombieAgentReaper() {
|
|
|
3219
3229
|
const tick = async () => traceDaemonTimer("zombie_agent_reaper", async () => {
|
|
3220
3230
|
fired("zombie_agent_reaper");
|
|
3221
3231
|
try {
|
|
3222
|
-
const { reapZombieAgentProcesses, createZombieAgentReaperRealDeps } = await import("../daemon-orchestration-
|
|
3232
|
+
const { reapZombieAgentProcesses, createZombieAgentReaperRealDeps } = await import("../daemon-orchestration-5KUKQOZ4.js");
|
|
3223
3233
|
const deps = createZombieAgentReaperRealDeps();
|
|
3224
3234
|
const reaped = reapZombieAgentProcesses(deps);
|
|
3225
3235
|
if (reaped.length > 0) acted("zombie_agent_reaper");
|
|
@@ -3242,7 +3252,7 @@ function startWorktreeReaper() {
|
|
|
3242
3252
|
const tick = async () => traceDaemonTimer("worktree_reaper", async () => {
|
|
3243
3253
|
fired("worktree_reaper");
|
|
3244
3254
|
try {
|
|
3245
|
-
const { reapOrphanedWorktrees, createWorktreeReaperRealDeps } = await import("../daemon-orchestration-
|
|
3255
|
+
const { reapOrphanedWorktrees, createWorktreeReaperRealDeps } = await import("../daemon-orchestration-5KUKQOZ4.js");
|
|
3246
3256
|
const deps = await createWorktreeReaperRealDeps();
|
|
3247
3257
|
const result = await reapOrphanedWorktrees(deps);
|
|
3248
3258
|
if (result.pruned.length > 0) {
|
|
@@ -3297,7 +3307,7 @@ function startStuckTaskRelease() {
|
|
|
3297
3307
|
if (!await ensureStoreForPolling()) return;
|
|
3298
3308
|
try {
|
|
3299
3309
|
const { getClient } = await import("./database.js");
|
|
3300
|
-
const { releaseStuckTasks, createStuckTaskRealDeps } = await import("../daemon-orchestration-
|
|
3310
|
+
const { releaseStuckTasks, createStuckTaskRealDeps } = await import("../daemon-orchestration-5KUKQOZ4.js");
|
|
3301
3311
|
const deps = createStuckTaskRealDeps(getClient);
|
|
3302
3312
|
const released = await releaseStuckTasks(deps);
|
|
3303
3313
|
if (released.length > 0) {
|
|
@@ -3401,12 +3411,12 @@ function startTaskEnforcementScanner() {
|
|
|
3401
3411
|
const tick = async () => traceDaemonTimer("task_enforcement", async () => {
|
|
3402
3412
|
fired("task_enforcement");
|
|
3403
3413
|
try {
|
|
3404
|
-
const { runTaskEnforcementTick } = await import("../task-enforcement-
|
|
3414
|
+
const { runTaskEnforcementTick } = await import("../task-enforcement-HVY36QRD.js");
|
|
3405
3415
|
const { getTransport } = await import("./transport.js");
|
|
3406
3416
|
const { loadAgentConfig } = await import("./agent-config.js");
|
|
3407
3417
|
const { getClient } = await import("./database.js");
|
|
3408
3418
|
const { loadEmployeesSync } = await import("./employees.js");
|
|
3409
|
-
const { sessionScopeFilter } = await import("../task-scope-
|
|
3419
|
+
const { sessionScopeFilter } = await import("../task-scope-ODSOEGTH.js");
|
|
3410
3420
|
const transport = getTransport();
|
|
3411
3421
|
const allSessions = (await getTmuxSessionsAsync()).filter((s) => s.includes("-"));
|
|
3412
3422
|
const [paneCache, aliveSessions] = await Promise.all([
|
|
@@ -4147,7 +4157,7 @@ try {
|
|
|
4147
4157
|
fired("orphan_task_cleanup");
|
|
4148
4158
|
try {
|
|
4149
4159
|
if (!await ensureStoreForPolling()) return;
|
|
4150
|
-
const { cleanOrphanedTaskFiles, checkTaskFileConsistency } = await import("../tasks-crud-
|
|
4160
|
+
const { cleanOrphanedTaskFiles, checkTaskFileConsistency } = await import("../tasks-crud-RIUHZJGR.js");
|
|
4151
4161
|
const count = await cleanOrphanedTaskFiles();
|
|
4152
4162
|
if (count > 0) {
|
|
4153
4163
|
acted("orphan_task_cleanup");
|
|
@@ -5,8 +5,8 @@ import {
|
|
|
5
5
|
recentRecords,
|
|
6
6
|
rrfMerge,
|
|
7
7
|
rrfMergeMulti
|
|
8
|
-
} from "../chunk-
|
|
9
|
-
import "../chunk-
|
|
8
|
+
} from "../chunk-RSHVFBKD.js";
|
|
9
|
+
import "../chunk-2IMUAL3X.js";
|
|
10
10
|
import "../chunk-CHCA3ZM2.js";
|
|
11
11
|
import "../chunk-Y2B6MB3J.js";
|
|
12
12
|
import "../chunk-F7LU65PQ.js";
|
package/dist/lib/messaging.js
CHANGED
|
@@ -12,8 +12,8 @@ import {
|
|
|
12
12
|
retryPendingMessages,
|
|
13
13
|
sendMessage,
|
|
14
14
|
setWsClientSend
|
|
15
|
-
} from "../chunk-
|
|
16
|
-
import "../chunk-
|
|
15
|
+
} from "../chunk-R2MZDZTQ.js";
|
|
16
|
+
import "../chunk-HW46Q4AR.js";
|
|
17
17
|
import "../chunk-ACOW43IN.js";
|
|
18
18
|
import "../chunk-QI4IXJN7.js";
|
|
19
19
|
import "../chunk-B7NO5U7H.js";
|
package/dist/lib/schedules.js
CHANGED
|
@@ -3,8 +3,8 @@ import {
|
|
|
3
3
|
deleteSchedule,
|
|
4
4
|
listSchedules,
|
|
5
5
|
parseHumanCron
|
|
6
|
-
} from "../chunk-
|
|
7
|
-
import "../chunk-
|
|
6
|
+
} from "../chunk-BN3HRSEU.js";
|
|
7
|
+
import "../chunk-2IMUAL3X.js";
|
|
8
8
|
import "../chunk-CHCA3ZM2.js";
|
|
9
9
|
import "../chunk-Y2B6MB3J.js";
|
|
10
10
|
import "../chunk-F7LU65PQ.js";
|
|
@@ -8,8 +8,8 @@ import {
|
|
|
8
8
|
hashSignature,
|
|
9
9
|
storeTrajectory,
|
|
10
10
|
sweepTrajectories
|
|
11
|
-
} from "../chunk-
|
|
12
|
-
import "../chunk-
|
|
11
|
+
} from "../chunk-RTGN42GD.js";
|
|
12
|
+
import "../chunk-BFLBZGPZ.js";
|
|
13
13
|
import "../chunk-4GXXYDNU.js";
|
|
14
14
|
import "../chunk-OSYUNKBM.js";
|
|
15
15
|
import "../chunk-FXU7JOXK.js";
|
package/dist/lib/store.js
CHANGED
package/dist/lib/tasks.js
CHANGED
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
createTask,
|
|
3
3
|
deleteTask,
|
|
4
4
|
updateTask
|
|
5
|
-
} from "../chunk-
|
|
5
|
+
} from "../chunk-IFSAR5IX.js";
|
|
6
6
|
import {
|
|
7
7
|
cleanupOrphanedReviews,
|
|
8
8
|
countNewPendingReviewsSince,
|
|
@@ -19,7 +19,7 @@ import {
|
|
|
19
19
|
slugify,
|
|
20
20
|
updateTaskStatus,
|
|
21
21
|
writeCheckpoint
|
|
22
|
-
} from "../chunk-
|
|
22
|
+
} from "../chunk-HW46Q4AR.js";
|
|
23
23
|
import "../chunk-ACOW43IN.js";
|
|
24
24
|
import "../chunk-QI4IXJN7.js";
|
|
25
25
|
import "../chunk-B7NO5U7H.js";
|