openzoo 0.49.11 → 0.49.12

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/lib/launch.js +18 -12
  2. package/package.json +1 -1
package/lib/launch.js CHANGED
@@ -280,18 +280,22 @@ export async function launchClaude(argv) {
280
280
 
281
281
  if (terminal) {
282
282
  const rejected = [];
283
- const cli = resolveClaudeCli(process.env, rejected);
283
+ let cli = resolveClaudeCli(process.env, rejected);
284
+ if (!cli && rejected.length) {
285
+ // THE FORMAT CHECK IS A TIE-BREAKER, NOT A VETO.
286
+ //
287
+ // isRunnableExecutable() knows four magics. Something legitimate that it
288
+ // has never seen — a packaging format we did not anticipate — would be
289
+ // refused here even though the OS would have run it happily, and we would
290
+ // have told the user to reinstall a CLI that was fine. When there is a
291
+ // real alternative the check earns its keep by preferring the good file;
292
+ // when this is the ONLY candidate, defer to the kernel and let the spawn
293
+ // below decide. A wrong heuristic must never be the sole reason we refuse.
294
+ cli = rejected[0];
295
+ console.error(`openzoo: ${cli} does not look like a runnable executable — trying it anyway.`);
296
+ }
284
297
  if (!cli) {
285
- if (rejected.length) {
286
- // Found it, could not run it. Say so — "not found on PATH" is a lie
287
- // here and sends the user off to reinstall something they already have.
288
- console.error('openzoo: found `claude` but it is not a runnable executable:');
289
- for (const f of rejected) console.error(` ${f}`);
290
- console.error(' (no shebang and no binary magic — usually a truncated or half-finished install)');
291
- console.error(' fix: reinstall Claude Code, or delete the broken file so another copy on PATH is used.');
292
- } else {
293
- console.error('openzoo: `claude` CLI not found on PATH — install Claude Code, or drop --terminal for the desktop app');
294
- }
298
+ console.error('openzoo: `claude` CLI not found on PATH — install Claude Code, or drop --terminal for the desktop app');
295
299
  process.exit(1);
296
300
  }
297
301
  // ALWAYS-ON HUD via Claude Code's NATIVE status line (the title bar is owned
@@ -422,9 +426,11 @@ export async function launchClaude(argv) {
422
426
  try { restoreStatus?.(); } catch { /* ignore */ }
423
427
  console.error(`openzoo: cannot execute ${cli} (${e?.code || e?.message})`);
424
428
  console.error(' it is marked executable but the OS refused to run it.');
425
- console.error(` check: head -1 ${cli} and file ${cli}`);
429
+ console.error(` check: file ${cli}`);
430
+ console.error(` head -c 2 ${cli} | xxd # a healthy script starts 2321 ("#!")`);
426
431
  console.error(' usually a truncated install, a wrong-architecture binary,');
427
432
  console.error(' or a shebang pointing at an interpreter that no longer exists.');
433
+ console.error(' fix: npm i -g @anthropic-ai/claude-code');
428
434
  process.exit(1);
429
435
  }
430
436
  child.on('exit', (c) => { try { restoreStatus?.(); } catch { /* ignore */ } process.exit(c ?? 0); });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "openzoo",
3
- "version": "0.49.11",
3
+ "version": "0.49.12",
4
4
  "description": "Local x402-paying proxy + MCP server for openzoo.fun — point any OpenAI-compatible harness (Cursor, Claude Code, aider, SDKs) at localhost and it pays per call from a local burner wallet. Solana and Base rails live; Robinhood experimental.",
5
5
  "license": "MIT",
6
6
  "type": "module",