@intentius/chant 0.124.26 → 0.124.28

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 (459) hide show
  1. package/README.md +1 -1
  2. package/dist/__golden__/wave-loop/fan-out-gated.json +8 -0
  3. package/dist/__golden__/wave-loop/fan-out-no-members.json +4 -0
  4. package/dist/__golden__/wave-loop/fan-out-only.json +6 -0
  5. package/dist/__golden__/wave-loop/op-by-apply-hold.json +2 -0
  6. package/dist/__golden__/wave-loop/op-cost-member.json +3 -0
  7. package/dist/__golden__/wave-loop/op-held-on-before-apply.json +1 -0
  8. package/dist/__golden__/wave-loop/op-held-on.json +2 -0
  9. package/dist/__golden__/wave-loop/op-hooks-held.json +2 -0
  10. package/dist/__golden__/wave-loop/op-hooks-hold-before-apply.json +2 -0
  11. package/dist/__golden__/wave-loop/op-hooks-refused-at-base.json +3 -0
  12. package/dist/__golden__/wave-loop/op-hooks-share.json +3 -0
  13. package/dist/__golden__/wave-loop/op-per-run.json +7 -0
  14. package/dist/__golden__/wave-loop/op-pr-review.json +7 -0
  15. package/dist/__golden__/wave-loop/op-sealed.json +3 -0
  16. package/dist/__golden__/wave-loop/op-spend.json +3 -0
  17. package/dist/__golden__/wave-loop/op-wave-commands.json +7 -0
  18. package/dist/__golden__/wave-loop/op-wide-waiting.json +4 -0
  19. package/dist/change-set-graph.d.ts +56 -0
  20. package/dist/change-set-graph.d.ts.map +1 -0
  21. package/dist/change-set-graph.js +128 -0
  22. package/dist/change-set.d.ts +52 -3
  23. package/dist/change-set.d.ts.map +1 -1
  24. package/dist/change-set.js +35 -4
  25. package/dist/chant-version.d.ts +9 -0
  26. package/dist/chant-version.d.ts.map +1 -0
  27. package/dist/chant-version.js +16 -0
  28. package/dist/cli/commands/build.d.ts +8 -0
  29. package/dist/cli/commands/build.d.ts.map +1 -1
  30. package/dist/cli/commands/build.js +9 -8
  31. package/dist/cli/commands/check-lexicon-docs.d.ts.map +1 -1
  32. package/dist/cli/commands/check-lexicon-docs.js +30 -2
  33. package/dist/cli/commands/check-lexicon.d.ts.map +1 -1
  34. package/dist/cli/commands/check-lexicon.js +13 -2
  35. package/dist/cli/commands/init-lexicon/templates/docs.d.ts +4 -1
  36. package/dist/cli/commands/init-lexicon/templates/docs.d.ts.map +1 -1
  37. package/dist/cli/commands/init-lexicon/templates/docs.js +6 -6
  38. package/dist/cli/commands/init-lexicon.d.ts.map +1 -1
  39. package/dist/cli/commands/init-lexicon.js +17 -8
  40. package/dist/cli/handlers/approve.d.ts.map +1 -1
  41. package/dist/cli/handlers/approve.js +19 -4
  42. package/dist/cli/handlers/build.d.ts.map +1 -1
  43. package/dist/cli/handlers/build.js +28 -0
  44. package/dist/cli/handlers/change-set.d.ts +10 -0
  45. package/dist/cli/handlers/change-set.d.ts.map +1 -1
  46. package/dist/cli/handlers/change-set.js +51 -1
  47. package/dist/cli/handlers/fan-out.d.ts +1 -1
  48. package/dist/cli/handlers/fan-out.d.ts.map +1 -1
  49. package/dist/cli/handlers/fan-out.js +14 -3
  50. package/dist/cli/handlers/pr.d.ts +8 -2
  51. package/dist/cli/handlers/pr.d.ts.map +1 -1
  52. package/dist/cli/handlers/pr.js +148 -24
  53. package/dist/cli/handlers/promote.d.ts.map +1 -1
  54. package/dist/cli/handlers/promote.js +256 -21
  55. package/dist/cli/handlers/release.d.ts +34 -0
  56. package/dist/cli/handlers/release.d.ts.map +1 -0
  57. package/dist/cli/handlers/release.js +203 -0
  58. package/dist/cli/handlers/run.d.ts +28 -2
  59. package/dist/cli/handlers/run.d.ts.map +1 -1
  60. package/dist/cli/handlers/run.js +170 -13
  61. package/dist/cli/main.d.ts.map +1 -1
  62. package/dist/cli/main.js +88 -13
  63. package/dist/cli/mcp/workspace-tools.js +1 -1
  64. package/dist/cli/parse-args.d.ts.map +1 -1
  65. package/dist/cli/parse-args.js +49 -3
  66. package/dist/cli/registry.d.ts +29 -3
  67. package/dist/cli/registry.d.ts.map +1 -1
  68. package/dist/cli/run-events.d.ts +29 -0
  69. package/dist/cli/run-events.d.ts.map +1 -0
  70. package/dist/cli/run-events.js +47 -0
  71. package/dist/cli/version.d.ts +3 -5
  72. package/dist/cli/version.d.ts.map +1 -1
  73. package/dist/cli/version.js +3 -13
  74. package/dist/codegen/docs-in-site.d.ts +71 -0
  75. package/dist/codegen/docs-in-site.d.ts.map +1 -0
  76. package/dist/codegen/docs-in-site.js +177 -0
  77. package/dist/codegen/docs-types.d.ts +14 -1
  78. package/dist/codegen/docs-types.d.ts.map +1 -1
  79. package/dist/codegen/docs.d.ts +18 -1
  80. package/dist/codegen/docs.d.ts.map +1 -1
  81. package/dist/codegen/docs.js +40 -7
  82. package/dist/codegen/rehype-base-url.mjs +15 -9
  83. package/dist/components/auto-release.d.ts +4 -1
  84. package/dist/components/auto-release.d.ts.map +1 -1
  85. package/dist/components/auto-release.js +2 -0
  86. package/dist/components/cli-support.d.ts +6 -0
  87. package/dist/components/cli-support.d.ts.map +1 -1
  88. package/dist/components/cli-support.js +10 -9
  89. package/dist/components/driver.d.ts +42 -9
  90. package/dist/components/driver.d.ts.map +1 -1
  91. package/dist/components/driver.js +81 -54
  92. package/dist/components/fan-out-run.d.ts +7 -0
  93. package/dist/components/fan-out-run.d.ts.map +1 -1
  94. package/dist/components/fan-out-run.js +35 -26
  95. package/dist/components/pr-run.d.ts +11 -0
  96. package/dist/components/pr-run.d.ts.map +1 -1
  97. package/dist/components/pr-run.js +20 -1
  98. package/dist/components/promote-order.d.ts +38 -0
  99. package/dist/components/promote-order.d.ts.map +1 -0
  100. package/dist/components/promote-order.js +62 -0
  101. package/dist/components/promote.d.ts +15 -2
  102. package/dist/components/promote.d.ts.map +1 -1
  103. package/dist/components/promote.js +17 -0
  104. package/dist/components/release-compile.d.ts +133 -0
  105. package/dist/components/release-compile.d.ts.map +1 -0
  106. package/dist/components/release-compile.js +376 -0
  107. package/dist/components/release-gate.d.ts +125 -0
  108. package/dist/components/release-gate.d.ts.map +1 -0
  109. package/dist/components/release-gate.js +282 -0
  110. package/dist/components/release-promote.d.ts +96 -0
  111. package/dist/components/release-promote.d.ts.map +1 -0
  112. package/dist/components/release-promote.js +204 -0
  113. package/dist/components/run-progress.d.ts +7 -0
  114. package/dist/components/run-progress.d.ts.map +1 -1
  115. package/dist/components/wave-plan.d.ts +3 -1
  116. package/dist/components/wave-plan.d.ts.map +1 -1
  117. package/dist/components/wave-plan.js +1 -1
  118. package/dist/config.d.ts +7 -0
  119. package/dist/config.d.ts.map +1 -1
  120. package/dist/config.js +1 -0
  121. package/dist/index.d.ts +1 -0
  122. package/dist/index.d.ts.map +1 -1
  123. package/dist/index.js +2 -0
  124. package/dist/lifecycle/change-set-store.d.ts +67 -0
  125. package/dist/lifecycle/change-set-store.d.ts.map +1 -0
  126. package/dist/lifecycle/change-set-store.js +96 -0
  127. package/dist/lifecycle/commit-sha.d.ts +13 -0
  128. package/dist/lifecycle/commit-sha.d.ts.map +1 -0
  129. package/dist/lifecycle/commit-sha.js +21 -0
  130. package/dist/lifecycle/gate-change-set.d.ts +69 -0
  131. package/dist/lifecycle/gate-change-set.d.ts.map +1 -0
  132. package/dist/lifecycle/gate-change-set.js +106 -0
  133. package/dist/lifecycle/gate-ledger.d.ts +49 -1
  134. package/dist/lifecycle/gate-ledger.d.ts.map +1 -1
  135. package/dist/lifecycle/gate-ledger.js +18 -0
  136. package/dist/lifecycle/release-cut.d.ts +107 -0
  137. package/dist/lifecycle/release-cut.d.ts.map +1 -0
  138. package/dist/lifecycle/release-cut.js +273 -0
  139. package/dist/lifecycle/release-ledger.d.ts +54 -0
  140. package/dist/lifecycle/release-ledger.d.ts.map +1 -1
  141. package/dist/lifecycle/release-ledger.js +53 -20
  142. package/dist/lifecycle/release-store.d.ts +190 -0
  143. package/dist/lifecycle/release-store.d.ts.map +1 -0
  144. package/dist/lifecycle/release-store.js +318 -0
  145. package/dist/lifecycle/run-ledger.d.ts +4 -0
  146. package/dist/lifecycle/run-ledger.d.ts.map +1 -1
  147. package/dist/lifecycle/run-ledger.js +2 -0
  148. package/dist/op/activities/change-coverage.d.ts.map +1 -1
  149. package/dist/op/activities/change-coverage.js +4 -2
  150. package/dist/op/activities/source-release.d.ts.map +1 -1
  151. package/dist/op/activities/source-release.js +7 -3
  152. package/dist/op/activities/source-rollback.d.ts.map +1 -1
  153. package/dist/op/activities/source-rollback.js +7 -3
  154. package/dist/op/activity-registry.d.ts +6 -3
  155. package/dist/op/activity-registry.d.ts.map +1 -1
  156. package/dist/op/activity-registry.js +7 -5
  157. package/dist/op/discover.d.ts.map +1 -1
  158. package/dist/op/discover.js +14 -7
  159. package/dist/op/gate-name.d.ts +11 -2
  160. package/dist/op/gate-name.d.ts.map +1 -1
  161. package/dist/op/gate-name.js +12 -3
  162. package/dist/op/gate-run-locator.d.ts +22 -0
  163. package/dist/op/gate-run-locator.d.ts.map +1 -1
  164. package/dist/op/gate-run-locator.js +31 -0
  165. package/dist/op/gate.d.ts +27 -3
  166. package/dist/op/gate.d.ts.map +1 -1
  167. package/dist/op/gate.js +57 -3
  168. package/dist/op/local-executor.d.ts +36 -1
  169. package/dist/op/local-executor.d.ts.map +1 -1
  170. package/dist/op/local-executor.js +158 -52
  171. package/dist/op/op-waves-run.d.ts.map +1 -1
  172. package/dist/op/op-waves-run.js +4 -0
  173. package/dist/op/run-live.d.ts +2 -0
  174. package/dist/op/run-live.d.ts.map +1 -1
  175. package/dist/op/run-live.js +1 -1
  176. package/dist/op/runtime.d.ts +46 -0
  177. package/dist/op/runtime.d.ts.map +1 -1
  178. package/dist/op/runtimes/local.d.ts.map +1 -1
  179. package/dist/op/runtimes/local.js +12 -2
  180. package/dist/point-decision.d.ts +2 -0
  181. package/dist/point-decision.d.ts.map +1 -1
  182. package/dist/point-decision.js +9 -2
  183. package/dist/run-event-store.d.ts +77 -0
  184. package/dist/run-event-store.d.ts.map +1 -0
  185. package/dist/run-event-store.js +204 -0
  186. package/dist/run-event-stream.d.ts +132 -0
  187. package/dist/run-event-stream.d.ts.map +1 -0
  188. package/dist/run-event-stream.js +238 -0
  189. package/dist/run-event.d.ts +267 -0
  190. package/dist/run-event.d.ts.map +1 -0
  191. package/dist/run-event.js +207 -0
  192. package/dist/wave-runtime.mjs +225 -242
  193. package/dist/workspace/__fixtures__/run-event-check.d.ts +19 -0
  194. package/dist/workspace/__fixtures__/run-event-check.d.ts.map +1 -0
  195. package/dist/workspace/__fixtures__/run-event-check.js +59 -0
  196. package/dist/workspace/change-set-show.d.ts +56 -0
  197. package/dist/workspace/change-set-show.d.ts.map +1 -0
  198. package/dist/workspace/change-set-show.js +54 -0
  199. package/dist/workspace/change-set-show.schema.json +102 -0
  200. package/dist/workspace/change-set.schema.json +28 -1
  201. package/dist/workspace/changes-cli.d.ts.map +1 -1
  202. package/dist/workspace/changes-cli.js +10 -1
  203. package/dist/workspace/changes.d.ts +37 -0
  204. package/dist/workspace/changes.d.ts.map +1 -1
  205. package/dist/workspace/changes.js +49 -2
  206. package/dist/workspace/changes.schema.json +135 -0
  207. package/dist/workspace/ci-green-cli.d.ts +19 -4
  208. package/dist/workspace/ci-green-cli.d.ts.map +1 -1
  209. package/dist/workspace/ci-green-cli.js +75 -12
  210. package/dist/workspace/ci-green-forge.d.ts +20 -3
  211. package/dist/workspace/ci-green-forge.d.ts.map +1 -1
  212. package/dist/workspace/ci-green-forge.js +6 -4
  213. package/dist/workspace/ci-green-workflow.d.ts +11 -0
  214. package/dist/workspace/ci-green-workflow.d.ts.map +1 -1
  215. package/dist/workspace/ci-green-workflow.js +6 -0
  216. package/dist/workspace/ci-green.d.ts +273 -13
  217. package/dist/workspace/ci-green.d.ts.map +1 -1
  218. package/dist/workspace/ci-green.js +449 -38
  219. package/dist/workspace/ci-last-green.schema.json +32 -2
  220. package/dist/workspace/ci-list.schema.json +525 -0
  221. package/dist/workspace/commit-links.d.ts +85 -0
  222. package/dist/workspace/commit-links.d.ts.map +1 -0
  223. package/dist/workspace/commit-links.js +163 -0
  224. package/dist/workspace/declaration.d.ts +19 -0
  225. package/dist/workspace/declaration.d.ts.map +1 -1
  226. package/dist/workspace/declaration.js +1 -1
  227. package/dist/workspace/declaration.schema.json +12 -0
  228. package/dist/workspace/identity-gate-rule.d.ts +37 -0
  229. package/dist/workspace/identity-gate-rule.d.ts.map +1 -1
  230. package/dist/workspace/identity-gate-rule.js +72 -7
  231. package/dist/workspace/identity.d.ts +12 -0
  232. package/dist/workspace/identity.d.ts.map +1 -1
  233. package/dist/workspace/identity.js +13 -1
  234. package/dist/workspace/intent.d.ts +6 -1
  235. package/dist/workspace/intent.d.ts.map +1 -1
  236. package/dist/workspace/intent.js +51 -1
  237. package/dist/workspace/ls.d.ts +4 -0
  238. package/dist/workspace/ls.d.ts.map +1 -1
  239. package/dist/workspace/ls.js +2 -0
  240. package/dist/workspace/ls.schema.json +3 -1
  241. package/dist/workspace/member-pipeline.d.ts +6 -0
  242. package/dist/workspace/member-pipeline.d.ts.map +1 -1
  243. package/dist/workspace/member-pipeline.js +6 -0
  244. package/dist/workspace/promotion-order.d.ts +41 -0
  245. package/dist/workspace/promotion-order.d.ts.map +1 -0
  246. package/dist/workspace/promotion-order.js +95 -0
  247. package/dist/workspace/reason-codes.d.ts +2 -0
  248. package/dist/workspace/reason-codes.d.ts.map +1 -1
  249. package/dist/workspace/reason-codes.js +4 -1
  250. package/dist/workspace/releases.d.ts +72 -0
  251. package/dist/workspace/releases.d.ts.map +1 -0
  252. package/dist/workspace/releases.js +94 -0
  253. package/dist/workspace/releases.schema.json +391 -0
  254. package/dist/workspace/run-event.schema.json +288 -0
  255. package/dist/workspace/status-gates.d.ts +26 -1
  256. package/dist/workspace/status-gates.d.ts.map +1 -1
  257. package/dist/workspace/status-gates.js +31 -2
  258. package/dist/workspace/status-stewards.d.ts +4 -0
  259. package/dist/workspace/status-stewards.d.ts.map +1 -1
  260. package/dist/workspace/status-stewards.js +2 -0
  261. package/dist/workspace/status.d.ts +39 -0
  262. package/dist/workspace/status.d.ts.map +1 -1
  263. package/dist/workspace/status.js +48 -1
  264. package/dist/workspace/status.schema.json +70 -1
  265. package/dist/workspace/trust/ci-tag-statement.d.ts +102 -0
  266. package/dist/workspace/trust/ci-tag-statement.d.ts.map +1 -0
  267. package/dist/workspace/trust/ci-tag-statement.js +123 -0
  268. package/dist/workspace/trust/op-run-statement.d.ts +91 -0
  269. package/dist/workspace/trust/op-run-statement.d.ts.map +1 -0
  270. package/dist/workspace/trust/op-run-statement.js +143 -0
  271. package/dist/workspace/trust/rotation.d.ts +18 -2
  272. package/dist/workspace/trust/rotation.d.ts.map +1 -1
  273. package/dist/workspace/trust/rotation.js +65 -16
  274. package/dist/workspace/trust/seal.d.ts +11 -0
  275. package/dist/workspace/trust/seal.d.ts.map +1 -1
  276. package/dist/workspace/trust/seal.js +9 -0
  277. package/dist/workspace/trust/ssh-commit.d.ts.map +1 -1
  278. package/dist/workspace/trust/ssh-commit.js +10 -10
  279. package/package.json +1 -1
  280. package/src/__golden__/wave-loop/fan-out-gated.json +8 -0
  281. package/src/__golden__/wave-loop/fan-out-no-members.json +4 -0
  282. package/src/__golden__/wave-loop/fan-out-only.json +6 -0
  283. package/src/__golden__/wave-loop/op-by-apply-hold.json +2 -0
  284. package/src/__golden__/wave-loop/op-cost-member.json +3 -0
  285. package/src/__golden__/wave-loop/op-held-on-before-apply.json +1 -0
  286. package/src/__golden__/wave-loop/op-held-on.json +2 -0
  287. package/src/__golden__/wave-loop/op-hooks-held.json +2 -0
  288. package/src/__golden__/wave-loop/op-hooks-hold-before-apply.json +2 -0
  289. package/src/__golden__/wave-loop/op-hooks-refused-at-base.json +3 -0
  290. package/src/__golden__/wave-loop/op-hooks-share.json +3 -0
  291. package/src/__golden__/wave-loop/op-per-run.json +7 -0
  292. package/src/__golden__/wave-loop/op-pr-review.json +7 -0
  293. package/src/__golden__/wave-loop/op-sealed.json +3 -0
  294. package/src/__golden__/wave-loop/op-spend.json +3 -0
  295. package/src/__golden__/wave-loop/op-wave-commands.json +7 -0
  296. package/src/__golden__/wave-loop/op-wide-waiting.json +4 -0
  297. package/src/change-set-graph.test.ts +72 -0
  298. package/src/change-set-graph.ts +133 -0
  299. package/src/change-set.ts +76 -6
  300. package/src/chant-version.ts +16 -0
  301. package/src/cli/commands/build.ts +19 -8
  302. package/src/cli/commands/check-lexicon-docs.test.ts +51 -0
  303. package/src/cli/commands/check-lexicon-docs.ts +39 -2
  304. package/src/cli/commands/check-lexicon.ts +14 -2
  305. package/src/cli/commands/init-lexicon/templates/docs.ts +7 -6
  306. package/src/cli/commands/init-lexicon.test.ts +25 -0
  307. package/src/cli/commands/init-lexicon.ts +18 -8
  308. package/src/cli/compiled-cli.e2e.test.ts +31 -6
  309. package/src/cli/handlers/approve-release.test.ts +80 -0
  310. package/src/cli/handlers/approve.ts +18 -2
  311. package/src/cli/handlers/build.test.ts +52 -0
  312. package/src/cli/handlers/build.ts +29 -0
  313. package/src/cli/handlers/change-set.ts +49 -1
  314. package/src/cli/handlers/fan-out.test.ts +48 -0
  315. package/src/cli/handlers/fan-out.ts +15 -3
  316. package/src/cli/handlers/operator.test.ts +37 -0
  317. package/src/cli/handlers/pr.test.ts +194 -0
  318. package/src/cli/handlers/pr.ts +168 -34
  319. package/src/cli/handlers/promote.test.ts +389 -5
  320. package/src/cli/handlers/promote.ts +279 -20
  321. package/src/cli/handlers/release-implicit.e2e.test.ts +153 -0
  322. package/src/cli/handlers/release.e2e.test.ts +85 -0
  323. package/src/cli/handlers/release.ts +206 -0
  324. package/src/cli/handlers/run-auto-release.test.ts +71 -0
  325. package/src/cli/handlers/run-events-cmd.test.ts +92 -0
  326. package/src/cli/handlers/run.test.ts +30 -0
  327. package/src/cli/handlers/run.ts +176 -15
  328. package/src/cli/main.test.ts +7 -0
  329. package/src/cli/main.ts +88 -13
  330. package/src/cli/mcp/never-over-mcp.test.ts +2 -0
  331. package/src/cli/mcp/workspace-tools.ts +1 -1
  332. package/src/cli/parse-args.ts +37 -3
  333. package/src/cli/registry.ts +29 -3
  334. package/src/cli/run-events.ts +54 -0
  335. package/src/cli/version.ts +3 -13
  336. package/src/codegen/docs-in-site.test.ts +166 -0
  337. package/src/codegen/docs-in-site.ts +182 -0
  338. package/src/codegen/docs-site/AgentPrompt.astro +26 -1
  339. package/src/codegen/docs-types.ts +14 -1
  340. package/src/codegen/docs.ts +60 -7
  341. package/src/codegen/rehype-base-url.d.mts +3 -1
  342. package/src/codegen/rehype-base-url.mjs +15 -9
  343. package/src/codegen/rehype-base-url.test.ts +34 -0
  344. package/src/components/auto-release.test.ts +21 -0
  345. package/src/components/auto-release.ts +6 -1
  346. package/src/components/cli-support.test.ts +82 -0
  347. package/src/components/cli-support.ts +16 -9
  348. package/src/components/driver.ts +129 -56
  349. package/src/components/fan-out-run.ts +56 -35
  350. package/src/components/pr-run.ts +30 -1
  351. package/src/components/promote-order.test.ts +90 -0
  352. package/src/components/promote-order.ts +75 -0
  353. package/src/components/promote.test.ts +10 -1
  354. package/src/components/promote.ts +26 -1
  355. package/src/components/release-compile.test.ts +147 -0
  356. package/src/components/release-compile.ts +445 -0
  357. package/src/components/release-gate.test.ts +215 -0
  358. package/src/components/release-gate.ts +341 -0
  359. package/src/components/release-promote.test.ts +159 -0
  360. package/src/components/release-promote.ts +232 -0
  361. package/src/components/run-progress.ts +7 -0
  362. package/src/components/wave-plan.ts +1 -1
  363. package/src/config.ts +7 -1
  364. package/src/index.ts +2 -0
  365. package/src/lifecycle/change-set-store.test.ts +217 -0
  366. package/src/lifecycle/change-set-store.ts +112 -0
  367. package/src/lifecycle/commit-sha.ts +23 -0
  368. package/src/lifecycle/gate-change-set.e2e.test.ts +122 -0
  369. package/src/lifecycle/gate-change-set.ts +133 -0
  370. package/src/lifecycle/gate-ledger.test.ts +33 -0
  371. package/src/lifecycle/gate-ledger.ts +66 -1
  372. package/src/lifecycle/release-cut-signed.test.ts +180 -0
  373. package/src/lifecycle/release-cut.test.ts +411 -0
  374. package/src/lifecycle/release-cut.ts +367 -0
  375. package/src/lifecycle/release-ledger.test.ts +14 -0
  376. package/src/lifecycle/release-ledger.ts +85 -17
  377. package/src/lifecycle/release-store.ts +423 -0
  378. package/src/lifecycle/run-ledger.test.ts +10 -0
  379. package/src/lifecycle/run-ledger.ts +6 -0
  380. package/src/op/activities/change-coverage.ts +4 -1
  381. package/src/op/activities/source-release.ts +8 -3
  382. package/src/op/activities/source-rollback.ts +8 -4
  383. package/src/op/activity-registry.ts +7 -5
  384. package/src/op/commit-run-gate-deploy-join.test.ts +117 -0
  385. package/src/op/discover-root.test.ts +39 -0
  386. package/src/op/discover.ts +15 -8
  387. package/src/op/gate-name.ts +13 -3
  388. package/src/op/gate-release.test.ts +126 -0
  389. package/src/op/gate-run-locator.test.ts +110 -0
  390. package/src/op/gate-run-locator.ts +35 -0
  391. package/src/op/gate.ts +88 -6
  392. package/src/op/local-executor.ts +207 -52
  393. package/src/op/op-waves-run.ts +4 -0
  394. package/src/op/run-events.test.ts +166 -0
  395. package/src/op/run-live.ts +1 -1
  396. package/src/op/runtime.ts +39 -0
  397. package/src/op/runtimes/local.test.ts +16 -0
  398. package/src/op/runtimes/local.ts +13 -2
  399. package/src/point-decision.ts +12 -2
  400. package/src/run-event-store.test.ts +144 -0
  401. package/src/run-event-store.ts +213 -0
  402. package/src/run-event-stream.test.ts +175 -0
  403. package/src/run-event-stream.ts +306 -0
  404. package/src/run-event.test.ts +277 -0
  405. package/src/run-event.ts +451 -0
  406. package/src/wave-loop-golden.test.ts +9 -0
  407. package/src/workspace/__fixtures__/run-event-check.ts +58 -0
  408. package/src/workspace/ancestry-index.test.ts +93 -0
  409. package/src/workspace/change-set-show.schema.json +102 -0
  410. package/src/workspace/change-set-show.ts +72 -0
  411. package/src/workspace/change-set.schema.json +28 -1
  412. package/src/workspace/changes-cli.ts +10 -1
  413. package/src/workspace/changes.schema.json +135 -0
  414. package/src/workspace/changes.test.ts +1 -1
  415. package/src/workspace/changes.ts +84 -2
  416. package/src/workspace/ci-green-cli.ts +75 -13
  417. package/src/workspace/ci-green-forge.ts +24 -4
  418. package/src/workspace/ci-green-runs.test.ts +242 -0
  419. package/src/workspace/ci-green-signed.test.ts +302 -0
  420. package/src/workspace/ci-green-workflow.test.ts +16 -0
  421. package/src/workspace/ci-green-workflow.ts +12 -0
  422. package/src/workspace/ci-green.test.ts +131 -2
  423. package/src/workspace/ci-green.ts +624 -42
  424. package/src/workspace/ci-last-green.schema.json +32 -2
  425. package/src/workspace/ci-list.schema.json +525 -0
  426. package/src/workspace/commit-links.test.ts +279 -0
  427. package/src/workspace/commit-links.ts +183 -0
  428. package/src/workspace/declaration.schema.json +12 -0
  429. package/src/workspace/declaration.ts +22 -2
  430. package/src/workspace/identity-gate-rule.ts +91 -7
  431. package/src/workspace/identity.ts +14 -1
  432. package/src/workspace/intent.ts +48 -1
  433. package/src/workspace/ls.schema.json +3 -1
  434. package/src/workspace/ls.ts +6 -0
  435. package/src/workspace/member-pipeline.test.ts +17 -0
  436. package/src/workspace/member-pipeline.ts +9 -0
  437. package/src/workspace/promotion-order.ts +97 -0
  438. package/src/workspace/read-contract.e2e.test.ts +4 -1
  439. package/src/workspace/reason-codes.test.ts +2 -1
  440. package/src/workspace/reason-codes.ts +4 -1
  441. package/src/workspace/releases.schema.json +391 -0
  442. package/src/workspace/releases.test.ts +108 -0
  443. package/src/workspace/releases.ts +122 -0
  444. package/src/workspace/run-event.schema.json +288 -0
  445. package/src/workspace/status-contract.test.ts +52 -1
  446. package/src/workspace/status-gates.ts +56 -1
  447. package/src/workspace/status-stewards.ts +6 -0
  448. package/src/workspace/status.schema.json +70 -1
  449. package/src/workspace/status.ts +80 -1
  450. package/src/workspace/trust/ci-tag-statement.ts +151 -0
  451. package/src/workspace/trust/op-run-statement.ts +148 -0
  452. package/src/workspace/trust/rotation.ts +61 -14
  453. package/src/workspace/trust/seal.ts +10 -0
  454. package/src/workspace/trust/ssh-commit.ts +10 -9
  455. package/src/cli/commands/__fixtures__/init-lexicon-output/docs/astro.config.mjs +0 -14
  456. package/src/cli/commands/__fixtures__/init-lexicon-output/docs/package.json +0 -16
  457. package/src/cli/commands/__fixtures__/init-lexicon-output/docs/src/content/docs/index.mdx +0 -8
  458. package/src/cli/commands/__fixtures__/init-lexicon-output/docs/src/content.config.ts +0 -15
  459. package/src/cli/commands/__fixtures__/init-lexicon-output/docs/tsconfig.json +0 -10
