@indigoai-us/hq-cli 5.345.219 → 5.345.221

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 (199) hide show
  1. package/CHANGELOG.md +170 -0
  2. package/dist/command-catalog.generated.d.ts +169 -3
  3. package/dist/command-catalog.generated.js +206 -3
  4. package/dist/commands/auth.js +4 -1
  5. package/dist/commands/bot-runtime.d.ts +18 -5
  6. package/dist/commands/bot-runtime.js +29 -12
  7. package/dist/commands/bot.d.ts +85 -0
  8. package/dist/commands/bot.js +245 -16
  9. package/dist/commands/cloud.d.ts +16 -0
  10. package/dist/commands/cloud.js +112 -102
  11. package/dist/commands/core-checkpoint-native.d.ts +13 -0
  12. package/dist/commands/core-checkpoint-native.js +167 -52
  13. package/dist/commands/core-hook-registration-plan.js +5 -4
  14. package/dist/commands/core-stop-autosave.d.ts +21 -0
  15. package/dist/commands/core-stop-autosave.js +300 -0
  16. package/dist/commands/core.js +2 -0
  17. package/dist/commands/daemon.d.ts +5 -0
  18. package/dist/commands/daemon.js +52 -9
  19. package/dist/commands/doctor-usage.d.ts +5 -0
  20. package/dist/commands/doctor-usage.js +25 -0
  21. package/dist/commands/env.d.ts +49 -4
  22. package/dist/commands/env.js +355 -5
  23. package/dist/commands/integrations.js +84 -3
  24. package/dist/commands/lanes-shared.d.ts +3 -0
  25. package/dist/commands/lanes.d.ts +3 -0
  26. package/dist/commands/lanes.js +87 -3
  27. package/dist/commands/packs.js +23 -0
  28. package/dist/commands/pkg-update.d.ts +6 -0
  29. package/dist/commands/pkg-update.js +15 -7
  30. package/dist/commands/run.js +55 -45
  31. package/dist/commands/sources.js +4 -3
  32. package/dist/commands/sync-core.d.ts +1 -0
  33. package/dist/commands/sync-core.js +77 -3
  34. package/dist/commands/whoami.js +96 -80
  35. package/dist/lib/bot/config.d.ts +17 -0
  36. package/dist/lib/bot/config.js +13 -0
  37. package/dist/lib/bot/fleet-cron.js +29 -4
  38. package/dist/lib/bot/fleet-local.d.ts +30 -2
  39. package/dist/lib/bot/fleet-local.js +60 -1
  40. package/dist/lib/bot/grok-login-scope.d.ts +36 -0
  41. package/dist/lib/bot/grok-login-scope.js +93 -0
  42. package/dist/lib/bot/inflight.d.ts +9 -0
  43. package/dist/lib/bot/jobs/hot-signal-sync.d.ts +51 -0
  44. package/dist/lib/bot/jobs/hot-signal-sync.js +90 -9
  45. package/dist/lib/bot/legacy-provider-login.d.ts +32 -9
  46. package/dist/lib/bot/legacy-provider-login.js +28 -22
  47. package/dist/lib/bot/run.d.ts +29 -5
  48. package/dist/lib/bot/run.js +203 -1
  49. package/dist/lib/bot/runtime-sign-in-check.js +6 -1
  50. package/dist/lib/bot/runtime-sign-in.d.ts +2 -0
  51. package/dist/lib/bot/signals-try-now.d.ts +76 -0
  52. package/dist/lib/bot/signals-try-now.js +111 -0
  53. package/dist/lib/capacity/collectors/claude-oauth.d.ts +22 -3
  54. package/dist/lib/capacity/collectors/claude-oauth.js +78 -22
  55. package/dist/lib/capacity/scheduler.d.ts +8 -0
  56. package/dist/lib/capacity/scheduler.js +5 -2
  57. package/dist/lib/core-utils/sentry-report.js +2 -0
  58. package/dist/lib/daemon/machine-checks.d.ts +22 -1
  59. package/dist/lib/daemon/machine-checks.js +54 -12
  60. package/dist/lib/daemon/run.js +71 -8
  61. package/dist/lib/daemon/runtime-notifications.d.ts +7 -0
  62. package/dist/lib/daemon/runtime-notifications.js +50 -0
  63. package/dist/lib/daemon/stop-autosave-lock.d.ts +19 -0
  64. package/dist/lib/daemon/stop-autosave-lock.js +166 -0
  65. package/dist/lib/daemon/stop-autosave.d.ts +28 -0
  66. package/dist/lib/daemon/stop-autosave.js +111 -0
  67. package/dist/lib/daemon/stop-diagnostics.d.ts +11 -0
  68. package/dist/lib/daemon/stop-diagnostics.js +136 -0
  69. package/dist/lib/daemon/stop-job-executor.d.ts +19 -0
  70. package/dist/lib/daemon/stop-job-executor.js +126 -0
  71. package/dist/lib/daemon/stop-jobs.d.ts +93 -0
  72. package/dist/lib/daemon/stop-jobs.js +599 -0
  73. package/dist/lib/doctor/checks/fleet-hook-core.d.ts +9 -1
  74. package/dist/lib/doctor/checks/fleet-hook-core.js +39 -15
  75. package/dist/lib/doctor/checks/host-core.js +1 -1
  76. package/dist/lib/environment/access-probes.d.ts +234 -0
  77. package/dist/lib/environment/access-probes.js +918 -0
  78. package/dist/lib/environment/profile.d.ts +15 -2
  79. package/dist/lib/environment/profile.js +55 -20
  80. package/dist/lib/environment/rfc3339.d.ts +8 -0
  81. package/dist/lib/environment/rfc3339.js +26 -0
  82. package/dist/lib/environment/work-requirements.d.ts +169 -0
  83. package/dist/lib/environment/work-requirements.js +389 -0
  84. package/dist/lib/hook-engine/coverage.d.ts +137 -7
  85. package/dist/lib/hook-engine/coverage.js +1424 -4
  86. package/dist/lib/hook-engine/fleet-registration.d.ts +17 -5
  87. package/dist/lib/hook-engine/fleet-registration.js +53 -17
  88. package/dist/lib/hook-engine/git-stop-config.json +513 -0
  89. package/dist/lib/hook-engine/native-stop-compatibility.json +311 -0
  90. package/dist/lib/hook-engine/reconcile.js +2 -2
  91. package/dist/lib/hot-channels/alert.d.ts +10 -1
  92. package/dist/lib/hot-channels/alert.js +38 -8
  93. package/dist/lib/hot-channels/signals-claude-login.d.ts +53 -0
  94. package/dist/lib/hot-channels/signals-claude-login.js +96 -0
  95. package/dist/lib/hot-channels/signals-pass.d.ts +143 -17
  96. package/dist/lib/hot-channels/signals-pass.js +324 -17
  97. package/dist/lib/hot-channels/signals-runtime.d.ts +30 -0
  98. package/dist/lib/hot-channels/signals-runtime.js +82 -0
  99. package/dist/lib/install/hook-target.js +1 -1
  100. package/dist/lib/lanes/host-capacity.d.ts +26 -2
  101. package/dist/lib/lanes/host-capacity.js +17 -2
  102. package/dist/lib/lanes/host-compute.d.ts +90 -0
  103. package/dist/lib/lanes/host-compute.js +185 -0
  104. package/dist/lib/lanes/index.d.ts +2 -0
  105. package/dist/lib/lanes/index.js +1 -0
  106. package/dist/lib/lanes/reconcile.js +22 -1
  107. package/dist/lib/lanes/resource-usage.d.ts +155 -0
  108. package/dist/lib/lanes/resource-usage.js +589 -0
  109. package/dist/lib/lanes/run-size.d.ts +46 -0
  110. package/dist/lib/lanes/run-size.js +197 -0
  111. package/dist/lib/lanes/store.js +27 -0
  112. package/dist/lib/lanes/throttle.d.ts +36 -1
  113. package/dist/lib/lanes/throttle.js +47 -10
  114. package/dist/lib/lanes/types.d.ts +40 -0
  115. package/dist/lib/lanes/types.js +2 -2
  116. package/dist/lib/lanes/watcher.js +13 -4
  117. package/dist/lib/lanes/worker-process.d.ts +25 -2
  118. package/dist/lib/lanes/worker-process.js +71 -19
  119. package/dist/lib/placement/match.d.ts +192 -0
  120. package/dist/lib/placement/match.js +667 -0
  121. package/dist/lib/safe-store.d.ts +14 -0
  122. package/dist/lib/safe-store.js +77 -4
  123. package/dist/lib/search-index/index.d.ts +88 -4
  124. package/dist/lib/search-index/index.js +299 -25
  125. package/dist/lib/search-index/max-doc-bytes.d.ts +17 -6
  126. package/dist/lib/search-index/max-doc-bytes.js +48 -23
  127. package/dist/lib/signals/codex-lockdown.d.ts +79 -0
  128. package/dist/lib/signals/codex-lockdown.js +271 -0
  129. package/dist/lib/signals/codex-login.d.ts +37 -0
  130. package/dist/lib/signals/codex-login.js +83 -0
  131. package/dist/lib/signals/engine.d.ts +28 -0
  132. package/dist/lib/signals/engine.js +77 -0
  133. package/dist/lib/signals/reply.d.ts +48 -0
  134. package/dist/lib/signals/reply.js +94 -12
  135. package/dist/lib/signals/run-record.js +6 -1
  136. package/dist/lib/signals/settings.d.ts +5 -0
  137. package/dist/lib/signals/settings.js +2 -0
  138. package/dist/lib/signals/steps/adapters.js +6 -0
  139. package/dist/lib/signals/steps/extract.d.ts +135 -12
  140. package/dist/lib/signals/steps/extract.js +416 -84
  141. package/dist/lib/signals/steps/types.d.ts +21 -0
  142. package/dist/lib/sync-core/engine-home.d.ts +41 -2
  143. package/dist/lib/sync-core/engine-home.js +132 -19
  144. package/dist/lib/sync-core/reconcile.js +1 -1
  145. package/dist/lib/sync-core/release-compare.d.ts +7 -0
  146. package/dist/lib/sync-core/release-compare.js +16 -0
  147. package/dist/lib/sync-core/release.d.ts +2 -1
  148. package/dist/lib/sync-core/release.js +2 -10
  149. package/dist/lib/sync-core/rollout-state.d.ts +2 -1
  150. package/dist/lib/sync-core/rollout-state.js +5 -2
  151. package/dist/lib/sync-core/vault-uid.d.ts +2 -0
  152. package/dist/lib/sync-core/vault-uid.js +4 -0
  153. package/dist/run/schema-env-overrides.d.ts +24 -0
  154. package/dist/run/schema-env-overrides.js +72 -0
  155. package/dist/schemas/hq-work-requirements.v1.schema.json +145 -0
  156. package/dist/utils/auth-session-check.d.ts +16 -0
  157. package/dist/utils/auth-session-check.js +16 -0
  158. package/dist/utils/client-health-contract.d.ts +6 -0
  159. package/dist/utils/client-health-contract.js +13 -0
  160. package/dist/utils/client-health.d.ts +7 -0
  161. package/dist/utils/client-health.js +22 -1
  162. package/dist/utils/command-usage.d.ts +40 -0
  163. package/dist/utils/command-usage.js +61 -0
  164. package/dist/utils/duplicate-command-usage.d.ts +72 -0
  165. package/dist/utils/duplicate-command-usage.js +125 -0
  166. package/dist/utils/host-registration.d.ts +1 -1
  167. package/dist/utils/host-registration.js +6 -1
  168. package/dist/utils/resident-package-preload.js +4 -0
  169. package/dist/utils/sentry-fingerprint.js +9 -0
  170. package/dist/utils/windows-bash.d.ts +2 -0
  171. package/dist/utils/windows-bash.js +2 -1
  172. package/package.json +15 -10
  173. package/scripts/bench-core-compare.mjs +313 -0
  174. package/scripts/bench-core.mjs +399 -12
  175. package/scripts/check-function-manifest.mjs +121 -7
  176. package/dist/commands/__fixtures__/access-vault.d.ts +0 -95
  177. package/dist/commands/__fixtures__/access-vault.js +0 -166
  178. package/dist/commands/__fixtures__/make-tar.d.ts +0 -38
  179. package/dist/commands/__fixtures__/make-tar.js +0 -102
  180. package/dist/commands/secrets-public-types.test-d.d.ts +0 -2
  181. package/dist/commands/secrets-public-types.test-d.js +0 -18
  182. package/dist/lib/decisions/fixtures/us001.d.ts +0 -137
  183. package/dist/lib/decisions/fixtures/us001.js +0 -21
  184. package/dist/lib/doctor/__testing__/fake-hq-tree.d.ts +0 -226
  185. package/dist/lib/doctor/__testing__/fake-hq-tree.js +0 -408
  186. package/dist/lib/doctor/__testing__/run-doctor.d.ts +0 -8
  187. package/dist/lib/doctor/__testing__/run-doctor.js +0 -69
  188. package/dist/lib/fingerprint/fixtures.d.ts +0 -19
  189. package/dist/lib/fingerprint/fixtures.js +0 -61
  190. package/dist/lib/hot-channels/adapters/__fixtures__/dummy.d.ts +0 -33
  191. package/dist/lib/hot-channels/adapters/__fixtures__/dummy.js +0 -53
  192. package/dist/lib/hot-channels/adapters/__fixtures__/meeting-providers.d.ts +0 -38
  193. package/dist/lib/hot-channels/adapters/__fixtures__/meeting-providers.js +0 -64
  194. package/dist/lib/mesh/live/daemon/mqtt-events.test-d.d.ts +0 -2
  195. package/dist/lib/mesh/live/daemon/mqtt-events.test-d.js +0 -10
  196. package/dist/lib/test-utils/isolated-flag-company-context.d.ts +0 -3
  197. package/dist/lib/test-utils/isolated-flag-company-context.js +0 -18
  198. package/scripts/hook-engine-manifest.mjs +0 -22
  199. package/scripts/mesh-daemon-if-stale.mjs +0 -20
