wildcrane-runner 0.6.12 → 0.6.13
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/akb/dist/kanban.mjs +17 -11
- package/dist/akb/package.json +1 -1
- package/dist/launcher.mjs +2 -2
- package/dist/runner.mjs +16 -8
- package/package.json +1 -1
package/dist/akb/dist/kanban.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
// ai4kanban 0.11.
|
|
2
|
+
// ai4kanban 0.11.10 — built by runner/scripts/build.mjs. Do not edit.
|
|
3
3
|
import { createRequire as __ai4kanbanRequire } from 'node:module'
|
|
4
4
|
const require = __ai4kanbanRequire(import.meta.url)
|
|
5
5
|
var __create = Object.create;
|
|
@@ -5477,8 +5477,8 @@ var init_package = __esm({
|
|
|
5477
5477
|
"../cli/package.json"() {
|
|
5478
5478
|
package_default = {
|
|
5479
5479
|
name: "wildcrane",
|
|
5480
|
-
version: "0.11.
|
|
5481
|
-
akbContract:
|
|
5480
|
+
version: "0.11.10",
|
|
5481
|
+
akbContract: 5,
|
|
5482
5482
|
description: "WildCrane's `akb` command \u2014 scaffold the Markdown board under docs/kanban/, put an agent on a card, and carry the flows the agent works by.",
|
|
5483
5483
|
keywords: [
|
|
5484
5484
|
"kanban",
|
|
@@ -18993,7 +18993,7 @@ function requestOf(record) {
|
|
|
18993
18993
|
pictures: record.pictures
|
|
18994
18994
|
};
|
|
18995
18995
|
}
|
|
18996
|
-
async function openResume(id) {
|
|
18996
|
+
async function openResume(id, requireSession = false) {
|
|
18997
18997
|
const restore = [];
|
|
18998
18998
|
const runs = withRuns((all2) => {
|
|
18999
18999
|
reap(all2, [], restore);
|
|
@@ -19013,6 +19013,9 @@ async function openResume(id) {
|
|
|
19013
19013
|
if (refused) return refused;
|
|
19014
19014
|
}
|
|
19015
19015
|
const retrying = lacksSession(prev);
|
|
19016
|
+
if (requireSession && !resumeSessionId(prev)) {
|
|
19017
|
+
return refusal("runNoSession", "the original conversation cannot be resumed; no new conversation was started");
|
|
19018
|
+
}
|
|
19016
19019
|
const ask2 = retrying && prev.status !== "stopped" ? retryAsk(prev) : void 0;
|
|
19017
19020
|
if (retrying && !ask2) return refusal("runNoSession", "that run never reported a session id to continue by");
|
|
19018
19021
|
const ended = endedDeliveryRefusal(prev);
|
|
@@ -22515,7 +22518,7 @@ function localBoard() {
|
|
|
22515
22518
|
const no = checkWrite({ board: true }, env2, boardRevision());
|
|
22516
22519
|
if (no) return no;
|
|
22517
22520
|
const res = await resumeDelivery(deliveryId);
|
|
22518
|
-
if (!res.ok) return opRefused(new Error(res.error || "the delivery could not be carried on"));
|
|
22521
|
+
if (!res.ok) return { ...opRefused(new Error(res.error || "the delivery could not be carried on")), reason: res.reason, args: res.args };
|
|
22519
22522
|
return opOk(boardRevision(), { deliveryId: res.deliveryId, landed: res.landed, carryOn: res.carryOn });
|
|
22520
22523
|
},
|
|
22521
22524
|
async discardDelivery(deliveryId, env2) {
|
|
@@ -23647,8 +23650,8 @@ function open2(req, sessionId) {
|
|
|
23647
23650
|
markSpawned(run2.sessionId, pid);
|
|
23648
23651
|
return { run: run2, spawned: pid !== void 0 };
|
|
23649
23652
|
}
|
|
23650
|
-
async function startResume(id) {
|
|
23651
|
-
const opened = await openResume(id);
|
|
23653
|
+
async function startResume(id, requireSession = false) {
|
|
23654
|
+
const opened = await openResume(id, requireSession);
|
|
23652
23655
|
if ("error" in opened) return opened;
|
|
23653
23656
|
const pid = spawnWatcher(opened.run.sessionId);
|
|
23654
23657
|
markSpawned(opened.run.sessionId, pid);
|
|
@@ -27588,13 +27591,13 @@ function readRequest(action, args, opts) {
|
|
|
27588
27591
|
return { req, follow: follow2, print };
|
|
27589
27592
|
}
|
|
27590
27593
|
async function cmdResume(id, opts) {
|
|
27591
|
-
const opened = await startResume(id ?? "last");
|
|
27594
|
+
const opened = await startResume(id ?? "last", opts.requireSession);
|
|
27592
27595
|
if ("error" in opened) die(opened.error, { kind: "run-refused" });
|
|
27593
27596
|
const { run: run2 } = opened;
|
|
27594
27597
|
if (!opened.spawned) die(`couldn't start a process for run ${run2.sessionId}`, { kind: "spawn-failed" });
|
|
27595
27598
|
const within = run2.deliveryId ? ` in delivery ${run2.deliveryId}` : "";
|
|
27596
27599
|
say(run2.resumedFrom ? `continuing ${short(run2.resumedFrom)} \u2014 run ${run2.sessionId}${within}` : `trying again \u2014 run ${run2.sessionId}${within}`);
|
|
27597
|
-
if (opts.follow === true) return await followStarted(run2.sessionId, "akb");
|
|
27600
|
+
if (opts.follow === true) return await followStarted(run2.sessionId, "akb", opts.events === true);
|
|
27598
27601
|
return { sessionId: run2.sessionId, resumedFrom: run2.resumedFrom };
|
|
27599
27602
|
}
|
|
27600
27603
|
async function cmdCancel(named2) {
|
|
@@ -27608,7 +27611,10 @@ async function cmdCancel(named2) {
|
|
|
27608
27611
|
}
|
|
27609
27612
|
async function cmdResumeDelivery(named2) {
|
|
27610
27613
|
const res = await resumeBoardDelivery(named2);
|
|
27611
|
-
if (!res.ok) die(res.error ?? "that delivery could not be carried on", {
|
|
27614
|
+
if (!res.ok) die(res.error ?? "that delivery could not be carried on", {
|
|
27615
|
+
kind: "run-refused",
|
|
27616
|
+
...res.kind === "refused" ? { reason: res.reason, args: res.args } : {}
|
|
27617
|
+
});
|
|
27612
27618
|
if (res.landed) {
|
|
27613
27619
|
say(`delivery ${res.deliveryId} is done \u2014 its changes were already on the target branch.`);
|
|
27614
27620
|
return { deliveryId: res.deliveryId, landed: true };
|
|
@@ -28603,7 +28609,7 @@ function declareRunning(run2, cli) {
|
|
|
28603
28609
|
});
|
|
28604
28610
|
verb("resume").argument("[id]", RUN_ID, String).summary("continue a run that failed, was cut off or was stopped").description(
|
|
28605
28611
|
"The one command that reaches past the board: it picks the coding agent's own session back up \u2014 the conversation it was having, with everything it had already read \u2014 while the board counts the work as a fresh run. Before resuming a creation with no card, check sign-in, project access and connection. A refusal starts no run and leaves triage unchanged. Keep the triage source and request identity; reuse any task already created in Cloud. Repairing an existing card creates no other task. Example: akb run resume abc12345"
|
|
28606
|
-
).option("-f, --follow", "watch its log instead of returning").action(async function(...vals) {
|
|
28612
|
+
).option("-f, --follow", "watch its log instead of returning").option("--events", "with --follow: print its structured events, one JSON object per line").option("--require-session", "refuse if the original conversation cannot be resumed").action(async function(...vals) {
|
|
28607
28613
|
const [id] = positional(vals);
|
|
28608
28614
|
await onBoard2(this, cli, () => cmdResume(id, this.opts()));
|
|
28609
28615
|
});
|
package/dist/akb/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"wildcrane","version":"0.11.
|
|
1
|
+
{"name":"wildcrane","version":"0.11.10","akbContract":5,"type":"module","private":true}
|
package/dist/launcher.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// wildcrane-runner 0.6.
|
|
1
|
+
// wildcrane-runner 0.6.13 — built by runner/scripts/build.mjs. Do not edit.
|
|
2
2
|
import { createRequire as __ai4kanbanRequire } from 'node:module'
|
|
3
3
|
const require = __ai4kanbanRequire(import.meta.url)
|
|
4
4
|
|
|
@@ -107,7 +107,7 @@ function status(line) {
|
|
|
107
107
|
}
|
|
108
108
|
|
|
109
109
|
// src/protocol.ts
|
|
110
|
-
var VERSION = true ? "0.6.
|
|
110
|
+
var VERSION = true ? "0.6.13" : "0.0.0";
|
|
111
111
|
var EXIT_REFUSED = 10;
|
|
112
112
|
var EXIT_OUTDATED = 11;
|
|
113
113
|
var EXIT_UPDATE = 12;
|
package/dist/runner.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// wildcrane-runner 0.6.
|
|
1
|
+
// wildcrane-runner 0.6.13 — built by runner/scripts/build.mjs. Do not edit.
|
|
2
2
|
import { createRequire as __ai4kanbanRequire } from 'node:module'
|
|
3
3
|
const require = __ai4kanbanRequire(import.meta.url)
|
|
4
4
|
var __create = Object.create;
|
|
@@ -84435,9 +84435,9 @@ function status(line) {
|
|
|
84435
84435
|
}
|
|
84436
84436
|
|
|
84437
84437
|
// src/protocol.ts
|
|
84438
|
-
var VERSION = true ? "0.6.
|
|
84439
|
-
var AKB_VERSION = true ? "0.11.
|
|
84440
|
-
var AKB_CONTRACT = true ?
|
|
84438
|
+
var VERSION = true ? "0.6.13" : "0.0.0";
|
|
84439
|
+
var AKB_VERSION = true ? "0.11.10" : "0.0.0";
|
|
84440
|
+
var AKB_CONTRACT = true ? 5 : 0;
|
|
84441
84441
|
var EXIT_REFUSED = 10;
|
|
84442
84442
|
var EXIT_OUTDATED = 11;
|
|
84443
84443
|
var EXIT_UPDATE = 12;
|
|
@@ -85923,8 +85923,8 @@ function createTail(log) {
|
|
|
85923
85923
|
// ../cli/package.json
|
|
85924
85924
|
var package_default = {
|
|
85925
85925
|
name: "wildcrane",
|
|
85926
|
-
version: "0.11.
|
|
85927
|
-
akbContract:
|
|
85926
|
+
version: "0.11.10",
|
|
85927
|
+
akbContract: 5,
|
|
85928
85928
|
description: "WildCrane's `akb` command \u2014 scaffold the Markdown board under docs/kanban/, put an agent on a card, and carry the flows the agent works by.",
|
|
85929
85929
|
keywords: [
|
|
85930
85930
|
"kanban",
|
|
@@ -92802,16 +92802,24 @@ ${draftLine(ws)}
|
|
|
92802
92802
|
}
|
|
92803
92803
|
if (verb === "revise" && !text3) return fail("Say what to change.");
|
|
92804
92804
|
let note = verb === "resolve" || verb === "revise" ? text3 : "";
|
|
92805
|
+
let continuation;
|
|
92805
92806
|
if (verb === "implement" && flow.resume) {
|
|
92806
|
-
const
|
|
92807
|
+
const restored = await akb(["delivery", "resume", String(id2), "--json"]);
|
|
92808
|
+
const resumed = answerOf2(restored);
|
|
92807
92809
|
if (io.lost()) return fail("");
|
|
92808
92810
|
if (resumed?.landed) return { ok: true, report: { card: id2 } };
|
|
92811
|
+
if (restored.code !== 0 && resumed?.error?.reason !== "deliveryActive") return fail(resumed?.error?.message ?? refusal(restored));
|
|
92812
|
+
const deliveryId = resumed?.deliveryId ?? resumed?.error?.args?.id;
|
|
92813
|
+
if (!deliveryId) return fail("\u627E\u4E0D\u5230\u4E0A\u6B21\u6784\u5EFA\u7684\u4EA4\u4ED8\u8BB0\u5F55\uFF0C\u65E0\u6CD5\u6062\u590D\u539F\u5BF9\u8BDD\u3002");
|
|
92814
|
+
const previous = answerOf2(await akb(["run", "list", "--card", String(id2), "--all", "--json"]))?.runs?.filter((r2) => ["implement", "conflict", "hook"].includes(r2.action ?? "") && r2.deliveryId === deliveryId).sort((a3, b2) => (b2.startedAt ?? 0) - (a3.startedAt ?? 0))[0];
|
|
92815
|
+
if (!previous) return fail("\u627E\u4E0D\u5230\u4E0A\u6B21\u6784\u5EFA\u7684\u8FD0\u884C\u8BB0\u5F55\uFF0C\u65E0\u6CD5\u6062\u590D\u539F\u5BF9\u8BDD\u3002");
|
|
92816
|
+
continuation = previous.status === "done" ? ["run", "log", previous.sessionId] : ["run", "resume", previous.sessionId, "--require-session"];
|
|
92809
92817
|
} else if (verb === "implement" && text3) {
|
|
92810
92818
|
const resolved = await akb(["card", "resolve", String(id2), "--follow", "--events", "--json", "--", text3], true);
|
|
92811
92819
|
if (io.lost()) return fail("");
|
|
92812
92820
|
if (resolved.code !== 0) note = text3;
|
|
92813
92821
|
}
|
|
92814
|
-
const ran = await akb(["card", verb, String(id2), "--follow", "--events", "--json", ...carryArgs(verb), ...note ? ["--", note] : []], true);
|
|
92822
|
+
const ran = await akb(continuation ? [...continuation, "--follow", "--events", "--json"] : ["card", verb, String(id2), "--follow", "--events", "--json", ...carryArgs(verb), ...note ? ["--", note] : []], true);
|
|
92815
92823
|
if (io.lost()) return fail("");
|
|
92816
92824
|
const answer = answerOf2(ran);
|
|
92817
92825
|
if (verb === "implement") {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "wildcrane-runner",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.13",
|
|
4
4
|
"description": "WildCrane's Local Runner — connects this computer to WildCrane and runs its jobs on your local Claude Code, Codex, OpenCode or Cursor.",
|
|
5
5
|
"license": "FSL-1.1-ALv2",
|
|
6
6
|
"homepage": "https://wildcrane.ai/",
|