@camstack/system 1.1.57 → 1.1.58

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 (50) hide show
  1. package/dist/addon-runner.js +2 -2
  2. package/dist/addon-runner.mjs +2 -2
  3. package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.js +1 -1
  4. package/dist/builtins/addon-pages-aggregator/addon-pages-aggregator.addon.mjs +1 -1
  5. package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.js +1 -1
  6. package/dist/builtins/addon-widgets-aggregator/addon-widgets-aggregator.addon.mjs +1 -1
  7. package/dist/builtins/alerts/alerts.addon.js +1 -1
  8. package/dist/builtins/alerts/alerts.addon.mjs +1 -1
  9. package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.js +1 -1
  10. package/dist/builtins/backup-orchestrator/backup-orchestrator.addon.mjs +1 -1
  11. package/dist/builtins/console-logging/index.js +1 -1
  12. package/dist/builtins/console-logging/index.mjs +1 -1
  13. package/dist/builtins/device-manager/device-manager.addon.js +1 -1
  14. package/dist/builtins/device-manager/device-manager.addon.mjs +1 -1
  15. package/dist/builtins/doorbell/virtual-doorbell.addon.js +1 -1
  16. package/dist/builtins/doorbell/virtual-doorbell.addon.mjs +1 -1
  17. package/dist/builtins/hub-forwarder/index.js +1 -1
  18. package/dist/builtins/hub-forwarder/index.mjs +1 -1
  19. package/dist/builtins/local-auth/local-auth.addon.js +1 -1
  20. package/dist/builtins/local-auth/local-auth.addon.mjs +1 -1
  21. package/dist/builtins/local-network/local-network.addon.js +1 -1
  22. package/dist/builtins/local-network/local-network.addon.mjs +1 -1
  23. package/dist/builtins/native-metrics/native-metrics.addon.js +1 -1
  24. package/dist/builtins/native-metrics/native-metrics.addon.mjs +1 -1
  25. package/dist/builtins/platform-probe/index.js +1 -1
  26. package/dist/builtins/platform-probe/index.mjs +1 -1
  27. package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.js +1 -1
  28. package/dist/builtins/remote-access-orchestrator/remote-access-orchestrator.addon.mjs +1 -1
  29. package/dist/builtins/snapshot/index.js +1 -1
  30. package/dist/builtins/snapshot/index.mjs +1 -1
  31. package/dist/builtins/sqlite-storage/filesystem-storage.addon.js +1 -1
  32. package/dist/builtins/sqlite-storage/filesystem-storage.addon.mjs +1 -1
  33. package/dist/builtins/sqlite-storage/sqlite-settings.addon.js +1 -1
  34. package/dist/builtins/sqlite-storage/sqlite-settings.addon.mjs +1 -1
  35. package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.js +1 -1
  36. package/dist/builtins/storage-orchestrator/storage-orchestrator.addon.mjs +1 -1
  37. package/dist/builtins/system-config/system-config.addon.js +1 -1
  38. package/dist/builtins/system-config/system-config.addon.mjs +1 -1
  39. package/dist/builtins/winston-logging/index.js +1 -1
  40. package/dist/builtins/winston-logging/index.mjs +1 -1
  41. package/dist/{dist-JAF9YR1q.mjs → dist-BNevCEAo.mjs} +0 -70
  42. package/dist/{dist-Bg795EQF.js → dist-BY6NWf-c.js} +0 -70
  43. package/dist/index.js +34 -105
  44. package/dist/index.mjs +35 -104
  45. package/dist/kernel/index.d.ts +1 -3
  46. package/dist/kernel/lifecycle/lifecycle-job-engine.d.ts +21 -26
  47. package/dist/{manifest-python-deps-eI3-3FeW.js → manifest-python-deps-D2G0DFWp.js} +1 -1
  48. package/dist/{manifest-python-deps-9wuRyL-k.mjs → manifest-python-deps-DtCMZhuR.mjs} +1 -1
  49. package/package.json +1 -1
  50. package/dist/kernel/lifecycle/framework-staging.d.ts +0 -15
@@ -1,6 +1,6 @@
1
1
  const require_chunk = require("./chunk-Cek0wNdY.js");
2
- const require_dist = require("./dist-Bg795EQF.js");
3
- const require_manifest_python_deps = require("./manifest-python-deps-eI3-3FeW.js");
2
+ const require_dist = require("./dist-BY6NWf-c.js");
3
+ const require_manifest_python_deps = require("./manifest-python-deps-D2G0DFWp.js");
4
4
  const require_custom_action_registry = require("./custom-action-registry-vLYEFTtv.js");
5
5
  let node_fs = require("node:fs");
6
6
  node_fs = require_chunk.__toESM(node_fs);
@@ -1,5 +1,5 @@
1
- import { j as isCollectionArrayMethod, t as ALL_CAPABILITY_DEFINITIONS } from "./dist-JAF9YR1q.mjs";
2
- import { F as createUdsLoggerWithControl, I as LocalChildClient, bt as resolveAddonClass, i as createUdsAddonContext, it as setWorkerNativeCapsChangeListener, nt as getWorkerNativeCapSnapshot, ot as validateProviderRegistrations, t as installManifestPythonDeps, tt as getWorkerNativeCapProvider, vt as installManifestNativeDeps } from "./manifest-python-deps-9wuRyL-k.mjs";
1
+ import { j as isCollectionArrayMethod, t as ALL_CAPABILITY_DEFINITIONS } from "./dist-BNevCEAo.mjs";
2
+ import { F as createUdsLoggerWithControl, I as LocalChildClient, bt as resolveAddonClass, i as createUdsAddonContext, it as setWorkerNativeCapsChangeListener, nt as getWorkerNativeCapSnapshot, ot as validateProviderRegistrations, t as installManifestPythonDeps, tt as getWorkerNativeCapProvider, vt as installManifestNativeDeps } from "./manifest-python-deps-DtCMZhuR.mjs";
3
3
  import { t as CustomActionRegistry } from "./custom-action-registry-BEXwC-oo.mjs";
4
4
  import { register } from "node:module";
5
5
  import * as fs from "node:fs";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  const require_settle_sources = require("../../settle-sources-Bhsy57y-.js");
8
8
  let node_fs = require("node:fs");
9
9
  node_fs = require_chunk.__toESM(node_fs);
@@ -1,4 +1,4 @@
1
- import { f as addonPagesCapability, it as BaseAddon, kt as EventCategory, rt as errMsg } from "../../dist-JAF9YR1q.mjs";
1
+ import { f as addonPagesCapability, it as BaseAddon, kt as EventCategory, rt as errMsg } from "../../dist-BNevCEAo.mjs";
2
2
  import { t as settleSourcesWithTimeout } from "../../settle-sources-CDtNC8ub.mjs";
3
3
  import * as fs from "node:fs";
4
4
  import * as path$1 from "node:path";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  const require_settle_sources = require("../../settle-sources-Bhsy57y-.js");
8
8
  let node_fs = require("node:fs");
9
9
  node_fs = require_chunk.__toESM(node_fs);
@@ -1,4 +1,4 @@
1
- import { it as BaseAddon, kt as EventCategory, m as addonWidgetsCapability, rt as errMsg } from "../../dist-JAF9YR1q.mjs";
1
+ import { it as BaseAddon, kt as EventCategory, m as addonWidgetsCapability, rt as errMsg } from "../../dist-BNevCEAo.mjs";
2
2
  import { t as settleSourcesWithTimeout } from "../../settle-sources-CDtNC8ub.mjs";
3
3
  import * as fs from "node:fs";
4
4
  import * as path$1 from "node:path";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  //#region src/builtins/alerts/alerts.addon.ts
