codeam-cli 2.61.79 → 2.61.80

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/CHANGELOG.md CHANGED
@@ -4,6 +4,12 @@ All notable changes to `codeam-cli` are documented here.
4
4
 
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [2.61.79] — 2026-07-31
8
+
9
+ ### Fixed
10
+
11
+ - **shared:** Convex uses the api_key (deploy key) rail, not OAuth
12
+
7
13
  ## [2.61.78] — 2026-07-31
8
14
 
9
15
  ### Added
package/dist/index.js CHANGED
@@ -7364,7 +7364,7 @@ function readAnonId() {
7364
7364
  }
7365
7365
  function superProperties() {
7366
7366
  return {
7367
- cliVersion: true ? "2.61.79" : "0.0.0-dev",
7367
+ cliVersion: true ? "2.61.80" : "0.0.0-dev",
7368
7368
  nodeVersion: process.version,
7369
7369
  platform: process.platform,
7370
7370
  arch: process.arch,
@@ -7545,7 +7545,7 @@ var os4 = __toESM(require("os"));
7545
7545
  // package.json
7546
7546
  var package_default = {
7547
7547
  name: "codeam-cli",
7548
- version: "2.61.79",
7548
+ version: "2.61.80",
7549
7549
  description: "Workflow-continuity bridge for AI coding agents. Wrap Claude Code or Codex in a PTY and supervise, approve, and redirect the session from any device \u2014 async. The terminal companion for CodeAgent Mobile.",
7550
7550
  type: "commonjs",
7551
7551
  main: "dist/index.js",
@@ -8777,7 +8777,7 @@ var CommandRelayService = class _CommandRelayService {
8777
8777
  // fresh + clear the "CLI update available" banner after a self-update
8778
8778
  // (a codespace that reinstalls @latest reconnects via heartbeat, not
8779
8779
  // pair/reconnect). Older backends ignore the extra field.
8780
- ..."2.61.79" ? { ideVersion: "2.61.79" } : {}
8780
+ ..."2.61.80" ? { ideVersion: "2.61.80" } : {}
8781
8781
  }).then(() => log.trace("relay", `heartbeat ok online=${online}`)).catch((err) => log.trace("relay", `heartbeat failed online=${online}`, err));
8782
8782
  }
8783
8783
  /**
@@ -19891,7 +19891,7 @@ async function autoUpgradeBeforeCriticalCommand() {
19891
19891
  if (process.env.NODE_ENV === "test") return;
19892
19892
  if (process.env.CODEAM_DISABLE_UPDATE_CHECK === "1") return;
19893
19893
  if (process.env.CI) return;
19894
- const current = true ? "2.61.79" : null;
19894
+ const current = true ? "2.61.80" : null;
19895
19895
  if (!current) return;
19896
19896
  const cache = readCache();
19897
19897
  const fresh = cache && Date.now() - cache.fetchedAt < TTL_MS;
@@ -19908,7 +19908,7 @@ function checkForUpdates() {
19908
19908
  if (process.env.CODEAM_DISABLE_UPDATE_CHECK === "1") return;
19909
19909
  if (process.env.CI) return;
19910
19910
  if (!process.stdout.isTTY) return;
19911
- const current = true ? "2.61.79" : null;
19911
+ const current = true ? "2.61.80" : null;
19912
19912
  if (!current) return;
19913
19913
  const cache = readCache();
19914
19914
  const fresh = cache && Date.now() - cache.fetchedAt < TTL_MS;
@@ -19928,7 +19928,7 @@ var SELF_UPDATE_INTERVAL_MS = 60 * 60 * 1e3;
19928
19928
  var SELF_UPDATE_VIEW_TIMEOUT_MS = 3e4;
19929
19929
  var SELF_UPDATE_INSTALL_TIMEOUT_MS = 18e4;
19930
19930
  function currentCliVersion() {
19931
- return true ? "2.61.79" : null;
19931
+ return true ? "2.61.80" : null;
19932
19932
  }
19933
19933
  function runCmd(cmd, args2, timeoutMs) {
19934
19934
  return new Promise((resolve9) => {
@@ -40626,7 +40626,7 @@ function checkChokidar() {
40626
40626
  }
40627
40627
  async function doctor(args2 = []) {
40628
40628
  const json = args2.includes("--json");
40629
- const cliVersion = true ? "2.61.79" : "0.0.0-dev";
40629
+ const cliVersion = true ? "2.61.80" : "0.0.0-dev";
40630
40630
  const apiBase2 = resolveApiBaseUrl();
40631
40631
  const diagnosticId = (0, import_node_crypto13.randomUUID)();
40632
40632
  log.info("doctor", `run id=${diagnosticId} cli=${cliVersion}`);
@@ -40883,6 +40883,10 @@ var import_node_child_process31 = require("child_process");
40883
40883
  var import_node_readline3 = __toESM(require("readline"));
40884
40884
  var RESTART_CHECK_INTERVAL_MS = 3e4;
40885
40885
  var SIGKILL_ESCALATION_MS = 2e3;
40886
+ var TOOL_CALL_TIMEOUT_MS = (() => {
40887
+ const raw = Number(process.env.CODEAM_MCP_TOOL_TIMEOUT_MS);
40888
+ return Number.isFinite(raw) && raw > 0 ? raw : 12e4;
40889
+ })();
40886
40890
  var REPLAY_INIT_ID = "__codeam_replay_init__";
40887
40891
  var RestartableStdioProxy = class {
40888
40892
  constructor(opts) {
@@ -40893,12 +40897,16 @@ var RestartableStdioProxy = class {
40893
40897
  childRl = null;
40894
40898
  initializeLine = null;
40895
40899
  inflight = /* @__PURE__ */ new Set();
40900
+ /** Per-`tools/call` request-id watchdog timers (see TOOL_CALL_TIMEOUT_MS). */
40901
+ toolTimers = /* @__PURE__ */ new Map();
40902
+ stdout = null;
40896
40903
  swapping = false;
40897
40904
  pendingClientLines = [];
40898
40905
  ended = () => void 0;
40899
40906
  async start() {
40900
40907
  const stdin = this.opts.stdin ?? process.stdin;
40901
40908
  const stdout = this.opts.stdout ?? process.stdout;
40909
+ this.stdout = stdout;
40902
40910
  await this.spawnChild(stdout);
40903
40911
  const rl = import_node_readline3.default.createInterface({ input: stdin, crlfDelay: Infinity });
40904
40912
  rl.on("line", (line) => this.onClientLine(line));
@@ -40925,9 +40933,15 @@ var RestartableStdioProxy = class {
40925
40933
  }
40926
40934
  if (msg.method === "notifications/cancelled") {
40927
40935
  const requestId = msg.params?.requestId;
40928
- if (requestId !== void 0) this.inflight.delete(requestId);
40936
+ if (requestId !== void 0) {
40937
+ this.inflight.delete(requestId);
40938
+ this.clearToolTimeout(requestId);
40939
+ }
40940
+ }
40941
+ if (msg.id !== void 0 && msg.method !== void 0) {
40942
+ this.inflight.add(msg.id);
40943
+ if (msg.method === "tools/call") this.armToolTimeout(msg.id);
40929
40944
  }
40930
- if (msg.id !== void 0 && msg.method !== void 0) this.inflight.add(msg.id);
40931
40945
  } catch {
40932
40946
  }
40933
40947
  this.child?.stdin?.write(line + "\n");
@@ -40940,12 +40954,54 @@ var RestartableStdioProxy = class {
40940
40954
  return;
40941
40955
  }
40942
40956
  this.inflight.delete(msg.id);
40957
+ this.clearToolTimeout(msg.id);
40943
40958
  }
