codeam-cli 2.60.31 → 2.60.32
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 +6 -0
- package/dist/index.js +58 -18
- package/package.json +1 -1
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.60.31] — 2026-07-10
|
|
8
|
+
|
|
9
|
+
### Tests
|
|
10
|
+
|
|
11
|
+
- **cli:** Fix kimi-config-provision (login removed) + stabilize Windows waitForBinary
|
|
12
|
+
|
|
7
13
|
## [2.60.29] — 2026-07-10
|
|
8
14
|
|
|
9
15
|
### Added
|
package/dist/index.js
CHANGED
|
@@ -5689,7 +5689,7 @@ function readAnonId() {
|
|
|
5689
5689
|
}
|
|
5690
5690
|
function superProperties() {
|
|
5691
5691
|
return {
|
|
5692
|
-
cliVersion: true ? "2.60.
|
|
5692
|
+
cliVersion: true ? "2.60.32" : "0.0.0-dev",
|
|
5693
5693
|
nodeVersion: process.version,
|
|
5694
5694
|
platform: process.platform,
|
|
5695
5695
|
arch: process.arch,
|
|
@@ -5870,7 +5870,7 @@ var os4 = __toESM(require("os"));
|
|
|
5870
5870
|
// package.json
|
|
5871
5871
|
var package_default = {
|
|
5872
5872
|
name: "codeam-cli",
|
|
5873
|
-
version: "2.60.
|
|
5873
|
+
version: "2.60.32",
|
|
5874
5874
|
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.",
|
|
5875
5875
|
type: "commonjs",
|
|
5876
5876
|
main: "dist/index.js",
|
|
@@ -6963,7 +6963,7 @@ var CommandRelayService = class {
|
|
|
6963
6963
|
// fresh + clear the "CLI update available" banner after a self-update
|
|
6964
6964
|
// (a codespace that reinstalls @latest reconnects via heartbeat, not
|
|
6965
6965
|
// pair/reconnect). Older backends ignore the extra field.
|
|
6966
|
-
..."2.60.
|
|
6966
|
+
..."2.60.32" ? { ideVersion: "2.60.32" } : {}
|
|
6967
6967
|
}).then(() => log.trace("relay", `heartbeat ok online=${online}`)).catch((err) => log.trace("relay", `heartbeat failed online=${online}`, err));
|
|
6968
6968
|
}
|
|
6969
6969
|
/**
|
|
@@ -17197,7 +17197,7 @@ async function autoUpgradeBeforeCriticalCommand() {
|
|
|
17197
17197
|
if (process.env.NODE_ENV === "test") return;
|
|
17198
17198
|
if (process.env.CODEAM_DISABLE_UPDATE_CHECK === "1") return;
|
|
17199
17199
|
if (process.env.CI) return;
|
|
17200
|
-
const current = true ? "2.60.
|
|
17200
|
+
const current = true ? "2.60.32" : null;
|
|
17201
17201
|
if (!current) return;
|
|
17202
17202
|
const cache = readCache();
|
|
17203
17203
|
const fresh = cache && Date.now() - cache.fetchedAt < TTL_MS;
|
|
@@ -17214,7 +17214,7 @@ function checkForUpdates() {
|
|
|
17214
17214
|
if (process.env.CODEAM_DISABLE_UPDATE_CHECK === "1") return;
|
|
17215
17215
|
if (process.env.CI) return;
|
|
17216
17216
|
if (!process.stdout.isTTY) return;
|
|
17217
|
-
const current = true ? "2.60.
|
|
17217
|
+
const current = true ? "2.60.32" : null;
|
|
17218
17218
|
if (!current) return;
|
|
17219
17219
|
const cache = readCache();
|
|
17220
17220
|
const fresh = cache && Date.now() - cache.fetchedAt < TTL_MS;
|
|
@@ -17234,7 +17234,7 @@ var SELF_UPDATE_INTERVAL_MS = 60 * 60 * 1e3;
|
|
|
17234
17234
|
var SELF_UPDATE_VIEW_TIMEOUT_MS = 3e4;
|
|
17235
17235
|
var SELF_UPDATE_INSTALL_TIMEOUT_MS = 18e4;
|
|
17236
17236
|
function currentCliVersion() {
|
|
17237
|
-
return true ? "2.60.
|
|
17237
|
+
return true ? "2.60.32" : null;
|
|
17238
17238
|
}
|
|
17239
17239
|
function runCmd(cmd, args2, timeoutMs) {
|
|
17240
17240
|
return new Promise((resolve7) => {
|
|
@@ -26254,6 +26254,14 @@ var AcpClient = class {
|
|
|
26254
26254
|
* swallows the Code Assist onboarding error and never rejects `newSession`,
|
|
26255
26255
|
* so without this the session hangs forever ("loading… / offline"). */
|
|
26256
26256
|
startupFailureReject = null;
|
|
26257
|
+
/** Set for the WHOLE initial handshake (initialize → newSession). The child
|
|
26258
|
+
* `exit` handler calls it when the adapter dies mid-startup — e.g. it crashes
|
|
26259
|
+
* at `import` (ERR_MODULE_NOT_FOUND on a still-installing dep) BEFORE the
|
|
26260
|
+
* `initialize` response the handshake awaits would ever arrive. Without it,
|
|
26261
|
+
* `startOnce` hangs on that response and `start()`'s transient-retry never
|
|
26262
|
+
* engages; with it, the crash rejects immediately → retry respawns once the
|
|
26263
|
+
* install settles. Broader than {@link startupFailureReject} (newSession-only). */
|
|
26264
|
+
startAbortReject = null;
|
|
26257
26265
|
/**
|
|
26258
26266
|
* Spawn the adapter + handshake, retrying a TRANSIENT in-adapter spawn race.
|
|
26259
26267
|
*
|
|
@@ -26286,10 +26294,22 @@ var AcpClient = class {
|
|
|
26286
26294
|
}
|
|
26287
26295
|
throw lastErr;
|
|
26288
26296
|
}
|
|
26289
|
-
/** True when a failed {@link startOnce} was caused by
|
|
26290
|
-
*
|
|
26291
|
-
*
|
|
26292
|
-
*
|
|
26297
|
+
/** True when a failed {@link startOnce} was caused by a TRANSIENT install
|
|
26298
|
+
* race that clears within ms, so respawning the adapter recovers. Two
|
|
26299
|
+
* distinct races, both fresh-codespace only:
|
|
26300
|
+
* 1. The adapter's OWN spawn of the agent binary (`claude-agent-acp`
|
|
26301
|
+
* exec'ing the ~250 MB SDK-bundled `claude`) mid-atomic-rename →
|
|
26302
|
+
* `ETXTBSY`/`ENOENT`.
|
|
26303
|
+
* 2. The adapter's OWN `import` of a still-installing dependency
|
|
26304
|
+
* (`claude-agent-acp` importing `@anthropic-ai/claude-agent-sdk/sdk.mjs`
|
|
26305
|
+
* before npm finished the package's atomic rename) → the node process
|
|
26306
|
+
* exits at load with `ERR_MODULE_NOT_FOUND` / a truncated-file
|
|
26307
|
+
* `SyntaxError` (2026-07-10 incident: EVERY codespace claude deploy died
|
|
26308
|
+
* "The claude agent failed to start" here — the pre-spawn module-graph
|
|
26309
|
+
* gate probes just BEFORE the real spawn, leaving a TOCTOU window npm's
|
|
26310
|
+
* rename slips through). {@link ADAPTER_MODULE_LOAD_ERROR_RE} matches it.
|
|
26311
|
+
* Checks the thrown error's message/data AND the adapter stderr ring — the
|
|
26312
|
+
* adapter logs the real cause to stderr while returning a generic error. */
|
|
26293
26313
|
isTransientAdapterSpawn(err) {
|
|
26294
26314
|
const parts = [...this.recentStderr];
|
|
26295
26315
|
if (err instanceof Error) parts.push(err.message);
|
|
@@ -26301,7 +26321,8 @@ var AcpClient = class {
|
|
|
26301
26321
|
}
|
|
26302
26322
|
if (typeof e.details === "string") parts.push(e.details);
|
|
26303
26323
|
}
|
|
26304
|
-
|
|
26324
|
+
const joined = parts.join(" ");
|
|
26325
|
+
return TRANSIENT_ADAPTER_SPAWN_RE.test(joined) || ADAPTER_MODULE_LOAD_ERROR_RE.test(joined);
|
|
26305
26326
|
}
|
|
26306
26327
|
async startOnce() {
|
|
26307
26328
|
if (this.child) throw new Error("AcpClient already started");
|
|
@@ -26340,6 +26361,16 @@ var AcpClient = class {
|
|
|
26340
26361
|
child.on("exit", (code, signal) => {
|
|
26341
26362
|
if (this.stopping) return;
|
|
26342
26363
|
log.warn("acpClient", `adapter exited unexpectedly code=${code} signal=${signal}`);
|
|
26364
|
+
if (this.startAbortReject) {
|
|
26365
|
+
const tail = this.recentStderr.slice(-6).join(" | ");
|
|
26366
|
+
this.startAbortReject(
|
|
26367
|
+
new Error(
|
|
26368
|
+
`ADAPTER_EXITED_DURING_START code=${code} signal=${signal}${tail ? ` \u2014 ${tail}` : ""}`
|
|
26369
|
+
)
|
|
26370
|
+
);
|
|
26371
|
+
this.startAbortReject = null;
|
|
26372
|
+
return;
|
|
26373
|
+
}
|
|
26343
26374
|
this.opts.onUnexpectedExit?.(code, signal);
|
|
26344
26375
|
});
|
|
26345
26376
|
child.on("error", (err) => {
|
|
@@ -26361,11 +26392,17 @@ var AcpClient = class {
|
|
|
26361
26392
|
(_agent) => this.buildClient(),
|
|
26362
26393
|
stream
|
|
26363
26394
|
);
|
|
26364
|
-
|
|
26365
|
-
|
|
26366
|
-
protocolVersion: PROTOCOL_VERSION2,
|
|
26367
|
-
clientCapabilities: CLIENT_CAPABILITIES
|
|
26395
|
+
const startAborted = new Promise((_2, reject) => {
|
|
26396
|
+
this.startAbortReject = reject;
|
|
26368
26397
|
});
|
|
26398
|
+
log.info("acpClient", "initialize \u2192 sending");
|
|
26399
|
+
const initialize = await Promise.race([
|
|
26400
|
+
this.connection.initialize({
|
|
26401
|
+
protocolVersion: PROTOCOL_VERSION2,
|
|
26402
|
+
clientCapabilities: CLIENT_CAPABILITIES
|
|
26403
|
+
}),
|
|
26404
|
+
startAborted
|
|
26405
|
+
]);
|
|
26369
26406
|
log.info(
|
|
26370
26407
|
"acpClient",
|
|
26371
26408
|
`initialize \u2190 ok protocolVersion=${initialize.protocolVersion} agentCaps=${JSON.stringify(initialize.agentCapabilities ?? {}).slice(0, 200)}`
|
|
@@ -26389,12 +26426,14 @@ var AcpClient = class {
|
|
|
26389
26426
|
try {
|
|
26390
26427
|
newSession = await Promise.race([
|
|
26391
26428
|
this.connection.newSession({ cwd, mcpServers: [] }),
|
|
26392
|
-
startupFailure
|
|
26429
|
+
startupFailure,
|
|
26430
|
+
startAborted
|
|
26393
26431
|
]);
|
|
26394
26432
|
} finally {
|
|
26395
26433
|
if (startupTimer) clearTimeout(startupTimer);
|
|
26396
26434
|
this.startupFailureReject = null;
|
|
26397
26435
|
}
|
|
26436
|
+
this.startAbortReject = null;
|
|
26398
26437
|
this.sessionId = newSession.sessionId;
|
|
26399
26438
|
const newSessionMeta = newSession;
|
|
26400
26439
|
log.info(
|
|
@@ -26429,6 +26468,7 @@ var AcpClient = class {
|
|
|
26429
26468
|
this.connection = null;
|
|
26430
26469
|
this.sessionId = null;
|
|
26431
26470
|
this.startupFailureReject = null;
|
|
26471
|
+
this.startAbortReject = null;
|
|
26432
26472
|
}
|
|
26433
26473
|
/**
|
|
26434
26474
|
* Send a user prompt to the active session. Returns the
|
|
@@ -34187,7 +34227,7 @@ function checkChokidar() {
|
|
|
34187
34227
|
}
|
|
34188
34228
|
async function doctor(args2 = []) {
|
|
34189
34229
|
const json = args2.includes("--json");
|
|
34190
|
-
const cliVersion = true ? "2.60.
|
|
34230
|
+
const cliVersion = true ? "2.60.32" : "0.0.0-dev";
|
|
34191
34231
|
const apiBase2 = resolveApiBaseUrl();
|
|
34192
34232
|
const diagnosticId = (0, import_node_crypto12.randomUUID)();
|
|
34193
34233
|
log.info("doctor", `run id=${diagnosticId} cli=${cliVersion}`);
|
|
@@ -34386,7 +34426,7 @@ async function completion(args2) {
|
|
|
34386
34426
|
// src/commands/version.ts
|
|
34387
34427
|
var import_picocolors15 = __toESM(require("picocolors"));
|
|
34388
34428
|
function version2() {
|
|
34389
|
-
const v = true ? "2.60.
|
|
34429
|
+
const v = true ? "2.60.32" : "unknown";
|
|
34390
34430
|
console.log(`${import_picocolors15.default.bold("codeam-cli")} ${import_picocolors15.default.cyan(v)}`);
|
|
34391
34431
|
}
|
|
34392
34432
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codeam-cli",
|
|
3
|
-
"version": "2.60.
|
|
3
|
+
"version": "2.60.32",
|
|
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",
|