@indigoai-us/hq-cli 5.345.139 → 5.345.140

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
@@ -2,6 +2,9 @@
2
2
 
3
3
  ## [Unreleased]
4
4
 
5
+ ## [5.345.140] — 2026-10-16
6
+ - `hq auth status` now reports the machine token cache when HQ runs under a machine identity (fleet agents and other machine sign-ins). Before, it read only the person token file and reported "no cached session yet" on a machine that held a valid machine session, even though `hq auth refresh` had just renewed it.
7
+
5
8
  ## [5.345.139] — 2026-10-15
6
9
  - `hq storage offload` and `hq storage fetch` no longer fail about 15 to 25 minutes into a run. Personal and company
7
10
  vault credentials are now re-vended before they expire, for the whole run and in the middle of a multipart upload.
@@ -21,7 +21,7 @@ import { open, realpath } from "node:fs/promises";
21
21
  import path from "node:path";
22
22
  import chalk from "chalk";
23
23
  import { browserLogin, clearCachedTokens, loadCachedTokens, isExpiring, loadMachineCreds, CognitoAuthError, } from "@indigoai-us/hq-cloud";
24
- import { DEFAULT_COGNITO, refreshCachedSession, resolveCognitoTokenSource, ensureMachineSessionTokens, personTokenCacheFile, machineTokenCacheFile, } from "../utils/cognito-session.js";
24
+ import { DEFAULT_COGNITO, refreshCachedSession, resolveCognitoTokenSource, ensureMachineSessionTokens, personTokenCacheFile, machineTokenCacheFile, loadMachineCachedTokens, } from "../utils/cognito-session.js";
25
25
  // Static (node builtins only): a lazy import here would need a resident
26
26
  // preload entry for the auth-login path.
27
27
  import * as tokenKeychain from "../utils/token-keychain.js";
@@ -358,7 +358,11 @@ export function registerAuthCommands(program) {
358
358
  // the person cache rejected (transient refresh errors still report person).
359
359
  const tokenSource = resolveCognitoTokenSource();
360
360
  const machine = tokenSource === "machine";
361
- const cached = loadCachedTokens();
361
+ // Machine tokens live in the daemon state dir, never ~/.hq. Reading the
362
+ // person cache here reported "no cached session" on agent boxes whose
363
+ // machine cache was valid, and could show a stale person session as the
364
+ // machine one.
365
+ const cached = machine ? loadMachineCachedTokens() : loadCachedTokens();
362
366
  if (!cached) {
363
367
  if (machine) {
364
368
  // No cached session yet, but machine creds mint one on demand —
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@indigoai-us/hq-cli",
3
- "version": "5.345.139",
3
+ "version": "5.345.140",
4
4
  "description": "HQ by Indigo management CLI — modules and cloud sync",
5
5
  "main": "dist/index.js",
6
6
  "bin": {