@@ -155,6 +155,10 @@ export interface OpenStoreDirOptions {
155
155
  export interface ReadOptions {
156
156
  /** Refuse a file larger than this. Default 1 MiB. */
157
157
  maxBytes?: number;
158
+ /** Read a bounded window from an append-only queue rather than the whole file. */
159
+ offset?: number;
160
+ /** Include the opened file's device/inode identity for queue cursors. */
161
+ identity?: boolean;
158
162
  }
159
163
  export interface AppendOptions {
160
164
  /** Refuse to append when the file is already this size or larger. */
@@ -173,6 +177,7 @@ export interface FileFacts {
173
177
  /** FileFacts plus the exact modification time in nanoseconds (mtimeMs is a float and can round across a millisecond). */
174
178
  export interface ReadFacts extends FileFacts {
175
179
  mtimeNs: bigint;
180
+ fileIdentity?: string;
176
181
  }
177
182
  export interface RenameOptions {
178
183
  /** Waits in milliseconds between rename attempts on EPERM, EACCES or EBUSY (Windows). Empty: no retry. */
@@ -212,9 +217,18 @@ export interface SafeStore {
212
217
  remove(name: string): SafeStoreResult<boolean>;
213
218
  /** The names in the folder. */
214
219
  list(): SafeStoreResult<string[]>;
220
+ /** Read directory names in bounded batches without materializing the directory. */
221
+ nameCursor(): SafeStoreResult<SafeStoreNameCursor>;
215
222
  /** Release the held folder. Later calls are refused with "closed". */
216
223
  close(): void;
217
224
  }
225
+ export interface SafeStoreNameCursor {
226
+ read(maxNames: number): SafeStoreResult<{
227
+ names: string[];
228
+ done: boolean;
229
+ }>;
230
+ close(): void;
231
+ }
218
232
  /** A plain file name: no separator, no NUL, not "." or "..", at most 255 bytes. */
219
233
  export declare function isPlainName(name: string): boolean;
220
234
  /** Owner and mode facts a check needs, from fs.Stats or fs.BigIntStats. */
@@ -602,12 +602,17 @@ class HeldStore {
602
602
  return opened;
603
603
  const { fd, stat } = opened.value;
604
604
  try {
605
- if (stat.size > BigInt(maxBytes))
605
+ const offset = options.offset ?? 0;
606
+ if (!Number.isSafeInteger(offset) || offset < 0)
607
+ return refusal("io-error", "invalid read offset");
608
+ if (options.offset === undefined && stat.size > BigInt(maxBytes))
606
609
  return refusal("too-large", `the file is larger than ${maxBytes} bytes`);
607
- const buffer = Buffer.alloc(maxBytes + 1);
610
+ const buffer = Buffer.alloc(maxBytes + (options.offset === undefined ? 1 : 0));
608
611
  let length = 0;
609
612
  for (;;) {
610
- const count = fs.readSync(fd, buffer, length, buffer.length - length, null);
613
+ if (length === buffer.length)
614
+ break;
615
+ const count = fs.readSync(fd, buffer, length, buffer.length - length, offset + length);
611
616
  if (count === 0)
612
617
  break;
613
618
  length += count;
@@ -615,7 +620,8 @@ class HeldStore {
615
620
  return refusal("too-large", `the file is larger than ${maxBytes} bytes`);
616
621
  }
617
622
  // Bigint stats round mtimeMs down to a whole millisecond; mtimeNs keeps the fraction.
618
- const facts = { size: length, mtimeMs: Number(stat.mtimeNs) / 1e6, mtimeNs: stat.mtimeNs };
623
+ const facts = { size: length, mtimeMs: Number(stat.mtimeNs) / 1e6, mtimeNs: stat.mtimeNs,
624
+ ...(options.identity ? { fileIdentity: `${stat.dev}:${stat.ino}` } : {}) };
619
625
  return { ok: true, value: { data: Buffer.from(buffer.subarray(0, length)), facts } };
620
626
  }
621
627
  catch (error) {
@@ -759,6 +765,73 @@ class HeldStore {
759
765
  return afterList;
760
766
  return { ok: true, value: names };
761
767
  }
768
+ nameCursor() {
769
+ const refused = this.start("list");
770
+ if (refused)
771
+ return refused;
772
+ let directory;
773
+ try {
774
+ directory = fs.opendirSync(this.base, { bufferSize: 32 });
775
+ }
776
+ catch (error) {
777
+ return ioError("opening directory cursor", error);
778
+ }
779
+ let closed = false;
780
+ const close = () => {
781
+ if (closed)
782
+ return;
783
+ closed = true;
784
+ try {
785
+ directory.closeSync();
786
+ }
787
+ catch { /* already closed */ }
788
+ };
789
+ const checked = this.check();
790
+ if (checked) {
791
+ close();
792
+ return checked;
793
+ }
794
+ return { ok: true, value: {
795
+ close,
796
+ read: (maxNames) => {
797
+ const before = this.start("list");
798
+ if (before) {
799
+ close();
800
+ return before;
801
+ }
802
+ if (closed)
803
+ return { ok: true, value: { names: [], done: true } };
804
+ if (!Number.isSafeInteger(maxNames) || maxNames < 1 || maxNames > 256) {
805
+ close();
806
+ return ioError("reading directory cursor", new Error("invalid batch size"));
807
+ }
808
+ const names = [];
809
+ let done = false;
810
+ try {
811
+ while (names.length < maxNames) {
812
+ const entry = directory.readSync();
813
+ if (!entry) {
814
+ done = true;
815
+ close();
816
+ break;
817
+ }
818
+ names.push(entry.name);
819
+ }
820
+ }
821
+ catch (error) {
822
+ close();
823
+ return ioError("reading directory cursor", error);
824
+ }
825
+ this.at("after-list", "list");
826
+ const after = this.check();
827
+ if (after) {
828
+ close();
829
+ return after;
830
+ }
831
+ return { ok: true, value: { names, done } };
832
+ },
833
+ } };
834
+ }
762
835
  close() {
763
836
  if (this.closed)
764
837
  return;
@@ -141,6 +141,77 @@ export declare class QmdCollectionExistsError extends QmdExitError {
141
141
  name: string;
142
142
  constructor(message: string, args: string[], status: number | null, stdout: string, stderr: string, collectionName: string);
143
143
  }
144
+ /**
145
+ * qmd's `collection add` exited non-zero because ANOTHER collection already
146
+ * covers exactly this path and pattern (qmd 2.5.3 prints "A collection already
147
+ * exists for this path and pattern:" and then `Name: <other> (qmd://<other>/)`).
148
+ * For unmanaged names, reconciliation skips its own add, prints a notice and
149
+ * carries on. HQ-managed name collisions remain fatal and captured. Before
150
+ * this, the duplicate aborted the whole `hq index sync`, so no collection was
151
+ * ever updated again on that machine (HQ-CLI-GJ).
152
+ */
153
+ export declare class QmdCollectionPathTakenError extends QmdExitError {
154
+ readonly existingName: string;
155
+ name: string;
156
+ constructor(message: string, args: string[], status: number | null, stdout: string, stderr: string, existingName: string);
157
+ }
158
+ /**
159
+ * hq or its qmd child was refused READ access to the HQ folder: EPERM/EACCES on
160
+ * `uv_cwd` (qmd's process.cwd() in the HQ root), or on a scandir/open of a path
161
+ * inside the HQ root. On macOS an EPERM there is the privacy (TCC) gate on a
162
+ * protected location such as Documents, Desktop or iCloud Drive. The message is
163
+ * the platform-specific remedy; the carrier is thrown marked expected, so the
164
+ * boundary prints it and skips capture (HQ-CLI-EJ, HQ-CLI-FV, HQ-CLI-BV,
165
+ * HQ-CLI-FF).
166
+ */
167
+ export declare class QmdAccessDeniedError extends QmdExitError {
168
+ readonly deniedPath: string;
169
+ readonly errnoCode: 'EPERM' | 'EACCES';
170
+ readonly syscall: string;
171
+ name: string;
172
+ constructor(message: string, args: string[], status: number | null, stdout: string, stderr: string, deniedPath: string, errnoCode: 'EPERM' | 'EACCES', syscall: string);
173
+ }
174
+ /**
175
+ * qmd could not create or write its own settings folder (QMD_CONFIG_DIR,
176
+ * $XDG_CONFIG_HOME/qmd or ~/.config/qmd): EPERM/EACCES on a path at or above
177
+ * that folder. The user's account cannot write there, typically because the
178
+ * folder was created by a command run with sudo. Thrown marked expected with
179
+ * the remedy as its message (HQ-CLI-GJ).
180
+ */
181
+ export declare class QmdConfigUnwritableError extends QmdExitError {
182
+ readonly configDir: string;
183
+ readonly errnoCode: 'EPERM' | 'EACCES';
184
+ name: string;
185
+ constructor(message: string, args: string[], status: number | null, stdout: string, stderr: string, configDir: string, errnoCode: 'EPERM' | 'EACCES');
186
+ }
187
+ /**
188
+ * qmd's SQLite index file is damaged (SQLITE_CORRUPT / SQLITE_NOTADB). qmd
189
+ * reports it as "sqlite-vec extension is unavailable ... Install Homebrew
190
+ * SQLite", which cannot fix a damaged file. hq names the file and the rebuild
191
+ * step instead. Still captured, because a trend of damaged index files would
192
+ * point at a writer bug (HQ-CLI-EJ).
193
+ */
194
+ export declare class QmdStoreCorruptError extends QmdExitError {
195
+ readonly storeFile: string | undefined;
196
+ name: string;
197
+ constructor(message: string, args: string[], status: number | null, stdout: string, stderr: string, storeFile: string | undefined);
198
+ }
199
+ type QmdPermissionFailure = {
200
+ code: 'EPERM' | 'EACCES';
201
+ syscall: string;
202
+ path?: string;
203
+ };
204
+ /**
205
+ * Parse an unambiguous fatal Node permission error from stderr, for example
206
+ * `Error: EPERM: operation not permitted, uv_cwd` or
207
+ * `[Error: EACCES: permission denied, mkdir '/home/u/.config/qmd']`.
208
+ * Incidental warnings and output containing another thrown error stay captured.
209
+ */
210
+ export declare function parseQmdPermissionFailure(text: string): QmdPermissionFailure | undefined;
211
+ /** Remedy for a refused read of the HQ folder, worded for the platform. */
212
+ export declare function qmdAccessDeniedMessage(deniedPath: string, code: 'EPERM' | 'EACCES', platform?: NodeJS.Platform): string;
213
+ /** Remedy for a qmd settings folder the user cannot write. */
214
+ export declare function qmdConfigUnwritableMessage(configDir: string, deniedPath: string, syscall: string, platform?: NodeJS.Platform): string;
144
215
  /**
145
216
  * qmd did NOT exit — it was KILLED BY A SIGNAL before it finished (spawnSync
146
217
  * reports `status: null` with a non-null `signal`). hq-cli passes qmd no timeout
@@ -553,6 +624,13 @@ export type ReconcileCollectionsOptions = {
553
624
  runner?: QmdProcessRunner;
554
625
  /** Test seam for the default-off collection-path repair rollout. */
555
626
  repairPathDrift?: boolean;
627
+ /** Where reconciliation notices go (default: process.stderr). */
628
+ writeStderr?: (text: string) => void;
629
+ /**
630
+ * File that records one-time notices already shown (default
631
+ * `<hqRoot>/.hq/search-index-notices.json`); `null` disables the record.
632
+ */
633
+ noticesFile?: string | null;
556
634
  };
557
635
  /**
558
636
  * Register expected collections that qmd does not yet know about, returning the
@@ -566,10 +644,16 @@ export type ReconcileCollectionsOptions = {
566
644
  * NOT a failure. Reconciliation still issues the `context add`, whose qmd-side
567
645
  * resyncConfig re-syncs YAML into SQLite and heals the divergence that provoked
568
646
  * the retry, then continues with later collections; such a pre-existing
569
- * collection is excluded from the returned list. Every other qmd failure still
570
- * propagates: the DIFFERENT path+pattern duplicate, a same-name duplicate that
571
- * named a different collection, a missing collection, a `context add` failure,
572
- * a missing/unbuilt qmd binary. HQ-CLI-Q (Sentry 7670823899).
647
+ * collection is excluded from the returned list.
648
+ *
649
+ * An unmanaged path+pattern duplicate is not fatal: the files are indexed under
650
+ * that name, but scoped search misses them. Print a notice, skip this add and
651
+ * its `context add`, and continue. It used to abort the whole sync, so
652
+ * `qmd update` never ran again on that machine (HQ-CLI-GJ).
653
+ *
654
+ * Every other qmd failure still propagates: a same-name duplicate that named a
655
+ * different collection, a missing collection, a `context add` failure, a
656
+ * missing/unbuilt qmd binary. HQ-CLI-Q (Sentry 7670823899).
573
657
  */
574
658
  export declare function reconcileCollections(hqRoot: string, options?: ReconcileCollectionsOptions): SearchCollection[];
575
659
  export declare function listRegisteredCollections(hqRoot: string, options?: RunQmdOptions): Set<string>;