poe-code 3.0.183 → 3.0.184
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/cli/commands/pipeline-init.d.ts +0 -1
- package/dist/cli/commands/pipeline-init.js +3 -1
- package/dist/cli/commands/pipeline-init.js.map +1 -1
- package/dist/cli/commands/pipeline.js +134 -90
- package/dist/cli/commands/pipeline.js.map +1 -1
- package/dist/index.js +1116 -699
- package/dist/index.js.map +4 -4
- package/dist/providers/poe-agent.js +33 -4
- package/dist/providers/poe-agent.js.map +3 -3
- package/dist/sdk/pipeline.d.ts +3 -3
- package/dist/sdk/pipeline.js +126 -9
- package/dist/sdk/pipeline.js.map +1 -1
- package/dist/templates/pipeline/SKILL_plan.md +26 -13
- package/dist/templates/pipeline/steps.yaml.mustache +5 -2
- package/package.json +1 -1
- package/packages/design-system/dist/dashboard/components/stats-pane.js +2 -1
- package/packages/design-system/dist/dashboard/types.d.ts +1 -0
|
@@ -15331,9 +15331,10 @@ function statsToLines(stats, width) {
|
|
|
15331
15331
|
}
|
|
15332
15332
|
const mutedStyle = getToneStyle("muted");
|
|
15333
15333
|
const totalTokens = stats.tokensIn + stats.tokensOut;
|
|
15334
|
+
const iterationsLabel = stats.iterationsLabel ?? "Iteration";
|
|
15334
15335
|
const lines = [
|
|
15335
15336
|
createKeyValueLine("Status", formatStatus(stats.status), width, getStatusStyle(stats.status)),
|
|
15336
|
-
createKeyValueLine(
|
|
15337
|
+
createKeyValueLine(iterationsLabel, formatNumber(stats.iterations), width),
|
|
15337
15338
|
createKeyValueLine("Elapsed", formatElapsed(stats.elapsedMs), width),
|
|
15338
15339
|
createBlankLine(),
|
|
15339
15340
|
createKeyValueLine("Tokens In", formatNumber(stats.tokensIn), width),
|
|
@@ -20113,8 +20114,35 @@ init_src4();
|
|
|
20113
20114
|
|
|
20114
20115
|
// packages/agent-kit/src/lock.ts
|
|
20115
20116
|
import * as fsPromises4 from "node:fs/promises";
|
|
20116
|
-
function
|
|
20117
|
-
|
|
20117
|
+
function createAbortError3() {
|
|
20118
|
+
const error2 = new Error("The operation was aborted.");
|
|
20119
|
+
error2.name = "AbortError";
|
|
20120
|
+
return error2;
|
|
20121
|
+
}
|
|
20122
|
+
function throwIfAborted(signal) {
|
|
20123
|
+
if (signal?.aborted) {
|
|
20124
|
+
throw createAbortError3();
|
|
20125
|
+
}
|
|
20126
|
+
}
|
|
20127
|
+
function sleep(ms, signal) {
|
|
20128
|
+
if (!signal) {
|
|
20129
|
+
return new Promise((resolve2) => setTimeout(resolve2, ms));
|
|
20130
|
+
}
|
|
20131
|
+
if (signal.aborted) {
|
|
20132
|
+
return Promise.reject(createAbortError3());
|
|
20133
|
+
}
|
|
20134
|
+
return new Promise((resolve2, reject) => {
|
|
20135
|
+
const timeoutId = setTimeout(() => {
|
|
20136
|
+
signal.removeEventListener("abort", onAbort);
|
|
20137
|
+
resolve2();
|
|
20138
|
+
}, ms);
|
|
20139
|
+
const onAbort = () => {
|
|
20140
|
+
clearTimeout(timeoutId);
|
|
20141
|
+
signal.removeEventListener("abort", onAbort);
|
|
20142
|
+
reject(createAbortError3());
|
|
20143
|
+
};
|
|
20144
|
+
signal.addEventListener("abort", onAbort, { once: true });
|
|
20145
|
+
});
|
|
20118
20146
|
}
|
|
20119
20147
|
function backoff(attempt, minTimeout, maxTimeout) {
|
|
20120
20148
|
const delay = Math.min(maxTimeout, minTimeout * Math.pow(2, attempt));
|
|
@@ -20156,6 +20184,7 @@ async function lockWorkflow(docPath, options = {}) {
|
|
|
20156
20184
|
const staleMs = options.staleMs ?? 3e4;
|
|
20157
20185
|
const lockPath = `${docPath}.lock`;
|
|
20158
20186
|
for (let attempt = 0; attempt <= retries; attempt += 1) {
|
|
20187
|
+
throwIfAborted(options.signal);
|
|
20159
20188
|
try {
|
|
20160
20189
|
await fs3.mkdir(lockPath);
|
|
20161
20190
|
let released = false;
|
|
@@ -20184,7 +20213,7 @@ async function lockWorkflow(docPath, options = {}) {
|
|
|
20184
20213
|
continue;
|
|
20185
20214
|
}
|
|
20186
20215
|
if (attempt < retries) {
|
|
20187
|
-
await sleep(backoff(attempt, minTimeout, maxTimeout));
|
|
20216
|
+
await sleep(backoff(attempt, minTimeout, maxTimeout), options.signal);
|
|
20188
20217
|
}
|
|
20189
20218
|
}
|
|
20190
20219
|
}
|