@indigoai-us/hq-cli 5.345.149 → 5.345.151

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 (34) hide show
  1. package/CHANGELOG.md +46 -0
  2. package/dist/command-catalog.generated.d.ts +18 -6
  3. package/dist/command-catalog.generated.js +21 -6
  4. package/dist/commands/_patterns.d.ts +6 -0
  5. package/dist/commands/_patterns.js +6 -0
  6. package/dist/commands/cloud-off-gate.d.ts +138 -0
  7. package/dist/commands/cloud-off-gate.js +234 -0
  8. package/dist/commands/cloud.d.ts +7 -0
  9. package/dist/commands/cloud.js +59 -17
  10. package/dist/commands/core-handoff.js +6 -1
  11. package/dist/commands/groups.js +9 -6
  12. package/dist/commands/lanes-questions.js +7 -4
  13. package/dist/commands/lanes.js +13 -6
  14. package/dist/commands/meetings.js +7 -3
  15. package/dist/commands/members.d.ts +35 -0
  16. package/dist/commands/members.js +65 -14
  17. package/dist/commands/secrets.d.ts +5 -0
  18. package/dist/commands/secrets.js +11 -6
  19. package/dist/hq-cloud-sync-runner/bin/sync-runner.js +63282 -62480
  20. package/dist/hq-cloud-sync-runner/package.json +1 -1
  21. package/dist/lib/daemon/catalog.d.ts +7 -0
  22. package/dist/lib/daemon/catalog.js +10 -1
  23. package/dist/lib/daemon/run.js +13 -0
  24. package/dist/lib/flag-registry-worker-source.generated.d.ts +1 -1
  25. package/dist/lib/flag-registry-worker-source.generated.js +1 -1
  26. package/dist/lib/lanes/index.d.ts +1 -1
  27. package/dist/lib/lanes/index.js +1 -1
  28. package/dist/lib/lanes/links.js +27 -11
  29. package/dist/lib/lanes/store.d.ts +11 -0
  30. package/dist/lib/lanes/store.js +20 -0
  31. package/dist/lib/lanes/watch.js +5 -3
  32. package/dist/lib/vault-sync-switches.d.ts +41 -0
  33. package/dist/lib/vault-sync-switches.js +86 -0
  34. package/package.json +8 -8
@@ -1 +1 @@
1
- {"name":"hq-cli-daemon-sync-runner","type":"module","version":"6.18.88","bundleSha256":"7e9ee380eae55e059a474fd5f415e8aeb16088805b761d791318d5299645becd","formatVersion":1}
1
+ {"name":"hq-cli-daemon-sync-runner","type":"module","version":"6.18.90","bundleSha256":"cb49486573d2d1141ee6e18d73dde825f2b7c02074560f19504e3b1daf7eeba8","formatVersion":1}
@@ -13,6 +13,7 @@ import type { MachineType } from "./machine-type.js";
13
13
  import type { SyncOwner } from "./config.js";
14
14
  import type { RemoteControlPoolsConfig } from "./remote-control-pools.js";
15
15
  import { type SyncRunnerProcess } from "./sync-runner.js";
16
+ import { type VaultSyncSwitches } from "../vault-sync-switches.js";
16
17
  export declare const SERVICE_NAMES: readonly ["sync", "mesh", "heartbeat", "inbox", "bots", "remote-control", "codex-remote-control", "session-host", "lanes-reconcile", "search-index", "jobs-reconcile", "updater", "housekeeping"];
17
18
  export type ServiceName = (typeof SERVICE_NAMES)[number];
18
19
  export declare function isServiceName(value: unknown): value is ServiceName;
