codeam-cli 2.76.29 → 2.76.30

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.76.29] — 2026-10-13
8
+
9
+ ### Fixed
10
+
11
+ - **cli:** Run a queued message only after the running turn closes
12
+
7
13
  ## [2.76.28] — 2026-10-13
8
14
 
9
15
  ### Added
package/dist/index.js CHANGED
@@ -10627,7 +10627,7 @@ function readAnonId() {
10627
10627
  }
10628
10628
  function superProperties() {
10629
10629
  return {
10630
- cliVersion: true ? "2.76.29" : "0.0.0-dev",
10630
+ cliVersion: true ? "2.76.30" : "0.0.0-dev",
10631
10631
  nodeVersion: process.version,
10632
10632
  platform: process.platform,
10633
10633
  arch: process.arch,
@@ -10876,7 +10876,7 @@ var http = __toESM(require("http"));
10876
10876
  // package.json
10877
10877
  var package_default = {
10878
10878
  name: "codeam-cli",
10879
- version: "2.76.29",
10879
+ version: "2.76.30",
10880
10880
  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.",
10881
10881
  type: "commonjs",
10882
10882
  main: "dist/index.js",
@@ -11064,7 +11064,9 @@ async function fetchCurrentPluginAuthToken(sessionId, pluginId, pollSecret, onUs
11064
11064
  const data = result?.data;
11065
11065
  if (!data?.paired) return null;
11066
11066
  if (onUserId && typeof data.userId === "string" && data.userId.length > 0) {
11067
- onUserId(data.userId);
11067
+ const user = data.user;
11068
+ const plan = typeof user === "object" && user !== null && "plan" in user && typeof user.plan === "string" ? user.plan : void 0;
11069
+ onUserId(data.userId, plan);
11068
11070
  }
11069
11071
  const token = data.pluginAuthToken;
11070
11072
  return typeof token === "string" && token.length > 0 ? token : null;
@@ -12239,7 +12241,7 @@ var CommandRelayService = class _CommandRelayService {
12239
12241
  // fresh + clear the "CLI update available" banner after a self-update
12240
12242
  // (a codespace that reinstalls @latest reconnects via heartbeat, not
12241
12243
  // pair/reconnect). Older backends ignore the extra field.
12242
- ..."2.76.29" ? { ideVersion: "2.76.29" } : {}
12244
+ ..."2.76.30" ? { ideVersion: "2.76.30" } : {}
12243
12245
  };
12244
12246
  try {
12245
12247
  const res = await _postJson(`${API_BASE2}/api/plugin/heartbeat`, body, this.pollSecretHeader());
@@ -30341,6 +30343,7 @@ function prewarmPreviewDetection(runtime) {
30341
30343
  try {
30342
30344
  const cwd = process.cwd();
30343
30345
  if (await readPreviewConfig(cwd)) return;
30346
+ if (isEmptyScratchProject(cwd)) return;
30344
30347
  const { raw } = await runDetectOneShot(generateOneShot);
30345
30348
  const detection = safeParseDetection(raw);
30346
30349
  if (!detection) {
@@ -47792,12 +47795,14 @@ async function start(requestedAgent, presetSession) {
47792
47795
  `);
47793
47796
  const cwd = process.cwd();
47794
47797
  let reconnectUserId;
47798
+ let reconnectPlan;
47795
47799
  const refreshed = await fetchCurrentPluginAuthToken(
47796
47800
  session.id,
47797
47801
  pluginId,
47798
47802
  session.pollSecret,
47799
- (userId) => {
47803
+ (userId, plan) => {
47800
47804
  reconnectUserId = userId;
47805
+ reconnectPlan = plan;
47801
47806
  }
47802
47807
  );
47803
47808
  if (refreshed && refreshed !== session.pluginAuthToken) {
@@ -47807,8 +47812,11 @@ async function start(requestedAgent, presetSession) {
47807
47812
  } else if (refreshed) {
47808
47813
  showInfo("Reconnected previous session.");
47809
47814
  }
47810
- if (reconnectUserId && reconnectUserId !== session.userId) {
47811
- session.userId = reconnectUserId;
47815
+ const staleUserId = !!reconnectUserId && reconnectUserId !== session.userId;
47816
+ const stalePlan = !!reconnectPlan && reconnectPlan !== session.plan;
47817
+ if (staleUserId || stalePlan) {
47818
+ if (reconnectUserId) session.userId = reconnectUserId;
47819
+ if (reconnectPlan) session.plan = reconnectPlan;
47812
47820
  addSession({ ...session });
47813
47821
  }
47814
47822
  if (session.userId) {
@@ -51413,7 +51421,7 @@ async function autoUpgradeBeforeCriticalCommand() {
51413
51421
  if (process.env.NODE_ENV === "test") return;
51414
51422
  if (process.env.CODEAM_DISABLE_UPDATE_CHECK === "1") return;
51415
51423
  if (process.env.CI) return;
51416
- const current2 = true ? "2.76.29" : null;
51424
+ const current2 = true ? "2.76.30" : null;
51417
51425
  if (!current2) return;
51418
51426
  const cache = readCache();
51419
51427
  const fresh = cache && Date.now() - cache.fetchedAt < TTL_MS;
@@ -51430,7 +51438,7 @@ function checkForUpdates() {
51430
51438
  if (process.env.CODEAM_DISABLE_UPDATE_CHECK === "1") return;
51431
51439
  if (process.env.CI) return;
51432
51440
  if (!process.stdout.isTTY) return;
51433
- const current2 = true ? "2.76.29" : null;
51441
+ const current2 = true ? "2.76.30" : null;
51434
51442
  if (!current2) return;
51435
51443
  const cache = readCache();
51436
51444
  const fresh = cache && Date.now() - cache.fetchedAt < TTL_MS;
@@ -51713,7 +51721,7 @@ var SELF_UPDATE_VIEW_TIMEOUT_MS = 3e4;
51713
51721
  var SELF_UPDATE_INSTALL_TIMEOUT_MS = 18e4;
51714
51722
  var SELF_UPDATE_LS_TIMEOUT_MS = 15e3;
51715
51723
  function currentCliVersion() {
51716
- return true ? "2.76.29" : null;
51724
+ return true ? "2.76.30" : null;
51717
51725
  }
51718
51726
  async function installedVersion(deps) {
51719
51727
  const ls = await deps.run(
@@ -51924,7 +51932,7 @@ function signalHostReady(send = process.send?.bind(process)) {
51924
51932
  }
51925
51933
  function defaultDeps() {
51926
51934
  return {
51927
- ownVersion: true ? "2.76.29" : null,
51935
+ ownVersion: true ? "2.76.30" : null,
51928
51936
  root: cliVersionsRoot(),
51929
51937
  args: process.argv.slice(3),
51930
51938
  execPath: process.execPath,
@@ -54462,7 +54470,7 @@ function checkChokidar() {
54462
54470
  }
54463
54471
  async function doctor(args2 = []) {
54464
54472
  const json = args2.includes("--json");
54465
- const cliVersion = true ? "2.76.29" : "0.0.0-dev";
54473
+ const cliVersion = true ? "2.76.30" : "0.0.0-dev";
54466
54474
  const apiBase2 = resolveApiBaseUrl();
54467
54475
  const diagnosticId = (0, import_node_crypto17.randomUUID)();
54468
54476
  log.info("doctor", `run id=${diagnosticId} cli=${cliVersion}`);
@@ -54998,7 +55006,7 @@ async function mcpWarm(argv = [], opts = {}) {
54998
55006
  // src/commands/version.ts
54999
55007
  var import_picocolors15 = __toESM(require("picocolors"));
55000
55008
  function version2() {
55001
- const v = true ? "2.76.29" : "unknown";
55009
+ const v = true ? "2.76.30" : "unknown";
55002
55010
  console.log(`${import_picocolors15.default.bold("codeam-cli")} ${import_picocolors15.default.cyan(v)}`);
55003
55011
  }
55004
55012
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codeam-cli",
3
- "version": "2.76.29",
3
+ "version": "2.76.30",
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",