8
8
  var CATEGORY_MAPPINGS = {
9
9
  "addon.crashed": {
@@ -1,4 +1,4 @@
1
- import { _t as createEvent, h as alertsCapability, it as BaseAddon, kt as EventCategory, n as AlertSchema, rt as errMsg } from "../../dist-JAF9YR1q.mjs";
1
+ import { _t as createEvent, h as alertsCapability, it as BaseAddon, kt as EventCategory, n as AlertSchema, rt as errMsg } from "../../dist-BNevCEAo.mjs";
2
2
  //#region src/builtins/alerts/alerts.addon.ts
3
3
  var CATEGORY_MAPPINGS = {
4
4
  "addon.crashed": {
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  let node_fs = require("node:fs");
8
8
  let node_fs$1 = require_chunk.__toESM(node_fs, 1);
9
9
  node_fs = require_chunk.__toESM(node_fs);
@@ -1,4 +1,4 @@
1
- import { it as BaseAddon, kt as EventCategory, v as backupCapability } from "../../dist-JAF9YR1q.mjs";
1
+ import { it as BaseAddon, kt as EventCategory, v as backupCapability } from "../../dist-BNevCEAo.mjs";
2
2
  import * as fs from "node:fs";
3
3
  import Kt from "node:fs";
4
4
  import * as path$1 from "node:path";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  const require_formatter = require("../../formatter-DqAKDlvN.js");
8
8
  //#region src/builtins/console-logging/console-destination.ts
9
9
  var LEVEL_RANK = {
@@ -1,4 +1,4 @@
1
- import { L as logDestinationCapability, it as BaseAddon } from "../../dist-JAF9YR1q.mjs";
1
+ import { L as logDestinationCapability, it as BaseAddon } from "../../dist-BNevCEAo.mjs";
2
2
  import { t as formatLogLine } from "../../formatter-B7qW8bPJ.mjs";
3
3
  //#region src/builtins/console-logging/console-destination.ts
4
4
  var LEVEL_RANK = {
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  let _camstack_types_node = require("@camstack/types/node");
8
8
  let zod = require("zod");
9
9
  let node_crypto = require("node:crypto");
@@ -1,4 +1,4 @@
1
- import { E as evaluateLinkExpression, J as setByPath, Ot as sleep, S as deviceStatusCapability, St as isDeviceConfigCap, T as enumerateSchemaFields, U as parseStreamParamsFormPatch, V as normalizeUnit, a as DeviceStatusSchema, b as deviceManagerCapability, c as STREAM_PROFILE_META, ct as DeviceFeature, et as toExpressionValue, g as applyTransform, i as CAP_NAMES_WITH_STATUS, it as BaseAddon, k as getByPath, kt as EventCategory, lt as DeviceRole, nt as validateExpressionSource, pt as WELL_KNOWN_TAB_MAP, rt as errMsg, t as ALL_CAPABILITY_DEFINITIONS, ut as DeviceType, w as enumerateItemArrayFields, x as deviceStateCapability, y as buildStreamParamsConfigSchema } from "../../dist-JAF9YR1q.mjs";
1
+ import { E as evaluateLinkExpression, J as setByPath, Ot as sleep, S as deviceStatusCapability, St as isDeviceConfigCap, T as enumerateSchemaFields, U as parseStreamParamsFormPatch, V as normalizeUnit, a as DeviceStatusSchema, b as deviceManagerCapability, c as STREAM_PROFILE_META, ct as DeviceFeature, et as toExpressionValue, g as applyTransform, i as CAP_NAMES_WITH_STATUS, it as BaseAddon, k as getByPath, kt as EventCategory, lt as DeviceRole, nt as validateExpressionSource, pt as WELL_KNOWN_TAB_MAP, rt as errMsg, t as ALL_CAPABILITY_DEFINITIONS, ut as DeviceType, w as enumerateItemArrayFields, x as deviceStateCapability, y as buildStreamParamsConfigSchema } from "../../dist-BNevCEAo.mjs";
2
2
  import { canonicalDeviceFingerprint } from "@camstack/types/node";
3
3
  import { z } from "zod";
4
4
  import { randomUUID } from "node:crypto";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  //#region src/builtins/doorbell/trigger-engine.ts
8
8
  /**
9
9
  * Pure trigger logic for the virtual-doorbell builtin — edge detection over
@@ -1,4 +1,4 @@
1
- import { C as doorbellCapability, _t as createEvent, it as BaseAddon, kt as EventCategory, rt as errMsg, ut as DeviceType } from "../../dist-JAF9YR1q.mjs";
1
+ import { C as doorbellCapability, _t as createEvent, it as BaseAddon, kt as EventCategory, rt as errMsg, ut as DeviceType } from "../../dist-BNevCEAo.mjs";
2
2
  //#region src/builtins/doorbell/trigger-engine.ts
3
3
  /**
4
4
  * Pure trigger logic for the virtual-doorbell builtin — edge detection over
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  const require_formatter = require("../../formatter-DqAKDlvN.js");
8
8
  //#region src/builtins/hub-forwarder/hub-forwarder-destination.ts
9
9
  var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
@@ -1,4 +1,4 @@
1
- import { L as logDestinationCapability, it as BaseAddon } from "../../dist-JAF9YR1q.mjs";
1
+ import { L as logDestinationCapability, it as BaseAddon } from "../../dist-BNevCEAo.mjs";
2
2
  import { t as formatLogLine } from "../../formatter-B7qW8bPJ.mjs";
3
3
  //#region src/builtins/hub-forwarder/hub-forwarder-destination.ts
4
4
  var DEFAULT_OUTBOUND_BUFFER_SIZE = 500;
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  let node_crypto = require("node:crypto");
8
8
  node_crypto = require_chunk.__toESM(node_crypto);
9
9
  let crypto$1 = require("crypto");
@@ -1,4 +1,4 @@
1
- import { _ as authProviderCapability, d as UserRecordSchema, it as BaseAddon, l as ScopedTokenSchema, r as ApiKeyRecordSchema, tt as userManagementCapability } from "../../dist-JAF9YR1q.mjs";
1
+ import { _ as authProviderCapability, d as UserRecordSchema, it as BaseAddon, l as ScopedTokenSchema, r as ApiKeyRecordSchema, tt as userManagementCapability } from "../../dist-BNevCEAo.mjs";
2
2
  import { createRequire } from "node:module";
3
3
  import * as crypto$1 from "node:crypto";
4
4
  import { randomUUID } from "node:crypto";
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_chunk = require("../../chunk-Cek0wNdY.js");
3
- const require_dist = require("../../dist-Bg795EQF.js");
3
+ const require_dist = require("../../dist-BY6NWf-c.js");
4
4
  let node_os = require("node:os");
5
5
  node_os = require_chunk.__toESM(node_os);
6
6
  //#region src/builtins/local-network/local-network.addon.ts
@@ -1,4 +1,4 @@
1
- import { I as localNetworkCapability, it as BaseAddon, kt as EventCategory } from "../../dist-JAF9YR1q.mjs";
1
+ import { I as localNetworkCapability, it as BaseAddon, kt as EventCategory } from "../../dist-BNevCEAo.mjs";
2
2
  import * as os from "node:os";
3
3
  //#region src/builtins/local-network/local-network.addon.ts
4
4
  /**
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  let node_fs = require("node:fs");
8
8
  node_fs = require_chunk.__toESM(node_fs);
9
9
  let node_child_process = require("node:child_process");
@@ -1,4 +1,4 @@
1
- import { _t as createEvent, it as BaseAddon, kt as EventCategory, z as metricsProviderCapability } from "../../dist-JAF9YR1q.mjs";
1
+ import { _t as createEvent, it as BaseAddon, kt as EventCategory, z as metricsProviderCapability } from "../../dist-BNevCEAo.mjs";
2
2
  import * as fs from "node:fs";
3
3
  import { execFile, execFileSync } from "node:child_process";
4
4
  import { promisify } from "node:util";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  let node_fs = require("node:fs");
8
8
  node_fs = require_chunk.__toESM(node_fs);
9
9
  let node_child_process = require("node:child_process");
@@ -1,4 +1,4 @@
1
- import { W as platformProbeCapability, it as BaseAddon, kt as EventCategory, q as scoreRuntimes, rt as errMsg, yt as emitReadiness } from "../../dist-JAF9YR1q.mjs";
1
+ import { W as platformProbeCapability, it as BaseAddon, kt as EventCategory, q as scoreRuntimes, rt as errMsg, yt as emitReadiness } from "../../dist-BNevCEAo.mjs";
2
2
  import * as fs from "node:fs";
3
3
  import { execFile } from "node:child_process";
4
4
  import { promisify } from "node:util";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  //#region src/builtins/remote-access-orchestrator/enabled-providers-reconcile.ts
8
8
  /**
9
9
  * Reconcile the durable `enabledProviders` set against authoritative
@@ -1,4 +1,4 @@
1
- import { it as BaseAddon, kt as EventCategory } from "../../dist-JAF9YR1q.mjs";
1
+ import { it as BaseAddon, kt as EventCategory } from "../../dist-BNevCEAo.mjs";
2
2
  //#region src/builtins/remote-access-orchestrator/enabled-providers-reconcile.ts
3
3
  /**
4
4
  * Reconcile the durable `enabledProviders` set against authoritative
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  let node_child_process = require("node:child_process");
8
8
  //#region src/builtins/snapshot/snapshot-coalescing.ts
9
9
  /**
@@ -1,4 +1,4 @@
1
- import { $ as streamQualityLabel, B as nodePin, X as snapshotCapability, ct as DeviceFeature, it as BaseAddon, rt as errMsg, ut as DeviceType } from "../../dist-JAF9YR1q.mjs";
1
+ import { $ as streamQualityLabel, B as nodePin, X as snapshotCapability, ct as DeviceFeature, it as BaseAddon, rt as errMsg, ut as DeviceType } from "../../dist-BNevCEAo.mjs";
2
2
  import { execFile } from "node:child_process";
3
3
  //#region src/builtins/snapshot/snapshot-coalescing.ts
4
4
  /**
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  let node_fs = require("node:fs");
8
8
  node_fs = require_chunk.__toESM(node_fs);
9
9
  let node_path = require("node:path");
@@ -1,4 +1,4 @@
1
- import { O as filesystemBrowseCapability, Q as storageProviderCapability, it as BaseAddon } from "../../dist-JAF9YR1q.mjs";
1
+ import { O as filesystemBrowseCapability, Q as storageProviderCapability, it as BaseAddon } from "../../dist-BNevCEAo.mjs";
2
2
  import * as fs from "node:fs";
3
3
  import * as path$1 from "node:path";
4
4
  import { basename, dirname, join, resolve, sep } from "node:path";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  let node_crypto = require("node:crypto");
8
8
  let better_sqlite3 = require("better-sqlite3");
9
9
  better_sqlite3 = require_chunk.__toESM(better_sqlite3);
@@ -1,4 +1,4 @@
1
- import { Y as settingsStoreCapability, it as BaseAddon, mt as asJsonObject, rt as errMsg, s as RUNTIME_DEFAULTS, wt as parseJsonUnknown } from "../../dist-JAF9YR1q.mjs";
1
+ import { Y as settingsStoreCapability, it as BaseAddon, mt as asJsonObject, rt as errMsg, s as RUNTIME_DEFAULTS, wt as parseJsonUnknown } from "../../dist-BNevCEAo.mjs";
2
2
  import { randomUUID } from "node:crypto";
3
3
  import Database from "better-sqlite3";
4
4
  //#region src/builtins/sqlite-storage/sqlite-settings-backend.ts
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  let node_path = require("node:path");
8
8
  node_path = require_chunk.__toESM(node_path);
9
9
  let node_fs_promises = require("node:fs/promises");
@@ -1,4 +1,4 @@
1
- import { Ct as parseJsonObject, Z as storageCapability, it as BaseAddon, u as StorageLocationTypeSchema } from "../../dist-JAF9YR1q.mjs";
1
+ import { Ct as parseJsonObject, Z as storageCapability, it as BaseAddon, u as StorageLocationTypeSchema } from "../../dist-BNevCEAo.mjs";
2
2
  import * as path$1 from "node:path";
3
3
  import * as fs from "node:fs/promises";
4
4
  import { buildStorageLocationRegistry } from "@camstack/system";
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  //#region src/builtins/system-config/system-config.addon.ts
8
8
  /**
9
9
  * Built-in `system-config` addon — Phase 4 of the settings redesign.
@@ -1,4 +1,4 @@
1
- import { it as BaseAddon, rt as errMsg, xt as hydrateSchema } from "../../dist-JAF9YR1q.mjs";
1
+ import { it as BaseAddon, rt as errMsg, xt as hydrateSchema } from "../../dist-BNevCEAo.mjs";
2
2
  //#region src/builtins/system-config/system-config.addon.ts
3
3
  /**
4
4
  * Built-in `system-config` addon — Phase 4 of the settings redesign.
@@ -3,7 +3,7 @@ Object.defineProperties(exports, {
3
3
  [Symbol.toStringTag]: { value: "Module" }
4
4
  });
5
5
  const require_chunk = require("../../chunk-Cek0wNdY.js");
6
- const require_dist = require("../../dist-Bg795EQF.js");
6
+ const require_dist = require("../../dist-BY6NWf-c.js");
7
7
  const require_formatter = require("../../formatter-DqAKDlvN.js");
8
8
  let node_path = require("node:path");
9
9
  node_path = require_chunk.__toESM(node_path);
@@ -1,4 +1,4 @@
1
- import { L as logDestinationCapability, it as BaseAddon } from "../../dist-JAF9YR1q.mjs";
1
+ import { L as logDestinationCapability, it as BaseAddon } from "../../dist-BNevCEAo.mjs";
2
2
  import { t as formatLogLine } from "../../formatter-B7qW8bPJ.mjs";
3
3
  import * as path$1 from "node:path";
4
4
  import path from "node:path";
@@ -19108,22 +19108,6 @@ var AddonAutoUpdateSchema = ChannelWithInheritSchema;
19108
19108
  var RestartAddonResultSchema = z.unknown();
19109
19109
  var InstallPackageResultSchema = z.unknown();
19110
19110
  var ReloadPackagesResultSchema = z.unknown();
19111
- /**
19112
- * Result of `updateFrameworkPackage`. The cap method returns BEFORE the
19113
- * server restarts so the admin UI can react to the `restartingAt`
19114
- * timestamp (shows reconnect overlay). The transition from
19115
- * `fromVersion` to `toVersion` will be confirmed by a subsequent
19116
- * `system.restart-completed` event after the new process boots.
19117
- *
19118
- * Spec: docs/superpowers/specs/2026-05-14-framework-live-update-design.md
19119
- */
19120
- var UpdateFrameworkPackageResultSchema = z.object({
19121
- packageName: z.string(),
19122
- fromVersion: z.string(),
19123
- toVersion: z.string(),
19124
- /** Ms-epoch the server scheduled its self-restart. */
19125
- restartingAt: z.number()
19126
- });
19127
19111
  var BulkUpdateItemStatusSchema = z.enum([
19128
19112
  "queued",
19129
19113
  "updating",
@@ -19369,28 +19353,6 @@ var addonsCapability = {
19369
19353
  kind: "mutation",
19370
19354
  auth: "admin"
19371
19355
  }),
19372
- /**
19373
- * Live-update one of the framework packages marked
19374
- * `camstack.system: true` (`@camstack/types|kernel|core|sdk|ui-library`).
19375
- * Runs `npm install --prefix <appRoot> <name>@<version> --no-save`,
19376
- * writes a `.restart-pending` marker, emits `system.restarting`
19377
- * and schedules a graceful process exit. The supervisor (Docker /
19378
- * Electron / systemd) brings the hub back up; on first boot after
19379
- * the restart the marker fires `system.restart-completed`.
19380
- *
19381
- * `version` defaults to `'latest'`. The allow-list of valid
19382
- * `packageName` values is enforced server-side.
19383
- *
19384
- * Spec: docs/superpowers/specs/2026-05-14-framework-live-update-design.md
19385
- */
19386
- updateFrameworkPackage: method(z.object({
19387
- packageName: z.string().min(1),
19388
- version: z.string().optional(),
19389
- deferRestart: z.boolean().optional()
19390
- }), UpdateFrameworkPackageResultSchema, {
19391
- kind: "mutation",
19392
- auth: "admin"
19393
- }),
19394
19356
  getVersions: method(z.object({ name: z.string() }), z.array(PackageVersionInfoSchema).readonly()),
19395
19357
  restartAddon: method(z.object({ addonId: z.string() }), RestartAddonResultSchema, {
19396
19358
  kind: "mutation",
@@ -22682,12 +22644,6 @@ var METHOD_ACCESS_MAP = Object.freeze({
22682
22644
  addonId: null,
22683
22645
  access: "delete"
22684
22646
  },
22685
- "addons.updateFrameworkPackage": {
22686
- capName: "addons",
22687
- capScope: "system",
22688
- addonId: null,
22689
- access: "create"
22690
- },
22691
22647
  "addons.updatePackage": {
22692
22648
  capName: "addons",
22693
22649
  capScope: "system",
@@ -27276,32 +27232,6 @@ Object.freeze({
27276
27232
  "network-access": "ingress",
27277
27233
  "smtp-provider": "email"
27278
27234
  });
27279
- var frameworkSwapPackageSchema = z.object({
27280
- name: z.string(),
27281
- stagedPath: z.string(),
27282
- backupPath: z.string(),
27283
- toVersion: z.string(),
27284
- fromVersion: z.string().nullable()
27285
- });
27286
- z.object({
27287
- jobId: z.string(),
27288
- taskId: z.string(),
27289
- packages: z.array(frameworkSwapPackageSchema),
27290
- requestedAtMs: z.number(),
27291
- schemaVersion: z.literal(1)
27292
- });
27293
- z.object({
27294
- jobId: z.string(),
27295
- taskId: z.string(),
27296
- backups: z.array(z.object({
27297
- name: z.string(),
27298
- backupPath: z.string(),
27299
- livePath: z.string()
27300
- })),
27301
- appliedAtMs: z.number(),
27302
- bootAttempts: z.number(),
27303
- schemaVersion: z.literal(1)
27304
- });
27305
27235
  /**
27306
27236
  * Scores all applicable inference backends for the given hardware.
27307
27237
  *
@@ -19108,22 +19108,6 @@ var AddonAutoUpdateSchema = ChannelWithInheritSchema;
19108
19108
  var RestartAddonResultSchema = zod.z.unknown();
19109
19109
  var InstallPackageResultSchema = zod.z.unknown();
19110
19110
  var ReloadPackagesResultSchema = zod.z.unknown();
19111
- /**
19112
- * Result of `updateFrameworkPackage`. The cap method returns BEFORE the
19113
- * server restarts so the admin UI can react to the `restartingAt`
19114
- * timestamp (shows reconnect overlay). The transition from
19115
- * `fromVersion` to `toVersion` will be confirmed by a subsequent
19116
- * `system.restart-completed` event after the new process boots.
19117
- *
19118
- * Spec: docs/superpowers/specs/2026-05-14-framework-live-update-design.md
19119
- */
19120
- var UpdateFrameworkPackageResultSchema = zod.z.object({
19121
- packageName: zod.z.string(),
19122
- fromVersion: zod.z.string(),
19123
- toVersion: zod.z.string(),
19124
- /** Ms-epoch the server scheduled its self-restart. */
19125
- restartingAt: zod.z.number()
19126
- });
19127
19111
  var BulkUpdateItemStatusSchema = zod.z.enum([
19128
19112
  "queued",
19129
19113
  "updating",
@@ -19369,28 +19353,6 @@ var addonsCapability = {
19369
19353
  kind: "mutation",
19370
19354
  auth: "admin"
19371
19355
  }),
19372
- /**
19373
- * Live-update one of the framework packages marked
19374
- * `camstack.system: true` (`@camstack/types|kernel|core|sdk|ui-library`).
19375
- * Runs `npm install --prefix <appRoot> <name>@<version> --no-save`,
19376
- * writes a `.restart-pending` marker, emits `system.restarting`
19377
- * and schedules a graceful process exit. The supervisor (Docker /
19378
- * Electron / systemd) brings the hub back up; on first boot after
19379
- * the restart the marker fires `system.restart-completed`.
19380
- *
19381
- * `version` defaults to `'latest'`. The allow-list of valid
19382
- * `packageName` values is enforced server-side.
19383
- *
19384
- * Spec: docs/superpowers/specs/2026-05-14-framework-live-update-design.md
19385
- */
19386
- updateFrameworkPackage: method(zod.z.object({
19387
- packageName: zod.z.string().min(1),
19388
- version: zod.z.string().optional(),
19389
- deferRestart: zod.z.boolean().optional()
19390
- }), UpdateFrameworkPackageResultSchema, {
19391
- kind: "mutation",
19392
- auth: "admin"
19393
- }),
19394
19356
  getVersions: method(zod.z.object({ name: zod.z.string() }), zod.z.array(PackageVersionInfoSchema).readonly()),
19395
19357
  restartAddon: method(zod.z.object({ addonId: zod.z.string() }), RestartAddonResultSchema, {
19396
19358
  kind: "mutation",
@@ -22682,12 +22644,6 @@ var METHOD_ACCESS_MAP = Object.freeze({
22682
22644
  addonId: null,
22683
22645
  access: "delete"
22684
22646
  },
22685
- "addons.updateFrameworkPackage": {
22686
- capName: "addons",
22687
- capScope: "system",
22688
- addonId: null,
22689
- access: "create"
22690
- },
22691
22647
  "addons.updatePackage": {
22692
22648
  capName: "addons",
22693
22649
  capScope: "system",
@@ -27276,32 +27232,6 @@ Object.freeze({
27276
27232
  "network-access": "ingress",
27277
27233
  "smtp-provider": "email"
27278
27234
  });
27279
- var frameworkSwapPackageSchema = zod.z.object({
27280
- name: zod.z.string(),
27281
- stagedPath: zod.z.string(),
27282
- backupPath: zod.z.string(),
27283
- toVersion: zod.z.string(),
27284
- fromVersion: zod.z.string().nullable()
27285
- });
27286
- zod.z.object({
27287
- jobId: zod.z.string(),
27288
- taskId: zod.z.string(),
27289
- packages: zod.z.array(frameworkSwapPackageSchema),
27290
- requestedAtMs: zod.z.number(),
27291
- schemaVersion: zod.z.literal(1)
27292
- });
27293
- zod.z.object({
27294
- jobId: zod.z.string(),
27295
- taskId: zod.z.string(),
27296
- backups: zod.z.array(zod.z.object({
27297
- name: zod.z.string(),
27298
- backupPath: zod.z.string(),
27299
- livePath: zod.z.string()
27300
- })),
27301
- appliedAtMs: zod.z.number(),
27302
- bootAttempts: zod.z.number(),
27303
- schemaVersion: zod.z.literal(1)
27304
- });
27305
27235
  /**
27306
27236
  * Scores all applicable inference backends for the given hardware.
27307
27237
  *
package/dist/index.js CHANGED
@@ -1,8 +1,8 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_chunk = require("./chunk-Cek0wNdY.js");
3
- const require_dist = require("./dist-Bg795EQF.js");
3
+ const require_dist = require("./dist-BY6NWf-c.js");
4
4
  const require_model_download_service = require("./model-download-service-hf0ookyy.js");
5
- const require_manifest_python_deps = require("./manifest-python-deps-eI3-3FeW.js");
5
+ const require_manifest_python_deps = require("./manifest-python-deps-D2G0DFWp.js");
6
6
  const require_resource_monitor = require("./resource-monitor-DNNomR-i.js");
7
7
  const require_builtins_sqlite_storage_filesystem_storage_addon = require("./builtins/sqlite-storage/filesystem-storage.addon.js");
8
8
  const require_builtins_sqlite_storage_sqlite_settings_addon = require("./builtins/sqlite-storage/sqlite-settings.addon.js");
@@ -93079,7 +93079,7 @@ var JobJournal = class {
93079
93079
  };
93080
93080
  //#endregion
93081
93081
  //#region src/kernel/lifecycle/staging-area.ts
93082
- function safeSegment$1(name) {
93082
+ function safeSegment(name) {
93083
93083
  return name.replace(/[^a-zA-Z0-9._-]/g, "_");
93084
93084
  }
93085
93085
  var StagingArea = class {
@@ -93090,7 +93090,7 @@ var StagingArea = class {
93090
93090
  this.deps = deps;
93091
93091
  }
93092
93092
  async fetchAndStage(input) {
93093
- const destDir = node_path.join(this.stagingDir, input.jobId, safeSegment$1(input.name));
93093
+ const destDir = node_path.join(this.stagingDir, input.jobId, safeSegment(input.name));
93094
93094
  node_fs.rmSync(destDir, {
93095
93095
  recursive: true,
93096
93096
  force: true
@@ -93226,50 +93226,22 @@ var LifecycleJobEngine = class {
93226
93226
  }
93227
93227
  }
93228
93228
  /**
93229
- * Run the framework task: stage lockstep → `staged` → requestFrameworkSwap.
93230
- * In production the process exits after requestFrameworkSwap and the reboot
93231
- * finalizes the job, so this returns the current durable job WITHOUT
93232
- * finalization. Returns null only if the framework deps are not wired (the
93233
- * task is marked `failed` and the caller finalizes the job).
93234
- */
93235
- async runFrameworkTask(job, task) {
93236
- const { stageFramework, requestFrameworkSwap } = this.deps;
93237
- if (stageFramework === void 0 || requestFrameworkSwap === void 0) {
93238
- this.advance(job.jobId, task, "failed", {
93239
- error: "framework swap deps not wired",
93240
- finishedAtMs: this.deps.now()
93241
- });
93242
- return null;
93243
- }
93244
- try {
93245
- this.advance(job.jobId, task, "fetching", {
93246
- startedAtMs: this.deps.now(),
93247
- attempts: task.attempts + 1
93248
- });
93249
- const ac = new AbortController();
93250
- const timer = setTimeout(() => ac.abort(), this.deps.fetchTimeoutMs ?? DEFAULT_FETCH_TIMEOUT_MS);
93251
- let packages;
93252
- try {
93253
- packages = await stageFramework(task, ac.signal);
93254
- } finally {
93255
- clearTimeout(timer);
93256
- }
93257
- const [firstPackage] = packages;
93258
- if (!firstPackage) throw new Error("stageFramework returned no packages");
93259
- this.advance(job.jobId, task, "staged", { stagedPath: firstPackage.stagedPath });
93260
- requestFrameworkSwap({
93261
- jobId: job.jobId,
93262
- taskId: task.taskId,
93263
- packages
93264
- });
93265
- return this.deps.journal.getJob(job.jobId) ?? job;
93266
- } catch (err) {
93267
- this.advance(job.jobId, task, "failed", {
93268
- error: err instanceof Error ? err.message : String(err),
93269
- finishedAtMs: this.deps.now()
93270
- });
93271
- return null;
93272
- }
93229
+ * Mark a framework task `skipped`.
93230
+ *
93231
+ * Framework packages (`@camstack/system` + its lockstep companions) are NO
93232
+ * LONGER updated through this engine. The legacy `/data/framework` per-package
93233
+ * swap was removed in the single-copy framework collapse (2026-07-18) — the
93234
+ * running framework is loaded from the active server-root single copy, and
93235
+ * framework/cap updates now ship EXCLUSIVELY via `applyServerUpdate` (the
93236
+ * node-root ServerUpdateService). Any framework task that still reaches this
93237
+ * engine (e.g. an "Update all" bulk job that swept `@camstack/system`) is
93238
+ * skipped, never applied — applying it would swap a dead dir.
93239
+ */
93240
+ skipFrameworkTask(job, task) {
93241
+ this.advance(job.jobId, task, "skipped", {
93242
+ startedAtMs: task.startedAtMs ?? this.deps.now(),
93243
+ finishedAtMs: this.deps.now()
93244
+ });
93273
93245
  }
93274
93246
  /**
93275
93247
  * Run the addon fetch phase with a bounded-concurrency worker pool. At most
@@ -93297,24 +93269,24 @@ var LifecycleJobEngine = class {
93297
93269
  * §10 boot reconcile: re-drive every NON-TERMINAL addon task of a job that
93298
93270
  * was interrupted mid-flight (e.g. a crash) from its on-disk checkpoint.
93299
93271
  *
93300
- * Framework tasks are LEFT UNTOUCHED they are owned by the F2
93301
- * `resumeFrameworkSwapJob` path (which marks `applied`→`done` on a healthy
93302
- * reboot). Terminal addon tasks (`done`/`failed`/`skipped`) are skipped.
93272
+ * Framework tasks are NOT applied by this engine (single-copy collapse
93273
+ * framework updates ship via `applyServerUpdate`). Any stray non-terminal
93274
+ * framework task is marked `skipped` so the interrupted job can finalize
93275
+ * instead of hanging `running` forever. Terminal addon tasks
93276
+ * (`done`/`failed`/`skipped`) are left as-is.
93303
93277
  *
93304
93278
  * Apply is idempotent (`applyAddonUpdate` backs up the live dir + restores on
93305
93279
  * failure), so every non-terminal addon phase collapses to:
93306
93280
  * ensure staged (reuse a still-valid `stagedPath` or re-fetch) → apply → done;
93307
93281
  * on failure → `failed`.
93308
- *
93309
- * The job is finalized (`completed`/`partially-failed`/`failed` + staging
93310
- * cleanup) ONLY when ALL tasks — including any framework task — are terminal.
93311
- * If a framework task is still non-terminal the job is LEFT `running` (the
93312
- * reboot/F2 path finalizes it).
93313
93282
  */
93314
93283
  async reconcileJob(job) {
93315
93284
  const exists = this.deps.stagedPathExists ?? ((p) => node_fs.existsSync(p));
93316
93285
  for (const task of job.tasks) {
93317
- if (task.target === "framework") continue;
93286
+ if (task.target === "framework") {
93287
+ if (!this.isTerminal(task.phase)) this.skipFrameworkTask(job, task);
93288
+ continue;
93289
+ }
93318
93290
  if (this.isTerminal(task.phase)) continue;
93319
93291
  await this.reconcileAddonTask(job, task, exists);
93320
93292
  }
@@ -93336,9 +93308,10 @@ var LifecycleJobEngine = class {
93336
93308
  }
93337
93309
  /**
93338
93310
  * Finalize a reconciled job: `completed` if all addon tasks succeeded,
93339
- * `failed` if all failed, `partially-failed` if mixed but ONLY when every
93340
- * task (including framework) is terminal. If any task is still non-terminal
93341
- * (a framework task pending its reboot resume), leave the job `running`.
93311
+ * `failed` if all failed, `partially-failed` if mixed. A skipped framework
93312
+ * task counts as neither success nor failure. Defensive: if a task is still
93313
+ * non-terminal (should not happen reconcile drives every task terminal),
93314
+ * leave the job `running` and do not clean staging.
93342
93315
  */
93343
93316
  finalizeReconciledJob(jobId) {
93344
93317
  const current = this.deps.journal.getJob(jobId);
@@ -93354,6 +93327,7 @@ var LifecycleJobEngine = class {
93354
93327
  async runJob(job) {
93355
93328
  const addonTasks = job.tasks.filter((t) => t.target !== "framework");
93356
93329
  const frameworkTasks = job.tasks.filter((t) => t.target === "framework");
93330
+ for (const task of frameworkTasks) this.skipFrameworkTask(job, task);
93357
93331
  let failures = 0;
93358
93332
  let successes = 0;
93359
93333
  const fetchOutcomes = await this.fetchAddonsBounded(job, addonTasks);
@@ -93363,11 +93337,6 @@ var LifecycleJobEngine = class {
93363
93337
  if (await this.applyAddonTask(job, outcome.task, outcome.stagedPath)) successes += 1;
93364
93338
  else failures += 1;
93365
93339
  }
93366
- for (const task of frameworkTasks) {
93367
- const result = await this.runFrameworkTask(job, task);
93368
- if (result !== null) return result;
93369
- failures += 1;
93370
- }
93371
93340
  const state = failures === 0 ? "completed" : successes === 0 ? "failed" : "partially-failed";
93372
93341
  const finalJob = this.deps.journal.setJobState(job.jobId, state);
93373
93342
  this.deps.staging.cleanup(job.jobId);
@@ -93375,44 +93344,6 @@ var LifecycleJobEngine = class {
93375
93344
  }
93376
93345
  };
93377
93346
  //#endregion
93378
- //#region src/kernel/lifecycle/framework-staging.ts
93379
- var FRAMEWORK_LOCKSTEP = [
93380
- "@camstack/system",
93381
- "@camstack/types",
93382
- "@camstack/sdk",
93383
- "@camstack/shm-ring"
93384
- ];
93385
- function safeSegment(name) {
93386
- return name.replace(/[^a-zA-Z0-9._-]/g, "_");
93387
- }
93388
- async function stageFrameworkLockstep(input) {
93389
- const stagingArea = new StagingArea(input.stagingDir, {
93390
- fetchTarball: input.fetchTarball,
93391
- extract: input.extract
93392
- });
93393
- const results = [];
93394
- const primary = FRAMEWORK_LOCKSTEP[0];
93395
- for (const pkg of FRAMEWORK_LOCKSTEP) {
93396
- const version = pkg === primary ? input.toVersion : await input.resolveVersion(pkg);
93397
- const { stagedPath } = await stagingArea.fetchAndStage({
93398
- jobId: input.jobId,
93399
- name: pkg,
93400
- version,
93401
- signal: input.signal
93402
- });
93403
- const backupPath = node_path.join(input.stagingDir, input.jobId, ".bak-fw", safeSegment(pkg));
93404
- const fromVersion = input.currentVersionOf(pkg);
93405
- results.push({
93406
- name: pkg,
93407
- stagedPath,
93408
- backupPath,
93409
- toVersion: version,
93410
- fromVersion
93411
- });
93412
- }
93413
- return results;
93414
- }
93415
- //#endregion
93416
93347
  exports.AGENT_CAP_FWD_ACTION = require_manifest_python_deps.AGENT_CAP_FWD_ACTION;
93417
93348
  exports.AGENT_CAP_FWD_SERVICE = require_manifest_python_deps.AGENT_CAP_FWD_SERVICE;
93418
93349
  exports.AGENT_READINESS_SERVICE_NAME = AGENT_READINESS_SERVICE_NAME;
@@ -93452,7 +93383,6 @@ exports.DeviceStore = require_builtins_sqlite_storage_index.DeviceStore$1;
93452
93383
  exports.EVENT_TOPIC_PREFIX = require_manifest_python_deps.EVENT_TOPIC_PREFIX;
93453
93384
  exports.EngineManagerResolver = EngineManagerResolver;
93454
93385
  exports.EventBus = EventBus;
93455
- exports.FRAMEWORK_LOCKSTEP = FRAMEWORK_LOCKSTEP;
93456
93386
  exports.FeatureManager = FeatureManager;
93457
93387
  exports.FilesystemStorageAddon = require_builtins_sqlite_storage_filesystem_storage_addon.FilesystemStorageAddon;
93458
93388
  exports.FilesystemStorageProvider = require_builtins_sqlite_storage_filesystem_storage_addon.FilesystemStorageProvider;
@@ -93690,7 +93620,6 @@ exports.scopesAllowDeviceCap = scopesAllowDeviceCap;
93690
93620
  exports.serializeTypedArrays = require_manifest_python_deps.serializeTypedArrays;
93691
93621
  exports.setHubConnected = require_manifest_python_deps.setHubConnected;
93692
93622
  exports.setNodeEventInterest = require_manifest_python_deps.setNodeEventInterest;
93693
- exports.stageFrameworkLockstep = stageFrameworkLockstep;
93694
93623
  exports.stripCamstackDeps = stripCamstackDeps;
93695
93624
  exports.subscribePassthrough = require_manifest_python_deps.subscribePassthrough;
93696
93625
  exports.udsChildLogToWorkerEntry = require_manifest_python_deps.udsChildLogToWorkerEntry;
package/dist/index.mjs CHANGED
@@ -1,6 +1,6 @@
1
- import { A as isArrayOutputSchema, Ct as parseJsonObject, D as extractNestedAddonId, Dt as scopeKey, Et as resolveCapMount, F as lifecycleJobSchema, G as procedureAuthKey, H as objectInputDeclaresAddonId, M as isObjectInput, N as isVoidInput, P as kebabToCamel, R as looseSchema, Tt as readinessKey, _t as createEvent, at as DATAPLANE_SECRET_HEADER$1, bt as expandCapMethods, dt as ReadinessRegistry, ft as ReadinessTimeoutError, gt as asString$1, ht as asNumber, j as isCollectionArrayMethod, kt as EventCategory$1, mt as asJsonObject$1, o as METHOD_ACCESS_MAP, ot as DEVICE_SETTINGS_CONTRIBUTION_METHODS, p as addonSettingsCapability, rt as errMsg$1, s as RUNTIME_DEFAULTS, st as DEVICE_STATUS_METHOD, t as ALL_CAPABILITY_DEFINITIONS, vt as emitDownForOwnedCaps, wt as parseJsonUnknown$1 } from "./dist-JAF9YR1q.mjs";
1
+ import { A as isArrayOutputSchema, Ct as parseJsonObject, D as extractNestedAddonId, Dt as scopeKey, Et as resolveCapMount, F as lifecycleJobSchema, G as procedureAuthKey, H as objectInputDeclaresAddonId, M as isObjectInput, N as isVoidInput, P as kebabToCamel, R as looseSchema, Tt as readinessKey, _t as createEvent, at as DATAPLANE_SECRET_HEADER$1, bt as expandCapMethods, dt as ReadinessRegistry, ft as ReadinessTimeoutError, gt as asString$1, ht as asNumber, j as isCollectionArrayMethod, kt as EventCategory$1, mt as asJsonObject$1, o as METHOD_ACCESS_MAP, ot as DEVICE_SETTINGS_CONTRIBUTION_METHODS, p as addonSettingsCapability, rt as errMsg$1, s as RUNTIME_DEFAULTS, st as DEVICE_STATUS_METHOD, t as ALL_CAPABILITY_DEFINITIONS, vt as emitDownForOwnedCaps, wt as parseJsonUnknown$1 } from "./dist-BNevCEAo.mjs";
2
2
  import { a as downloadModel, c as getModelFilePath, d as contentTypeFor, f as createAuthenticatedFileServer, h as resolveFilePath, i as downloadFile, l as isModelDownloaded, m as parseTokenizedUrl, n as collectModelFiles, o as ensureModel, p as parseRangeHeader, r as deleteModelFromDisk, s as fetchJson, t as ModelDownloadService, u as createFileDataPlaneHandler } from "./model-download-service-Cp9f4dk6.mjs";
3
- import { $ as buildUdsNativeCapProxy, A as createParentUnownedCallHandler, B as AGENT_CAP_FWD_SERVICE, C as buildLinkChain, D as HUB_CAP_FWD_ACTION, E as localProviderLink, F as createUdsLoggerWithControl, G as createLocalTransport, H as CapRouteError, I as LocalChildClient, J as SocketChannel, K as UdsLocalTransportClient, L as LocalChildRegistry, M as createUdsEventBus, N as udsChildLogToWorkerEntry, O as HUB_CAP_FWD_SERVICE, P as createUdsLogger, Q as buildNativeCapProxy, R as UDS_NO_ROUTE_PREFIX, S as brokerTransportLink, T as ipcParentLink, U as classifyCapRoute, V as CapRouteResolver, W as callWithServiceDiscovery, X as FrameDecoder, Y as localEndpointPath, Z as encodeFrame, _ as resolveHwAccel, _t as CapabilityUnavailableError, a as getWorkerDeviceRegistry, at as createAddonService, b as getCapUsageRegistry, bt as resolveAddonClass, c as setHubConnected, ct as capActionName, d as getMoleculerEventStats, dt as capServiceName, et as createBrokerDeviceManagerApi, f as registerEventBusService, ft as parseCapAction, g as createKernelHwAccel, gt as CapabilityHandle, h as AddonDepsManager, ht as DeviceRegistry, i as createUdsAddonContext, j as createUdsEventBridge, k as createHubCapForwardService, l as EVENT_TOPIC_PREFIX, lt as capActionSuffix, m as subscribePassthrough, mt as serializeTypedArrays, n as adaptBrokerToCluster, o as getOrInitReadinessRegistry, ot as validateProviderRegistrations, p as setNodeEventInterest, pt as deserializeTypedArrays, q as UdsLocalTransportServer, r as createAddonContext, rt as mountNativeCapService, s as getOrInitReadinessRegistryForClient, st as NATIVE_PROVIDER_SERVICE_INFIX, t as installManifestPythonDeps, u as getBrokerEventBus, ut as capBareAction, v as CapUsageRegistry, vt as installManifestNativeDeps, w as ipcChildLink, x as brokerCallForCap, xt as createAddonDataPlaneFacility, y as __resetCapUsageRegistryForTests, yt as runNpm, z as AGENT_CAP_FWD_ACTION } from "./manifest-python-deps-9wuRyL-k.mjs";
3
+ import { $ as buildUdsNativeCapProxy, A as createParentUnownedCallHandler, B as AGENT_CAP_FWD_SERVICE, C as buildLinkChain, D as HUB_CAP_FWD_ACTION, E as localProviderLink, F as createUdsLoggerWithControl, G as createLocalTransport, H as CapRouteError, I as LocalChildClient, J as SocketChannel, K as UdsLocalTransportClient, L as LocalChildRegistry, M as createUdsEventBus, N as udsChildLogToWorkerEntry, O as HUB_CAP_FWD_SERVICE, P as createUdsLogger, Q as buildNativeCapProxy, R as UDS_NO_ROUTE_PREFIX, S as brokerTransportLink, T as ipcParentLink, U as classifyCapRoute, V as CapRouteResolver, W as callWithServiceDiscovery, X as FrameDecoder, Y as localEndpointPath, Z as encodeFrame, _ as resolveHwAccel, _t as CapabilityUnavailableError, a as getWorkerDeviceRegistry, at as createAddonService, b as getCapUsageRegistry, bt as resolveAddonClass, c as setHubConnected, ct as capActionName, d as getMoleculerEventStats, dt as capServiceName, et as createBrokerDeviceManagerApi, f as registerEventBusService, ft as parseCapAction, g as createKernelHwAccel, gt as CapabilityHandle, h as AddonDepsManager, ht as DeviceRegistry, i as createUdsAddonContext, j as createUdsEventBridge, k as createHubCapForwardService, l as EVENT_TOPIC_PREFIX, lt as capActionSuffix, m as subscribePassthrough, mt as serializeTypedArrays, n as adaptBrokerToCluster, o as getOrInitReadinessRegistry, ot as validateProviderRegistrations, p as setNodeEventInterest, pt as deserializeTypedArrays, q as UdsLocalTransportServer, r as createAddonContext, rt as mountNativeCapService, s as getOrInitReadinessRegistryForClient, st as NATIVE_PROVIDER_SERVICE_INFIX, t as installManifestPythonDeps, u as getBrokerEventBus, ut as capBareAction, v as CapUsageRegistry, vt as installManifestNativeDeps, w as ipcChildLink, x as brokerCallForCap, xt as createAddonDataPlaneFacility, y as __resetCapUsageRegistryForTests, yt as runNpm, z as AGENT_CAP_FWD_ACTION } from "./manifest-python-deps-DtCMZhuR.mjs";
4
4
  import { n as getSinglePidStats, t as getPidStats } from "./resource-monitor-Le3l0qS2.mjs";
5
5
  import { FilesystemStorageAddon, t as FilesystemStorageProvider } from "./builtins/sqlite-storage/filesystem-storage.addon.mjs";
6
6
  import { SqliteSettingsAddon, t as SqliteSettingsBackend } from "./builtins/sqlite-storage/sqlite-settings.addon.mjs";
@@ -93071,7 +93071,7 @@ var JobJournal = class {
93071
93071
  };
93072
93072
  //#endregion
93073
93073
  //#region src/kernel/lifecycle/staging-area.ts
93074
- function safeSegment$1(name) {
93074
+ function safeSegment(name) {
93075
93075
  return name.replace(/[^a-zA-Z0-9._-]/g, "_");
93076
93076
  }
93077
93077
  var StagingArea = class {
@@ -93082,7 +93082,7 @@ var StagingArea = class {
93082
93082
  this.deps = deps;
93083
93083
  }
93084
93084
  async fetchAndStage(input) {
93085
- const destDir = path$39.join(this.stagingDir, input.jobId, safeSegment$1(input.name));
93085
+ const destDir = path$39.join(this.stagingDir, input.jobId, safeSegment(input.name));
93086
93086
  fs$17.rmSync(destDir, {
93087
93087
  recursive: true,
93088
93088
  force: true
@@ -93218,50 +93218,22 @@ var LifecycleJobEngine = class {
93218
93218
  }
93219
93219
  }
93220
93220
  /**
93221
- * Run the framework task: stage lockstep → `staged` → requestFrameworkSwap.
93222
- * In production the process exits after requestFrameworkSwap and the reboot
93223
- * finalizes the job, so this returns the current durable job WITHOUT
93224
- * finalization. Returns null only if the framework deps are not wired (the
93225
- * task is marked `failed` and the caller finalizes the job).
93226
- */
93227
- async runFrameworkTask(job, task) {
93228
- const { stageFramework, requestFrameworkSwap } = this.deps;
93229
- if (stageFramework === void 0 || requestFrameworkSwap === void 0) {
93230
- this.advance(job.jobId, task, "failed", {
93231
- error: "framework swap deps not wired",
93232
- finishedAtMs: this.deps.now()
93233
- });
93234
- return null;
93235
- }
93236
- try {
93237
- this.advance(job.jobId, task, "fetching", {
93238
- startedAtMs: this.deps.now(),
93239
- attempts: task.attempts + 1
93240
- });
93241
- const ac = new AbortController();
93242
- const timer = setTimeout(() => ac.abort(), this.deps.fetchTimeoutMs ?? DEFAULT_FETCH_TIMEOUT_MS);
93243
- let packages;
93244
- try {
93245
- packages = await stageFramework(task, ac.signal);
93246
- } finally {
93247
- clearTimeout(timer);
93248
- }
93249
- const [firstPackage] = packages;
93250
- if (!firstPackage) throw new Error("stageFramework returned no packages");
93251
- this.advance(job.jobId, task, "staged", { stagedPath: firstPackage.stagedPath });
93252
- requestFrameworkSwap({
93253
- jobId: job.jobId,
93254
- taskId: task.taskId,
93255
- packages
93256
- });
93257
- return this.deps.journal.getJob(job.jobId) ?? job;
93258
- } catch (err) {
93259
- this.advance(job.jobId, task, "failed", {
93260
- error: err instanceof Error ? err.message : String(err),
93261
- finishedAtMs: this.deps.now()
93262
- });
93263
- return null;
93264
- }
93221
+ * Mark a framework task `skipped`.
93222
+ *
93223
+ * Framework packages (`@camstack/system` + its lockstep companions) are NO
93224
+ * LONGER updated through this engine. The legacy `/data/framework` per-package
93225
+ * swap was removed in the single-copy framework collapse (2026-07-18) — the
93226
+ * running framework is loaded from the active server-root single copy, and
93227
+ * framework/cap updates now ship EXCLUSIVELY via `applyServerUpdate` (the
93228
+ * node-root ServerUpdateService). Any framework task that still reaches this
93229
+ * engine (e.g. an "Update all" bulk job that swept `@camstack/system`) is
93230
+ * skipped, never applied — applying it would swap a dead dir.
93231
+ */
93232
+ skipFrameworkTask(job, task) {
93233
+ this.advance(job.jobId, task, "skipped", {
93234
+ startedAtMs: task.startedAtMs ?? this.deps.now(),
93235
+ finishedAtMs: this.deps.now()
93236
+ });
93265
93237
  }
93266
93238
  /**
93267
93239
  * Run the addon fetch phase with a bounded-concurrency worker pool. At most
@@ -93289,24 +93261,24 @@ var LifecycleJobEngine = class {
93289
93261
  * §10 boot reconcile: re-drive every NON-TERMINAL addon task of a job that
93290
93262
  * was interrupted mid-flight (e.g. a crash) from its on-disk checkpoint.
93291
93263
  *
93292
- * Framework tasks are LEFT UNTOUCHED they are owned by the F2
93293
- * `resumeFrameworkSwapJob` path (which marks `applied`→`done` on a healthy
93294
- * reboot). Terminal addon tasks (`done`/`failed`/`skipped`) are skipped.
93264
+ * Framework tasks are NOT applied by this engine (single-copy collapse
93265
+ * framework updates ship via `applyServerUpdate`). Any stray non-terminal
93266
+ * framework task is marked `skipped` so the interrupted job can finalize
93267
+ * instead of hanging `running` forever. Terminal addon tasks
93268
+ * (`done`/`failed`/`skipped`) are left as-is.
93295
93269
  *
93296
93270
  * Apply is idempotent (`applyAddonUpdate` backs up the live dir + restores on
93297
93271
  * failure), so every non-terminal addon phase collapses to:
93298
93272
  * ensure staged (reuse a still-valid `stagedPath` or re-fetch) → apply → done;
93299
93273
  * on failure → `failed`.
93300
- *
93301
- * The job is finalized (`completed`/`partially-failed`/`failed` + staging
93302
- * cleanup) ONLY when ALL tasks — including any framework task — are terminal.
93303
- * If a framework task is still non-terminal the job is LEFT `running` (the
93304
- * reboot/F2 path finalizes it).
93305
93274
  */
93306
93275
  async reconcileJob(job) {
93307
93276
  const exists = this.deps.stagedPathExists ?? ((p) => fs$17.existsSync(p));
93308
93277
  for (const task of job.tasks) {
93309
- if (task.target === "framework") continue;
93278
+ if (task.target === "framework") {
93279
+ if (!this.isTerminal(task.phase)) this.skipFrameworkTask(job, task);
93280
+ continue;
93281
+ }
93310
93282
  if (this.isTerminal(task.phase)) continue;
93311
93283
  await this.reconcileAddonTask(job, task, exists);
93312
93284
  }
@@ -93328,9 +93300,10 @@ var LifecycleJobEngine = class {
93328
93300
  }
93329
93301
  /**
93330
93302
  * Finalize a reconciled job: `completed` if all addon tasks succeeded,
93331
- * `failed` if all failed, `partially-failed` if mixed but ONLY when every
93332
- * task (including framework) is terminal. If any task is still non-terminal
93333
- * (a framework task pending its reboot resume), leave the job `running`.
93303
+ * `failed` if all failed, `partially-failed` if mixed. A skipped framework
93304
+ * task counts as neither success nor failure. Defensive: if a task is still
93305
+ * non-terminal (should not happen reconcile drives every task terminal),
93306
+ * leave the job `running` and do not clean staging.
93334
93307
  */
93335
93308
  finalizeReconciledJob(jobId) {
93336
93309
  const current = this.deps.journal.getJob(jobId);
@@ -93346,6 +93319,7 @@ var LifecycleJobEngine = class {
93346
93319
  async runJob(job) {
93347
93320
  const addonTasks = job.tasks.filter((t) => t.target !== "framework");
93348
93321
  const frameworkTasks = job.tasks.filter((t) => t.target === "framework");
93322
+ for (const task of frameworkTasks) this.skipFrameworkTask(job, task);
93349
93323
  let failures = 0;
93350
93324
  let successes = 0;
93351
93325
  const fetchOutcomes = await this.fetchAddonsBounded(job, addonTasks);
@@ -93355,11 +93329,6 @@ var LifecycleJobEngine = class {
93355
93329
  if (await this.applyAddonTask(job, outcome.task, outcome.stagedPath)) successes += 1;
93356
93330
  else failures += 1;
93357
93331
  }
93358
- for (const task of frameworkTasks) {
93359
- const result = await this.runFrameworkTask(job, task);
93360
- if (result !== null) return result;
93361
- failures += 1;
93362
- }
93363
93332
  const state = failures === 0 ? "completed" : successes === 0 ? "failed" : "partially-failed";
93364
93333
  const finalJob = this.deps.journal.setJobState(job.jobId, state);
93365
93334
  this.deps.staging.cleanup(job.jobId);
@@ -93367,42 +93336,4 @@ var LifecycleJobEngine = class {
93367
93336
  }
93368
93337
  };
93369
93338
  //#endregion
93370
- //#region src/kernel/lifecycle/framework-staging.ts
93371
- var FRAMEWORK_LOCKSTEP = [
93372
- "@camstack/system",
93373
- "@camstack/types",
93374
- "@camstack/sdk",
93375
- "@camstack/shm-ring"
93376
- ];
93377
- function safeSegment(name) {
93378
- return name.replace(/[^a-zA-Z0-9._-]/g, "_");
93379
- }
93380
- async function stageFrameworkLockstep(input) {
93381
- const stagingArea = new StagingArea(input.stagingDir, {
93382
- fetchTarball: input.fetchTarball,
93383
- extract: input.extract
93384
- });
93385
- const results = [];
93386
- const primary = FRAMEWORK_LOCKSTEP[0];
93387
- for (const pkg of FRAMEWORK_LOCKSTEP) {
93388
- const version = pkg === primary ? input.toVersion : await input.resolveVersion(pkg);
93389
- const { stagedPath } = await stagingArea.fetchAndStage({
93390
- jobId: input.jobId,
93391
- name: pkg,
93392
- version,
93393
- signal: input.signal
93394
- });
93395
- const backupPath = path$39.join(input.stagingDir, input.jobId, ".bak-fw", safeSegment(pkg));
93396
- const fromVersion = input.currentVersionOf(pkg);
93397
- results.push({
93398
- name: pkg,
93399
- stagedPath,
93400
- backupPath,
93401
- toVersion: version,
93402
- fromVersion
93403
- });
93404
- }
93405
- return results;
93406
- }
93407
- //#endregion
93408
- export { AGENT_CAP_FWD_ACTION, AGENT_CAP_FWD_SERVICE, AGENT_READINESS_SERVICE_NAME, ALL_CAPABILITY_DEFINITIONS, AddonApiFactory, AddonDepsManager, AddonEngineManager, AddonHealthMonitor, AddonInstaller, AddonLoader, AddonManifest, AddonRouteRegistry, AlertCenterAddon, ApiKeyManager, AuthManager, CLUSTER_SECRET_MISMATCH_TYPE, CLUSTER_SECRET_REJECTED_EXIT_CODE, CORE_CAP_SERVICE_NAME, CapRouteError, CapRouteResolver, CapUsageRegistry, CapabilityHandle, CapabilityRegistry, CapabilityUnavailableError, ConfigManager, ConfigStore, ConsoleDestination, ConsoleLoggingAddon, CustomActionRegistry, DEFAULT_DATA_PATH, DEVICE_SETTINGS_CONTRIBUTION_METHODS, DEVICE_STATUS_METHOD, DataPlaneRegistry, DeviceManagerAddon, DeviceRegistry, DeviceStore, EVENT_TOPIC_PREFIX, EngineManagerResolver, EventBus, FRAMEWORK_LOCKSTEP, FeatureManager, FilesystemStorageAddon, FilesystemStorageProvider, FrameDecoder, FsStorageBackend, HEALTH_MONITOR_GRACE_PERIOD_MS, HEALTH_MONITOR_RETRY_INTERVALS_MS, HEALTH_MONITOR_TICK_MS, HUB_CAP_FWD_ACTION, HUB_CAP_FWD_SERVICE, HubForwarderAddon, HubForwarderDestination, HubLogForwarder, HubNodeRegistry, INFRA_CAPABILITIES, IntegrationRegistry, JobJournal, LifecycleJobEngine, LifecycleStateMachine, LocalAuthAddon, LocalChildClient, LocalChildRegistry, LogManager, LogRingBuffer, METHOD_ACCESS_MAP, ModelDownloadService, NATIVE_PROVIDER_SERVICE_INFIX, NativeMetricsAddon, NativeMetricsProvider, NetworkQualityTracker, NotificationService, PYTHON_VERSION, PipelineRunner, PipelineValidator, PythonEnvManager, RESTART_MARKER_FILE, RUNTIME_DEFAULTS, ReadinessRegistry, ReadinessTimeoutError, ReplEngine, RingBuffer, ScopedLogger, ScopedTokenManager, SocketChannel, SqliteSettingsAddon, SqliteSettingsBackend, StagingArea, StorageLocationManager, StorageManager, StorageOrchestratorAddon, StorageOrchestratorService, SystemConfigAddon, SystemEventBus, ToastService, UDS_NO_ROUTE_PREFIX, UdsLocalTransportClient, UdsLocalTransportServer, UserManager, WinstonDestination, WinstonLoggingAddon, __resetCapUsageRegistryForTests, adaptBrokerToCluster, addonSettingsCapability, bootstrapSchema, brokerCallForCap, brokerTransportLink, buildBinaryPath, buildCapRouters, buildLinkChain, buildNativeCapProxy, buildNodeManifest, buildStorageLocationRegistry, buildUdsNativeCapProxy, builderMountedCapNames, callRegisterNodeWithRetry, callWithServiceDiscovery, capActionName, capActionSuffix, capBareAction, capServiceName, classifyCapRoute, clearPendingRestart, clusterSecretMatches, collectModelFiles, contentTypeFor, copyDirRecursive, copyExtraFileDirs, createAddonContext, createAddonDataPlaneFacility, createAddonService, createAuthenticatedFileServer, createBroker, createBrokerDeviceManagerApi, createCoreCapService, createFileDataPlaneHandler, createHubCapForwardService, createHubService, createKernelHwAccel, createLocalTransport, createParentUnownedCallHandler, createProcessService, createReadinessService, createReadinessServiceForRegistry, createScopedProcessManager, createStreamProbeBrokerService, createUdsAddonContext, createUdsEventBridge, createUdsEventBus, createUdsLogger, createUdsLoggerWithControl, deleteModelFromDisk, deriveAgentListenPort, describeProviderKindDrift, detectWorkspacePackagesDir, downloadBinary, downloadFile, downloadModel, emitDownForOwnedCaps, encodeFrame, ensureBinary, ensureDir, ensureFfmpeg, ensureLibraryBuilt, ensureModel, ensurePython, ensureTlsCert, expandCapMethods, fetchJson, findInPath, formatLogLine, getBrokerEventBus, getCapUsageRegistry, getFfmpegDownloadUrl, getModelFilePath, getMoleculerEventStats, getOrInitReadinessRegistry, getOrInitReadinessRegistryForClient, getPidStats, getPlatformInfo, getPythonDownloadUrl, getRestartMarkerPath, getSinglePidStats, getWorkerDeviceRegistry, hashClusterSecret, installManifestNativeDeps, installManifestPythonDeps, installPackageFromNpm, installPythonPackages, installPythonRequirements, ipcChildLink, ipcParentLink, isAddonDeploySource, isArrayOutputSchema, isClusterSecretMismatchError, isCollectionArrayMethod, isInfraCapability, isModelDownloaded, isSourceNewer, loadTlsCert, localEndpointPath, localProviderLink, mountNativeCapService, parseCapAction, parseRangeHeader, parseTokenizedUrl, proxyToUpstream, readPendingRestart, readinessKey, registerEventBusService, resolveFilePath, resolveHwAccel, scheduleSelfRestart, scopeKey, scopesAllowDeviceCap, serializeTypedArrays, setHubConnected, setNodeEventInterest, stageFrameworkLockstep, stripCamstackDeps, subscribePassthrough, udsChildLogToWorkerEntry, validateProviderRegistrations, writePendingRestart };
93339
+ export { AGENT_CAP_FWD_ACTION, AGENT_CAP_FWD_SERVICE, AGENT_READINESS_SERVICE_NAME, ALL_CAPABILITY_DEFINITIONS, AddonApiFactory, AddonDepsManager, AddonEngineManager, AddonHealthMonitor, AddonInstaller, AddonLoader, AddonManifest, AddonRouteRegistry, AlertCenterAddon, ApiKeyManager, AuthManager, CLUSTER_SECRET_MISMATCH_TYPE, CLUSTER_SECRET_REJECTED_EXIT_CODE, CORE_CAP_SERVICE_NAME, CapRouteError, CapRouteResolver, CapUsageRegistry, CapabilityHandle, CapabilityRegistry, CapabilityUnavailableError, ConfigManager, ConfigStore, ConsoleDestination, ConsoleLoggingAddon, CustomActionRegistry, DEFAULT_DATA_PATH, DEVICE_SETTINGS_CONTRIBUTION_METHODS, DEVICE_STATUS_METHOD, DataPlaneRegistry, DeviceManagerAddon, DeviceRegistry, DeviceStore, EVENT_TOPIC_PREFIX, EngineManagerResolver, EventBus, FeatureManager, FilesystemStorageAddon, FilesystemStorageProvider, FrameDecoder, FsStorageBackend, HEALTH_MONITOR_GRACE_PERIOD_MS, HEALTH_MONITOR_RETRY_INTERVALS_MS, HEALTH_MONITOR_TICK_MS, HUB_CAP_FWD_ACTION, HUB_CAP_FWD_SERVICE, HubForwarderAddon, HubForwarderDestination, HubLogForwarder, HubNodeRegistry, INFRA_CAPABILITIES, IntegrationRegistry, JobJournal, LifecycleJobEngine, LifecycleStateMachine, LocalAuthAddon, LocalChildClient, LocalChildRegistry, LogManager, LogRingBuffer, METHOD_ACCESS_MAP, ModelDownloadService, NATIVE_PROVIDER_SERVICE_INFIX, NativeMetricsAddon, NativeMetricsProvider, NetworkQualityTracker, NotificationService, PYTHON_VERSION, PipelineRunner, PipelineValidator, PythonEnvManager, RESTART_MARKER_FILE, RUNTIME_DEFAULTS, ReadinessRegistry, ReadinessTimeoutError, ReplEngine, RingBuffer, ScopedLogger, ScopedTokenManager, SocketChannel, SqliteSettingsAddon, SqliteSettingsBackend, StagingArea, StorageLocationManager, StorageManager, StorageOrchestratorAddon, StorageOrchestratorService, SystemConfigAddon, SystemEventBus, ToastService, UDS_NO_ROUTE_PREFIX, UdsLocalTransportClient, UdsLocalTransportServer, UserManager, WinstonDestination, WinstonLoggingAddon, __resetCapUsageRegistryForTests, adaptBrokerToCluster, addonSettingsCapability, bootstrapSchema, brokerCallForCap, brokerTransportLink, buildBinaryPath, buildCapRouters, buildLinkChain, buildNativeCapProxy, buildNodeManifest, buildStorageLocationRegistry, buildUdsNativeCapProxy, builderMountedCapNames, callRegisterNodeWithRetry, callWithServiceDiscovery, capActionName, capActionSuffix, capBareAction, capServiceName, classifyCapRoute, clearPendingRestart, clusterSecretMatches, collectModelFiles, contentTypeFor, copyDirRecursive, copyExtraFileDirs, createAddonContext, createAddonDataPlaneFacility, createAddonService, createAuthenticatedFileServer, createBroker, createBrokerDeviceManagerApi, createCoreCapService, createFileDataPlaneHandler, createHubCapForwardService, createHubService, createKernelHwAccel, createLocalTransport, createParentUnownedCallHandler, createProcessService, createReadinessService, createReadinessServiceForRegistry, createScopedProcessManager, createStreamProbeBrokerService, createUdsAddonContext, createUdsEventBridge, createUdsEventBus, createUdsLogger, createUdsLoggerWithControl, deleteModelFromDisk, deriveAgentListenPort, describeProviderKindDrift, detectWorkspacePackagesDir, downloadBinary, downloadFile, downloadModel, emitDownForOwnedCaps, encodeFrame, ensureBinary, ensureDir, ensureFfmpeg, ensureLibraryBuilt, ensureModel, ensurePython, ensureTlsCert, expandCapMethods, fetchJson, findInPath, formatLogLine, getBrokerEventBus, getCapUsageRegistry, getFfmpegDownloadUrl, getModelFilePath, getMoleculerEventStats, getOrInitReadinessRegistry, getOrInitReadinessRegistryForClient, getPidStats, getPlatformInfo, getPythonDownloadUrl, getRestartMarkerPath, getSinglePidStats, getWorkerDeviceRegistry, hashClusterSecret, installManifestNativeDeps, installManifestPythonDeps, installPackageFromNpm, installPythonPackages, installPythonRequirements, ipcChildLink, ipcParentLink, isAddonDeploySource, isArrayOutputSchema, isClusterSecretMismatchError, isCollectionArrayMethod, isInfraCapability, isModelDownloaded, isSourceNewer, loadTlsCert, localEndpointPath, localProviderLink, mountNativeCapService, parseCapAction, parseRangeHeader, parseTokenizedUrl, proxyToUpstream, readPendingRestart, readinessKey, registerEventBusService, resolveFilePath, resolveHwAccel, scheduleSelfRestart, scopeKey, scopesAllowDeviceCap, serializeTypedArrays, setHubConnected, setNodeEventInterest, stripCamstackDeps, subscribePassthrough, udsChildLogToWorkerEntry, validateProviderRegistrations, writePendingRestart };
@@ -77,7 +77,5 @@ export type { ReadinessHandler, ReadinessTransition, AwaitReadyOptions, Readines
77
77
  export { JobJournal } from './lifecycle/job-journal.js';
78
78
  export { StagingArea } from './lifecycle/staging-area.js';
79
79
  export { LifecycleJobEngine } from './lifecycle/lifecycle-job-engine.js';
80
- export type { ApplyAddonUpdateFn, EmitFn, StageFrameworkFn, RequestFrameworkSwapFn, } from './lifecycle/lifecycle-job-engine.js';
80
+ export type { ApplyAddonUpdateFn, EmitFn } from './lifecycle/lifecycle-job-engine.js';
81
81
  export type { TarballFetcher, ExtractFn } from './lifecycle/staging-area.js';
82
- export { stageFrameworkLockstep, FRAMEWORK_LOCKSTEP } from './lifecycle/framework-staging.js';
83
- export type { StageFrameworkInput } from './lifecycle/framework-staging.js';
@@ -1,18 +1,12 @@
1
1
  import { JobJournal } from './job-journal.js';
2
2
  import { StagingArea } from './staging-area.js';
3
- import { LifecycleJob, LifecycleTask, TaskLogEntry, FrameworkSwapPackage } from '@camstack/types';
3
+ import { LifecycleJob, TaskLogEntry } from '@camstack/types';
4
4
  export type ApplyAddonUpdateFn = (input: {
5
5
  name: string;
6
6
  version: string;
7
7
  stagedPath: string;
8
8
  }) => Promise<void>;
9
9
  export type EmitFn = (kind: 'progress' | 'log', job: LifecycleJob, entry?: TaskLogEntry) => void;
10
- export type StageFrameworkFn = (task: LifecycleTask, signal: AbortSignal) => Promise<FrameworkSwapPackage[]>;
11
- export type RequestFrameworkSwapFn = (input: {
12
- jobId: string;
13
- taskId: string;
14
- packages: FrameworkSwapPackage[];
15
- }) => void;
16
10
  interface Deps {
17
11
  readonly journal: JobJournal;
18
12
  readonly staging: StagingArea;
@@ -21,8 +15,6 @@ interface Deps {
21
15
  readonly now: () => number;
22
16
  readonly fetchTimeoutMs?: number;
23
17
  readonly fetchConcurrency?: number;
24
- readonly stageFramework?: StageFrameworkFn;
25
- readonly requestFrameworkSwap?: RequestFrameworkSwapFn;
26
18
  /**
27
19
  * Predicate used by `reconcileJob` to decide whether a task's recorded
28
20
  * `stagedPath` directory still exists on disk (so apply can reuse it instead
@@ -48,13 +40,18 @@ export declare class LifecycleJobEngine {
48
40
  */
49
41
  private applyAddonTask;
50
42
  /**
51
- * Run the framework task: stage lockstep → `staged` → requestFrameworkSwap.
52
- * In production the process exits after requestFrameworkSwap and the reboot
53
- * finalizes the job, so this returns the current durable job WITHOUT
54
- * finalization. Returns null only if the framework deps are not wired (the
55
- * task is marked `failed` and the caller finalizes the job).
43
+ * Mark a framework task `skipped`.
44
+ *
45
+ * Framework packages (`@camstack/system` + its lockstep companions) are NO
46
+ * LONGER updated through this engine. The legacy `/data/framework` per-package
47
+ * swap was removed in the single-copy framework collapse (2026-07-18) — the
48
+ * running framework is loaded from the active server-root single copy, and
49
+ * framework/cap updates now ship EXCLUSIVELY via `applyServerUpdate` (the
50
+ * node-root ServerUpdateService). Any framework task that still reaches this
51
+ * engine (e.g. an "Update all" bulk job that swept `@camstack/system`) is
52
+ * skipped, never applied — applying it would swap a dead dir.
56
53
  */
57
- private runFrameworkTask;
54
+ private skipFrameworkTask;
58
55
  /**
59
56
  * Run the addon fetch phase with a bounded-concurrency worker pool. At most
60
57
  * `fetchConcurrency` fetches are in flight at once; completion order may vary
@@ -65,19 +62,16 @@ export declare class LifecycleJobEngine {
65
62
  * §10 boot reconcile: re-drive every NON-TERMINAL addon task of a job that
66
63
  * was interrupted mid-flight (e.g. a crash) from its on-disk checkpoint.
67
64
  *
68
- * Framework tasks are LEFT UNTOUCHED they are owned by the F2
69
- * `resumeFrameworkSwapJob` path (which marks `applied`→`done` on a healthy
70
- * reboot). Terminal addon tasks (`done`/`failed`/`skipped`) are skipped.
65
+ * Framework tasks are NOT applied by this engine (single-copy collapse
66
+ * framework updates ship via `applyServerUpdate`). Any stray non-terminal
67
+ * framework task is marked `skipped` so the interrupted job can finalize
68
+ * instead of hanging `running` forever. Terminal addon tasks
69
+ * (`done`/`failed`/`skipped`) are left as-is.
71
70
  *
72
71
  * Apply is idempotent (`applyAddonUpdate` backs up the live dir + restores on
73
72
  * failure), so every non-terminal addon phase collapses to:
74
73
  * ensure staged (reuse a still-valid `stagedPath` or re-fetch) → apply → done;
75
74
  * on failure → `failed`.
76
- *
77
- * The job is finalized (`completed`/`partially-failed`/`failed` + staging
78
- * cleanup) ONLY when ALL tasks — including any framework task — are terminal.
79
- * If a framework task is still non-terminal the job is LEFT `running` (the
80
- * reboot/F2 path finalizes it).
81
75
  */
82
76
  reconcileJob(job: LifecycleJob): Promise<LifecycleJob>;
83
77
  private isTerminal;
@@ -88,9 +82,10 @@ export declare class LifecycleJobEngine {
88
82
  private reconcileAddonTask;
89
83
  /**
90
84
  * Finalize a reconciled job: `completed` if all addon tasks succeeded,
91
- * `failed` if all failed, `partially-failed` if mixed but ONLY when every
92
- * task (including framework) is terminal. If any task is still non-terminal
93
- * (a framework task pending its reboot resume), leave the job `running`.
85
+ * `failed` if all failed, `partially-failed` if mixed. A skipped framework
86
+ * task counts as neither success nor failure. Defensive: if a task is still
87
+ * non-terminal (should not happen reconcile drives every task terminal),
88
+ * leave the job `running` and do not clean staging.
94
89
  */
95
90
  private finalizeReconciledJob;
96
91
  runJob(job: LifecycleJob): Promise<LifecycleJob>;
@@ -1,5 +1,5 @@
1
1
  const require_chunk = require("./chunk-Cek0wNdY.js");
2
- const require_dist = require("./dist-Bg795EQF.js");
2
+ const require_dist = require("./dist-BY6NWf-c.js");
3
3
  let _camstack_types_node = require("@camstack/types/node");
4
4
  let node_http = require("node:http");
5
5
  let node_fs = require("node:fs");
@@ -1,4 +1,4 @@
1
- import { K as readNodePin } from "./dist-JAF9YR1q.mjs";
1
+ import { K as readNodePin } from "./dist-BNevCEAo.mjs";
2
2
  import { ensureBinary, ensureFfmpeg, ensurePython, installPythonPackages, installPythonRequirements } from "@camstack/types/node";
3
3
  import { createServer } from "node:http";
4
4
  import * as fs from "node:fs";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/system",
3
- "version": "1.1.57",
3
+ "version": "1.1.58",
4
4
  "description": "Core addon for CamStack — builtins, pipeline, process management, auth, logging, events",
5
5
  "keywords": [
6
6
  "camstack",
@@ -1,15 +0,0 @@
1
- import { TarballFetcher, ExtractFn } from './staging-area.js';
2
- import { FrameworkSwapPackage } from '@camstack/types';
3
- export declare const FRAMEWORK_LOCKSTEP: readonly ["@camstack/system", "@camstack/types", "@camstack/sdk", "@camstack/shm-ring"];
4
- export interface StageFrameworkInput {
5
- readonly jobId: string;
6
- readonly toVersion: string;
7
- readonly frameworkDir: string;
8
- readonly stagingDir: string;
9
- readonly fetchTarball: TarballFetcher;
10
- readonly extract: ExtractFn;
11
- readonly resolveVersion: (name: string) => Promise<string>;
12
- readonly currentVersionOf: (name: string) => string | null;
13
- readonly signal: AbortSignal;
14
- }
15
- export declare function stageFrameworkLockstep(input: StageFrameworkInput): Promise<FrameworkSwapPackage[]>;