@@ -64,10 +64,10 @@
64
64
  },
65
65
  "ref": {
66
66
  "type": "string",
67
- "description": "The ref whose first-parent commits were walked: refs/remotes/origin/<branch> when the checkout has it, else refs/heads/<branch>."
67
+ "description": "The ref whose first-parent commits were walked: refs/remotes/origin/<branch> when the checkout has it, else refs/heads/<branch>, or the revision --from names (#4031)."
68
68
  },
69
69
  "commit": {
70
- "description": "The newest green commit that is not revoked, or null when there is none.",
70
+ "description": "The newest green commit that is not revoked, or null when there is none. Only tags that count are read: with ci.green.signedSince set, a tag on a commit that is not a strict first-parent ancestor of it counts only with a valid statement signed by a runner key (#4031).",
71
71
  "oneOf": [
72
72
  {
73
73
  "type": "null"
@@ -103,6 +103,36 @@
103
103
  }
104
104
  }
105
105
  ]
106
+ },
107
+ "ignored": {
108
+ "type": "array",
109
+ "description": "Added within contract version 1 by #4031, written by chant 0.124.28 and newer. The tags on the commits walked, newest first and down to the one found, that do not count for want of a valid statement. Empty when ci.green.signedSince is not set.",
110
+ "items": {
111
+ "type": "object",
112
+ "required": [
113
+ "tag",
114
+ "status",
115
+ "reason"
116
+ ],
117
+ "properties": {
118
+ "tag": {
119
+ "type": "string",
120
+ "description": "ci/green/<sha> or ci/revoked/<sha>."
121
+ },
122
+ "status": {
123
+ "enum": [
124
+ "unsigned",
125
+ "invalid",
126
+ "untrusted",
127
+ "mismatch"
128
+ ],
129
+ "description": "unsigned: the annotation carries no statement. invalid: the statement is not a ci-tag statement, or names another signer than the key's. untrusted: no runner key .chant/trust.json lists at base signed it, or its principal holds no runner role. mismatch: it signs another commit, tag kind or branch, the annotation's record is not the one signed, or the tag points at another commit than its name gives."
130
+ },
131
+ "reason": {
132
+ "type": "string"
133
+ }
134
+ }
135
+ }
106
136
  }
