create-principles-disciple 1.121.7 → 1.121.9

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 (461) hide show
  1. package/README.md +13 -1
  2. package/console/dist/server/config/pd-config-store.d.ts +1 -3
  3. package/console/dist/server/config/pd-config-store.js +4 -4
  4. package/console/dist/server/feedback/channels.d.ts +2 -8
  5. package/console/dist/server/feedback/channels.js +0 -11
  6. package/console/dist/server/index.js +34 -5
  7. package/console/dist/server/models/ActivationsConsoleModel.d.ts +28 -1
  8. package/console/dist/server/models/ActivationsConsoleModel.js +72 -30
  9. package/console/dist/server/models/GovernanceExperienceCollector.d.ts +28 -0
  10. package/console/dist/server/models/GovernanceExperienceCollector.js +305 -0
  11. package/console/dist/server/models/GovernanceProjectionCollector.d.ts +60 -2
  12. package/console/dist/server/models/GovernanceProjectionCollector.js +323 -285
  13. package/console/dist/server/models/PrincipleClassifier.d.ts +1 -1
  14. package/console/dist/server/models/PrincipleClassifier.js +7 -4
  15. package/console/dist/server/models/PrinciplesConsoleModel.d.ts +2 -1
  16. package/console/dist/server/models/ReceiptsConsoleModel.d.ts +5 -0
  17. package/console/dist/server/models/ReceiptsConsoleModel.js +140 -13
  18. package/console/dist/server/routes/activations.js +1 -1
  19. package/console/dist/server/routes/failed-tasks.js +28 -11
  20. package/console/dist/server/routes/governance.d.ts +26 -0
  21. package/console/dist/server/routes/governance.js +51 -0
  22. package/console/dist/server/routes/owner-identity.d.ts +31 -0
  23. package/console/dist/server/routes/owner-identity.js +76 -0
  24. package/console/dist/server/routes/update-history.d.ts +5 -0
  25. package/console/dist/server/routes/update-history.js +50 -4
  26. package/console/dist/server/routes/update.js +186 -32
  27. package/console/dist/shared/feedback-channel-ids.d.ts +13 -0
  28. package/console/dist/shared/feedback-channel-ids.js +12 -0
  29. package/console/dist/shared/feedback-contract.d.ts +46 -0
  30. package/console/dist/shared/feedback-contract.js +45 -0
  31. package/console/dist/ui/App.js +1 -1
  32. package/console/dist/ui/api.d.ts +22 -3
  33. package/console/dist/ui/api.js +63 -3
  34. package/console/dist/ui/components/receipts/ReceiptCoverageDisclosure.d.ts +6 -0
  35. package/console/dist/ui/components/receipts/ReceiptCoverageDisclosure.js +66 -0
  36. package/console/dist/ui/i18n/en.json +198 -2
  37. package/console/dist/ui/i18n/zh-CN.json +196 -0
  38. package/console/dist/ui/pages/activation/ActivationPage.js +14 -2
  39. package/console/dist/ui/pages/failed-tasks/FailedTasksPage.js +25 -5
  40. package/console/dist/ui/pages/focus/FocusPage.d.ts +28 -1
  41. package/console/dist/ui/pages/focus/FocusPage.js +128 -15
  42. package/console/dist/ui/pages/principles/PrincipleDetailPage.d.ts +30 -0
  43. package/console/dist/ui/pages/principles/PrincipleDetailPage.js +49 -6
  44. package/console/dist/ui/pages/settings/SettingsPage.js +67 -2
  45. package/console/dist/ui/pages/settings/UpdatePage.js +7 -7
  46. package/console/dist/ui/utils/enum-labels.js +0 -1
  47. package/console/dist/ui/utils/validators.d.ts +53 -21
  48. package/console/dist/ui/utils/validators.js +248 -21
  49. package/console/dist/web/assets/app.css +6 -0
  50. package/console/dist/web/assets/app.js +2721 -1664
  51. package/console/package.json +4 -2
  52. package/core/dist/host/host-adapter.d.ts +1 -1
  53. package/core/dist/host/host-adapter.d.ts.map +1 -1
  54. package/core/dist/host/host-adapter.js +1 -0
  55. package/core/dist/host/host-adapter.js.map +1 -1
  56. package/core/dist/runtime-v2/__tests__/architecture-regression.test.js +12 -2
  57. package/core/dist/runtime-v2/__tests__/architecture-regression.test.js.map +1 -1
  58. package/core/dist/runtime-v2/__tests__/attack-e2e-pipeline-smoke.test.js +1 -1
  59. package/core/dist/runtime-v2/__tests__/attack-e2e-pipeline-smoke.test.js.map +1 -1
  60. package/core/dist/runtime-v2/__tests__/governance-experience.test.d.ts +2 -0
  61. package/core/dist/runtime-v2/__tests__/governance-experience.test.d.ts.map +1 -0
  62. package/core/dist/runtime-v2/__tests__/governance-experience.test.js +300 -0
  63. package/core/dist/runtime-v2/__tests__/governance-experience.test.js.map +1 -0
  64. package/core/dist/runtime-v2/__tests__/owner-identity.test.d.ts +2 -0
  65. package/core/dist/runtime-v2/__tests__/owner-identity.test.d.ts.map +1 -0
  66. package/core/dist/runtime-v2/__tests__/owner-identity.test.js +147 -0
  67. package/core/dist/runtime-v2/__tests__/owner-identity.test.js.map +1 -0
  68. package/core/dist/runtime-v2/__tests__/product-telemetry-contract.test.d.ts +18 -0
  69. package/core/dist/runtime-v2/__tests__/product-telemetry-contract.test.d.ts.map +1 -0
  70. package/core/dist/runtime-v2/__tests__/product-telemetry-contract.test.js +303 -0
  71. package/core/dist/runtime-v2/__tests__/product-telemetry-contract.test.js.map +1 -0
  72. package/core/dist/runtime-v2/__tests__/recovery-actions-log.test.js +40 -0
  73. package/core/dist/runtime-v2/__tests__/recovery-actions-log.test.js.map +1 -1
  74. package/core/dist/runtime-v2/__tests__/status-contract.test.d.ts +2 -0
  75. package/core/dist/runtime-v2/__tests__/status-contract.test.d.ts.map +1 -0
  76. package/core/dist/runtime-v2/__tests__/status-contract.test.js +107 -0
  77. package/core/dist/runtime-v2/__tests__/status-contract.test.js.map +1 -0
  78. package/core/dist/runtime-v2/activation/__tests__/promotion-evidence-snapshot.test.d.ts +2 -0
  79. package/core/dist/runtime-v2/activation/__tests__/promotion-evidence-snapshot.test.d.ts.map +1 -0
  80. package/core/dist/runtime-v2/activation/__tests__/promotion-evidence-snapshot.test.js +104 -0
  81. package/core/dist/runtime-v2/activation/__tests__/promotion-evidence-snapshot.test.js.map +1 -0
  82. package/core/dist/runtime-v2/activation/__tests__/promotion-readiness-evaluator.test.js +19 -0
  83. package/core/dist/runtime-v2/activation/__tests__/promotion-readiness-evaluator.test.js.map +1 -1
  84. package/core/dist/runtime-v2/activation/__tests__/rulecode-owner-decision-service.test.js +20 -0
  85. package/core/dist/runtime-v2/activation/__tests__/rulecode-owner-decision-service.test.js.map +1 -1
  86. package/core/dist/runtime-v2/activation/__tests__/sqlite-activation-safety-store.test.js +40 -0
  87. package/core/dist/runtime-v2/activation/__tests__/sqlite-activation-safety-store.test.js.map +1 -1
  88. package/core/dist/runtime-v2/activation/index.d.ts +2 -0
  89. package/core/dist/runtime-v2/activation/index.d.ts.map +1 -1
  90. package/core/dist/runtime-v2/activation/index.js +1 -0
  91. package/core/dist/runtime-v2/activation/index.js.map +1 -1
  92. package/core/dist/runtime-v2/activation/promotion-evidence-snapshot.d.ts +30 -0
  93. package/core/dist/runtime-v2/activation/promotion-evidence-snapshot.d.ts.map +1 -0
  94. package/core/dist/runtime-v2/activation/promotion-evidence-snapshot.js +87 -0
  95. package/core/dist/runtime-v2/activation/promotion-evidence-snapshot.js.map +1 -0
  96. package/core/dist/runtime-v2/activation/promotion-readiness-evaluator.d.ts.map +1 -1
  97. package/core/dist/runtime-v2/activation/promotion-readiness-evaluator.js +3 -0
  98. package/core/dist/runtime-v2/activation/promotion-readiness-evaluator.js.map +1 -1
  99. package/core/dist/runtime-v2/activation/promotion-readiness-reader.d.ts +1 -1
  100. package/core/dist/runtime-v2/activation/promotion-readiness-reader.d.ts.map +1 -1
  101. package/core/dist/runtime-v2/activation/promotion-readiness-reader.js +2 -2
  102. package/core/dist/runtime-v2/activation/promotion-readiness-reader.js.map +1 -1
  103. package/core/dist/runtime-v2/activation/rulecode-owner-decision-service.d.ts.map +1 -1
  104. package/core/dist/runtime-v2/activation/rulecode-owner-decision-service.js +18 -9
  105. package/core/dist/runtime-v2/activation/rulecode-owner-decision-service.js.map +1 -1
  106. package/core/dist/runtime-v2/adapter/__tests__/chaos-json-repair.test.js +1 -1
  107. package/core/dist/runtime-v2/adapter/__tests__/chaos-json-repair.test.js.map +1 -1
  108. package/core/dist/runtime-v2/adapter/__tests__/json-extractor.test.js +91 -1
  109. package/core/dist/runtime-v2/adapter/__tests__/json-extractor.test.js.map +1 -1
  110. package/core/dist/runtime-v2/adapter/__tests__/pi-ai-runtime-adapter.test.js +59 -12
  111. package/core/dist/runtime-v2/adapter/__tests__/pi-ai-runtime-adapter.test.js.map +1 -1
  112. package/core/dist/runtime-v2/adapter/__tests__/runtime-config-contract.test.js +10 -9
  113. package/core/dist/runtime-v2/adapter/__tests__/runtime-config-contract.test.js.map +1 -1
  114. package/core/dist/runtime-v2/adapter/__tests__/structured-output-repair.test.js +42 -1
  115. package/core/dist/runtime-v2/adapter/__tests__/structured-output-repair.test.js.map +1 -1
  116. package/core/dist/runtime-v2/adapter/json-extractor.d.ts +25 -0
  117. package/core/dist/runtime-v2/adapter/json-extractor.d.ts.map +1 -1
  118. package/core/dist/runtime-v2/adapter/json-extractor.js +126 -0
  119. package/core/dist/runtime-v2/adapter/json-extractor.js.map +1 -1
  120. package/core/dist/runtime-v2/adapter/l2-agent-loop-adapter.d.ts +9 -4
  121. package/core/dist/runtime-v2/adapter/l2-agent-loop-adapter.d.ts.map +1 -1
  122. package/core/dist/runtime-v2/adapter/l2-agent-loop-adapter.js +9 -4
  123. package/core/dist/runtime-v2/adapter/l2-agent-loop-adapter.js.map +1 -1
  124. package/core/dist/runtime-v2/adapter/output-repair-contract.d.ts +5 -1
  125. package/core/dist/runtime-v2/adapter/output-repair-contract.d.ts.map +1 -1
  126. package/core/dist/runtime-v2/adapter/output-repair-contract.js +4 -1
  127. package/core/dist/runtime-v2/adapter/output-repair-contract.js.map +1 -1
  128. package/core/dist/runtime-v2/adapter/pi-ai-catalog.d.ts +7 -0
  129. package/core/dist/runtime-v2/adapter/pi-ai-catalog.d.ts.map +1 -0
  130. package/core/dist/runtime-v2/adapter/pi-ai-catalog.js +19 -0
  131. package/core/dist/runtime-v2/adapter/pi-ai-catalog.js.map +1 -0
  132. package/core/dist/runtime-v2/adapter/pi-ai-runtime-adapter.d.ts +13 -15
  133. package/core/dist/runtime-v2/adapter/pi-ai-runtime-adapter.d.ts.map +1 -1
  134. package/core/dist/runtime-v2/adapter/pi-ai-runtime-adapter.js +104 -37
  135. package/core/dist/runtime-v2/adapter/pi-ai-runtime-adapter.js.map +1 -1
  136. package/core/dist/runtime-v2/adapter/structured-output-repair.d.ts +16 -1
  137. package/core/dist/runtime-v2/adapter/structured-output-repair.d.ts.map +1 -1
  138. package/core/dist/runtime-v2/adapter/structured-output-repair.js +38 -6
  139. package/core/dist/runtime-v2/adapter/structured-output-repair.js.map +1 -1
  140. package/core/dist/runtime-v2/adapter/tools/diagnostician-tool.d.ts +1 -1
  141. package/core/dist/runtime-v2/adapter/tools/diagnostician-tool.d.ts.map +1 -1
  142. package/core/dist/runtime-v2/config/__tests__/pd-config-agent-binding.test.js +8 -9
  143. package/core/dist/runtime-v2/config/__tests__/pd-config-agent-binding.test.js.map +1 -1
  144. package/core/dist/runtime-v2/config/__tests__/pd-config-contract.test.js +27 -3
  145. package/core/dist/runtime-v2/config/__tests__/pd-config-contract.test.js.map +1 -1
  146. package/core/dist/runtime-v2/config/__tests__/pd-config-principles.test.d.ts +11 -0
  147. package/core/dist/runtime-v2/config/__tests__/pd-config-principles.test.d.ts.map +1 -0
  148. package/core/dist/runtime-v2/config/__tests__/pd-config-principles.test.js +93 -0
  149. package/core/dist/runtime-v2/config/__tests__/pd-config-principles.test.js.map +1 -0
  150. package/core/dist/runtime-v2/config/__tests__/pd-config-workspace.test.js +41 -0
  151. package/core/dist/runtime-v2/config/__tests__/pd-config-workspace.test.js.map +1 -1
  152. package/core/dist/runtime-v2/config/index.d.ts +2 -2
  153. package/core/dist/runtime-v2/config/index.d.ts.map +1 -1
  154. package/core/dist/runtime-v2/config/index.js +2 -0
  155. package/core/dist/runtime-v2/config/index.js.map +1 -1
  156. package/core/dist/runtime-v2/config/pd-config-agent-binding.d.ts.map +1 -1
  157. package/core/dist/runtime-v2/config/pd-config-agent-binding.js +4 -13
  158. package/core/dist/runtime-v2/config/pd-config-agent-binding.js.map +1 -1
  159. package/core/dist/runtime-v2/config/pd-config-effective.d.ts.map +1 -1
  160. package/core/dist/runtime-v2/config/pd-config-effective.js +14 -7
  161. package/core/dist/runtime-v2/config/pd-config-effective.js.map +1 -1
  162. package/core/dist/runtime-v2/config/pd-config-feature-flags.d.ts.map +1 -1
  163. package/core/dist/runtime-v2/config/pd-config-feature-flags.js +5 -12
  164. package/core/dist/runtime-v2/config/pd-config-feature-flags.js.map +1 -1
  165. package/core/dist/runtime-v2/config/pd-config-types.d.ts +8 -0
  166. package/core/dist/runtime-v2/config/pd-config-types.d.ts.map +1 -1
  167. package/core/dist/runtime-v2/config/pd-config-types.js +2 -0
  168. package/core/dist/runtime-v2/config/pd-config-types.js.map +1 -1
  169. package/core/dist/runtime-v2/config/pd-config-validate.d.ts.map +1 -1
  170. package/core/dist/runtime-v2/config/pd-config-validate.js +48 -3
  171. package/core/dist/runtime-v2/config/pd-config-validate.js.map +1 -1
  172. package/core/dist/runtime-v2/core-principles/__tests__/core-axiom-block.test.js +36 -8
  173. package/core/dist/runtime-v2/core-principles/__tests__/core-axiom-block.test.js.map +1 -1
  174. package/core/dist/runtime-v2/core-principles/__tests__/core-principle-registry.test.js +36 -12
  175. package/core/dist/runtime-v2/core-principles/__tests__/core-principle-registry.test.js.map +1 -1
  176. package/core/dist/runtime-v2/core-principles/core-axiom-block.d.ts +22 -8
  177. package/core/dist/runtime-v2/core-principles/core-axiom-block.d.ts.map +1 -1
  178. package/core/dist/runtime-v2/core-principles/core-axiom-block.js +28 -13
  179. package/core/dist/runtime-v2/core-principles/core-axiom-block.js.map +1 -1
  180. package/core/dist/runtime-v2/core-principles/core-principle-registry.d.ts +29 -4
  181. package/core/dist/runtime-v2/core-principles/core-principle-registry.d.ts.map +1 -1
  182. package/core/dist/runtime-v2/core-principles/core-principle-registry.js +68 -33
  183. package/core/dist/runtime-v2/core-principles/core-principle-registry.js.map +1 -1
  184. package/core/dist/runtime-v2/core-principles/index.d.ts +3 -3
  185. package/core/dist/runtime-v2/core-principles/index.d.ts.map +1 -1
  186. package/core/dist/runtime-v2/core-principles/index.js +1 -1
  187. package/core/dist/runtime-v2/core-principles/index.js.map +1 -1
  188. package/core/dist/runtime-v2/evolution/evolution-types.d.ts +2 -1
  189. package/core/dist/runtime-v2/evolution/evolution-types.d.ts.map +1 -1
  190. package/core/dist/runtime-v2/evolution/evolution-types.js.map +1 -1
  191. package/core/dist/runtime-v2/feature-flags/__tests__/anonymous-product-telemetry-flag.test.d.ts +2 -0
  192. package/core/dist/runtime-v2/feature-flags/__tests__/anonymous-product-telemetry-flag.test.d.ts.map +1 -0
  193. package/core/dist/runtime-v2/feature-flags/__tests__/anonymous-product-telemetry-flag.test.js +48 -0
  194. package/core/dist/runtime-v2/feature-flags/__tests__/anonymous-product-telemetry-flag.test.js.map +1 -0
  195. package/core/dist/runtime-v2/feature-flags/__tests__/codex-conversation-ingestion-flag.test.d.ts +2 -0
  196. package/core/dist/runtime-v2/feature-flags/__tests__/codex-conversation-ingestion-flag.test.d.ts.map +1 -0
  197. package/core/dist/runtime-v2/feature-flags/__tests__/codex-conversation-ingestion-flag.test.js +46 -0
  198. package/core/dist/runtime-v2/feature-flags/__tests__/codex-conversation-ingestion-flag.test.js.map +1 -0
  199. package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-contract.test.js +86 -31
  200. package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-contract.test.js.map +1 -1
  201. package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-lifecycle.test.d.ts +2 -0
  202. package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-lifecycle.test.d.ts.map +1 -0
  203. package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-lifecycle.test.js +83 -0
  204. package/core/dist/runtime-v2/feature-flags/__tests__/feature-flag-lifecycle.test.js.map +1 -0
  205. package/core/dist/runtime-v2/feature-flags/feature-flag-contract.d.ts +19 -1
  206. package/core/dist/runtime-v2/feature-flags/feature-flag-contract.d.ts.map +1 -1
  207. package/core/dist/runtime-v2/feature-flags/feature-flag-contract.js +128 -10
  208. package/core/dist/runtime-v2/feature-flags/feature-flag-contract.js.map +1 -1
  209. package/core/dist/runtime-v2/feature-flags/feature-flag-lifecycle.d.ts +37 -0
  210. package/core/dist/runtime-v2/feature-flags/feature-flag-lifecycle.d.ts.map +1 -0
  211. package/core/dist/runtime-v2/feature-flags/feature-flag-lifecycle.js +304 -0
  212. package/core/dist/runtime-v2/feature-flags/feature-flag-lifecycle.js.map +1 -0
  213. package/core/dist/runtime-v2/feature-flags/index.d.ts +4 -2
  214. package/core/dist/runtime-v2/feature-flags/index.d.ts.map +1 -1
  215. package/core/dist/runtime-v2/feature-flags/index.js +3 -1
  216. package/core/dist/runtime-v2/feature-flags/index.js.map +1 -1
  217. package/core/dist/runtime-v2/governance-experience-contract.d.ts +468 -0
  218. package/core/dist/runtime-v2/governance-experience-contract.d.ts.map +1 -0
  219. package/core/dist/runtime-v2/governance-experience-contract.js +208 -0
  220. package/core/dist/runtime-v2/governance-experience-contract.js.map +1 -0
  221. package/core/dist/runtime-v2/governance-experience.d.ts +11 -0
  222. package/core/dist/runtime-v2/governance-experience.d.ts.map +1 -0
  223. package/core/dist/runtime-v2/governance-experience.js +276 -0
  224. package/core/dist/runtime-v2/governance-experience.js.map +1 -0
  225. package/core/dist/runtime-v2/index.d.ts +20 -8
  226. package/core/dist/runtime-v2/index.d.ts.map +1 -1
  227. package/core/dist/runtime-v2/index.js +20 -6
  228. package/core/dist/runtime-v2/index.js.map +1 -1
  229. package/core/dist/runtime-v2/internalization/__tests__/artificer-output-retry-flag.test.js +29 -10
  230. package/core/dist/runtime-v2/internalization/__tests__/artificer-output-retry-flag.test.js.map +1 -1
  231. package/core/dist/runtime-v2/owner-identity.d.ts +69 -0
  232. package/core/dist/runtime-v2/owner-identity.d.ts.map +1 -0
  233. package/core/dist/runtime-v2/owner-identity.js +179 -0
  234. package/core/dist/runtime-v2/owner-identity.js.map +1 -0
  235. package/core/dist/runtime-v2/pain-signal-runtime-factory.d.ts.map +1 -1
  236. package/core/dist/runtime-v2/pain-signal-runtime-factory.js +2 -3
  237. package/core/dist/runtime-v2/pain-signal-runtime-factory.js.map +1 -1
  238. package/core/dist/runtime-v2/product-telemetry/daily-identity.d.ts +70 -0
  239. package/core/dist/runtime-v2/product-telemetry/daily-identity.d.ts.map +1 -0
  240. package/core/dist/runtime-v2/product-telemetry/daily-identity.js +89 -0
  241. package/core/dist/runtime-v2/product-telemetry/daily-identity.js.map +1 -0
  242. package/core/dist/runtime-v2/product-telemetry/snapshot-contract.d.ts +110 -0
  243. package/core/dist/runtime-v2/product-telemetry/snapshot-contract.d.ts.map +1 -0
  244. package/core/dist/runtime-v2/product-telemetry/snapshot-contract.js +250 -0
  245. package/core/dist/runtime-v2/product-telemetry/snapshot-contract.js.map +1 -0
  246. package/core/dist/runtime-v2/pruning-read-model.d.ts +2 -1
  247. package/core/dist/runtime-v2/pruning-read-model.d.ts.map +1 -1
  248. package/core/dist/runtime-v2/pruning-read-model.js.map +1 -1
  249. package/core/dist/runtime-v2/receipt-coverage.d.ts +63 -0
  250. package/core/dist/runtime-v2/receipt-coverage.d.ts.map +1 -0
  251. package/core/dist/runtime-v2/receipt-coverage.js +19 -0
  252. package/core/dist/runtime-v2/receipt-coverage.js.map +1 -0
  253. package/core/dist/runtime-v2/recovery-actions-log.d.ts +7 -0
  254. package/core/dist/runtime-v2/recovery-actions-log.d.ts.map +1 -1
  255. package/core/dist/runtime-v2/recovery-actions-log.js +6 -0
  256. package/core/dist/runtime-v2/recovery-actions-log.js.map +1 -1
  257. package/core/dist/runtime-v2/runtime-protocol.js +1 -1
  258. package/core/dist/runtime-v2/runtime-protocol.js.map +1 -1
  259. package/core/dist/runtime-v2/store/task/__tests__/sqlite-task-store.failed-tasks.test.js +17 -1
  260. package/core/dist/runtime-v2/store/task/__tests__/sqlite-task-store.failed-tasks.test.js.map +1 -1
  261. package/core/dist/runtime-v2/store/task/sqlite-task-store.d.ts.map +1 -1
  262. package/core/dist/runtime-v2/store/task/sqlite-task-store.js +10 -0
  263. package/core/dist/runtime-v2/store/task/sqlite-task-store.js.map +1 -1
  264. package/core/dist/runtime-v2/store/task/task-types.d.ts +2 -0
  265. package/core/dist/runtime-v2/store/task/task-types.d.ts.map +1 -1
  266. package/core/dist/runtime-v2/task-status.d.ts +9 -5
  267. package/core/dist/runtime-v2/task-status.d.ts.map +1 -1
  268. package/core/dist/runtime-v2/task-status.js +15 -7
  269. package/core/dist/runtime-v2/task-status.js.map +1 -1
  270. package/core/dist/runtime-v2/types/event-types.d.ts +4 -0
  271. package/core/dist/runtime-v2/types/event-types.d.ts.map +1 -1
  272. package/core/dist/runtime-v2/types/event-types.js.map +1 -1
  273. package/core/dist/runtime-v2/types/index.d.ts +1 -1
  274. package/core/dist/runtime-v2/types/index.d.ts.map +1 -1
  275. package/core/dist/runtime-v2/types/index.js +1 -1
  276. package/core/dist/runtime-v2/types/index.js.map +1 -1
  277. package/core/dist/runtime-v2/types/principle-enums.d.ts +3 -2
  278. package/core/dist/runtime-v2/types/principle-enums.d.ts.map +1 -1
  279. package/core/dist/runtime-v2/types/principle-enums.js +11 -5
  280. package/core/dist/runtime-v2/types/principle-enums.js.map +1 -1
  281. package/core/dist/runtime-v2/types/principle-schema.d.ts +1 -1
  282. package/core/dist/runtime-v2/types/principle-tree-store.d.ts +1 -1
  283. package/core/dist/runtime-v2/utils/cli-process-runner.d.ts.map +1 -1
  284. package/core/dist/runtime-v2/utils/cli-process-runner.js +3 -2
  285. package/core/dist/runtime-v2/utils/cli-process-runner.js.map +1 -1
  286. package/core/package.json +4 -5
  287. package/dist/i18n.d.ts.map +1 -1
  288. package/dist/i18n.js +4 -2
  289. package/dist/i18n.js.map +1 -1
  290. package/dist/index.d.ts +2 -0
  291. package/dist/index.d.ts.map +1 -1
  292. package/dist/index.js +47 -11
  293. package/dist/index.js.map +1 -1
  294. package/dist/installer.d.ts +31 -5
  295. package/dist/installer.d.ts.map +1 -1
  296. package/dist/installer.js +472 -161
  297. package/dist/installer.js.map +1 -1
  298. package/dist/installers/codex-host-installer.d.ts.map +1 -1
  299. package/dist/installers/codex-host-installer.js +4 -0
  300. package/dist/installers/codex-host-installer.js.map +1 -1
  301. package/dist/mvp-config.d.ts +10 -0
  302. package/dist/mvp-config.d.ts.map +1 -1
  303. package/dist/mvp-config.js +30 -3
  304. package/dist/mvp-config.js.map +1 -1
  305. package/dist/uninstaller.d.ts +9 -1
  306. package/dist/uninstaller.d.ts.map +1 -1
  307. package/dist/uninstaller.js +103 -23
  308. package/dist/uninstaller.js.map +1 -1
  309. package/dist/update/atomic-file.d.ts +35 -0
  310. package/dist/update/atomic-file.d.ts.map +1 -0
  311. package/dist/update/atomic-file.js +120 -0
  312. package/dist/update/atomic-file.js.map +1 -0
  313. package/dist/update/bootstrap-protocol.d.ts +55 -0
  314. package/dist/update/bootstrap-protocol.d.ts.map +1 -0
  315. package/dist/update/bootstrap-protocol.js +132 -0
  316. package/dist/update/bootstrap-protocol.js.map +1 -0
  317. package/dist/update/channel-metadata.d.ts +28 -0
  318. package/dist/update/channel-metadata.d.ts.map +1 -0
  319. package/dist/update/channel-metadata.js +90 -0
  320. package/dist/update/channel-metadata.js.map +1 -0
  321. package/dist/update/channel-promotion.d.ts +39 -0
  322. package/dist/update/channel-promotion.d.ts.map +1 -0
  323. package/dist/update/channel-promotion.js +55 -0
  324. package/dist/update/channel-promotion.js.map +1 -0
  325. package/dist/update/data-compatibility.d.ts +35 -0
  326. package/dist/update/data-compatibility.d.ts.map +1 -0
  327. package/dist/update/data-compatibility.js +45 -0
  328. package/dist/update/data-compatibility.js.map +1 -0
  329. package/dist/update/install-layout.d.ts +59 -0
  330. package/dist/update/install-layout.d.ts.map +1 -0
  331. package/dist/update/install-layout.js +127 -0
  332. package/dist/update/install-layout.js.map +1 -0
  333. package/dist/update/legacy-migration.d.ts +56 -0
  334. package/dist/update/legacy-migration.d.ts.map +1 -0
  335. package/dist/update/legacy-migration.js +254 -0
  336. package/dist/update/legacy-migration.js.map +1 -0
  337. package/dist/update/product-identity.d.ts +50 -0
  338. package/dist/update/product-identity.d.ts.map +1 -0
  339. package/dist/update/product-identity.js +63 -0
  340. package/dist/update/product-identity.js.map +1 -0
  341. package/dist/update/release-asset-manifest.d.ts +31 -0
  342. package/dist/update/release-asset-manifest.d.ts.map +1 -0
  343. package/dist/update/release-asset-manifest.js +161 -0
  344. package/dist/update/release-asset-manifest.js.map +1 -0
  345. package/dist/update/release-identity.d.ts +33 -0
  346. package/dist/update/release-identity.d.ts.map +1 -0
  347. package/dist/update/release-identity.js +108 -0
  348. package/dist/update/release-identity.js.map +1 -0
  349. package/dist/update/release-manager.d.ts +96 -0
  350. package/dist/update/release-manager.d.ts.map +1 -0
  351. package/dist/update/release-manager.js +253 -0
  352. package/dist/update/release-manager.js.map +1 -0
  353. package/dist/update/release-metadata.d.ts +57 -0
  354. package/dist/update/release-metadata.d.ts.map +1 -0
  355. package/dist/update/release-metadata.js +200 -0
  356. package/dist/update/release-metadata.js.map +1 -0
  357. package/dist/update/release-policy.d.ts +51 -0
  358. package/dist/update/release-policy.d.ts.map +1 -0
  359. package/dist/update/release-policy.js +103 -0
  360. package/dist/update/release-policy.js.map +1 -0
  361. package/dist/update/rollback-policy.d.ts +56 -0
  362. package/dist/update/rollback-policy.d.ts.map +1 -0
  363. package/dist/update/rollback-policy.js +61 -0
  364. package/dist/update/rollback-policy.js.map +1 -0
  365. package/dist/update/transaction-journal.d.ts +121 -0
  366. package/dist/update/transaction-journal.d.ts.map +1 -0
  367. package/dist/update/transaction-journal.js +333 -0
  368. package/dist/update/transaction-journal.js.map +1 -0
  369. package/dist/update/trust-metadata.d.ts +55 -0
  370. package/dist/update/trust-metadata.d.ts.map +1 -0
  371. package/dist/update/trust-metadata.js +170 -0
  372. package/dist/update/trust-metadata.js.map +1 -0
  373. package/dist/update/update-history.d.ts +46 -0
  374. package/dist/update/update-history.d.ts.map +1 -0
  375. package/dist/update/update-history.js +123 -0
  376. package/dist/update/update-history.js.map +1 -0
  377. package/dist/utils/env.d.ts +7 -0
  378. package/dist/utils/env.d.ts.map +1 -1
  379. package/dist/utils/env.js +134 -44
  380. package/dist/utils/env.js.map +1 -1
  381. package/host-runtime/dist/governance-observation-store.d.ts +172 -0
  382. package/host-runtime/dist/governance-observation-store.js +649 -0
  383. package/host-runtime/dist/index.d.ts +6 -0
  384. package/host-runtime/dist/index.js +8 -0
  385. package/host-runtime/dist/product-telemetry/consent-store.d.ts +107 -0
  386. package/host-runtime/dist/product-telemetry/consent-store.js +329 -0
  387. package/host-runtime/dist/product-telemetry/eligibility.d.ts +53 -0
  388. package/host-runtime/dist/product-telemetry/eligibility.js +69 -0
  389. package/host-runtime/dist/product-telemetry/exporter.d.ts +46 -0
  390. package/host-runtime/dist/product-telemetry/exporter.js +71 -0
  391. package/host-runtime/dist/product-telemetry/milestone-readers.d.ts +61 -0
  392. package/host-runtime/dist/product-telemetry/milestone-readers.js +234 -0
  393. package/host-runtime/dist/product-telemetry/service.d.ts +142 -0
  394. package/host-runtime/dist/product-telemetry/service.js +532 -0
  395. package/host-runtime/dist/product-telemetry/workspace-scope.d.ts +38 -0
  396. package/host-runtime/dist/product-telemetry/workspace-scope.js +64 -0
  397. package/host-runtime/package.json +7 -2
  398. package/install-layout/dist/index.d.ts +48 -0
  399. package/install-layout/dist/index.js +81 -0
  400. package/install-layout/dist/index.test.d.ts +1 -0
  401. package/install-layout/dist/index.test.js +34 -0
  402. package/install-layout/package.json +33 -0
  403. package/package.json +16 -6
  404. package/pd-cli/dist/commands/__tests__/telemetry-flag-wiring.test.d.ts +9 -0
  405. package/pd-cli/dist/commands/__tests__/telemetry-flag-wiring.test.d.ts.map +1 -0
  406. package/pd-cli/dist/commands/__tests__/telemetry-flag-wiring.test.js +76 -0
  407. package/pd-cli/dist/commands/__tests__/telemetry-flag-wiring.test.js.map +1 -0
  408. package/pd-cli/dist/commands/__tests__/version.test.d.ts +2 -0
  409. package/pd-cli/dist/commands/__tests__/version.test.d.ts.map +1 -0
  410. package/pd-cli/dist/commands/__tests__/version.test.js +134 -0
  411. package/pd-cli/dist/commands/__tests__/version.test.js.map +1 -0
  412. package/pd-cli/dist/commands/console.d.ts.map +1 -1
  413. package/pd-cli/dist/commands/console.js +29 -10
  414. package/pd-cli/dist/commands/console.js.map +1 -1
  415. package/pd-cli/dist/commands/pain-record.d.ts.map +1 -1
  416. package/pd-cli/dist/commands/pain-record.js +6 -15
  417. package/pd-cli/dist/commands/pain-record.js.map +1 -1
  418. package/pd-cli/dist/commands/runtime-activation.d.ts +29 -0
  419. package/pd-cli/dist/commands/runtime-activation.d.ts.map +1 -1
  420. package/pd-cli/dist/commands/runtime-activation.js +70 -31
  421. package/pd-cli/dist/commands/runtime-activation.js.map +1 -1
  422. package/pd-cli/dist/commands/runtime-internalization-enqueue-successors.d.ts.map +1 -1
  423. package/pd-cli/dist/commands/runtime-internalization-enqueue-successors.js +2 -2
  424. package/pd-cli/dist/commands/runtime-internalization-enqueue-successors.js.map +1 -1
  425. package/pd-cli/dist/commands/telemetry.d.ts +82 -0
  426. package/pd-cli/dist/commands/telemetry.d.ts.map +1 -0
  427. package/pd-cli/dist/commands/telemetry.js +268 -0
  428. package/pd-cli/dist/commands/telemetry.js.map +1 -0
  429. package/pd-cli/dist/commands/version.d.ts +11 -0
  430. package/pd-cli/dist/commands/version.d.ts.map +1 -0
  431. package/pd-cli/dist/commands/version.js +48 -0
  432. package/pd-cli/dist/commands/version.js.map +1 -0
  433. package/pd-cli/dist/index.js +35 -2
  434. package/pd-cli/dist/index.js.map +1 -1
  435. package/pd-cli/dist/services/version-report.d.ts +44 -0
  436. package/pd-cli/dist/services/version-report.d.ts.map +1 -0
  437. package/pd-cli/dist/services/version-report.js +152 -0
  438. package/pd-cli/dist/services/version-report.js.map +1 -0
  439. package/pd-cli/package.json +3 -2
  440. package/plugin/dist/bundle.js +870 -932
  441. package/plugin/dist/core/init.d.ts +2 -1
  442. package/plugin/dist/core/principle-application-ledger.d.ts +10 -0
  443. package/plugin/dist/core/product-telemetry-trigger.d.ts +14 -0
  444. package/plugin/dist/core/thinking-os-parser.d.ts +5 -2
  445. package/plugin/dist/governance-audit.js +386 -0
  446. package/plugin/dist/hooks/gate-block-helper.d.ts +25 -1
  447. package/plugin/dist/hooks/gate.d.ts +22 -0
  448. package/plugin/dist/openclaw.plugin.json +1 -1
  449. package/plugin/dist/rulehost-evidence.js +832 -0
  450. package/plugin/dist/templates/langs/en/principles/THINKING_OS.md +53 -45
  451. package/plugin/dist/templates/langs/en/skills/pd-mentor/SKILL.md +1 -1
  452. package/plugin/dist/templates/langs/zh/principles/THINKING_OS.md +62 -46
  453. package/plugin/dist/templates/langs/zh/skills/pd-mentor/SKILL.md +1 -1
  454. package/plugin/dist/templates/workspace/.principles/THINKING_OS.md +66 -38
  455. package/plugin/openclaw.plugin.json +1 -1
  456. package/plugin/package.json +1 -1
  457. package/plugin/templates/langs/en/principles/THINKING_OS.md +53 -45
  458. package/plugin/templates/langs/en/skills/pd-mentor/SKILL.md +1 -1
  459. package/plugin/templates/langs/zh/principles/THINKING_OS.md +62 -46
  460. package/plugin/templates/langs/zh/skills/pd-mentor/SKILL.md +1 -1
  461. package/plugin/templates/workspace/.principles/THINKING_OS.md +66 -38
