@clawos-dev/clawd 0.2.650 → 0.2.651
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.cjs +11 -1
- package/package.json +1 -1
package/dist/cli.cjs
CHANGED
|
@@ -53677,6 +53677,7 @@ function driveCodexThread(opts) {
|
|
|
53677
53677
|
let threadId = ctx.toolSessionId;
|
|
53678
53678
|
let turnId;
|
|
53679
53679
|
let turnOpen = false;
|
|
53680
|
+
let activeTrace;
|
|
53680
53681
|
const firstByte = createFirstByteClock(opts.now);
|
|
53681
53682
|
const approvalIds = /* @__PURE__ */ new Map();
|
|
53682
53683
|
const subagents = new CodexSubagentTracker();
|
|
@@ -53705,6 +53706,7 @@ function driveCodexThread(opts) {
|
|
|
53705
53706
|
if (threadId !== void 0 && ownerThreadId === threadId && method === "turn/started") {
|
|
53706
53707
|
const id = params?.turn?.id;
|
|
53707
53708
|
if (id) turnId = id;
|
|
53709
|
+
activeTrace?.("native.turn.started", { threadId, turnId });
|
|
53708
53710
|
}
|
|
53709
53711
|
const events = route === "subagent" && ownerThreadId ? subagents.handleChildNotification(ownerThreadId, method, params) : route === "foreground" ? [
|
|
53710
53712
|
...subagents.handleParentNotification(method, params),
|
|
@@ -53719,6 +53721,8 @@ function driveCodexThread(opts) {
|
|
|
53719
53721
|
if (!subagentsRunning) opts.onSubagentsIdle?.();
|
|
53720
53722
|
}
|
|
53721
53723
|
if (route === "foreground" && method === "turn/completed") {
|
|
53724
|
+
activeTrace?.("native.turn.completed", { threadId, turnId, status: turnOutcomeOf(params) });
|
|
53725
|
+
activeTrace = void 0;
|
|
53722
53726
|
turnOpen = false;
|
|
53723
53727
|
opts.onTurnCompleted?.(turnOutcomeOf(params), firstByte.afterFirstByteMs());
|
|
53724
53728
|
}
|
|
@@ -53764,6 +53768,8 @@ function driveCodexThread(opts) {
|
|
|
53764
53768
|
})().catch((e) => sink.onError(`codex app-server init failed: ${e.message}`));
|
|
53765
53769
|
const session = {
|
|
53766
53770
|
startTurn(text) {
|
|
53771
|
+
const trace = opts.onTurnTrace?.();
|
|
53772
|
+
trace?.("native.ready.waiting");
|
|
53767
53773
|
const model = opts.turnModel?.();
|
|
53768
53774
|
const modelSelected = opts.onTurnModelSelected?.();
|
|
53769
53775
|
void ready.then(() => {
|
|
@@ -53772,8 +53778,10 @@ function driveCodexThread(opts) {
|
|
|
53772
53778
|
if (opened) {
|
|
53773
53779
|
turnOpen = true;
|
|
53774
53780
|
firstByte.reset();
|
|
53781
|
+
activeTrace = trace;
|
|
53775
53782
|
opts.onTurnStarting?.();
|
|
53776
53783
|
}
|
|
53784
|
+
trace?.("native.query.sent", { threadId });
|
|
53777
53785
|
void client.request("turn/start", {
|
|
53778
53786
|
threadId,
|
|
53779
53787
|
input: turnStartInput(text, opts.imageInput),
|
|
@@ -53781,9 +53789,11 @@ function driveCodexThread(opts) {
|
|
|
53781
53789
|
...effort ? { effort } : {},
|
|
53782
53790
|
...model ? { model } : {}
|
|
53783
53791
|
}).then(() => {
|
|
53792
|
+
trace?.("native.query.accepted", { threadId });
|
|
53784
53793
|
if (model) modelSelected?.(model);
|
|
53785
53794
|
}).catch((e) => {
|
|
53786
53795
|
if (exited) return;
|
|
53796
|
+
trace?.("native.query.failed", { threadId });
|
|
53787
53797
|
sink.pushEvents([
|
|
53788
53798
|
{ kind: "error", message: `turn/start failed: ${e.message}` },
|
|
53789
53799
|
{ kind: "turn_end" }
|
|
@@ -74406,7 +74416,7 @@ function computeMethodAccess(args) {
|
|
|
74406
74416
|
}
|
|
74407
74417
|
|
|
74408
74418
|
// src/version.ts
|
|
74409
|
-
var version = "0.2.
|
|
74419
|
+
var version = "0.2.651".length > 0 ? "0.2.651" : "dev";
|
|
74410
74420
|
|
|
74411
74421
|
// src/cli-probe/probe.ts
|
|
74412
74422
|
var fs85 = __toESM(require("fs"), 1);
|