@hmharness/cli 0.22.1 → 0.22.2

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.
Files changed (2) hide show
  1. package/dist/ablate-task.js +9 -3
  2. package/package.json +12 -12
@@ -89,7 +89,7 @@ async function runOnce(task, bare, timeoutMs) {
89
89
  const { runAgentTask, buildRegistry } = await import('@hmharness/agent');
90
90
  const { loadConfig } = await import('@hmharness/kernel');
91
91
  const { reg } = await buildRegistry({ mcp: false });
92
- const result = await Promise.race([
92
+ await Promise.race([
93
93
  runAgentTask({
94
94
  task,
95
95
  registry: reg,
@@ -103,9 +103,14 @@ async function runOnce(task, bare, timeoutMs) {
103
103
  throw err;
104
104
  return undefined;
105
105
  });
106
- void result;
107
106
  return { ok: true, output: finalText };
108
107
  }
108
+ catch (err) {
109
+ // a crashed run is a FAILED run (honest reading): record it and keep the
110
+ // ablation alive — one transient provider 400 must not kill the whole
111
+ // experiment and lose every arm's data
112
+ return { ok: false, output: finalText, error: String(err).slice(0, 120) };
113
+ }
109
114
  finally {
110
115
  if (prev === undefined)
111
116
  delete process.env.HMH_NO_COGNITIVE;
@@ -131,7 +136,8 @@ export async function runTaskAblation(write, home, runs, difficulty = 'easy', fi
131
136
  withOk += aHit ? 1 : 0;
132
137
  bareOk += bHit ? 1 : 0;
133
138
  details.push({ label: t.label, with: aHit, bare: bHit });
134
- write(` ${t.label.padEnd(24)} 认知 ${aHit ? GREEN('✓') : RED('✗')} · 裸 ${bHit ? GREEN('✓') : RED('✗')}\n`);
139
+ const crash = a.error || b.error ? DIM(` ⚠ ${String(a.error ?? b.error).slice(0, 70)}`) : '';
140
+ write(` ${t.label.padEnd(24)} 认知 ${aHit ? GREEN('✓') : RED('✗')} · 裸 ${bHit ? GREEN('✓') : RED('✗')}${crash}\n`);
135
141
  }
136
142
  }
137
143
  const record = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hmharness/cli",
3
- "version": "0.22.1",
3
+ "version": "0.22.2",
4
4
  "description": "hmharness command line: one-shot tasks, an interactive REPL, a fullscreen TUI, the web frontend, and direct tool invocation.",
5
5
  "type": "module",
6
6
  "main": "dist/main.js",
@@ -43,17 +43,17 @@
43
43
  "build": "tsc -p tsconfig.build.json"
44
44
  },
45
45
  "dependencies": {
46
- "@hmharness/agent": "0.22.1",
47
- "@hmharness/cognitive": "0.22.1",
48
- "@hmharness/domain-harmony": "0.22.1",
49
- "@hmharness/domain-ops": "0.22.1",
50
- "@hmharness/environments": "0.22.1",
51
- "@hmharness/evaluation": "0.22.1",
52
- "@hmharness/evolution": "0.22.1",
53
- "@hmharness/kernel": "0.22.1",
54
- "@hmharness/observability": "0.22.1",
55
- "@hmharness/sandbox": "0.22.1",
56
- "@hmharness/web": "0.22.1",
46
+ "@hmharness/agent": "0.22.2",
47
+ "@hmharness/cognitive": "0.22.2",
48
+ "@hmharness/domain-harmony": "0.22.2",
49
+ "@hmharness/domain-ops": "0.22.2",
50
+ "@hmharness/environments": "0.22.2",
51
+ "@hmharness/evaluation": "0.22.2",
52
+ "@hmharness/evolution": "0.22.2",
53
+ "@hmharness/kernel": "0.22.2",
54
+ "@hmharness/observability": "0.22.2",
55
+ "@hmharness/sandbox": "0.22.2",
56
+ "@hmharness/web": "0.22.2",
57
57
  "qrcode": "^1.5.4"
58
58
  }
59
59
  }