nexus-agents 8.130.4 → 8.130.6
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/{ast-rule-runner-P42U5PCG.js → ast-rule-runner-3M77VFHJ.js} +3 -3
- package/dist/{child-mcp-config-JVBLHGPR.js → child-mcp-config-NHSUFBNN.js} +33 -9
- package/dist/child-mcp-config-NHSUFBNN.js.map +1 -0
- package/dist/{chunk-BMFPFCDH.js → chunk-2MWL47YX.js} +2 -2
- package/dist/{chunk-G2OCXWFR.js → chunk-3MWUYHEE.js} +2 -2
- package/dist/{chunk-JOYN26BG.js → chunk-4AP64XCN.js} +2 -2
- package/dist/{chunk-QDGM3LNQ.js → chunk-4FYLSRZJ.js} +4 -4
- package/dist/{chunk-LEWJQLEC.js → chunk-6YWV4ZAL.js} +3 -3
- package/dist/{chunk-BVNRU5WX.js → chunk-B2LLOTB2.js} +5 -5
- package/dist/{chunk-Z7I6DJ3A.js → chunk-C2JEGIZ2.js} +168 -61
- package/dist/chunk-C2JEGIZ2.js.map +1 -0
- package/dist/{chunk-HTGUGK3T.js → chunk-CYATMZW7.js} +2 -2
- package/dist/{chunk-A3VN5QVF.js → chunk-EQTKZHO6.js} +2 -2
- package/dist/{chunk-5MNTAXZ4.js → chunk-ERHP5N36.js} +2 -2
- package/dist/{chunk-KPRUVLLV.js → chunk-ERHQVKRC.js} +5 -5
- package/dist/{chunk-3P3VEM43.js → chunk-EYQPQR6C.js} +3 -3
- package/dist/{chunk-2FHR7KX7.js → chunk-FD232XB4.js} +44 -44
- package/dist/chunk-FD232XB4.js.map +1 -0
- package/dist/{chunk-TPUD2XJI.js → chunk-G5F44YKP.js} +2 -2
- package/dist/{chunk-JIB54TK5.js → chunk-G6HQGFO5.js} +11 -11
- package/dist/{chunk-NC2Z3ULV.js → chunk-GZM746JQ.js} +6 -6
- package/dist/{chunk-VGGRQQ4L.js → chunk-HDDXP26H.js} +3 -3
- package/dist/{chunk-GNDVHJBG.js → chunk-HVVZSJEY.js} +3 -3
- package/dist/{chunk-5FUAP5RK.js → chunk-JJU2GHK7.js} +10 -10
- package/dist/{chunk-OITVVSWO.js → chunk-JPFRRNRR.js} +2 -7
- package/dist/{chunk-OITVVSWO.js.map → chunk-JPFRRNRR.js.map} +1 -1
- package/dist/{chunk-RO572OKZ.js → chunk-M7FO5W7A.js} +5 -5
- package/dist/{chunk-Z7QFPQSU.js → chunk-N3PSIMXT.js} +2 -2
- package/dist/{chunk-BLBAXXM7.js → chunk-P7F52452.js} +2 -2
- package/dist/{chunk-222HCPM2.js → chunk-PS7ZNSC6.js} +2 -2
- package/dist/{chunk-WVYS34G3.js → chunk-Q4JD3ZZP.js} +4 -4
- package/dist/{chunk-Y7SY74LP.js → chunk-QQH3KA5T.js} +2 -2
- package/dist/{chunk-QYQ2V6YD.js → chunk-R4AH6LIE.js} +2 -2
- package/dist/{chunk-6SGB2REH.js → chunk-RSFEYQA5.js} +4 -4
- package/dist/{chunk-JMH4TL22.js → chunk-T4WUK562.js} +2 -2
- package/dist/{chunk-S7AXE7JM.js → chunk-TN5SDJYU.js} +5 -5
- package/dist/{chunk-4E6XQ2SN.js → chunk-TRIA7Q2H.js} +2 -2
- package/dist/{chunk-4IKZ55E7.js → chunk-UQPHTTMO.js} +3 -3
- package/dist/{chunk-HVZG3LD2.js → chunk-VL65KGVM.js} +39 -44
- package/dist/chunk-VL65KGVM.js.map +1 -0
- package/dist/{chunk-ZRB3WUEW.js → chunk-VVQXRBA7.js} +20 -5
- package/dist/chunk-VVQXRBA7.js.map +1 -0
- package/dist/{chunk-UMFH67CM.js → chunk-YN6EO4QO.js} +2 -2
- package/dist/{chunk-X2WDNE4Q.js → chunk-ZXMZMMBV.js} +4 -4
- package/dist/{cli-circuit-breaker-UEC7ORHN.js → cli-circuit-breaker-EP7H2ZTN.js} +3 -3
- package/dist/cli.js +119 -160
- package/dist/cli.js.map +1 -1
- package/dist/{composite-router-RH4X5EDO.js → composite-router-VJVHYM2O.js} +2 -2
- package/dist/{consensus-vote-NM4MNYSM.js → consensus-vote-2JX2VEUI.js} +18 -18
- package/dist/{context-retriever-35Z4IWT5.js → context-retriever-TG2SH7CT.js} +8 -8
- package/dist/{doctor-deep-X6NMJBPO.js → doctor-deep-IYUHW6T2.js} +3 -3
- package/dist/{doctor-gateway-report-V2CUP7A6.js → doctor-gateway-report-XOX6GIEL.js} +8 -8
- package/dist/{doctor-live-TMIGJPAW.js → doctor-live-GCXBUEPY.js} +12 -12
- package/dist/{expert-bridge-3QEMUXT5.js → expert-bridge-REZ6NY76.js} +4 -4
- package/dist/{factory-DKKMM223.js → factory-35OY5YJ7.js} +11 -11
- package/dist/{factory-7ZWGRFEK.js → factory-7ETXZOGV.js} +5 -5
- package/dist/{improvement-review-DUMMWRNW.js → improvement-review-NDBNYKNM.js} +6 -6
- package/dist/index.js +33 -33
- package/dist/{init-opencode-477R7MU7.js → init-opencode-SJZINN4S.js} +6 -6
- package/dist/{issue-triage-6M6X5LE3.js → issue-triage-SZRBPDAR.js} +6 -6
- package/dist/{openai-compat-adapter-FSBJXHKI.js → openai-compat-adapter-UW2Z4HF7.js} +6 -6
- package/dist/{outcome-store-adapter-AL5RDO5W.js → outcome-store-adapter-DZRQ77YG.js} +2 -2
- package/dist/{pr-reviewer-helpers-HFV72QPJ.js → pr-reviewer-helpers-5CGBGREQ.js} +4 -4
- package/dist/{registry-command-6ESIA7FU.js → registry-command-NI3LIWQA.js} +2 -2
- package/dist/{repo-security-plan-5EN7SUGD.js → repo-security-plan-SKVL27H3.js} +3 -3
- package/dist/{research-helpers-synthesize-UUNI5KE3.js → research-helpers-synthesize-UADXNMID.js} +4 -4
- package/dist/{routing-memory-JFWDOQKF.js → routing-memory-B5HYTZC7.js} +2 -2
- package/dist/{session-memory-YDBEKS2R.js → session-memory-SWTWLYGY.js} +3 -3
- package/dist/{setup-config-TJCZYWYQ.js → setup-config-37EXEYOM.js} +3 -3
- package/dist/{setup-custom-api-AQNOF4GK.js → setup-custom-api-CVI7NLPW.js} +4 -4
- package/dist/setup-data-dir-5VI2U6KY.js +33 -0
- package/dist/{tool-memory-4UZ64PAP.js → tool-memory-AJIAJ2CN.js} +5 -5
- package/dist/{unified-registry-I3GWI6VY.js → unified-registry-JHQ7UIS4.js} +12 -12
- package/dist/{weather-report-AZXWBBJN.js → weather-report-KJ4X3HVU.js} +2 -2
- package/package.json +1 -1
- package/dist/child-mcp-config-JVBLHGPR.js.map +0 -1
- package/dist/chunk-2FHR7KX7.js.map +0 -1
- package/dist/chunk-HVZG3LD2.js.map +0 -1
- package/dist/chunk-Z7I6DJ3A.js.map +0 -1
- package/dist/chunk-ZRB3WUEW.js.map +0 -1
- package/dist/setup-data-dir-AHEIUZMI.js +0 -33
- /package/dist/{ast-rule-runner-P42U5PCG.js.map → ast-rule-runner-3M77VFHJ.js.map} +0 -0
- /package/dist/{chunk-BMFPFCDH.js.map → chunk-2MWL47YX.js.map} +0 -0
- /package/dist/{chunk-G2OCXWFR.js.map → chunk-3MWUYHEE.js.map} +0 -0
- /package/dist/{chunk-JOYN26BG.js.map → chunk-4AP64XCN.js.map} +0 -0
- /package/dist/{chunk-QDGM3LNQ.js.map → chunk-4FYLSRZJ.js.map} +0 -0
- /package/dist/{chunk-LEWJQLEC.js.map → chunk-6YWV4ZAL.js.map} +0 -0
- /package/dist/{chunk-BVNRU5WX.js.map → chunk-B2LLOTB2.js.map} +0 -0
- /package/dist/{chunk-HTGUGK3T.js.map → chunk-CYATMZW7.js.map} +0 -0
- /package/dist/{chunk-A3VN5QVF.js.map → chunk-EQTKZHO6.js.map} +0 -0
- /package/dist/{chunk-5MNTAXZ4.js.map → chunk-ERHP5N36.js.map} +0 -0
- /package/dist/{chunk-KPRUVLLV.js.map → chunk-ERHQVKRC.js.map} +0 -0
- /package/dist/{chunk-3P3VEM43.js.map → chunk-EYQPQR6C.js.map} +0 -0
- /package/dist/{chunk-TPUD2XJI.js.map → chunk-G5F44YKP.js.map} +0 -0
- /package/dist/{chunk-JIB54TK5.js.map → chunk-G6HQGFO5.js.map} +0 -0
- /package/dist/{chunk-NC2Z3ULV.js.map → chunk-GZM746JQ.js.map} +0 -0
- /package/dist/{chunk-VGGRQQ4L.js.map → chunk-HDDXP26H.js.map} +0 -0
- /package/dist/{chunk-GNDVHJBG.js.map → chunk-HVVZSJEY.js.map} +0 -0
- /package/dist/{chunk-5FUAP5RK.js.map → chunk-JJU2GHK7.js.map} +0 -0
- /package/dist/{chunk-RO572OKZ.js.map → chunk-M7FO5W7A.js.map} +0 -0
- /package/dist/{chunk-Z7QFPQSU.js.map → chunk-N3PSIMXT.js.map} +0 -0
- /package/dist/{chunk-BLBAXXM7.js.map → chunk-P7F52452.js.map} +0 -0
- /package/dist/{chunk-222HCPM2.js.map → chunk-PS7ZNSC6.js.map} +0 -0
- /package/dist/{chunk-WVYS34G3.js.map → chunk-Q4JD3ZZP.js.map} +0 -0
- /package/dist/{chunk-Y7SY74LP.js.map → chunk-QQH3KA5T.js.map} +0 -0
- /package/dist/{chunk-QYQ2V6YD.js.map → chunk-R4AH6LIE.js.map} +0 -0
- /package/dist/{chunk-6SGB2REH.js.map → chunk-RSFEYQA5.js.map} +0 -0
- /package/dist/{chunk-JMH4TL22.js.map → chunk-T4WUK562.js.map} +0 -0
- /package/dist/{chunk-S7AXE7JM.js.map → chunk-TN5SDJYU.js.map} +0 -0
- /package/dist/{chunk-4E6XQ2SN.js.map → chunk-TRIA7Q2H.js.map} +0 -0
- /package/dist/{chunk-4IKZ55E7.js.map → chunk-UQPHTTMO.js.map} +0 -0
- /package/dist/{chunk-UMFH67CM.js.map → chunk-YN6EO4QO.js.map} +0 -0
- /package/dist/{chunk-X2WDNE4Q.js.map → chunk-ZXMZMMBV.js.map} +0 -0
- /package/dist/{cli-circuit-breaker-UEC7ORHN.js.map → cli-circuit-breaker-EP7H2ZTN.js.map} +0 -0
- /package/dist/{composite-router-RH4X5EDO.js.map → composite-router-VJVHYM2O.js.map} +0 -0
- /package/dist/{consensus-vote-NM4MNYSM.js.map → consensus-vote-2JX2VEUI.js.map} +0 -0
- /package/dist/{context-retriever-35Z4IWT5.js.map → context-retriever-TG2SH7CT.js.map} +0 -0
- /package/dist/{doctor-deep-X6NMJBPO.js.map → doctor-deep-IYUHW6T2.js.map} +0 -0
- /package/dist/{doctor-gateway-report-V2CUP7A6.js.map → doctor-gateway-report-XOX6GIEL.js.map} +0 -0
- /package/dist/{doctor-live-TMIGJPAW.js.map → doctor-live-GCXBUEPY.js.map} +0 -0
- /package/dist/{expert-bridge-3QEMUXT5.js.map → expert-bridge-REZ6NY76.js.map} +0 -0
- /package/dist/{factory-7ZWGRFEK.js.map → factory-35OY5YJ7.js.map} +0 -0
- /package/dist/{factory-DKKMM223.js.map → factory-7ETXZOGV.js.map} +0 -0
- /package/dist/{improvement-review-DUMMWRNW.js.map → improvement-review-NDBNYKNM.js.map} +0 -0
- /package/dist/{init-opencode-477R7MU7.js.map → init-opencode-SJZINN4S.js.map} +0 -0
- /package/dist/{issue-triage-6M6X5LE3.js.map → issue-triage-SZRBPDAR.js.map} +0 -0
- /package/dist/{openai-compat-adapter-FSBJXHKI.js.map → openai-compat-adapter-UW2Z4HF7.js.map} +0 -0
- /package/dist/{outcome-store-adapter-AL5RDO5W.js.map → outcome-store-adapter-DZRQ77YG.js.map} +0 -0
- /package/dist/{pr-reviewer-helpers-HFV72QPJ.js.map → pr-reviewer-helpers-5CGBGREQ.js.map} +0 -0
- /package/dist/{registry-command-6ESIA7FU.js.map → registry-command-NI3LIWQA.js.map} +0 -0
- /package/dist/{repo-security-plan-5EN7SUGD.js.map → repo-security-plan-SKVL27H3.js.map} +0 -0
- /package/dist/{research-helpers-synthesize-UUNI5KE3.js.map → research-helpers-synthesize-UADXNMID.js.map} +0 -0
- /package/dist/{routing-memory-JFWDOQKF.js.map → routing-memory-B5HYTZC7.js.map} +0 -0
- /package/dist/{session-memory-YDBEKS2R.js.map → session-memory-SWTWLYGY.js.map} +0 -0
- /package/dist/{setup-config-TJCZYWYQ.js.map → setup-config-37EXEYOM.js.map} +0 -0
- /package/dist/{setup-custom-api-AQNOF4GK.js.map → setup-custom-api-CVI7NLPW.js.map} +0 -0
- /package/dist/{setup-data-dir-AHEIUZMI.js.map → setup-data-dir-5VI2U6KY.js.map} +0 -0
- /package/dist/{tool-memory-4UZ64PAP.js.map → tool-memory-AJIAJ2CN.js.map} +0 -0
- /package/dist/{unified-registry-I3GWI6VY.js.map → unified-registry-JHQ7UIS4.js.map} +0 -0
- /package/dist/{weather-report-AZXWBBJN.js.map → weather-report-KJ4X3HVU.js.map} +0 -0
|
@@ -9,8 +9,8 @@ import {
|
|
|
9
9
|
getBuiltInAstRulesPath,
|
|
10
10
|
loadRules,
|
|
11
11
|
runAstQaRules
|
|
12
|
-
} from "./chunk-
|
|
13
|
-
import "./chunk-
|
|
12
|
+
} from "./chunk-G5F44YKP.js";
|
|
13
|
+
import "./chunk-VVQXRBA7.js";
|
|
14
14
|
import "./chunk-XBEKMUTO.js";
|
|
15
15
|
import "./chunk-UE7A2XHM.js";
|
|
16
16
|
import "./chunk-LWOX65CP.js";
|
|
@@ -27,4 +27,4 @@ export {
|
|
|
27
27
|
loadRules,
|
|
28
28
|
runAstQaRules
|
|
29
29
|
};
|
|
30
|
-
//# sourceMappingURL=ast-rule-runner-
|
|
30
|
+
//# sourceMappingURL=ast-rule-runner-3M77VFHJ.js.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
} from "./chunk-
|
|
2
|
+
nexusMkdtempSync
|
|
3
|
+
} from "./chunk-JPFRRNRR.js";
|
|
4
4
|
import {
|
|
5
5
|
createLogger
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-VVQXRBA7.js";
|
|
7
7
|
import "./chunk-XBEKMUTO.js";
|
|
8
8
|
import "./chunk-UE7A2XHM.js";
|
|
9
9
|
import "./chunk-LWOX65CP.js";
|
|
@@ -11,8 +11,21 @@ import "./chunk-PX6F3LHL.js";
|
|
|
11
11
|
|
|
12
12
|
// src/cli-adapters/child-mcp-config.ts
|
|
13
13
|
import { writeFile, rm } from "node:fs/promises";
|
|
14
|
+
import { rmSync } from "node:fs";
|
|
14
15
|
import { join } from "node:path";
|
|
15
16
|
var logger = createLogger({ component: "swe-bench-mcp-config" });
|
|
17
|
+
var activeMcpDirs = /* @__PURE__ */ new Set();
|
|
18
|
+
function cleanupOnExit() {
|
|
19
|
+
for (const dir of activeMcpDirs) {
|
|
20
|
+
try {
|
|
21
|
+
rmSync(dir, { recursive: true, force: true });
|
|
22
|
+
} catch (error) {
|
|
23
|
+
logger.debug("MCP-config exit cleanup failed", {
|
|
24
|
+
error: error instanceof Error ? error.message : String(error)
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
}
|
|
16
29
|
function resolveCliPath(override) {
|
|
17
30
|
if (override !== void 0) return override;
|
|
18
31
|
const distDir = join(__dirname, "..");
|
|
@@ -35,19 +48,30 @@ function buildConfig(options) {
|
|
|
35
48
|
}
|
|
36
49
|
async function generateMcpConfig(options) {
|
|
37
50
|
const config = buildConfig(options);
|
|
38
|
-
const tempDir =
|
|
51
|
+
const tempDir = nexusMkdtempSync("nexus-mcp-");
|
|
39
52
|
const configPath = join(tempDir, "mcp-config.json");
|
|
40
|
-
|
|
53
|
+
if (activeMcpDirs.size === 0) process.on("exit", cleanupOnExit);
|
|
54
|
+
activeMcpDirs.add(tempDir);
|
|
41
55
|
const cleanup = async () => {
|
|
42
|
-
|
|
56
|
+
try {
|
|
57
|
+
await rm(tempDir, { recursive: true, force: true });
|
|
58
|
+
activeMcpDirs.delete(tempDir);
|
|
59
|
+
if (activeMcpDirs.size === 0) process.removeListener("exit", cleanupOnExit);
|
|
60
|
+
} catch (e) {
|
|
43
61
|
logger.debug("Best-effort cleanup failed", {
|
|
44
62
|
error: e instanceof Error ? e.message : String(e)
|
|
45
63
|
});
|
|
46
|
-
}
|
|
64
|
+
}
|
|
47
65
|
};
|
|
48
|
-
|
|
66
|
+
try {
|
|
67
|
+
await writeFile(configPath, JSON.stringify(config, null, 2), "utf-8");
|
|
68
|
+
return { configPath, cleanup };
|
|
69
|
+
} catch (error) {
|
|
70
|
+
await cleanup();
|
|
71
|
+
throw error;
|
|
72
|
+
}
|
|
49
73
|
}
|
|
50
74
|
export {
|
|
51
75
|
generateMcpConfig
|
|
52
76
|
};
|
|
53
|
-
//# sourceMappingURL=child-mcp-config-
|
|
77
|
+
//# sourceMappingURL=child-mcp-config-NHSUFBNN.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/cli-adapters/child-mcp-config.ts"],"sourcesContent":["/**\n * nexus-agents/cli-adapters - Child CLI MCP Config Generator\n *\n * Generates MCP server configuration for child Claude CLI sessions so\n * spawned agents can call back into nexus-agents' MCP tools (memory,\n * research, etc.). Used by `pipeline/expert-bridge.ts` to give expert\n * agents tool access. Originally lived under `swe-bench/` (#1413);\n * relocated here in #2515 — the helper is generic CLI-spawn\n * infrastructure, not benchmark-specific.\n *\n * The generated config grants NO tool approvals. It only tells the child\n * where the nexus-agents MCP server is; whether an expert may actually call\n * one of its tools follows the host's Claude permission settings (for\n * example `defaultMode`). Measured 2026-09-24: in auto mode the calls run,\n * in default mode they are refused (#6784). An unused `allowedTools` list\n * that read like a guard but was never passed to the CLI was removed then.\n *\n * @module cli-adapters/child-mcp-config\n */\n\nimport { writeFile, rm } from 'node:fs/promises';\nimport { rmSync } from 'node:fs';\nimport { nexusMkdtempSync } from '../config/nexus-tmp-dir.js';\nimport { join } from 'node:path';\nimport { createLogger } from '../core/index.js';\n\nconst logger = createLogger({ component: 'swe-bench-mcp-config' });\n\n// Async finally blocks cannot run after process.exit (#4631). One listener\n// covers concurrent configs; SIGKILL cannot execute any in-process cleanup.\nconst activeMcpDirs = new Set<string>();\n\nfunction cleanupOnExit(): void {\n for (const dir of activeMcpDirs) {\n try {\n rmSync(dir, { recursive: true, force: true });\n } catch (error: unknown) {\n logger.debug('MCP-config exit cleanup failed', {\n error: error instanceof Error ? error.message : String(error),\n });\n }\n }\n}\n\n/**\n * MCP server entry in Claude CLI config format.\n */\ninterface McpServerEntry {\n readonly command: string;\n readonly args: readonly string[];\n readonly env?: Readonly<Record<string, string>>;\n}\n\n/**\n * MCP config file format for Claude CLI (--mcp-config).\n */\ninterface McpConfigFile {\n readonly mcpServers: Readonly<Record<string, McpServerEntry>>;\n}\n\n/**\n * Options for generating MCP config.\n */\nexport interface McpConfigOptions {\n /** Path to nexus-agents CLI entry point. */\n readonly cliPath?: string;\n /** Additional environment variables for the MCP server. */\n readonly env?: Readonly<Record<string, string>>;\n}\n\n/**\n * Resolves the nexus-agents CLI path.\n * Uses the built dist/cli.js relative to this package.\n */\nfunction resolveCliPath(override?: string): string {\n if (override !== undefined) return override;\n // Resolve relative to this file: src/swe-bench/ → dist/cli.js\n // At runtime we're in dist/swe-bench/, so go up one level\n const distDir = join(__dirname, '..');\n return join(distDir, 'cli.js');\n}\n\n/**\n * Env marker naming a child server (#6795). The child's stdio caller is an\n * expert CLI driven by a model, not the operator, so the child must not\n * measure it at tier 1; `connectTransport` reads this and records the caller\n * as unmeasured.\n */\nconst MCP_CHILD_ENV = 'NEXUS_MCP_CHILD';\n\n/**\n * Builds the MCP config object for a nexus-agents server.\n */\nfunction buildConfig(options?: McpConfigOptions): McpConfigFile {\n const cliPath = resolveCliPath(options?.cliPath);\n\n const entry: McpServerEntry = {\n command: 'node',\n args: [cliPath, '--mode=server'],\n // The child marker is applied LAST so caller-supplied env cannot unset it.\n env: { ...options?.env, [MCP_CHILD_ENV]: '1' },\n };\n\n return {\n mcpServers: {\n 'nexus-agents': entry,\n },\n };\n}\n\n/**\n * Generated MCP config with path and cleanup function.\n */\nexport interface GeneratedMcpConfig {\n /** Path to the generated config file. */\n readonly configPath: string;\n /** Cleanup function to remove temp files. */\n readonly cleanup: () => Promise<void>;\n}\n\n/**\n * Generates an MCP config file for Claude CLI child sessions.\n *\n * Creates a temporary JSON file that can be passed to `claude --mcp-config`.\n * Returns the file path and a cleanup function.\n */\nexport async function generateMcpConfig(options?: McpConfigOptions): Promise<GeneratedMcpConfig> {\n const config = buildConfig(options);\n\n // Creation and exit registration must occur in one turn: async mkdtemp\n // can finish in its worker before JS can register cleanup (#4631).\n const tempDir = nexusMkdtempSync('nexus-mcp-');\n const configPath = join(tempDir, 'mcp-config.json');\n\n if (activeMcpDirs.size === 0) process.on('exit', cleanupOnExit);\n activeMcpDirs.add(tempDir);\n\n const cleanup = async (): Promise<void> => {\n try {\n await rm(tempDir, { recursive: true, force: true });\n activeMcpDirs.delete(tempDir);\n if (activeMcpDirs.size === 0) process.removeListener('exit', cleanupOnExit);\n } catch (e: unknown) {\n logger.debug('Best-effort cleanup failed', {\n error: e instanceof Error ? e.message : String(e),\n });\n }\n };\n\n try {\n await writeFile(configPath, JSON.stringify(config, null, 2), 'utf-8');\n return { configPath, cleanup };\n } catch (error: unknown) {\n await cleanup();\n throw error;\n }\n}\n"],"mappings":";;;;;;;;;;;;AAoBA,SAAS,WAAW,UAAU;AAC9B,SAAS,cAAc;AAEvB,SAAS,YAAY;AAGrB,IAAM,SAAS,aAAa,EAAE,WAAW,uBAAuB,CAAC;AAIjE,IAAM,gBAAgB,oBAAI,IAAY;AAEtC,SAAS,gBAAsB;AAC7B,aAAW,OAAO,eAAe;AAC/B,QAAI;AACF,aAAO,KAAK,EAAE,WAAW,MAAM,OAAO,KAAK,CAAC;AAAA,IAC9C,SAAS,OAAgB;AACvB,aAAO,MAAM,kCAAkC;AAAA,QAC7C,OAAO,iBAAiB,QAAQ,MAAM,UAAU,OAAO,KAAK;AAAA,MAC9D,CAAC;AAAA,IACH;AAAA,EACF;AACF;AAgCA,SAAS,eAAe,UAA2B;AACjD,MAAI,aAAa,OAAW,QAAO;AAGnC,QAAM,UAAU,KAAK,WAAW,IAAI;AACpC,SAAO,KAAK,SAAS,QAAQ;AAC/B;AAQA,IAAM,gBAAgB;AAKtB,SAAS,YAAY,SAA2C;AAC9D,QAAM,UAAU,eAAe,SAAS,OAAO;AAE/C,QAAM,QAAwB;AAAA,IAC5B,SAAS;AAAA,IACT,MAAM,CAAC,SAAS,eAAe;AAAA;AAAA,IAE/B,KAAK,EAAE,GAAG,SAAS,KAAK,CAAC,aAAa,GAAG,IAAI;AAAA,EAC/C;AAEA,SAAO;AAAA,IACL,YAAY;AAAA,MACV,gBAAgB;AAAA,IAClB;AAAA,EACF;AACF;AAkBA,eAAsB,kBAAkB,SAAyD;AAC/F,QAAM,SAAS,YAAY,OAAO;AAIlC,QAAM,UAAU,iBAAiB,YAAY;AAC7C,QAAM,aAAa,KAAK,SAAS,iBAAiB;AAElD,MAAI,cAAc,SAAS,EAAG,SAAQ,GAAG,QAAQ,aAAa;AAC9D,gBAAc,IAAI,OAAO;AAEzB,QAAM,UAAU,YAA2B;AACzC,QAAI;AACF,YAAM,GAAG,SAAS,EAAE,WAAW,MAAM,OAAO,KAAK,CAAC;AAClD,oBAAc,OAAO,OAAO;AAC5B,UAAI,cAAc,SAAS,EAAG,SAAQ,eAAe,QAAQ,aAAa;AAAA,IAC5E,SAAS,GAAY;AACnB,aAAO,MAAM,8BAA8B;AAAA,QACzC,OAAO,aAAa,QAAQ,EAAE,UAAU,OAAO,CAAC;AAAA,MAClD,CAAC;AAAA,IACH;AAAA,EACF;AAEA,MAAI;AACF,UAAM,UAAU,YAAY,KAAK,UAAU,QAAQ,MAAM,CAAC,GAAG,OAAO;AACpE,WAAO,EAAE,YAAY,QAAQ;AAAA,EAC/B,SAAS,OAAgB;AACvB,UAAM,QAAQ;AACd,UAAM;AAAA,EACR;AACF;","names":[]}
|
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
MCP_TIMEOUTS,
|
|
9
9
|
TEST_TIMEOUTS,
|
|
10
10
|
WORKFLOW_TIMEOUTS
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-VVQXRBA7.js";
|
|
12
12
|
import {
|
|
13
13
|
createGetToolRateLimit
|
|
14
14
|
} from "./chunk-LWOX65CP.js";
|
|
@@ -223,4 +223,4 @@ export {
|
|
|
223
223
|
CUSTOM_API_DEFAULT_MODEL,
|
|
224
224
|
DEFAULTS
|
|
225
225
|
};
|
|
226
|
-
//# sourceMappingURL=chunk-
|
|
226
|
+
//# sourceMappingURL=chunk-2MWL47YX.js.map
|
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
getAdaptiveBonus,
|
|
9
9
|
getOutcomeStore,
|
|
10
10
|
hasMeasuredCategory
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-VVQXRBA7.js";
|
|
12
12
|
|
|
13
13
|
// src/cli/doctor-deep.ts
|
|
14
14
|
var CLI_NAMES = ["claude", "gemini", "codex", "opencode"];
|
|
@@ -148,4 +148,4 @@ export {
|
|
|
148
148
|
runDeepDiagnostics,
|
|
149
149
|
formatDeepDiagnostics
|
|
150
150
|
};
|
|
151
|
-
//# sourceMappingURL=chunk-
|
|
151
|
+
//# sourceMappingURL=chunk-3MWUYHEE.js.map
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
createLogger,
|
|
8
8
|
err,
|
|
9
9
|
ok
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-VVQXRBA7.js";
|
|
11
11
|
|
|
12
12
|
// src/adapters/gateway-redaction.ts
|
|
13
13
|
var GATEWAY_REDACTED = "<redacted>";
|
|
@@ -341,4 +341,4 @@ export {
|
|
|
341
341
|
validateCustomApiBaseUrl,
|
|
342
342
|
assertCustomApiHostResolvesPublic
|
|
343
343
|
};
|
|
344
|
-
//# sourceMappingURL=chunk-
|
|
344
|
+
//# sourceMappingURL=chunk-4AP64XCN.js.map
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-ZO6ZKR7L.js";
|
|
4
4
|
import {
|
|
5
5
|
SessionMemory
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-ERHP5N36.js";
|
|
7
7
|
import {
|
|
8
8
|
TRUST_TIER_NUMERIC,
|
|
9
9
|
TrustTierSchema
|
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
} from "./chunk-ROYGBFVE.js";
|
|
18
18
|
import {
|
|
19
19
|
generateId
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-P7F52452.js";
|
|
21
21
|
import {
|
|
22
22
|
ErrorCode,
|
|
23
23
|
NexusError,
|
|
@@ -34,7 +34,7 @@ import {
|
|
|
34
34
|
stringifyValue,
|
|
35
35
|
tokenize,
|
|
36
36
|
tokenizeFiltered
|
|
37
|
-
} from "./chunk-
|
|
37
|
+
} from "./chunk-VVQXRBA7.js";
|
|
38
38
|
import {
|
|
39
39
|
nexusDataPath
|
|
40
40
|
} from "./chunk-LWOX65CP.js";
|
|
@@ -5841,4 +5841,4 @@ export {
|
|
|
5841
5841
|
shutdownToolMemory,
|
|
5842
5842
|
ToolMemoryManager
|
|
5843
5843
|
};
|
|
5844
|
-
//# sourceMappingURL=chunk-
|
|
5844
|
+
//# sourceMappingURL=chunk-4FYLSRZJ.js.map
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
toolStructuredError,
|
|
8
8
|
toolSuccessStructured,
|
|
9
9
|
wrapToolWithTimeout
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-RSFEYQA5.js";
|
|
11
11
|
import {
|
|
12
12
|
JsonlStore,
|
|
13
13
|
SECURITY_KEYWORDS,
|
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
hasMeasuredCategory,
|
|
22
22
|
isDeclaredNeverDeprecate,
|
|
23
23
|
isRegisteredToolName
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-VVQXRBA7.js";
|
|
25
25
|
import {
|
|
26
26
|
getNexusDataDir,
|
|
27
27
|
nexusDataPath
|
|
@@ -2428,4 +2428,4 @@ export {
|
|
|
2428
2428
|
runImprovementReview,
|
|
2429
2429
|
registerImprovementReviewTool
|
|
2430
2430
|
};
|
|
2431
|
-
//# sourceMappingURL=chunk-
|
|
2431
|
+
//# sourceMappingURL=chunk-6YWV4ZAL.js.map
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createAutoAdapter
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-JJU2GHK7.js";
|
|
4
4
|
import {
|
|
5
5
|
ensureGatewayDiscovered,
|
|
6
6
|
gatewayDiscoveryGeneration
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-HDDXP26H.js";
|
|
8
8
|
import {
|
|
9
9
|
getDefaultCliCircuitBreakerRegistry,
|
|
10
10
|
mapModelErrorToCategory
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-EQTKZHO6.js";
|
|
12
12
|
import {
|
|
13
13
|
CircularBuffer,
|
|
14
14
|
ConfigError,
|
|
@@ -33,7 +33,7 @@ import {
|
|
|
33
33
|
recordRateLimitEvent,
|
|
34
34
|
toRateLimitError,
|
|
35
35
|
warnIfGatewayCostUndeclared
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-VVQXRBA7.js";
|
|
37
37
|
|
|
38
38
|
// src/agents/collaboration/event-bus-helpers.ts
|
|
39
39
|
import { randomUUID } from "node:crypto";
|
|
@@ -1040,4 +1040,4 @@ export {
|
|
|
1040
1040
|
getGlobalRegistry,
|
|
1041
1041
|
resetGlobalRegistry
|
|
1042
1042
|
};
|
|
1043
|
-
//# sourceMappingURL=chunk-
|
|
1043
|
+
//# sourceMappingURL=chunk-B2LLOTB2.js.map
|