@@ -103,6 +104,12 @@ export interface PlanContext {
103
104
  instantSyncEnabled?: boolean;
104
105
  /** Keep the local sync runner stopped until the operator resumes it. */
105
106
  syncPaused: boolean;
107
+ /**
108
+ * The desktop app's Settings > Sync switches on this computer (US-016).
109
+ * Off vaults are skipped by the runner; all off keeps the unit stopped.
110
+ * Absent means every vault is on.
111
+ */
112
+ vaultSync?: VaultSyncSwitches;
106
113
  /** Persisted/effective owner selected for this machine. */
107
114
  syncOwner: SyncOwner;
108
115
  /** A legacy desktop app or sync unit is still managing sync. */
@@ -10,6 +10,7 @@
10
10
  * them instead of silently dropping them.
11
11
  */
12
12
  import { SYNC_RUNNER_OWNER, syncRunnerUnleasedBlockReason } from "./sync-runner.js";
13
+ import { vaultSkipEnv } from "../vault-sync-switches.js";
13
14
  export const SERVICE_NAMES = [
14
15
  "sync",
15
16
  "mesh",
@@ -142,7 +143,11 @@ function planService(service, ctx) {
142
143
  SYNC_RUNNER_OWNER,
143
144
  ],
144
145
  },
145
- env: { ...ctx.legacySyncEnv, HQ_SYNC_PASS_REQUEST_DIR: ctx.syncPassRequestsDir },
146
+ env: {
147
+ ...ctx.legacySyncEnv,
148
+ ...(ctx.vaultSync ? vaultSkipEnv(ctx.vaultSync) : {}),
149
+ HQ_SYNC_PASS_REQUEST_DIR: ctx.syncPassRequestsDir,
150
+ },
146
151
  heartbeatTimeoutMs: ctx.syncHeartbeatTimeoutMs,
147
152
  });
148
153
  let ownerBlock;
@@ -160,6 +165,10 @@ function planService(service, ctx) {
160
165
  }
161
166
  unit.blocked = firstBlock([
162
167
  [ctx.syncPaused, "sync is paused (run `hq daemon sync resume`)"],
168
+ [
169
+ ctx.vaultSync?.allOff === true,
170
+ "cloud sync is off for every vault on this computer (turn it back on in HQ Settings > Sync)",
171
+ ],
163
172
  [!ctx.hqRoot, NO_HQ_ROOT],
164
173
  [!ctx.signedIn, NOT_SIGNED_IN],
165
174
  [!!ownerBlock, ownerBlock ?? ""],
@@ -32,6 +32,7 @@ import { DAEMON_CHILD_BOOTSTRAP_HANDOFF_WATCH_FLAG, DAEMON_LANES_RECONCILE_FILE_
32
32
  import { createLanesReconcileWatcher } from "./lanes-reconcile-watcher.js";
33
33
  import { findLegacyUnits, legacyMeshUnitsToRetire, legacyOwnerLookup } from "./legacy.js";
34
34
  import { readLegacySyncEnv } from "./legacy-sync-env.js";
35
+ import { readVaultSyncSwitches, unreadableSwitchesWarning } from "../vault-sync-switches.js";
35
36
  import { acquireDaemonLock, isProcessAlive, processCommandLine, releaseDaemonLock } from "./lock.js";
36
37
  import { retireLegacyMeshUnits } from "./migrate.js";
37
38
  import { daemonDir as meshDaemonDir, daemonPidPath as meshDaemonPidPath } from "../mesh/live/daemon/paths.js";
@@ -581,6 +582,8 @@ export async function runDaemon(opts) {
581
582
  finishSuccession(succession, tracker.records(), log);
582
583
  /** Service processes this daemon spawned, so a handoff can let go of them. */
583
584
  const spawned = new Set();
585
+ /** Last unreadable-settings warning logged, so it is logged once per change. */
586
+ let lastVaultSyncWarning;
584
587
  const updatable = cliSelfUpdatable();
585
588
  const hostName = os.hostname().split(".")[0] || "hq-host";
586
589
  let legacyCache = null;
@@ -949,6 +952,16 @@ export async function runDaemon(opts) {
949
952
  signedIn: isSignedIn,
950
953
  kitConfigured: fs.existsSync(agentKitPaths(home, env).kitConfigPath),
951
954
  syncPaused: config.syncPaused === true,
955
+ vaultSync: (() => {
956
+ const switches = readVaultSyncSwitches(home);
957
+ // Log once per change, not every reconcile.
958
+ if (switches.unreadable !== lastVaultSyncWarning) {
959
+ if (switches.unreadable)
960
+ log("warn", unreadableSwitchesWarning(switches.unreadable));
961
+ lastVaultSyncWarning = switches.unreadable;
962
+ }
963
+ return switches;
964
+ })(),
952
965
  syncOwner,
953
966
  desktopAppManagesSync: appManagesSync,
954
967
  syncRunnerProcesses,