harnessed 4.32.21 → 4.32.22
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.mjs +201 -24
- package/dist/cli.mjs.map +1 -1
- package/dist/index.mjs +1 -1
- package/dist/index.mjs.map +1 -1
- package/manifests/optional/chrome-devtools-mcp.yaml +60 -0
- package/manifests/optional/ecc.yaml +28 -14
- package/manifests/tools/exa-mcp.yaml +51 -0
- package/manifests/tools/tavily-mcp.yaml +4 -4
- package/messages/en.json +3 -0
- package/messages/zh-Hans.json +3 -0
- package/package.json +1 -1
- package/workflows/capabilities.yaml +11 -6
- package/workflows/judgments/web-search-routing.yaml +3 -3
- package/workflows/judgments/web-testing-routing.yaml +5 -0
- package/manifests/tools/chrome-devtools-mcp.yaml +0 -64
package/dist/cli.mjs
CHANGED
|
@@ -38,7 +38,7 @@ var init_package = __esm({
|
|
|
38
38
|
"package.json"() {
|
|
39
39
|
package_default = {
|
|
40
40
|
name: "harnessed",
|
|
41
|
-
version: "4.32.
|
|
41
|
+
version: "4.32.22",
|
|
42
42
|
description: "AI coding harness package manager + composition orchestrator",
|
|
43
43
|
type: "module",
|
|
44
44
|
license: "Apache-2.0",
|
|
@@ -1829,6 +1829,9 @@ var init_en = __esm({
|
|
|
1829
1829
|
"setup.complete": "setup complete \u2014 {{skills}} workflows + {{manifests}} base manifests configured",
|
|
1830
1830
|
"setup.mcp_hint": "Run /mcp in Claude Code to verify MCP server connections.",
|
|
1831
1831
|
"setup.mcp_hint_codex": "Run codex mcp list to verify MCP server connections.",
|
|
1832
|
+
"setup.search_key_hint.header": "\n\u26A0 Search MCP API keys missing \u2014 the server(s) below are installed but will fail at query time until the key is configured:",
|
|
1833
|
+
"setup.search_key_hint.line": ' {{server}}: set {{envVar}} \u2014 add it to the ~/.claude/settings.json "env" block (e.g. {"env": {"{{envVar}}": "<your-key>"}}) or export {{envVar}} in your shell',
|
|
1834
|
+
"setup.optional_offer.ecc_note": " ecc (bonus tier): installing it unlocks finer-grained scenario orchestration (per-language review/build expert routing etc.); the trade-off is ~20k+ tokens/session of static listing overhead \u2014 inherent to ECC's own scale (281 skills / 94 commands / 67 agents), not introduced by harnessed.",
|
|
1832
1835
|
"setup.bundled_summary": "\nharnessed workflows bundled at <packageRoot>/workflows/ (share-only, read-only)",
|
|
1833
1836
|
"setup.bundled_location": "",
|
|
1834
1837
|
"setup.doctor_hint": "\nRun harnessed doctor to verify your environment.",
|
|
@@ -4200,6 +4203,72 @@ var init_check_mattpocock_skills = __esm({
|
|
|
4200
4203
|
}
|
|
4201
4204
|
});
|
|
4202
4205
|
|
|
4206
|
+
// src/cli/lib/search-mcp-keys.ts
|
|
4207
|
+
var search_mcp_keys_exports = {};
|
|
4208
|
+
__export(search_mcp_keys_exports, {
|
|
4209
|
+
SEARCH_MCP_KEY_VARS: () => SEARCH_MCP_KEY_VARS,
|
|
4210
|
+
missingSearchMcpKeys: () => missingSearchMcpKeys,
|
|
4211
|
+
probeSearchMcpKey: () => probeSearchMcpKey,
|
|
4212
|
+
searchMcpKeyHintLines: () => searchMcpKeyHintLines
|
|
4213
|
+
});
|
|
4214
|
+
function nonEmpty(v) {
|
|
4215
|
+
return typeof v === "string" && v.trim() !== "";
|
|
4216
|
+
}
|
|
4217
|
+
async function probeSearchMcpKey(server) {
|
|
4218
|
+
const envVar = SEARCH_MCP_KEY_VARS[server];
|
|
4219
|
+
if (!envVar) return { server, envVar: "", present: false };
|
|
4220
|
+
try {
|
|
4221
|
+
const cfg = await readUserClaudeJson();
|
|
4222
|
+
const entry = cfg.mcpServers?.[server];
|
|
4223
|
+
if (entry?.env && nonEmpty(entry.env[envVar])) {
|
|
4224
|
+
return { server, envVar, present: true, source: "mcp-env" };
|
|
4225
|
+
}
|
|
4226
|
+
} catch {
|
|
4227
|
+
}
|
|
4228
|
+
try {
|
|
4229
|
+
const raw = await readFile(getSettingsPath(), "utf8");
|
|
4230
|
+
const parsed = JSON.parse(raw);
|
|
4231
|
+
if (parsed?.env && nonEmpty(parsed.env[envVar])) {
|
|
4232
|
+
return { server, envVar, present: true, source: "settings-env" };
|
|
4233
|
+
}
|
|
4234
|
+
} catch {
|
|
4235
|
+
}
|
|
4236
|
+
if (nonEmpty(process.env[envVar])) {
|
|
4237
|
+
return { server, envVar, present: true, source: "process-env" };
|
|
4238
|
+
}
|
|
4239
|
+
return { server, envVar, present: false };
|
|
4240
|
+
}
|
|
4241
|
+
async function missingSearchMcpKeys() {
|
|
4242
|
+
const out = [];
|
|
4243
|
+
for (const server of Object.keys(SEARCH_MCP_KEY_VARS)) {
|
|
4244
|
+
if (!await isMcpServerRegistered(server)) continue;
|
|
4245
|
+
const probe = await probeSearchMcpKey(server);
|
|
4246
|
+
if (!probe.present) out.push(probe);
|
|
4247
|
+
}
|
|
4248
|
+
return out;
|
|
4249
|
+
}
|
|
4250
|
+
async function searchMcpKeyHintLines() {
|
|
4251
|
+
const missing = await missingSearchMcpKeys();
|
|
4252
|
+
if (missing.length === 0) return [];
|
|
4253
|
+
const lines = [t("setup.search_key_hint.header")];
|
|
4254
|
+
for (const m of missing) {
|
|
4255
|
+
lines.push(t("setup.search_key_hint.line", { server: m.server, envVar: m.envVar }));
|
|
4256
|
+
}
|
|
4257
|
+
return lines;
|
|
4258
|
+
}
|
|
4259
|
+
var SEARCH_MCP_KEY_VARS;
|
|
4260
|
+
var init_search_mcp_keys = __esm({
|
|
4261
|
+
"src/cli/lib/search-mcp-keys.ts"() {
|
|
4262
|
+
init_i18n();
|
|
4263
|
+
init_readClaudeConfig();
|
|
4264
|
+
init_platform();
|
|
4265
|
+
SEARCH_MCP_KEY_VARS = {
|
|
4266
|
+
"tavily-mcp": "TAVILY_API_KEY",
|
|
4267
|
+
"exa-mcp": "EXA_API_KEY"
|
|
4268
|
+
};
|
|
4269
|
+
}
|
|
4270
|
+
});
|
|
4271
|
+
|
|
4203
4272
|
// src/cli/lib/check-mcp-availability.ts
|
|
4204
4273
|
var check_mcp_availability_exports = {};
|
|
4205
4274
|
__export(check_mcp_availability_exports, {
|
|
@@ -4209,41 +4278,51 @@ async function checkMcpAvailability() {
|
|
|
4209
4278
|
const installed = [];
|
|
4210
4279
|
const missing = [];
|
|
4211
4280
|
for (const s of TARGET_SERVERS) {
|
|
4212
|
-
|
|
4213
|
-
|
|
4214
|
-
installed.push(s);
|
|
4215
|
-
} else {
|
|
4216
|
-
missing.push(s);
|
|
4217
|
-
}
|
|
4281
|
+
if (await isMcpServerRegistered(s)) installed.push(s);
|
|
4282
|
+
else missing.push(s);
|
|
4218
4283
|
}
|
|
4219
|
-
|
|
4284
|
+
const keyless = [];
|
|
4285
|
+
for (const s of installed) {
|
|
4286
|
+
const probe = await probeSearchMcpKey(s);
|
|
4287
|
+
if (!probe.present) keyless.push(probe);
|
|
4288
|
+
}
|
|
4289
|
+
if (missing.length === 0 && keyless.length === 0) {
|
|
4220
4290
|
return {
|
|
4221
4291
|
name: CHECK_NAME,
|
|
4222
4292
|
status: "pass",
|
|
4223
|
-
message: `installed: ${installed.join(", ")}`
|
|
4293
|
+
message: `installed: ${installed.join(", ")} (API keys configured)`
|
|
4224
4294
|
};
|
|
4225
4295
|
}
|
|
4226
|
-
|
|
4227
|
-
|
|
4228
|
-
|
|
4229
|
-
|
|
4230
|
-
|
|
4231
|
-
|
|
4232
|
-
|
|
4296
|
+
const parts = [];
|
|
4297
|
+
if (installed.length > 0) parts.push(`installed: ${installed.join(", ")}`);
|
|
4298
|
+
if (missing.length > 0) parts.push(`not registered: ${missing.join(", ")}`);
|
|
4299
|
+
if (keyless.length > 0) {
|
|
4300
|
+
parts.push(`API key missing: ${keyless.map((k) => `${k.server} \u2192 ${k.envVar}`).join(", ")}`);
|
|
4301
|
+
}
|
|
4302
|
+
const fixes = [];
|
|
4303
|
+
if (missing.length > 0) {
|
|
4304
|
+
fixes.push("run `harnessed setup` to install missing MCPs via Step B (manifests/tools/)");
|
|
4305
|
+
}
|
|
4306
|
+
if (keyless.length > 0) {
|
|
4307
|
+
const vars = keyless.map((k) => k.envVar).join(" / ");
|
|
4308
|
+
fixes.push(
|
|
4309
|
+
`set ${vars} in the ~/.claude/settings.json "env" block (e.g. {"env": {"${keyless[0]?.envVar}": "<your-key>"}}) or export it in your shell; a mcpServers.<name>.env entry in ~/.claude.json also works`
|
|
4310
|
+
);
|
|
4233
4311
|
}
|
|
4234
4312
|
return {
|
|
4235
4313
|
name: CHECK_NAME,
|
|
4236
4314
|
status: "warn",
|
|
4237
|
-
message:
|
|
4238
|
-
fix: "
|
|
4315
|
+
message: parts.join("; "),
|
|
4316
|
+
fix: fixes.join("; ")
|
|
4239
4317
|
};
|
|
4240
4318
|
}
|
|
4241
4319
|
var TARGET_SERVERS, CHECK_NAME;
|
|
4242
4320
|
var init_check_mcp_availability = __esm({
|
|
4243
4321
|
"src/cli/lib/check-mcp-availability.ts"() {
|
|
4244
4322
|
init_readClaudeConfig();
|
|
4245
|
-
|
|
4246
|
-
|
|
4323
|
+
init_search_mcp_keys();
|
|
4324
|
+
TARGET_SERVERS = Object.keys(SEARCH_MCP_KEY_VARS);
|
|
4325
|
+
CHECK_NAME = "MCP servers (tavily/exa)";
|
|
4247
4326
|
}
|
|
4248
4327
|
});
|
|
4249
4328
|
|
|
@@ -5099,6 +5178,67 @@ var init_check_stale_hooks = __esm({
|
|
|
5099
5178
|
}
|
|
5100
5179
|
});
|
|
5101
5180
|
|
|
5181
|
+
// src/cli/lib/check-ecc.ts
|
|
5182
|
+
var check_ecc_exports = {};
|
|
5183
|
+
__export(check_ecc_exports, {
|
|
5184
|
+
checkEcc: () => checkEcc
|
|
5185
|
+
});
|
|
5186
|
+
async function pathExists(p7) {
|
|
5187
|
+
try {
|
|
5188
|
+
await stat(p7);
|
|
5189
|
+
return true;
|
|
5190
|
+
} catch {
|
|
5191
|
+
return false;
|
|
5192
|
+
}
|
|
5193
|
+
}
|
|
5194
|
+
async function checkEcc() {
|
|
5195
|
+
const ccInstalled = await isPluginRegistered("ecc");
|
|
5196
|
+
const codexHome = join(homedir(), ".codex");
|
|
5197
|
+
const codexPresent = await pathExists(join(codexHome, "config.toml"));
|
|
5198
|
+
const codexInstalled = codexPresent && await pathExists(join(codexHome, ".cache", "ecc", ".git"));
|
|
5199
|
+
const ccPart = ccInstalled ? "CC: installed (plugin ecc@ecc)" : "CC: not installed";
|
|
5200
|
+
const codexPart = codexPresent ? codexInstalled ? "codex: installed (~/.codex/.cache/ecc sync clone)" : "codex: not installed" : "codex: not present (no ~/.codex/config.toml)";
|
|
5201
|
+
if (ccInstalled) {
|
|
5202
|
+
const leftovers = [];
|
|
5203
|
+
const fixes = [];
|
|
5204
|
+
if (await isPluginRegistered("chrome-devtools-mcp")) {
|
|
5205
|
+
leftovers.push("official chrome-devtools-mcp@claude-plugins-official plugin still enabled");
|
|
5206
|
+
fixes.push("`claude plugin uninstall chrome-devtools-mcp@claude-plugins-official`");
|
|
5207
|
+
}
|
|
5208
|
+
if (await isMcpServerRegistered("chrome-devtools-mcp")) {
|
|
5209
|
+
leftovers.push("chrome-devtools-mcp stdio entry still registered in mcpServers");
|
|
5210
|
+
fixes.push("`claude mcp remove chrome-devtools-mcp`");
|
|
5211
|
+
}
|
|
5212
|
+
if (leftovers.length > 0) {
|
|
5213
|
+
return {
|
|
5214
|
+
name: NAME2,
|
|
5215
|
+
status: "warn",
|
|
5216
|
+
message: `${ccPart}; ${codexPart}; chrome-devtools dual-install \u2014 ECC already bundles the chrome-devtools connector (its only default MCP), but: ${leftovers.join("; ")} (same-name dual-prefix tool-call ambiguity)`,
|
|
5217
|
+
fix: `remove the leftover, keep ecc: ${fixes.join(" and ")}`
|
|
5218
|
+
};
|
|
5219
|
+
}
|
|
5220
|
+
}
|
|
5221
|
+
if (!ccInstalled && !codexInstalled) {
|
|
5222
|
+
return {
|
|
5223
|
+
name: NAME2,
|
|
5224
|
+
status: "pass",
|
|
5225
|
+
message: `not installed (${ccPart}; ${codexPart}) \u2014 optional enhancement: \`harnessed install ecc\` unlocks finer-grained orchestration (per-language review/build expert routing etc.) at a ~20k+ tokens/session static-listing cost (ECC-side scale, not harnessed)`
|
|
5226
|
+
};
|
|
5227
|
+
}
|
|
5228
|
+
return {
|
|
5229
|
+
name: NAME2,
|
|
5230
|
+
status: "pass",
|
|
5231
|
+
message: `${ccPart}; ${codexPart} \u2014 chrome-devtools connector provided by ECC`
|
|
5232
|
+
};
|
|
5233
|
+
}
|
|
5234
|
+
var NAME2;
|
|
5235
|
+
var init_check_ecc = __esm({
|
|
5236
|
+
"src/cli/lib/check-ecc.ts"() {
|
|
5237
|
+
init_readClaudeConfig();
|
|
5238
|
+
NAME2 = "ecc";
|
|
5239
|
+
}
|
|
5240
|
+
});
|
|
5241
|
+
|
|
5102
5242
|
// src/cli/lib/doctor-registry.ts
|
|
5103
5243
|
var CHECKS;
|
|
5104
5244
|
var init_doctor_registry = __esm({
|
|
@@ -5146,7 +5286,11 @@ var init_doctor_registry = __esm({
|
|
|
5146
5286
|
// issue #8 — orphaned harnessed Stop/UserPromptSubmit hooks (warn-only): a hook
|
|
5147
5287
|
// pointing at a deleted bin/*.mjs makes Claude Code error MODULE_NOT_FOUND every
|
|
5148
5288
|
// prompt; `harnessed uninstall` now strips them.
|
|
5149
|
-
async () => (await Promise.resolve().then(() => (init_check_stale_hooks(), check_stale_hooks_exports))).checkStaleHooks()
|
|
5289
|
+
async () => (await Promise.resolve().then(() => (init_check_stale_hooks(), check_stale_hooks_exports))).checkStaleHooks(),
|
|
5290
|
+
// 4.32.22 — ECC per-harness detect (optional; pass unless CC-side ecc overlaps
|
|
5291
|
+
// the official chrome-devtools-mcp plugin → warn). CC plugin registry + codex
|
|
5292
|
+
// sync-clone probed independently.
|
|
5293
|
+
async () => (await Promise.resolve().then(() => (init_check_ecc(), check_ecc_exports))).checkEcc()
|
|
5150
5294
|
];
|
|
5151
5295
|
}
|
|
5152
5296
|
});
|
|
@@ -8495,6 +8639,9 @@ ${names.length} optional component(s) available (opt-in, not part of base setup)
|
|
|
8495
8639
|
`
|
|
8496
8640
|
${pending.length} optional component(s) available (opt-in \u2014 none selected by default):`
|
|
8497
8641
|
);
|
|
8642
|
+
if (pending.some((m) => m.metadata.name === "ecc")) {
|
|
8643
|
+
console.log(t("setup.optional_offer.ecc_note"));
|
|
8644
|
+
}
|
|
8498
8645
|
const ans = await p.multiselect({
|
|
8499
8646
|
message: "Select optional components to install (space to toggle, enter to continue \u2014 empty = install nothing)",
|
|
8500
8647
|
options: pending.map((m) => ({
|
|
@@ -8544,6 +8691,7 @@ ${pending.length} optional component(s) available (opt-in \u2014 none selected b
|
|
|
8544
8691
|
var PROBE_OPTS;
|
|
8545
8692
|
var init_optional_offer = __esm({
|
|
8546
8693
|
"src/cli/lib/optional-offer.ts"() {
|
|
8694
|
+
init_i18n();
|
|
8547
8695
|
init_installers();
|
|
8548
8696
|
init_idempotent();
|
|
8549
8697
|
init_validate();
|
|
@@ -9471,7 +9619,7 @@ init_i18n();
|
|
|
9471
9619
|
init_doctor_registry();
|
|
9472
9620
|
function registerDoctor(program2) {
|
|
9473
9621
|
program2.command("doctor").description(
|
|
9474
|
-
"Preflight checks (Node / MCP scope / jq / Win bash / origin URL / gstack prefix / deprecations / token budget / Agent Teams / planning-with-files / mattpocock-skills / MCP availability)"
|
|
9622
|
+
"Preflight checks (Node / MCP scope / jq / Win bash / origin URL / gstack prefix / deprecations / token budget / Agent Teams / planning-with-files / mattpocock-skills / MCP availability / ECC)"
|
|
9475
9623
|
).option("--json", "output JSON instead of human-readable").action(async (opts) => {
|
|
9476
9624
|
const results = await Promise.all(CHECKS.map((c) => c()));
|
|
9477
9625
|
const hasFail = results.some((r) => r.status === "fail");
|
|
@@ -12952,6 +13100,28 @@ async function scanWorkflowsWithSkill(workflowsDir, entries) {
|
|
|
12952
13100
|
return scanWorkflowsNested(workflowsDir, entries);
|
|
12953
13101
|
}
|
|
12954
13102
|
var MCP_METHODS = /* @__PURE__ */ new Set(["mcp-stdio-add", "mcp-http-add"]);
|
|
13103
|
+
function effectiveInstallMethod(manifest) {
|
|
13104
|
+
if (detectPlatform().id === "codex") {
|
|
13105
|
+
const override = manifest.spec.harness_overrides?.codex;
|
|
13106
|
+
if (override) return override.install.method;
|
|
13107
|
+
}
|
|
13108
|
+
return manifest.spec.install.method;
|
|
13109
|
+
}
|
|
13110
|
+
function installGroupOf(manifest) {
|
|
13111
|
+
const method = effectiveInstallMethod(manifest);
|
|
13112
|
+
if (MCP_METHODS.has(method)) return "mcp-tool";
|
|
13113
|
+
switch (method) {
|
|
13114
|
+
case "cc-plugin-marketplace":
|
|
13115
|
+
case "git-clone-with-setup":
|
|
13116
|
+
case "npx-skill-installer":
|
|
13117
|
+
case "cc-hook-add":
|
|
13118
|
+
return "command";
|
|
13119
|
+
case "npm-cli":
|
|
13120
|
+
return "cli-binary";
|
|
13121
|
+
default:
|
|
13122
|
+
return "other";
|
|
13123
|
+
}
|
|
13124
|
+
}
|
|
12955
13125
|
async function runStepBInstall(manifestPaths, runOpts = {}) {
|
|
12956
13126
|
const opts = {
|
|
12957
13127
|
apply: true,
|
|
@@ -12996,7 +13166,7 @@ async function runStepBInstall(manifestPaths, runOpts = {}) {
|
|
|
12996
13166
|
);
|
|
12997
13167
|
continue;
|
|
12998
13168
|
}
|
|
12999
|
-
componentTypes[v.manifest.metadata.name] = v.manifest
|
|
13169
|
+
componentTypes[v.manifest.metadata.name] = installGroupOf(v.manifest);
|
|
13000
13170
|
valid.push({ manifest: v.manifest });
|
|
13001
13171
|
}
|
|
13002
13172
|
const runOne = async (manifest) => {
|
|
@@ -13301,8 +13471,10 @@ installing ${manifestPaths.length} upstream components (MCP serialized, rest par
|
|
|
13301
13471
|
const isTty = process.stdin.isTTY === true && process.stdout.isTTY === true;
|
|
13302
13472
|
if (isTty) {
|
|
13303
13473
|
const { confirm: confirm5, isCancel: isCancel7 } = await import('@clack/prompts');
|
|
13474
|
+
const mcpExcluded = b.alreadyInstalled.filter((n) => b.componentTypes[n] === "mcp-tool");
|
|
13475
|
+
const exclusionNote = mcpExcluded.length > 0 ? ` (${mcpExcluded.length} MCP server(s) excluded \u2014 they ignore force-update: ${mcpExcluded.join(", ")})` : "";
|
|
13304
13476
|
const ans = await confirm5({
|
|
13305
|
-
message: `Update ${b.alreadyInstalled.length} already-installed plugin(s) listed above
|
|
13477
|
+
message: `Update ${b.alreadyInstalled.length} already-installed plugin(s) listed above?${exclusionNote}`,
|
|
13306
13478
|
initialValue: false
|
|
13307
13479
|
});
|
|
13308
13480
|
if (!isCancel7(ans) && ans === true) {
|
|
@@ -13466,6 +13638,11 @@ ${b.failed.length} component(s) failed \u2014 see the notes in the tables above;
|
|
|
13466
13638
|
if (b.alreadyInstalled.length > 0 || b.installed.length > 0) {
|
|
13467
13639
|
console.log(t(detectPlatform().id === "codex" ? "setup.mcp_hint_codex" : "setup.mcp_hint"));
|
|
13468
13640
|
}
|
|
13641
|
+
try {
|
|
13642
|
+
const { searchMcpKeyHintLines: searchMcpKeyHintLines2 } = await Promise.resolve().then(() => (init_search_mcp_keys(), search_mcp_keys_exports));
|
|
13643
|
+
for (const line of await searchMcpKeyHintLines2()) console.warn(line);
|
|
13644
|
+
} catch {
|
|
13645
|
+
}
|
|
13469
13646
|
console.log(t("setup.bundled_summary"));
|
|
13470
13647
|
console.log(t("setup.bundled_location"));
|
|
13471
13648
|
console.log(t("setup.doctor_hint"));
|