@agentv/core 4.26.0-next.1 → 4.26.1
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/{chunk-46TUI4JM.js → chunk-JNBHD34F.js} +30 -3
- package/dist/chunk-JNBHD34F.js.map +1 -0
- package/dist/index.cjs +44 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +30 -1
- package/dist/index.d.ts +30 -1
- package/dist/index.js +8 -2
- package/dist/index.js.map +1 -1
- package/dist/{ts-eval-loader-E6N374V2.js → ts-eval-loader-BZ54W52K.js} +2 -2
- package/package.json +1 -1
- package/dist/chunk-46TUI4JM.js.map +0 -1
- /package/dist/{ts-eval-loader-E6N374V2.js.map → ts-eval-loader-BZ54W52K.js.map} +0 -0
package/dist/index.cjs
CHANGED
|
@@ -9311,6 +9311,33 @@ var init_agentv_provider = __esm({
|
|
|
9311
9311
|
}
|
|
9312
9312
|
});
|
|
9313
9313
|
|
|
9314
|
+
// src/runtime/child-tracker.ts
|
|
9315
|
+
function trackChild(child) {
|
|
9316
|
+
tracked.add(child);
|
|
9317
|
+
child.once("close", () => {
|
|
9318
|
+
tracked.delete(child);
|
|
9319
|
+
});
|
|
9320
|
+
}
|
|
9321
|
+
function killAllTrackedChildren(signal = "SIGTERM") {
|
|
9322
|
+
for (const child of tracked) {
|
|
9323
|
+
try {
|
|
9324
|
+
child.kill(signal);
|
|
9325
|
+
} catch {
|
|
9326
|
+
}
|
|
9327
|
+
}
|
|
9328
|
+
}
|
|
9329
|
+
function trackedChildCount() {
|
|
9330
|
+
return tracked.size;
|
|
9331
|
+
}
|
|
9332
|
+
var tracked;
|
|
9333
|
+
var init_child_tracker = __esm({
|
|
9334
|
+
"src/runtime/child-tracker.ts"() {
|
|
9335
|
+
"use strict";
|
|
9336
|
+
init_cjs_shims();
|
|
9337
|
+
tracked = /* @__PURE__ */ new Set();
|
|
9338
|
+
}
|
|
9339
|
+
});
|
|
9340
|
+
|
|
9314
9341
|
// src/evaluation/providers/claude-content.ts
|
|
9315
9342
|
function toContentArray(content) {
|
|
9316
9343
|
if (!Array.isArray(content)) return void 0;
|
|
@@ -9789,6 +9816,7 @@ var init_claude_cli = __esm({
|
|
|
9789
9816
|
import_node_fs3 = require("fs");
|
|
9790
9817
|
import_promises13 = require("fs/promises");
|
|
9791
9818
|
import_node_path14 = __toESM(require("path"), 1);
|
|
9819
|
+
init_child_tracker();
|
|
9792
9820
|
init_claude_content();
|
|
9793
9821
|
init_claude_log_tracker();
|
|
9794
9822
|
init_normalize_tool_call();
|
|
@@ -9993,6 +10021,7 @@ var init_claude_cli = __esm({
|
|
|
9993
10021
|
spawnOptions.cwd = options.cwd;
|
|
9994
10022
|
}
|
|
9995
10023
|
const child = (0, import_node_child_process.spawn)(this.config.executable, options.args, spawnOptions);
|
|
10024
|
+
trackChild(child);
|
|
9996
10025
|
let stdout = "";
|
|
9997
10026
|
let stderr = "";
|
|
9998
10027
|
let timedOut = false;
|
|
@@ -12033,6 +12062,7 @@ var init_copilot_cli = __esm({
|
|
|
12033
12062
|
import_node_stream = require("stream");
|
|
12034
12063
|
import_node_child_process4 = require("child_process");
|
|
12035
12064
|
acp = __toESM(require("@agentclientprotocol/sdk"), 1);
|
|
12065
|
+
init_child_tracker();
|
|
12036
12066
|
init_file_changes();
|
|
12037
12067
|
init_copilot_cli_log_tracker();
|
|
12038
12068
|
init_copilot_utils();
|
|
@@ -12061,6 +12091,7 @@ var init_copilot_cli = __esm({
|
|
|
12061
12091
|
const agentProcess = (0, import_node_child_process4.spawn)(executable, args, {
|
|
12062
12092
|
stdio: ["pipe", "pipe", "inherit"]
|
|
12063
12093
|
});
|
|
12094
|
+
trackChild(agentProcess);
|
|
12064
12095
|
await waitForProcessSpawn(agentProcess, executable, this.targetName);
|
|
12065
12096
|
const toolCallsInProgress = /* @__PURE__ */ new Map();
|
|
12066
12097
|
const completedToolCalls = [];
|
|
@@ -13714,6 +13745,7 @@ async function defaultPiRunner(options) {
|
|
|
13714
13745
|
env: options.env,
|
|
13715
13746
|
stdio: ["pipe", "pipe", "pipe"]
|
|
13716
13747
|
});
|
|
13748
|
+
trackChild(child);
|
|
13717
13749
|
let stdout = "";
|
|
13718
13750
|
let stderr = "";
|
|
13719
13751
|
let timedOut = false;
|
|
@@ -13776,6 +13808,7 @@ var init_pi_cli = __esm({
|
|
|
13776
13808
|
import_promises22 = require("fs/promises");
|
|
13777
13809
|
import_node_os8 = require("os");
|
|
13778
13810
|
import_node_path24 = __toESM(require("path"), 1);
|
|
13811
|
+
init_child_tracker();
|
|
13779
13812
|
init_normalize_tool_call();
|
|
13780
13813
|
init_pi_log_tracker();
|
|
13781
13814
|
init_pi_provider_aliases();
|
|
@@ -16564,6 +16597,7 @@ function spawnVsCode(vscodeCmd, args, options) {
|
|
|
16564
16597
|
shell: useShell,
|
|
16565
16598
|
detached: false
|
|
16566
16599
|
});
|
|
16600
|
+
trackChild(child);
|
|
16567
16601
|
child.on("error", (error) => {
|
|
16568
16602
|
const label = options?.label ?? "spawn";
|
|
16569
16603
|
const renderedArgs = args.map((value) => JSON.stringify(value)).join(" ");
|
|
@@ -16702,6 +16736,7 @@ var init_vscodeProcess = __esm({
|
|
|
16702
16736
|
import_promises26 = require("fs/promises");
|
|
16703
16737
|
import_node_path32 = __toESM(require("path"), 1);
|
|
16704
16738
|
import_node_util3 = require("util");
|
|
16739
|
+
init_child_tracker();
|
|
16705
16740
|
init_fs();
|
|
16706
16741
|
init_path();
|
|
16707
16742
|
init_time();
|
|
@@ -24705,6 +24740,7 @@ __export(index_exports, {
|
|
|
24705
24740
|
isNonEmptyString: () => isNonEmptyString,
|
|
24706
24741
|
isTestMessage: () => isTestMessage,
|
|
24707
24742
|
isTestMessageRole: () => isTestMessageRole,
|
|
24743
|
+
killAllTrackedChildren: () => killAllTrackedChildren,
|
|
24708
24744
|
listTargetNames: () => listTargetNames,
|
|
24709
24745
|
loadBenchmarkRegistry: () => loadBenchmarkRegistry,
|
|
24710
24746
|
loadConfig: () => loadConfig,
|
|
@@ -24778,6 +24814,8 @@ __export(index_exports, {
|
|
|
24778
24814
|
toTranscriptJsonLines: () => toTranscriptJsonLines,
|
|
24779
24815
|
tokensPerTool: () => tokensPerTool,
|
|
24780
24816
|
touchBenchmark: () => touchBenchmark,
|
|
24817
|
+
trackChild: () => trackChild,
|
|
24818
|
+
trackedChildCount: () => trackedChildCount,
|
|
24781
24819
|
transpileEvalYaml: () => transpileEvalYaml,
|
|
24782
24820
|
transpileEvalYamlFile: () => transpileEvalYamlFile,
|
|
24783
24821
|
trimBaselineResult: () => trimBaselineResult
|
|
@@ -26502,6 +26540,9 @@ function runBeforeSessionHook(command) {
|
|
|
26502
26540
|
}
|
|
26503
26541
|
}
|
|
26504
26542
|
|
|
26543
|
+
// src/index.ts
|
|
26544
|
+
init_child_tracker();
|
|
26545
|
+
|
|
26505
26546
|
// src/import/index.ts
|
|
26506
26547
|
init_cjs_shims();
|
|
26507
26548
|
|
|
@@ -27270,6 +27311,7 @@ function createAgentKernel() {
|
|
|
27270
27311
|
isNonEmptyString,
|
|
27271
27312
|
isTestMessage,
|
|
27272
27313
|
isTestMessageRole,
|
|
27314
|
+
killAllTrackedChildren,
|
|
27273
27315
|
listTargetNames,
|
|
27274
27316
|
loadBenchmarkRegistry,
|
|
27275
27317
|
loadConfig,
|
|
@@ -27343,6 +27385,8 @@ function createAgentKernel() {
|
|
|
27343
27385
|
toTranscriptJsonLines,
|
|
27344
27386
|
tokensPerTool,
|
|
27345
27387
|
touchBenchmark,
|
|
27388
|
+
trackChild,
|
|
27389
|
+
trackedChildCount,
|
|
27346
27390
|
transpileEvalYaml,
|
|
27347
27391
|
transpileEvalYamlFile,
|
|
27348
27392
|
trimBaselineResult
|