40944
40959
  } catch {
40945
40960
  }
40946
40961
  stdout.write(line + "\n");
40947
40962
  if (this.inflight.size === 0) this.checkRestart(stdout);
40948
40963
  }
40964
+ /**
40965
+ * Arm a per-`tools/call` watchdog. If the server never answers this request
40966
+ * id within {@link TOOL_CALL_TIMEOUT_MS}, synthesize a JSON-RPC error response
40967
+ * to the client so the agent's turn unblocks (clean tool error) instead of
40968
+ * hanging forever with no Stop. Idempotent per id.
40969
+ */
40970
+ armToolTimeout(id) {
40971
+ const existing = this.toolTimers.get(id);
40972
+ if (existing) clearTimeout(existing);
40973
+ const t2 = setTimeout(() => {
40974
+ this.toolTimers.delete(id);
40975
+ if (!this.inflight.has(id)) return;
40976
+ this.inflight.delete(id);
40977
+ process.stderr.write(
40978
+ `[codeam mcp-run] tools/call id=${String(id)} timed out after ${TOOL_CALL_TIMEOUT_MS}ms \u2014 server did not respond; failing the call so the turn can proceed
40979
+ `
40980
+ );
40981
+ const errResponse = {
40982
+ jsonrpc: "2.0",
40983
+ id,
40984
+ error: {
40985
+ code: -32001,
40986
+ message: `MCP tool call timed out after ${Math.round(TOOL_CALL_TIMEOUT_MS / 1e3)}s \u2014 the server did not respond. The target service/deployment may be unreachable (e.g. a Convex dev deployment is only reachable while \`convex dev\` is running \u2014 use a production deploy key or start \`convex dev\`).`
40987
+ }
40988
+ };
40989
+ (this.stdout ?? process.stdout).write(JSON.stringify(errResponse) + "\n");
40990
+ }, TOOL_CALL_TIMEOUT_MS);
40991
+ t2.unref();
40992
+ this.toolTimers.set(id, t2);
40993
+ }
40994
+ clearToolTimeout(id) {
40995
+ const t2 = this.toolTimers.get(id);
40996
+ if (t2) {
40997
+ clearTimeout(t2);
40998
+ this.toolTimers.delete(id);
40999
+ }
41000
+ }
41001
+ clearAllToolTimeouts() {
41002
+ for (const t2 of this.toolTimers.values()) clearTimeout(t2);
41003
+ this.toolTimers.clear();
41004
+ }
40949
41005
  /**
40950
41006
  * Failsafe wrapper for the fire-and-forget call sites (post-response check
40951
41007
  * + the 30 s timer): `maybeRestart` handles the token-fetch failure itself,
@@ -41016,6 +41072,7 @@ var RestartableStdioProxy = class {
41016
41072
  });
41017
41073
  child.on("exit", (code) => {
41018
41074
  if (child !== this.child) return;
41075
+ this.clearAllToolTimeouts();
41019
41076
  this.ended(code ?? 1);
41020
41077
  });
41021
41078
  }
@@ -41148,7 +41205,7 @@ async function mcpRun(args2) {
41148
41205
  // src/commands/version.ts
41149
41206
  var import_picocolors15 = __toESM(require("picocolors"));
41150
41207
  function version2() {
41151
- const v = true ? "2.61.79" : "unknown";
41208
+ const v = true ? "2.61.80" : "unknown";
41152
41209
  console.log(`${import_picocolors15.default.bold("codeam-cli")} ${import_picocolors15.default.cyan(v)}`);
41153
41210
  }
41154
41211
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codeam-cli",
3
- "version": "2.61.79",
3
+ "version": "2.61.80",
4
4
  "description": "Workflow-continuity bridge for AI coding agents. Wrap Claude Code or Codex in a PTY and supervise, approve, and redirect the session from any device — async. The terminal companion for CodeAgent Mobile.",
5
5
  "type": "commonjs",
6
6
  "main": "dist/index.js",