@@ -0,0 +1,103 @@
1
+ /**
2
+ * Release advancement preflight policy (SPEC §4.3, §9, §13).
3
+ *
4
+ * Pure decisions over already-validated metadata: publication sequence
5
+ * monotonicity, the explicit downgrade policy, channel pointer integrity,
6
+ * expiry, and bootstrap compatibility. Every refusal carries a stable reason
7
+ * code and an Owner-visible next action (rc-9) and must happen BEFORE any
8
+ * installation state is mutated (ERR-074 guard placement).
9
+ */
10
+ import { isChannelMetadataExpired } from './channel-metadata.js';
11
+ import { isReleaseMetadataExpired } from './release-metadata.js';
12
+ import { compareProductVersions, parseProductVersion } from './product-identity.js';
13
+ /**
14
+ * The channel pointer must reference exactly this release metadata document
15
+ * (SPEC §4.3: "Channel Metadata references the exact Release Metadata digest").
16
+ */
17
+ export function verifyChannelPointer(channel, release) {
18
+ if (channel.releaseMetadataDigest !== release.metadataDigest || channel.releaseId !== release.releaseId) {
19
+ return {
20
+ allowed: false,
21
+ reason: 'channel_pointer_mismatch',
22
+ message: `The signed ${channel.channel} channel points at release metadata ${channel.releaseMetadataDigest.slice(0, 12)} (${channel.productVersion}), not the presented release ${release.releaseId.slice(0, 12)} (${release.productVersion}).`,
23
+ nextAction: 'Do not install this release. Re-fetch channel metadata and the release it references, then retry.',
24
+ };
25
+ }
26
+ if (channel.publicationSequence !== release.publicationSequence) {
27
+ return {
28
+ allowed: false,
29
+ reason: 'channel_pointer_mismatch',
30
+ message: `The channel publication sequence (${channel.publicationSequence}) disagrees with the release metadata sequence (${release.publicationSequence}).`,
31
+ nextAction: 'Do not install this release. The channel pointer and release metadata must come from the same publication.',
32
+ };
33
+ }
34
+ return null;
35
+ }
36
+ /**
37
+ * Full advancement decision. `allowExplicitDowngrade` is the Owner's explicit
38
+ * confirmation flag; even with it, the target must be a previously confirmed
39
+ * release — arbitrary downgrades to unseen releases stay refused because their
40
+ * data compatibility window is unproven (SPEC §10).
41
+ */
42
+ export function evaluateReleaseAdvancement(input) {
43
+ const { channel, candidate, current, bootstrapVersion } = input;
44
+ const now = input.now ?? new Date();
45
+ const pointerFailure = verifyChannelPointer(channel, candidate);
46
+ if (pointerFailure)
47
+ return pointerFailure;
48
+ if (isReleaseMetadataExpired(candidate, now)) {
49
+ return {
50
+ allowed: false,
51
+ reason: 'release_metadata_expired',
52
+ message: `Release ${candidate.productVersion} metadata expired at ${candidate.expiresAt}.`,
53
+ nextAction: 'Do not install this release. Wait for refreshed signed metadata from the official repository.',
54
+ };
55
+ }
56
+ if (isChannelMetadataExpired(channel, now)) {
57
+ return {
58
+ allowed: false,
59
+ reason: 'channel_metadata_expired',
60
+ message: `The ${channel.channel} channel metadata expired at ${channel.expiresAt}.`,
61
+ nextAction: 'Do not install this release. Refresh the signed channel metadata and retry.',
62
+ };
63
+ }
64
+ const bootstrap = parseProductVersion(bootstrapVersion, 'bootstrapVersion');
65
+ const requiredBootstrap = parseProductVersion(candidate.minBootstrapVersion, 'candidate.minBootstrapVersion');
66
+ if (compareProductVersions(bootstrap, requiredBootstrap) < 0) {
67
+ return {
68
+ allowed: false,
69
+ reason: 'bootstrap_too_old',
70
+ message: `Release ${candidate.productVersion} requires bootstrap >= ${candidate.minBootstrapVersion}; installed bootstrap is ${bootstrapVersion}.`,
71
+ nextAction: 'Do not install this release. Run the official installer once to update the bootstrap, then retry the update.',
72
+ };
73
+ }
74
+ if (current === null) {
75
+ return { allowed: true, direction: 'update' };
76
+ }
77
+ if (candidate.releaseId === current.releaseId) {
78
+ return { allowed: true, direction: 'reinstall' };
79
+ }
80
+ if (candidate.publicationSequence < current.publicationSequence) {
81
+ if (input.allowExplicitDowngrade === true && current.previouslyConfirmedReleaseIds.includes(candidate.releaseId)) {
82
+ return { allowed: true, direction: 'explicit_downgrade' };
83
+ }
84
+ return {
85
+ allowed: false,
86
+ reason: current.publicationSequence > candidate.publicationSequence ? 'downgrade_blocked' : 'sequence_regression',
87
+ message: `Release ${candidate.productVersion} (sequence ${candidate.publicationSequence}) is older than the active ${current.productVersion} (sequence ${current.publicationSequence}).`,
88
+ nextAction: input.allowExplicitDowngrade === true
89
+ ? 'Explicit downgrade is only permitted to releases previously confirmed on this installation. Select a confirmed release or update forward.'
90
+ : 'Downgrades are refused by default. If the Owner explicitly intends this, re-run with downgrade confirmation to a previously confirmed release.',
91
+ };
92
+ }
93
+ if (candidate.publicationSequence === current.publicationSequence && candidate.releaseId !== current.releaseId) {
94
+ return {
95
+ allowed: false,
96
+ reason: 'sequence_regression',
97
+ message: `Two different releases claim publication sequence ${candidate.publicationSequence}; the active release is ${current.releaseId.slice(0, 12)}.`,
98
+ nextAction: 'Do not install this release. Report the conflicting metadata to the repository maintainer.',
99
+ };
100
+ }
101
+ return { allowed: true, direction: 'update' };
102
+ }
103
+ //# sourceMappingURL=release-policy.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"release-policy.js","sourceRoot":"","sources":["../../src/update/release-policy.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAIH,OAAO,EAAE,wBAAwB,EAAE,MAAM,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ic-rollback policy (SPEC §9).
3
+ *
4
+ * One global active release per installation. Only hosts that were RUNNING
5
+ * before activation must restart and complete the handshake — hosts that
6
+ * were already stopped are not failures. If any previously-running host
7
+ * cannot start the same release, every affected host returns to the prior
8
+ * release: a split-brain component mix must never become active.
9
+ *
10
+ * Attribution rules:
11
+ * - Deterministic failures attributable to the new release (entrypoint load,
12
+ * handshake mismatch, startup crash) qualify for automatic rollback.
13
+ * - Network unavailability, empty business data, and unrelated
14
+ * external-service failures do NOT — they would roll back a healthy
15
+ * release for environmental noise.
16
+ *
17
+ * At most ONE automatic rollback per transaction. A second deterministic
18
+ * failure opens the circuit breaker: the last confirmed release stays
19
+ * active and an explicit Owner action is required.
20
+ */
21
+ export type HostHandshakeOutcome = {
22
+ readonly kind: 'passed';
23
+ } | {
24
+ readonly kind: 'not_restarted';
25
+ } | {
26
+ readonly kind: 'failed';
27
+ readonly failureClass: HostFailureClass;
28
+ readonly detail: string;
29
+ };
30
+ export type HostFailureClass = 'deterministic_start_failure' | 'handshake_mismatch' | 'network_unavailable' | 'external_service_unavailable' | 'unknown';
31
+ export interface HostObservation {
32
+ readonly hostId: string;
33
+ readonly wasRunningBeforeActivation: boolean;
34
+ readonly outcome: HostHandshakeOutcome;
35
+ }
36
+ export type RollbackDecision = {
37
+ readonly action: 'confirm';
38
+ readonly reason: string;
39
+ } | {
40
+ readonly action: 'retry_handshake';
41
+ readonly reason: string;
42
+ readonly nextAction: string;
43
+ } | {
44
+ readonly action: 'auto_rollback';
45
+ readonly reason: string;
46
+ readonly hosts: readonly string[];
47
+ } | {
48
+ readonly action: 'circuit_breaker_open';
49
+ readonly reason: string;
50
+ readonly nextAction: string;
51
+ };
52
+ export declare function decideHostCoordination(input: {
53
+ observations: readonly HostObservation[];
54
+ autoRollbackAlreadyUsed: boolean;
55
+ }): RollbackDecision;
56
+ //# sourceMappingURL=rollback-policy.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"rollback-policy.d.ts","sourceRoot":"","s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,CAAC,KAAK,EAAE;IAC5C,YAAY,EAAE,SAAS,eAAe,EAAE,CAAC;IACzC,uBAAuB,EAAE,OAAO,CAAC;CAClC,GAAG,gBAAgB,CA2CnB"}
@@ -0,0 +1,61 @@
1
+ /**
2
+ * Host coordination and automatic-rollback policy (SPEC §9).
3
+ *
4
+ * One global active release per installation. Only hosts that were RUNNING
5
+ * before activation must restart and complete the handshake — hosts that
6
+ * were already stopped are not failures. If any previously-running host
7
+ * cannot start the same release, every affected host returns to the prior
8
+ * release: a split-brain component mix must never become active.
9
+ *
10
+ * Attribution rules:
11
+ * - Deterministic failures attributable to the new release (entrypoint load,
12
+ * handshake mismatch, startup crash) qualify for automatic rollback.
13
+ * - Network unavailability, empty business data, and unrelated
14
+ * external-service failures do NOT — they would roll back a healthy
15
+ * release for environmental noise.
16
+ *
17
+ * At most ONE automatic rollback per transaction. A second deterministic
18
+ * failure opens the circuit breaker: the last confirmed release stays
19
+ * active and an explicit Owner action is required.
20
+ */
21
+ const DETERMINISTIC_CLASSES = new Set(['deterministic_start_failure', 'handshake_mismatch']);
22
+ export function decideHostCoordination(input) {
23
+ const { observations, autoRollbackAlreadyUsed } = input;
24
+ if (observations.length === 0) {
25
+ return { action: 'confirm', reason: 'no hosts required coordination' };
26
+ }
27
+ const mustRestart = observations.filter((observation) => observation.wasRunningBeforeActivation);
28
+ if (mustRestart.length === 0) {
29
+ return { action: 'confirm', reason: 'no hosts were running before activation; nothing to restart' };
30
+ }
31
+ const deterministicFailures = mustRestart.filter((observation) => observation.outcome.kind === 'failed'
32
+ && DETERMINISTIC_CLASSES.has(observation.outcome.failureClass));
33
+ const environmentalFailures = mustRestart.filter((observation) => observation.outcome.kind === 'failed'
34
+ && !DETERMINISTIC_CLASSES.has(observation.outcome.failureClass));
35
+ const pending = mustRestart.filter((observation) => observation.outcome.kind === 'not_restarted');
36
+ if (deterministicFailures.length > 0) {
37
+ const failingHosts = deterministicFailures.map((observation) => observation.hostId);
38
+ if (autoRollbackAlreadyUsed) {
39
+ return {
40
+ action: 'circuit_breaker_open',
41
+ reason: `A second deterministic failure followed the transaction's single automatic rollback (hosts: ${failingHosts.join(', ')}).`,
42
+ nextAction: 'The last confirmed release remains active. Inspect the failing host logs under ~/.pd/logs, fix the cause, and run an explicit update or rollback operation.',
43
+ };
44
+ }
45
+ return {
46
+ action: 'auto_rollback',
47
+ reason: `Deterministic startup failures attributable to the new release (hosts: ${failingHosts.join(', ')}); all affected hosts return to the previous confirmed release to avoid split brain.`,
48
+ hosts: failingHosts,
49
+ };
50
+ }
51
+ if (environmentalFailures.length > 0 || pending.length > 0) {
52
+ const affected = [...environmentalFailures, ...pending].map((observation) => observation.hostId);
53
+ return {
54
+ action: 'retry_handshake',
55
+ reason: `Non-deterministic conditions (network / external service / still restarting) on hosts: ${affected.join(', ')}. These do not qualify for automatic rollback.`,
56
+ nextAction: 'Retry the release handshake for the affected hosts. The release stays activated-but-unconfirmed until every previously running host passes or a deterministic failure appears.',
57
+ };
58
+ }
59
+ return { action: 'confirm', reason: 'every previously running host completed the release handshake' };
60
+ }
61
+ //# sourceMappingURL=rollback-policy.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"rollback-policy.js","sourceRoot":"","sources":["../../src/update/rollback-policy.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AA0BH,MAAM,qBAAqB,GAAkC,IAAI,GAAG,CAAC,CAAC,6BAA6B,EAAE,oBAAoB,CAAC,CAAC,CAAC;AAE5H,MAAM,UAAU,sBAAsB,CAAC,KAGtC;IACC,MAAM,EAAE,YAAY,EAAE,uBAAuB,EAAE,GAAG,KAAK,CAAC;IACxD,IAAI,YAAY,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QAC9B,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,gCAAgC,EAAE,CAAC;IACzE,CAAC;IAED,MAAM,WAAW,GAAG,YAAY,CAAC,MAAM,CAAC,CAAC,WAAW,EAAE,EAAE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;IACJ,CAAC;IAED,IAAI,qBAAqB,CAAC,MAAM,GAAG,CAAC,IAAI,OAAO,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QAC3D,MAAM,QAAQ,GAAG,CAAC,GAAG,qBAAqB,EAAE,GAAG,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,WAAW,CAAC,MAAM,CAAC,CAAC;QACjG,OAAO;YACL,MAAM,EAAE,iBAAiB;YACzB,MAAM,EAAE,0FAA0F,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,gDAAgD;YACrK,UAAU,EAAE,gLAAgL;SAC7L,CAAC;IACJ,CAAC;IAED,OAAO,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,EAAE,+DAA+D,EAAE,CAAC;AACxG,CAAC"}
@@ -0,0 +1,121 @@
1
+ /**
2
+ * Transaction journal and recovery (SPEC §8, §14.3).
3
+ *
4
+ * An update follows a persisted state machine:
5
+ *
6
+ * planned -> downloaded -> verified -> staged -> probed
7
+ * -> activated -> host_verified -> confirmed
8
+ * -> rolled_back | refused | failed
9
+ *
10
+ * EVERY transition is appended (and fsynced) to the transaction journal
11
+ * BEFORE the side effect it describes. On restart, recovery reconciles any
12
+ * unfinished transaction: the outcome is always old-confirmed, new-confirmed,
13
+ * or an explicit safe refusal — never a hybrid.
14
+ */
15
+ export declare const TRANSACTION_STATES: readonly ['planned', 'downloaded', 'verified', 'staged', 'probed', 'activated', 'host_verified', 'confirmed', 'rolled_back', 'refused', 'failed'];
16
+ export type TransactionState = typeof TRANSACTION_STATES[number];
17
+ export type TransactionKind = 'update' | 'reinstall' | 'explicit_downgrade' | 'rollback' | 'legacy_migration' | 'recovery';
18
+ export interface JournalTransition {
19
+ readonly at: string;
20
+ readonly from: TransactionState | null;
21
+ readonly to: TransactionState;
22
+ readonly transactionId: string;
23
+ readonly releaseId: string;
24
+ readonly productVersion: string;
25
+ readonly releaseMetadataDigest: string;
26
+ readonly generation: number;
27
+ readonly detail?: string;
28
+ }
29
+ export interface ActiveRecord {
30
+ readonly schemaVersion: 1;
31
+ readonly generation: number;
32
+ readonly releaseId: string;
33
+ readonly releaseMetadataDigest: string;
34
+ readonly previousReleaseId: string | null;
35
+ readonly transactionId: string;
36
+ readonly productVersion: string;
37
+ }
38
+ export declare class TransactionJournalError extends Error {
39
+ readonly code: string;
40
+ constructor(code: string, message: string);
41
+ }
42
+ export interface RecoveryAwareJournalRead {
43
+ readonly transitions: readonly JournalTransition[];
44
+ /**
45
+ * True when the final physical journal record was a torn (unparseable,
46
+ * unterminated) write — its transition never durably committed and is
47
+ * EXCLUDED from `transitions`. Physical repair (truncation) belongs to an
48
+ * explicit recovery operation, never to this reader.
49
+ */
50
+ readonly tornTailDetected: boolean;
51
+ }
52
+ /** Reads and strictly validates the whole journal (fail loud on any tear). */
53
+ export declare function readTransactionJournal(journalPath: string): readonly JournalTransition[];
54
+ /**
55
+ * Recovery-aware journal reader (crash contract, SPEC §8).
56
+ *
57
+ * The writer appends `JSON + '\n'` and fsyncs. A crash mid-append can leave a
58
+ * TORN final record: unparseable JSON without a trailing newline. Such a
59
+ * record never durably committed, so recovery drops it. Everything else is
60
+ * strict: a malformed line anywhere else (including a complete-but-invalid
61
+ * final line that DOES end with a newline) fails loud, because a complete
62
+ * write with bad content is corruption, not a torn write.
63
+ */
64
+ export declare function readTransactionJournalForRecovery(journalPath: string): RecoveryAwareJournalRead;
65
+ /**
66
+ * Appends one transition durably (append + fsync) BEFORE the caller performs
67
+ * the side effect the transition describes. Journal-first ordering is what
68
+ * makes crash recovery sound.
69
+ */
70
+ export declare function appendJournalTransition(journalPath: string, transition: JournalTransition): void;
71
+ export interface ActiveRecordWrite {
72
+ readonly generation: number;
73
+ readonly releaseId: string;
74
+ readonly releaseMetadataDigest: string;
75
+ readonly previousReleaseId: string | null;
76
+ readonly transactionId: string;
77
+ readonly productVersion: string;
78
+ }
79
+ /** Serializes + atomically replaces active.json (see atomic-file adapter). */
80
+ export declare function writeActiveRecord(recordPath: string, write: ActiveRecordWrite): void;
81
+ /** Strict active.json reader; returns null when absent. */
82
+ export declare function readActiveRecord(recordPath: string): ActiveRecord | null;
83
+ export type RecoveryOutcome = {
84
+ readonly kind: 'old_confirmed';
85
+ readonly releaseId: string | null;
86
+ readonly generation: number | null;
87
+ readonly reason: string;
88
+ } | {
89
+ readonly kind: 'new_confirmed';
90
+ readonly releaseId: string;
91
+ readonly generation: number;
92
+ readonly reason: string;
93
+ } | {
94
+ readonly kind: 'explicit_refusal';
95
+ readonly reason: string;
96
+ readonly nextAction: string;
97
+ };
98
+ /**
99
+ * Reconciles ONE transaction against the active record after a crash. The
100
+ * invariant: the result is old-confirmed, new-confirmed, or an explicit
101
+ * refusal — never a hybrid release (SPEC §18-4).
102
+ *
103
+ * Rules:
104
+ * - No journal activity for this transaction → nothing to reconcile.
105
+ * - Journal reached `confirmed` → new release stands.
106
+ * - Journal never reached `activated` → old release stands (nothing was
107
+ * swapped); staging residue is cleaned up by the caller.
108
+ * - Journal reached `activated` (or later, unconfirmed) but active.json does
109
+ * not carry this transaction's generation → the crash interrupted the
110
+ * active-record write. The journal-confirmed PREVIOUS generation wins:
111
+ * recovery re-points to it; a hybrid (new code, old pointer) is never
112
+ * activated. If there is no previous pointer to fall back to, refuse
113
+ * explicitly and demand the official installer.
114
+ */
115
+ export declare function recoverUnfinishedTransaction(input: {
116
+ transitions: readonly JournalTransition[];
117
+ activeRecord: ActiveRecord | null;
118
+ previousRecord: ActiveRecord | null;
119
+ transactionId: string;
120
+ }): RecoveryOutcome;
121
+ //# sourceMappingURL=transaction-journal.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"transaction-journal.d.ts","sourceRoot":"","sources":["../../src/update/transaction-journal.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAMH,eAAO,MAAM,kBAAkB,YAC7B,SAAS,EACT,YAAY,EACZ,UAAU,EACV,QAAQ,EACR,QAAQ,EACR,WAAW,EACX,eAAe,E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