@adhdev/daemon-standalone 1.0.40 → 1.0.41-rc.1

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/dist/index.js CHANGED
@@ -31423,9 +31423,9 @@ var require_streamx = __commonJS({
31423
31423
  }
31424
31424
  });
31425
31425
 
31426
- // ../daemon-core/node_modules/b4a/index.js
31426
+ // ../../node_modules/tar-stream/node_modules/b4a/index.js
31427
31427
  var require_b4a2 = __commonJS({
31428
- "../daemon-core/node_modules/b4a/index.js"(exports2, module2) {
31428
+ "../../node_modules/tar-stream/node_modules/b4a/index.js"(exports2, module2) {
31429
31429
  "use strict";
31430
31430
  function isBuffer(value) {
31431
31431
  return Buffer.isBuffer(value) || value instanceof Uint8Array;
@@ -31581,9 +31581,9 @@ var require_b4a2 = __commonJS({
31581
31581
  }
31582
31582
  });
31583
31583
 
31584
- // ../daemon-core/node_modules/tar-stream/headers.js
31584
+ // ../../node_modules/tar-stream/headers.js
31585
31585
  var require_headers = __commonJS({
31586
- "../daemon-core/node_modules/tar-stream/headers.js"(exports2) {
31586
+ "../../node_modules/tar-stream/headers.js"(exports2) {
31587
31587
  "use strict";
31588
31588
  var b4a = require_b4a2();
31589
31589
  var ZEROS = "0000000000000000000";
@@ -31844,9 +31844,9 @@ var require_headers = __commonJS({
31844
31844
  }
31845
31845
  });
31846
31846
 
31847
- // ../daemon-core/node_modules/tar-stream/extract.js
31847
+ // ../../node_modules/tar-stream/extract.js
31848
31848
  var require_extract = __commonJS({
31849
- "../daemon-core/node_modules/tar-stream/extract.js"(exports2, module2) {
31849
+ "../../node_modules/tar-stream/extract.js"(exports2, module2) {
31850
31850
  "use strict";
31851
31851
  var { Writable, Readable, getStreamError } = require_streamx();
31852
31852
  var FIFO = require_fast_fifo();
@@ -32189,9 +32189,9 @@ var require_extract = __commonJS({
32189
32189
  }
32190
32190
  });
32191
32191
 
32192
- // ../daemon-core/node_modules/tar-stream/constants.js
32192
+ // ../../node_modules/tar-stream/constants.js
32193
32193
  var require_constants = __commonJS({
32194
- "../daemon-core/node_modules/tar-stream/constants.js"(exports2, module2) {
32194
+ "../../node_modules/tar-stream/constants.js"(exports2, module2) {
32195
32195
  "use strict";
32196
32196
  var constants = {
32197
32197
  // just for envs without fs
@@ -32210,9 +32210,9 @@ var require_constants = __commonJS({
32210
32210
  }
32211
32211
  });
32212
32212
 
32213
- // ../daemon-core/node_modules/tar-stream/pack.js
32213
+ // ../../node_modules/tar-stream/pack.js
32214
32214
  var require_pack = __commonJS({
32215
- "../daemon-core/node_modules/tar-stream/pack.js"(exports2, module2) {
32215
+ "../../node_modules/tar-stream/pack.js"(exports2, module2) {
32216
32216
  "use strict";
32217
32217
  var { Readable, Writable, getStreamError } = require_streamx();
32218
32218
  var b4a = require_b4a2();
@@ -32445,9 +32445,9 @@ var require_pack = __commonJS({
32445
32445
  }
32446
32446
  });
32447
32447
 
32448
- // ../daemon-core/node_modules/tar-stream/index.js
32448
+ // ../../node_modules/tar-stream/index.js
32449
32449
  var require_tar_stream = __commonJS({
32450
- "../daemon-core/node_modules/tar-stream/index.js"(exports2) {
32450
+ "../../node_modules/tar-stream/index.js"(exports2) {
32451
32451
  "use strict";
32452
32452
  exports2.extract = require_extract();
32453
32453
  exports2.pack = require_pack();
@@ -32690,9 +32690,9 @@ var require_pump = __commonJS({
32690
32690
  }
32691
32691
  });
32692
32692
 
32693
- // ../daemon-core/node_modules/tar-fs/index.js
32693
+ // ../../node_modules/tar-fs/index.js
32694
32694
  var require_tar_fs = __commonJS({
32695
- "../daemon-core/node_modules/tar-fs/index.js"(exports2) {
32695
+ "../../node_modules/tar-fs/index.js"(exports2) {
32696
32696
  "use strict";
32697
32697
  var tar = require_tar_stream();
32698
32698
  var pump = require_pump();
@@ -36539,10 +36539,10 @@ var require_dist3 = __commonJS({
36539
36539
  }
36540
36540
  function getDaemonBuildInfo() {
36541
36541
  if (cached2) return cached2;
36542
- const commit = readInjected(true ? "b69c800c03574e46aead4f5878b4891592e872e0" : void 0) ?? "unknown";
36543
- const commitShort = readInjected(true ? "b69c800" : void 0) ?? (commit !== "unknown" ? commit.slice(0, 7) : "unknown");
36544
- const version2 = readInjected(true ? "1.0.40" : void 0) ?? readInjected(typeof process !== "undefined" ? process.env?.ADHDEV_PKG_VERSION : void 0) ?? "unknown";
36545
- const builtAt = readInjected(true ? "2026-08-08T11:17:21.191Z" : void 0);
36542
+ const commit = readInjected(true ? "677372ac5df1e74e95aa7c5ffa04ee21dd840f29" : void 0) ?? "unknown";
36543
+ const commitShort = readInjected(true ? "677372ac" : void 0) ?? (commit !== "unknown" ? commit.slice(0, 7) : "unknown");
36544
+ const version2 = readInjected(true ? "1.0.41-rc.1" : void 0) ?? readInjected(typeof process !== "undefined" ? process.env?.ADHDEV_PKG_VERSION : void 0) ?? "unknown";
36545
+ const builtAt = readInjected(true ? "2026-08-08T19:06:28.571Z" : void 0);
36546
36546
  cached2 = builtAt ? { commit, commitShort, version: version2, builtAt } : { commit, commitShort, version: version2 };
36547
36547
  return cached2;
36548
36548
  }
@@ -37800,7 +37800,7 @@ var require_dist3 = __commonJS({
37800
37800
  }
37801
37801
  });
37802
37802
  function resolveBuildTrack(env2 = process.env) {
37803
- const injected = true ? "" : void 0;
37803
+ const injected = true ? "preview" : void 0;
37804
37804
  const stamped = typeof injected === "string" ? injected.trim() : "";
37805
37805
  const raw = (stamped || (env2[BUILD_CHANNEL_ENV_VAR] ?? "").trim()).toLowerCase();
37806
37806
  return raw === "preview" || raw === "next" ? "preview" : "stable";
@@ -40521,7 +40521,7 @@ child.on('exit', () => process.exit(0));
40521
40521
  const platform10 = os42.platform();
40522
40522
  const whichCmd = platform10 === "win32" ? "where" : "which";
40523
40523
  const includeVersion = options?.includeVersion !== false;
40524
- const cliList = providerLoader ? providerLoader.getCliDetectionList() : [];
40524
+ const cliList = providerLoader ? providerLoader.getCliDetectionList({ includeDisabled: options?.includeDisabled }) : [];
40525
40525
  const results = await Promise.all(
40526
40526
  cliList.map(async (cli) => {
40527
40527
  try {
@@ -105895,11 +105895,24 @@ Run 'adhdev doctor' for detailed diagnostics.`
105895
105895
  /**
105896
105896
  * Build CLI/ACP detection list (replaces cli-detector)
105897
105897
  * Dynamically generated from provider.js spawn.command.
105898
+ *
105899
+ * By default this only returns providers already enabled for this machine
105900
+ * (config.machineProviders[type].enabled === true) — that's the right scope
105901
+ * for `launch`, which must not spawn something the user never opted into.
105902
+ *
105903
+ * `includeDisabled: true` returns every cli/acp provider with a spawn
105904
+ * command regardless of the enabled flag, with `enabled` reporting the REAL
105905
+ * per-provider state instead of the hardcoded `true` the gated list implies.
105906
+ * This exists for first-run setup detection: a fresh machine's
105907
+ * machineProviders is `{}` (nothing enabled yet), so the gated list is always
105908
+ * empty and setup could never show what it actually found on disk — the
105909
+ * wizard needs to see candidates BEFORE anything has been enabled.
105898
105910
  */
105899
- getCliDetectionList() {
105911
+ getCliDetectionList(options) {
105900
105912
  const result = [];
105901
105913
  for (const p of this.providers.values()) {
105902
- if ((p.category === "cli" || p.category === "acp") && p.spawn?.command && this.isMachineProviderEnabled(p.type)) {
105914
+ const enabled = this.isMachineProviderEnabled(p.type);
105915
+ if ((p.category === "cli" || p.category === "acp") && p.spawn?.command && (enabled || options?.includeDisabled)) {
105903
105916
  const versionCommand = this.getPlatformVersionCommand(p.versionCommand);
105904
105917
  const command = this.getSpawnCommand(p.type, p.spawn.command);
105905
105918
  const args = this.getSpawnArgs(p.type, p.spawn.args || []);
@@ -105910,7 +105923,7 @@ Run 'adhdev doctor' for detailed diagnostics.`
105910
105923
  command,
105911
105924
  ...args.length > 0 ? { args } : {},
105912
105925
  category: p.category,
105913
- enabled: true,
105926
+ enabled,
105914
105927
  ...typeof versionCommand === "string" && versionCommand.trim() ? { versionCommand: versionCommand.trim() } : {}
105915
105928
  });
105916
105929
  }
@@ -124779,12 +124792,15 @@ ${upgradeFailureNotice.notice}${supersededHint}`);
124779
124792
  });
124780
124793
  providerLoader.loadAll();
124781
124794
  providerLoader.registerToDetector();
124782
- void providerLoader.maybeFirstSyncVerifiedChannel().then((report) => {
124795
+ void providerLoader.maybeFirstSyncVerifiedChannel().then(async (report) => {
124783
124796
  if (!report) return;
124784
124797
  if (report.status === "error") {
124785
124798
  LOG2.warn("Init", `Verified channel first-sync failed (last-known-good preserved): ${report.errors.map((e) => e.code).join(", ") || "unknown"}`);
124786
124799
  } else if (report.activated.length > 0) {
124787
124800
  LOG2.info("Init", `Verified channel first-sync activated ${report.activated.length} providers (${providerLoader.channel})`);
124801
+ providerLoader.registerToDetector();
124802
+ await refreshProviderAvailability();
124803
+ config2.onStatusChange?.();
124788
124804
  }
124789
124805
  }).catch((e) => LOG2.warn("Init", `Verified channel first-sync error: ${e?.message || e}`));
124790
124806
  setDefaultProviderLoader(providerLoader);