107
137
  }
108
138
  },
@@ -0,0 +1,525 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://intentius.io/chant/schemas/workspace/ci-list/v1/ci-list.schema.json",
4
+ "title": "chant ci list output",
5
+ "description": "What `chant ci list --json` prints (#4021, ws-103): the first-parent commits of the branch ci.green names, newest first, within ci.green.window or after --since, each with its state from the ci/green/<sha> and ci/revoked/<sha> tags and the result of each required phase. It reads local refs and tags and never fetches; with --forge it also reads check runs for the commits that have no ci tag. With the source chant runs (ci.green.source or --source runs, #4044) it reads the signed Op runs on the local chant/lifecycle for those commits instead, and refuses --forge. Version 1 of the read contract. Readers ignore fields they do not know; a field is only ever added within a version, so a later release may add more fields to each commit. `work` says whether the commit names its work item; it was added by #4029. The codes are a closed list, each in the one closed list of `reason-codes.ts`. Contract version 1 of this document is written by chant 0.124.28 and newer; the read contract as a whole by chant 0.81.0 and newer.",
6
+ "oneOf": [
7
+ {
8
+ "$ref": "#/$defs/result"
9
+ },
10
+ {
11
+ "$ref": "#/$defs/failure"
12
+ }
13
+ ],
14
+ "$defs": {
15
+ "result": {
16
+ "type": "object",
17
+ "description": "Exit code 0, with or without commits.",
18
+ "required": [
19
+ "$schema",
20
+ "contract",
21
+ "chant",
22
+ "workspace",
23
+ "branch",
24
+ "ref",
25
+ "window",
26
+ "since",
27
+ "require",
28
+ "commits"
29
+ ],
30
+ "properties": {
31
+ "$schema": {
32
+ "const": "https://intentius.io/chant/schemas/workspace/ci-list/v1/ci-list.schema.json"
33
+ },
34
+ "contract": {
35
+ "const": 1
36
+ },
37
+ "chant": {
38
+ "type": "string"
39
+ },
40
+ "error": false,
41
+ "workspace": {
42
+ "type": "object",
43
+ "required": [
44
+ "name",
45
+ "root",
46
+ "file"
47
+ ],
48
+ "properties": {
49
+ "name": {
50
+ "type": "string"
51
+ },
52
+ "root": {
53
+ "type": "string",
54
+ "description": "The workspace root relative to the git root, with / separators, \".\" for the git root itself."
55
+ },
56
+ "file": {
57
+ "enum": [
58
+ "chant.workspace.json",
59
+ "chant.workspace.jsonc"
60
+ ]
61
+ }
62
+ }
63
+ },
64
+ "branch": {
65
+ "type": "string",
66
+ "description": "ci.green.branch."
67
+ },
68
+ "ref": {
69
+ "type": "string",
70
+ "description": "The ref whose first-parent commits were walked: refs/remotes/origin/<branch> when the checkout has it, else refs/heads/<branch>."
71
+ },
72
+ "window": {
73
+ "type": [
74
+ "string",
75
+ "null"
76
+ ],
77
+ "description": "ci.green.window, or null when --since replaced it."
78
+ },
79
+ "since": {
80
+ "type": [
81
+ "string",
82
+ "null"
83
+ ],
84
+ "description": "The revision --since named; the commits listed come after it. Null when it was not given."
85
+ },
86
+ "require": {
87
+ "type": "array",
88
+ "items": {
89
+ "type": "string"
90
+ },
91
+ "description": "ci.green.require: the phases a commit must pass, in order. Each commit's phases list them in the same order."
92
+ },
93
+ "commits": {
94
+ "type": "array",
95
+ "description": "Newest first.",
96
+ "items": {
97
+ "type": "object",
98
+ "required": [
99
+ "sha",
100
+ "committed",
101
+ "state",
102
+ "green",
103
+ "revoked",
104
+ "phases"
105
+ ],
106
+ "properties": {
107
+ "sha": {
108
+ "type": "string",
109
+ "pattern": "^[0-9a-f]{40,64}$"
110
+ },
111
+ "committed": {
112
+ "type": "string",
113
+ "description": "The commit's committer time, ISO 8601, UTC."
114
+ },
115
+ "state": {
116
+ "enum": [
117
+ "green",
118
+ "revoked",
119
+ "undecided"
120
+ ],
121
+ "description": "revoked when the commit has a revoked tag, else green when it has a green tag, else undecided."
122
+ },
123
+ "green": {
124
+ "description": "The commit's green tag, or null.",
125
+ "oneOf": [
126
+ {
127
+ "type": "null"
128
+ },
129
+ {
130
+ "type": "object",
131
+ "required": [
132
+ "tag",
133
+ "tagged"
134
+ ],
135
+ "properties": {
136
+ "tag": {
137
+ "type": "string",
138
+ "description": "ci/green/<sha>."
139
+ },
140
+ "tagged": {
141
+ "type": [
142
+ "string",
143
+ "null"
144
+ ],
145
+ "description": "When the tag was made, ISO 8601, or null for a lightweight tag."
146
+ },
147
+ "signer": {
148
+ "type": [
149
+ "string",
150
+ "null"
151
+ ],
152
+ "description": "Added within contract version 1 by #4031, written by chant 0.124.28 and newer. The runner principal whose statement the tag carries, or null when it counts unsigned: ci.green.signedSince is not set, or the commit is a strict first-parent ancestor of it."
153
+ }
154
+ }
155
+ }
156
+ ]
157
+ },
158
+ "revoked": {
159
+ "description": "The commit's revoked tag, or null.",
160
+ "oneOf": [
161
+ {
162
+ "type": "null"
163
+ },
164
+ {
165
+ "type": "object",
166
+ "required": [
167
+ "tag",
168
+ "tagged",
169
+ "phase",
170
+ "run"
171
+ ],
172
+ "properties": {
173
+ "tag": {
174
+ "type": "string",
175
+ "description": "ci/revoked/<sha>."
176
+ },
177
+ "tagged": {
178
+ "type": [
179
+ "string",
180
+ "null"
181
+ ],
182
+ "description": "When the tag was made, ISO 8601, or null for a lightweight tag."
183
+ },
184
+ "phase": {
185
+ "type": [
186
+ "string",
187
+ "null"
188
+ ],
189
+ "description": "The phase the annotation names as failed, or null when the annotation can't be read."
190
+ },
191
+ "run": {
192
+ "oneOf": [
193
+ {
194
+ "type": "null"
195
+ },
196
+ {
197
+ "type": "object",
198
+ "required": [
199
+ "name",
200
+ "id",
201
+ "conclusion",
202
+ "url"
203
+ ],
204
+ "properties": {
205
+ "name": {
206
+ "type": "string"
207
+ },
208
+ "id": {
209
+ "type": [
210
+ "integer",
211
+ "null"
212
+ ]
213
+ },
214
+ "conclusion": {
215
+ "type": [
216
+ "string",
217
+ "null"
218
+ ]
219
+ },
220
+ "url": {
221
+ "type": [
222
+ "string",
223
+ "null"
224
+ ]
225
+ },
226
+ "opRun": {
227
+ "type": "object",
228
+ "required": [
229
+ "id",
230
+ "env",
231
+ "signer"
232
+ ],
233
+ "properties": {
234
+ "id": {
235
+ "type": "string",
236
+ "description": "The Op run's id."
237
+ },
238
+ "env": {
239
+ "type": "string",
240
+ "description": "The env the run is recorded under."
241
+ },
242
+ "signer": {
243
+ "type": "string",
244
+ "description": "The runner principal whose statement the run carries."
245
+ }
246
+ },
247
+ "description": "Added within contract version 1 by #4044, written by chant 0.124.28 and newer. Present only when the run is a chant Op run (ci.green.source runs): name is then the Op's name and id is null. Absent for a check run."
248
+ }
249
+ }
250
+ }
251
+ ],
252
+ "description": "The run the annotation names as failed."
253
+ },
254
+ "signer": {
255
+ "type": [
256
+ "string",
257
+ "null"
258
+ ],
259
+ "description": "Added within contract version 1 by #4031, written by chant 0.124.28 and newer. The runner principal whose statement the tag carries, or null when it counts unsigned: ci.green.signedSince is not set, or the commit is a strict first-parent ancestor of it."
260
+ }
261
+ }
262
+ }
263
+ ]
264
+ },
265
+ "phases": {
266
+ "type": "array",
267
+ "description": "Each required phase, in `require` order.",
268
+ "items": {
269
+ "type": "object",
270
+ "required": [
271
+ "phase",
272
+ "result",
273
+ "runs"
274
+ ],
275
+ "properties": {
276
+ "phase": {
277
+ "type": "string"
278
+ },
279
+ "result": {
280
+ "enum": [
281
+ "pass",
282
+ "fail",
283
+ "pending",
284
+ "unrecorded"
285
+ ],
286
+ "description": "pass and fail come from the tags (a green tag records the phases that passed, a revoked tag the one that failed) or, for an undecided commit, from the forge under --forge, or from the signed Op runs on the local chant/lifecycle when the source is chant runs (#4044). pending is such a read with runs still going or not yet reported. unrecorded means no tag holds the result and nothing was read."
287
+ },
288
+ "runs": {
289
+ "type": "array",
290
+ "items": {
291
+ "type": "object",
292
+ "required": [
293
+ "name",
294
+ "id",
295
+ "conclusion",
296
+ "url"
297
+ ],
298
+ "properties": {
299
+ "name": {
300
+ "type": "string"
301
+ },
302
+ "id": {
303
+ "type": [
304
+ "integer",
305
+ "null"
306
+ ]
307
+ },
308
+ "conclusion": {
309
+ "type": [
310
+ "string",
311
+ "null"
312
+ ]
313
+ },
314
+ "url": {
315
+ "type": [
316
+ "string",
317
+ "null"
318
+ ]
319
+ },
320
+ "opRun": {
321
+ "type": "object",
322
+ "required": [
323
+ "id",
324
+ "env",
325
+ "signer"
326
+ ],
327
+ "properties": {
328
+ "id": {
329
+ "type": "string",
330
+ "description": "The Op run's id."
331
+ },
332
+ "env": {
333
+ "type": "string",
334
+ "description": "The env the run is recorded under."
335
+ },
336
+ "signer": {
337
+ "type": "string",
338
+ "description": "The runner principal whose statement the run carries."
339
+ }
340
+ },
341
+ "description": "Added within contract version 1 by #4044, written by chant 0.124.28 and newer. Present only when the run is a chant Op run (ci.green.source runs): name is then the Op's name and id is null. Absent for a check run."
342
+ }
343
+ }
344
+ },
345
+ "description": "The check runs behind the result: those the green tag recorded, the failed run a revoked tag names, or those the forge returned. Empty when unrecorded."
346
+ }
347
+ }
348
+ }
349
+ },
350
+ "work": {
351
+ "description": "Whether the commit names the work item it belongs to (#4029), by the definition `workspace check --changes` uses: a Chant-Record trailer of a work kind the declaration names whose record exists, or a Chant-Lease trailer that resolves to a work item. The records are read at `ref`. A window match does not count. Null when the checkout is not in a workspace that declares a work kind, or the kinds can't be read. Added within contract version 1, and written by chant 0.124.28 and newer; a reader that finds no `work` is reading an older chant, and one that finds null has been told nothing. A commit that is unlinked or wrong is why its work item is unknown.",
352
+ "oneOf": [
353
+ {
354
+ "type": "null"
355
+ },
356
+ {
357
+ "type": "object",
358
+ "required": [
359
+ "state",
360
+ "ids",
361
+ "problems"
362
+ ],
363
+ "properties": {
364
+ "state": {
365
+ "enum": [
366
+ "linked",
367
+ "unlinked",
368
+ "wrong",
369
+ "merge"
370
+ ],
371
+ "description": "linked: a trailer names a work record that exists, or a lease that resolves to one (a lease is taken as linked when this checkout has no chant/lifecycle branch to read). unlinked: no Chant-Record or Chant-Lease trailer names anything. wrong: trailers name a work item but none of them is one that exists. merge: a merge commit, whose work is the commits it brings."
372
+ },
373
+ "ids": {
374
+ "type": "array",
375
+ "items": {
376
+ "type": "string"
377
+ },
378
+ "description": "The work records the trailers name, as <kind>:<id>. Empty unless state is linked."
379
+ },
380
+ "problems": {
381
+ "type": "array",
382
+ "description": "The trailers that do not link the commit. Empty unless state is wrong.",
383
+ "items": {
384
+ "type": "object",
385
+ "required": [
386
+ "trailer",
387
+ "message"
388
+ ],
389
+ "properties": {
390
+ "trailer": {
391
+ "type": "string"
392
+ },
393
+ "message": {
394
+ "type": "string"
395
+ }
396
+ }
397
+ }
398
+ }
399
+ }
400
+ }
401
+ ]
402
+ },
403
+ "ignored": {
404
+ "type": "array",
405
+ "description": "Added within contract version 1 by #4031, written by chant 0.124.28 and newer. The commit's ci tags that do not count for want of a valid statement signed by a runner key. A tag on any commit that is not a strict first-parent ancestor of ci.green.signedSince needs one; empty when signedSince is not set. state, green and revoked count only the tags that are not ignored.",
406
+ "items": {
407
+ "type": "object",
408
+ "required": [
409
+ "tag",
410
+ "status",
411
+ "reason"
412
+ ],
413
+ "properties": {
414
+ "tag": {
415
+ "type": "string",
416
+ "description": "ci/green/<sha> or ci/revoked/<sha>."
417
+ },
418
+ "status": {
419
+ "enum": [
420
+ "unsigned",
421
+ "invalid",
422
+ "untrusted",
423
+ "mismatch"
424
+ ],
425
+ "description": "unsigned: the annotation carries no statement. invalid: the statement is not a ci-tag statement, or names another signer than the key's. untrusted: no runner key .chant/trust.json lists at base signed it, or its principal holds no runner role. mismatch: it signs another commit, tag kind or branch, the annotation's record is not the one signed, or the tag points at another commit than its name gives."
426
+ },
427
+ "reason": {
428
+ "type": "string"
429
+ }
430
+ }
431
+ }
432
+ },
433
+ "ignoredRuns": {
434
+ "type": "array",
435
+ "description": "Added within contract version 1 by #4044, written by chant 0.124.28 and newer. Present only when the source is chant runs (ci.green.source or --source runs): the Op runs on the commit that do not count for want of a valid statement signed by a runner key whose principal holds the runner role. They neither green nor revoke the commit.",
436
+ "items": {
437
+ "type": "object",
438
+ "required": [
439
+ "run",
440
+ "op",
441
+ "env",
442
+ "status",
443
+ "reason"
444
+ ],
445
+ "properties": {
446
+ "run": {
447
+ "type": "string",
448
+ "description": "The Op run's id."
449
+ },
450
+ "op": {
451
+ "type": "string"
452
+ },
453
+ "env": {
454
+ "type": "string"
455
+ },
456
+ "status": {
457
+ "enum": [
458
+ "unsigned",
459
+ "invalid",
460
+ "untrusted",
461
+ "mismatch"
462
+ ],
463
+ "description": "unsigned: the record carries no statement. invalid: the statement is not an op-run statement, or names another signer than the key's. untrusted: no runner key .chant/trust.json lists at base signed it, or its principal holds no runner role. mismatch: it signs another run, commit or record than the ledger holds."
464
+ },
465
+ "reason": {
466
+ "type": "string"
467
+ }
468
+ }
469
+ }
470
+ }
471
+ }
472
+ }
473
+ }
474
+ }
475
+ },
476
+ "failure": {
477
+ "type": "object",
478
+ "description": "Nothing was read. Exit code 1.",
479
+ "required": [
480
+ "$schema",
481
+ "contract",
482
+ "chant",
483
+ "error"
484
+ ],
485
+ "properties": {
486
+ "$schema": {
487
+ "const": "https://intentius.io/chant/schemas/workspace/ci-list/v1/ci-list.schema.json"
488
+ },
489
+ "contract": {
490
+ "const": 1
491
+ },
492
+ "chant": {
493
+ "type": "string"
494
+ },
495
+ "error": {
496
+ "type": "object",
497
+ "required": [
498
+ "code",
499
+ "message"
500
+ ],
501
+ "properties": {
502
+ "code": {
503
+ "enum": [
504
+ "declaration-missing",
505
+ "declaration-ambiguous",
506
+ "declaration-unparseable",
507
+ "declaration-invalid",
508
+ "placement-invalid",
509
+ "reader-too-old",
510
+ "root-chant-required",
511
+ "not-a-git-repository",
512
+ "revision-unknown",
513
+ "ci-green-undeclared",
514
+ "ci-branch-unknown"
515
+ ]
516
+ },
517
+ "message": {
518
+ "type": "string"
519
+ }
520
+ }
521
+ }
522
+ }
523
+ }
524
+ }
525
+ }