@unbrained/pm-cli 2026.8.7 → 2026.8.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 (288) hide show
  1. package/.claude-plugin/marketplace.json +2 -2
  2. package/CHANGELOG.md +54 -0
  3. package/dist/cli/main.js +4 -3
  4. package/dist/cli/register-annotations.d.ts +11 -0
  5. package/dist/cli/register-annotations.js +195 -0
  6. package/dist/cli/register-history-author.js +7 -30
  7. package/dist/cli/register-mutation.js +25 -206
  8. package/dist/cli/runtime-compatibility-boundary.d.ts +17 -0
  9. package/dist/cli/runtime-compatibility-boundary.js +43 -0
  10. package/dist/cli-bundle/bundle-manifest.json +158 -694
  11. package/dist/cli-bundle/chunks/chunk-2DTCZXSD.js +13 -0
  12. package/dist/cli-bundle/chunks/chunk-5JO6R4BS.js +3 -0
  13. package/dist/cli-bundle/chunks/chunk-5KN4DZYV.js +194 -0
  14. package/dist/cli-bundle/chunks/chunk-EF43KODO.js +2 -0
  15. package/dist/cli-bundle/chunks/chunk-GMX5YOI3.js +77 -0
  16. package/dist/cli-bundle/chunks/chunk-HUV2Z7IS.js +28 -0
  17. package/dist/cli-bundle/chunks/chunk-MHBVCUF2.js +2 -0
  18. package/dist/cli-bundle/chunks/chunk-PYO5GZU6.js +5 -0
  19. package/dist/cli-bundle/chunks/chunk-QWRRFYK3.js +2 -0
  20. package/dist/cli-bundle/chunks/chunk-RJC7TPF4.js +8 -0
  21. package/dist/cli-bundle/chunks/chunk-YC3UF2IO.js +2068 -0
  22. package/dist/cli-bundle/chunks/{register-list-query-FJZCJ67O.js → register-list-query-BUE7PTCU.js} +8 -8
  23. package/dist/cli-bundle/chunks/register-mutation-FC3XLVIK.js +20 -0
  24. package/dist/cli-bundle/chunks/register-operations-YH2WAOXU.js +2 -0
  25. package/dist/cli-bundle/chunks/register-setup-UQDTNTLJ.js +2 -0
  26. package/dist/cli-bundle/focused-chunks/chunk-2VVP5RAA.js +153 -0
  27. package/dist/cli-bundle/focused-chunks/{chunk-4VJQTS3P.js → chunk-3GSFUDAI.js} +2 -2
  28. package/dist/cli-bundle/focused-chunks/chunk-3WVHTUAW.js +5 -0
  29. package/dist/cli-bundle/focused-chunks/chunk-4H6MVCK3.js +16 -0
  30. package/dist/cli-bundle/focused-chunks/{chunk-73JUDYXT.js → chunk-54TZJ4BM.js} +2 -2
  31. package/dist/cli-bundle/focused-chunks/chunk-5NK5TJ5D.js +2 -0
  32. package/dist/cli-bundle/focused-chunks/{chunk-HNL6IFGS.js → chunk-6DO4YQWZ.js} +2 -2
  33. package/dist/cli-bundle/focused-chunks/chunk-73FIJONU.js +2 -0
  34. package/dist/cli-bundle/focused-chunks/{chunk-TIKDBG4D.js → chunk-C3GCHDSQ.js} +29 -27
  35. package/dist/cli-bundle/focused-chunks/chunk-JGRSQZJT.js +18 -0
  36. package/dist/cli-bundle/focused-chunks/{chunk-YZEZAPJK.js → chunk-KNEHLPBF.js} +2 -2
  37. package/dist/cli-bundle/focused-chunks/chunk-MRWVJ3ZG.js +2 -0
  38. package/dist/cli-bundle/focused-chunks/chunk-NL57J7BZ.js +4 -0
  39. package/dist/cli-bundle/focused-chunks/{chunk-NBJKQP4S.js → chunk-P6BBIQRG.js} +2 -2
  40. package/dist/cli-bundle/focused-chunks/{chunk-QHRTT7WT.js → chunk-PZAGVQNN.js} +2 -2
  41. package/dist/cli-bundle/focused-chunks/chunk-QDAO3XEK.js +14 -0
  42. package/dist/cli-bundle/focused-chunks/chunk-T4IGQCSY.js +2 -0
  43. package/dist/cli-bundle/focused-chunks/chunk-U46GQJNY.js +2 -0
  44. package/dist/cli-bundle/focused-chunks/{chunk-RPNYG5MO.js → chunk-VRXJSGIT.js} +6 -6
  45. package/dist/cli-bundle/focused-chunks/{chunk-R2LEMEV5.js → chunk-XC2ZW3CJ.js} +2 -2
  46. package/dist/cli-bundle/focused-chunks/chunk-ZG54B4XG.js +2 -0
  47. package/dist/cli-bundle/main.js +13 -13
  48. package/dist/cli-bundle/sdk-authoring.js +1 -1
  49. package/dist/cli-bundle/sdk-contracts.js +1 -1
  50. package/dist/cli-bundle/sdk-core.js +38 -38
  51. package/dist/cli-bundle/sdk-governance.js +1 -1
  52. package/dist/cli-bundle/sdk-graph.js +1 -1
  53. package/dist/cli-bundle/sdk-merge.js +1 -1
  54. package/dist/cli-bundle/sdk-query.js +1 -1
  55. package/dist/cli-bundle/sdk-runtime.js +1 -1
  56. package/dist/cli-bundle/sdk-testing.js +1 -1
  57. package/dist/cli-bundle/sdk.js +2 -1
  58. package/dist/cli.js +14 -4
  59. package/dist/core/diagnostics/remediation.js +12 -2
  60. package/dist/core/history/history.js +13 -4
  61. package/dist/core/item/actionability.d.ts +7 -1
  62. package/dist/core/item/actionability.js +71 -15
  63. package/dist/core/output/output.js +9 -2
  64. package/dist/core/sentry/helpers.d.ts +10 -0
  65. package/dist/core/sentry/helpers.js +59 -4
  66. package/dist/core/shared/author.d.ts +25 -0
  67. package/dist/core/shared/author.js +114 -9
  68. package/dist/core/shared/constants.d.ts +2 -0
  69. package/dist/core/shared/constants.js +4 -2
  70. package/dist/sdk/actionability.d.ts +1 -1
  71. package/dist/sdk/actionability.js +3 -3
  72. package/dist/sdk/annotations.d.ts +40 -0
  73. package/dist/sdk/annotations.js +61 -9
  74. package/dist/sdk/author-attribution.d.ts +12 -0
  75. package/dist/sdk/author-attribution.js +73 -11
  76. package/dist/sdk/cli-contracts/command-exit-contracts.d.ts +118 -0
  77. package/dist/sdk/cli-contracts/command-exit-contracts.js +152 -0
  78. package/dist/sdk/cli-contracts/completeness.js +5 -3
  79. package/dist/sdk/cli-contracts/flag-contracts.js +5 -2
  80. package/dist/sdk/cli-contracts/runtime-contracts.d.ts +19 -0
  81. package/dist/sdk/cli-contracts/runtime-contracts.js +44 -2
  82. package/dist/sdk/cli-contracts/tool-parameter-tables.js +15 -2
  83. package/dist/sdk/cli-contracts/tool-schema.d.ts +1 -1
  84. package/dist/sdk/cli-contracts/tool-schema.js +6 -3
  85. package/dist/sdk/comments.d.ts +7 -0
  86. package/dist/sdk/comments.js +2 -2
  87. package/dist/sdk/completion.js +9 -5
  88. package/dist/sdk/contracts.d.ts +1 -0
  89. package/dist/sdk/contracts.js +3 -2
  90. package/dist/sdk/core-governance.d.ts +1 -1
  91. package/dist/sdk/core-governance.js +3 -3
  92. package/dist/sdk/dependencies.d.ts +2 -0
  93. package/dist/sdk/dependencies.js +7 -6
  94. package/dist/sdk/environment/host-environment-errors.d.ts +27 -0
  95. package/dist/sdk/environment/host-environment-errors.js +124 -0
  96. package/dist/sdk/environment/project-runtime-compatibility.d.ts +65 -0
  97. package/dist/sdk/environment/project-runtime-compatibility.js +385 -0
  98. package/dist/sdk/environment/source-context.d.ts +23 -0
  99. package/dist/sdk/environment/source-context.js +29 -0
  100. package/dist/sdk/error-code-catalog.d.ts +6 -0
  101. package/dist/sdk/error-code-catalog.js +62 -8
  102. package/dist/sdk/extension/bundled-catalog.js +19 -6
  103. package/dist/sdk/generated-error-code-catalog.js +665 -3
  104. package/dist/sdk/governance/health.d.ts +11 -3
  105. package/dist/sdk/governance/health.js +32 -13
  106. package/dist/sdk/governance/provenance-health.d.ts +26 -0
  107. package/dist/sdk/governance/provenance-health.js +139 -0
  108. package/dist/sdk/governance/validate.js +13 -8
  109. package/dist/sdk/governance.d.ts +1 -0
  110. package/dist/sdk/governance.js +3 -2
  111. package/dist/sdk/graph/assembly.d.ts +4 -0
  112. package/dist/sdk/graph/assembly.js +22 -2
  113. package/dist/sdk/graph/run.d.ts +2 -0
  114. package/dist/sdk/graph/run.js +3 -2
  115. package/dist/sdk/index.d.ts +7 -3
  116. package/dist/sdk/index.js +9 -5
  117. package/dist/sdk/learnings.d.ts +15 -0
  118. package/dist/sdk/learnings.js +2 -2
  119. package/dist/sdk/lifecycle/close-many.d.ts +6 -1
  120. package/dist/sdk/lifecycle/close-many.js +43 -5
  121. package/dist/sdk/lifecycle/close.js +13 -8
  122. package/dist/sdk/lifecycle/create.js +6 -12
  123. package/dist/sdk/lifecycle/plan.js +6 -3
  124. package/dist/sdk/lifecycle/update-many.d.ts +2 -1
  125. package/dist/sdk/lifecycle/update-many.js +29 -5
  126. package/dist/sdk/lifecycle/update.js +6 -20
  127. package/dist/sdk/merge/driver.d.ts +2 -1
  128. package/dist/sdk/merge/driver.js +7 -4
  129. package/dist/sdk/merge/index.d.ts +1 -1
  130. package/dist/sdk/merge/index.js +3 -3
  131. package/dist/sdk/merge/install.d.ts +21 -0
  132. package/dist/sdk/merge/install.js +51 -21
  133. package/dist/sdk/merge/receipts.d.ts +14 -1
  134. package/dist/sdk/merge/receipts.js +36 -8
  135. package/dist/sdk/merge/reconcile.js +21 -4
  136. package/dist/sdk/merge/three-way.d.ts +6 -2
  137. package/dist/sdk/merge/three-way.js +24 -10
  138. package/dist/sdk/notes.d.ts +7 -0
  139. package/dist/sdk/notes.js +2 -2
  140. package/dist/sdk/query/get.d.ts +11 -0
  141. package/dist/sdk/query/get.js +37 -3
  142. package/dist/sdk/read-output-contracts.d.ts +1 -1
  143. package/dist/sdk/read-output-contracts.js +103 -5
  144. package/dist/sdk/relationship-kinds/contract.d.ts +48 -0
  145. package/dist/sdk/relationship-kinds/contract.js +22 -0
  146. package/dist/sdk/relationships.d.ts +6 -41
  147. package/dist/sdk/relationships.js +12 -126
  148. package/dist/sdk/runtime-primitives.d.ts +1 -1
  149. package/dist/sdk/runtime-primitives.js +3 -3
  150. package/dist/sdk/runtime.d.ts +1 -1
  151. package/dist/sdk/runtime.js +9 -25
  152. package/dist/sdk/similarity.d.ts +5 -0
  153. package/dist/sdk/similarity.js +40 -10
  154. package/dist/sdk/structured-mutations.js +5 -2
  155. package/dist/sdk/test/execution.js +4 -2
  156. package/dist/sdk/test/linked-command-detection.d.ts +2 -7
  157. package/dist/sdk/test/linked-command-detection.js +22 -9
  158. package/dist/sdk/test/parsers.js +5 -2
  159. package/dist/sdk/workspace-snapshot.d.ts +9 -0
  160. package/dist/sdk/workspace-snapshot.js +48 -16
  161. package/docs/AGENT_GUIDE.md +2 -1
  162. package/docs/AGENT_RUNTIME_PRIMITIVES.md +11 -4
  163. package/docs/COMMANDS.md +19 -1
  164. package/docs/DEPENDENCY_KIND_CONTRACT.md +29 -0
  165. package/docs/ITEM_READ_PROJECTIONS.md +26 -0
  166. package/docs/MERGE_SAFETY.md +10 -3
  167. package/docs/README.md +1 -0
  168. package/docs/RELATIONSHIP_GRAPH.md +1 -1
  169. package/docs/RELEASING.md +27 -2
  170. package/docs/SCRIPTING.md +27 -1
  171. package/docs/SDK_AGENT_SESSION_CONTEXT.md +35 -2
  172. package/docs/SDK_CONTEXT_INTEGRITY.md +81 -0
  173. package/docs/SDK_RUNTIME_BOUNDARIES.md +58 -0
  174. package/docs/SELF_DESCRIBING_CONTEXT_CONTRACTS.md +13 -0
  175. package/docs/SENTRY_CONTRACT_EPOCHS.md +20 -0
  176. package/docs/TESTING.md +17 -0
  177. package/docs/agent-task-token-baseline.json +2 -2
  178. package/marketplace.json +2 -2
  179. package/package.json +5 -3
  180. package/packages/pm-beads/package.json +1 -1
  181. package/packages/pm-calendar/package.json +1 -1
  182. package/packages/pm-command-kit/package.json +1 -1
  183. package/packages/pm-digital-twin/package.json +1 -1
  184. package/packages/pm-governance-audit/package.json +1 -1
  185. package/packages/pm-guide-shell/package.json +1 -1
  186. package/packages/pm-kanban/package.json +1 -1
  187. package/packages/pm-lifecycle-hooks/package.json +1 -1
  188. package/packages/pm-linked-test-adapters/package.json +1 -1
  189. package/packages/pm-search-advanced/package.json +1 -1
  190. package/packages/pm-templates/package.json +1 -1
  191. package/packages/pm-todos/package.json +1 -1
  192. package/packages/pm-vcs/package.json +1 -1
  193. package/plugins/pm-claude/.claude-plugin/plugin.json +1 -1
  194. package/plugins/pm-codex/.codex-plugin/plugin.json +1 -1
  195. package/sdk/public-surface.json +756 -57
  196. package/dist/cli-bundle/chunks/append-7BXBFDGD.js +0 -2
  197. package/dist/cli-bundle/chunks/chunk-2AXF3VSK.js +0 -2
  198. package/dist/cli-bundle/chunks/chunk-2XS43CCV.js +0 -2
  199. package/dist/cli-bundle/chunks/chunk-3A6KWB72.js +0 -8
  200. package/dist/cli-bundle/chunks/chunk-3ISTDB42.js +0 -8
  201. package/dist/cli-bundle/chunks/chunk-4MTI7XOV.js +0 -5
  202. package/dist/cli-bundle/chunks/chunk-6BX5UDCN.js +0 -3
  203. package/dist/cli-bundle/chunks/chunk-6QPO7KLR.js +0 -2
  204. package/dist/cli-bundle/chunks/chunk-7MXHZHSQ.js +0 -5
  205. package/dist/cli-bundle/chunks/chunk-7ZPMJW4U.js +0 -2
  206. package/dist/cli-bundle/chunks/chunk-A6KGKEWT.js +0 -2
  207. package/dist/cli-bundle/chunks/chunk-AGYNSNCI.js +0 -2
  208. package/dist/cli-bundle/chunks/chunk-B4H7FEFH.js +0 -5
  209. package/dist/cli-bundle/chunks/chunk-B4KLBBMN.js +0 -2
  210. package/dist/cli-bundle/chunks/chunk-BXCSXK4J.js +0 -2
  211. package/dist/cli-bundle/chunks/chunk-CALJHNBL.js +0 -23
  212. package/dist/cli-bundle/chunks/chunk-CFIGP5LY.js +0 -2
  213. package/dist/cli-bundle/chunks/chunk-CHOQ2VAW.js +0 -2
  214. package/dist/cli-bundle/chunks/chunk-CS6MRHG7.js +0 -2
  215. package/dist/cli-bundle/chunks/chunk-CUGNQQKH.js +0 -2
  216. package/dist/cli-bundle/chunks/chunk-D4FPS43D.js +0 -164
  217. package/dist/cli-bundle/chunks/chunk-E2ZSLTOP.js +0 -2
  218. package/dist/cli-bundle/chunks/chunk-FB7G2HY2.js +0 -2
  219. package/dist/cli-bundle/chunks/chunk-H5Y5YE6A.js +0 -2
  220. package/dist/cli-bundle/chunks/chunk-H5Y6UV6E.js +0 -2
  221. package/dist/cli-bundle/chunks/chunk-H7KGWPDF.js +0 -2
  222. package/dist/cli-bundle/chunks/chunk-HFSD77TQ.js +0 -2
  223. package/dist/cli-bundle/chunks/chunk-HX2GTA6L.js +0 -2
  224. package/dist/cli-bundle/chunks/chunk-J2IEKAVR.js +0 -2
  225. package/dist/cli-bundle/chunks/chunk-JC6FKIFM.js +0 -2
  226. package/dist/cli-bundle/chunks/chunk-K44PYFXH.js +0 -2
  227. package/dist/cli-bundle/chunks/chunk-K4KGEEBT.js +0 -2
  228. package/dist/cli-bundle/chunks/chunk-KFLK5TRH.js +0 -21
  229. package/dist/cli-bundle/chunks/chunk-KL6IEBV2.js +0 -2
  230. package/dist/cli-bundle/chunks/chunk-KWQZDZSS.js +0 -2
  231. package/dist/cli-bundle/chunks/chunk-KZ4X3DGU.js +0 -3
  232. package/dist/cli-bundle/chunks/chunk-LD77HJMQ.js +0 -13
  233. package/dist/cli-bundle/chunks/chunk-LEPJJ6QC.js +0 -2
  234. package/dist/cli-bundle/chunks/chunk-ME2JJ4LA.js +0 -3
  235. package/dist/cli-bundle/chunks/chunk-NE5VRDAI.js +0 -2
  236. package/dist/cli-bundle/chunks/chunk-NFLJ3FHD.js +0 -2
  237. package/dist/cli-bundle/chunks/chunk-NG6OXIBR.js +0 -19
  238. package/dist/cli-bundle/chunks/chunk-NYIGHWQY.js +0 -8
  239. package/dist/cli-bundle/chunks/chunk-NZ75GNSA.js +0 -2
  240. package/dist/cli-bundle/chunks/chunk-PCJWJNC2.js +0 -2
  241. package/dist/cli-bundle/chunks/chunk-PD3225AM.js +0 -2
  242. package/dist/cli-bundle/chunks/chunk-PDEGKG7P.js +0 -2
  243. package/dist/cli-bundle/chunks/chunk-PIE5HBNA.js +0 -2
  244. package/dist/cli-bundle/chunks/chunk-PW2H7YJR.js +0 -56
  245. package/dist/cli-bundle/chunks/chunk-RSIC5OPE.js +0 -2
  246. package/dist/cli-bundle/chunks/chunk-TPKN3S7S.js +0 -2
  247. package/dist/cli-bundle/chunks/chunk-TPXAXTCO.js +0 -2
  248. package/dist/cli-bundle/chunks/chunk-UFWUJO4V.js +0 -2
  249. package/dist/cli-bundle/chunks/chunk-UQLZQVFW.js +0 -55
  250. package/dist/cli-bundle/chunks/chunk-VT3Z5G7D.js +0 -2
  251. package/dist/cli-bundle/chunks/chunk-WOD3WWUN.js +0 -2
  252. package/dist/cli-bundle/chunks/chunk-WSJEIGJF.js +0 -3
  253. package/dist/cli-bundle/chunks/chunk-WYNUU7ZW.js +0 -2008
  254. package/dist/cli-bundle/chunks/chunk-YGPNCCXZ.js +0 -2
  255. package/dist/cli-bundle/chunks/close-CMY3BAUG.js +0 -2
  256. package/dist/cli-bundle/chunks/close-many-SA4XZCTK.js +0 -2
  257. package/dist/cli-bundle/chunks/comments-EZ556ZD3.js +0 -2
  258. package/dist/cli-bundle/chunks/copy-ZSGPA52X.js +0 -2
  259. package/dist/cli-bundle/chunks/create-I5DVV4YG.js +0 -2
  260. package/dist/cli-bundle/chunks/delete-RL3JACSW.js +0 -2
  261. package/dist/cli-bundle/chunks/deps-S7UBCECS.js +0 -2
  262. package/dist/cli-bundle/chunks/docs-ZZNVBBYO.js +0 -2
  263. package/dist/cli-bundle/chunks/files-27C337VT.js +0 -2
  264. package/dist/cli-bundle/chunks/focus-5Z2SG7LU.js +0 -2
  265. package/dist/cli-bundle/chunks/history-compact-HJQK67CZ.js +0 -2
  266. package/dist/cli-bundle/chunks/history-redact-PWC6PDWA.js +0 -2
  267. package/dist/cli-bundle/chunks/history-repair-N3CY4WBF.js +0 -2
  268. package/dist/cli-bundle/chunks/learnings-4FH23XDT.js +0 -2
  269. package/dist/cli-bundle/chunks/profile-5Y5XXH5N.js +0 -2
  270. package/dist/cli-bundle/chunks/register-mutation-YGYPW3BL.js +0 -20
  271. package/dist/cli-bundle/chunks/register-operations-WMDSUMQF.js +0 -2
  272. package/dist/cli-bundle/chunks/register-setup-DL7FFABC.js +0 -2
  273. package/dist/cli-bundle/chunks/restore-6KYBV5BY.js +0 -2
  274. package/dist/cli-bundle/chunks/schema-EQGKBYXJ.js +0 -2
  275. package/dist/cli-bundle/chunks/update-QVTYOD6I.js +0 -2
  276. package/dist/cli-bundle/chunks/update-many-DJSBU525.js +0 -2
  277. package/dist/cli-bundle/focused-chunks/chunk-2ECLECMK.js +0 -12
  278. package/dist/cli-bundle/focused-chunks/chunk-3K4XV2BF.js +0 -16
  279. package/dist/cli-bundle/focused-chunks/chunk-4EX25PXM.js +0 -8
  280. package/dist/cli-bundle/focused-chunks/chunk-CIXVQPB7.js +0 -5
  281. package/dist/cli-bundle/focused-chunks/chunk-DLTS3IHM.js +0 -2
  282. package/dist/cli-bundle/focused-chunks/chunk-DQ6FKGL3.js +0 -14
  283. package/dist/cli-bundle/focused-chunks/chunk-JLG2C4EQ.js +0 -2
  284. package/dist/cli-bundle/focused-chunks/chunk-MHMTKV5V.js +0 -2
  285. package/dist/cli-bundle/focused-chunks/chunk-MOTJFQ3F.js +0 -153
  286. package/dist/cli-bundle/focused-chunks/chunk-RW5IYD4J.js +0 -4
  287. package/dist/cli-bundle/focused-chunks/chunk-VZFU2R4M.js +0 -2
  288. package/dist/cli-bundle/focused-chunks/chunk-ZJIMJHDB.js +0 -2
@@ -6,14 +6,14 @@
6
6
  },
7
7
  "metadata": {
8
8
  "description": "Official marketplace for pm CLI — native git-based project management for Claude Code and AI coding agents.",
9
- "version": "2026.8.7"
9
+ "version": "2026.8.9"
10
10
  },
11
11
  "plugins": [
12
12
  {
13
13
  "name": "pm-claude",
14
14
  "source": "./plugins/pm-claude",
15
15
  "description": "Native pm CLI integration for Claude Code — 28 MCP tools, 5 workflow skills, 14 slash commands, 4 subagents, hybrid TUI task tracking, session context injection, and coordination subagents for git-based project management without leaving Claude Code.",
16
- "version": "2026.8.7",
16
+ "version": "2026.8.9",
17
17
  "author": {
18
18
  "name": "unbrained",
19
19
  "url": "https://github.com/unbraind/pm-cli"
package/CHANGELOG.md CHANGED
@@ -1,5 +1,59 @@
1
1
  # Changelog
2
2
 
3
+ ## 2026.8.9 - 2026-08-09
4
+
5
+ ### Fixed
6
+
7
+ - The release gate cannot classify Sentry events emitted before its own contract producer shipped, so a correct usage refusal from an older release blocks the daily cut for the whole rolling window and clears only by hand ([pm-h75tjh](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-h75tjh.toon))
8
+ - Entity projections carry a collection key only when it is non-empty, so an absent key cannot be distinguished from an unprojected one and neither projection level is a superset of the other ([pm-b1w8vr](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-b1w8vr.toon))
9
+ - Ordering recorded as blocks is invisible to actionability: the same prerequisite schedules differently depending on which endpoint wrote it ([pm-jkbqt8](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-jkbqt8.toon))
10
+ - Dependency-kind lexicon: fifteen accepted spellings for roughly eight relations, canonicalized inconsistently at write time, so the stored graph vocabulary keeps fragmenting ([pm-4020c5](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-4020c5.toon))
11
+ - GH-930: duplicates --status all silently scans zero items ([pm-sy24w2](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-sy24w2.toon))
12
+ - GH-920: health conflates lossless merge receipts with discarded-value decisions ([pm-jtwsct](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-jtwsct.toon))
13
+ - GH-937: package list exposes alias rows as packages and overstates the catalog total ([pm-fr6u17](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-fr6u17.toon))
14
+ - Post-merge guidance names history-repair, which clears drift but never settles the merge receipt, so every merged item leaves a permanent merge_decisions_unreviewed warning ([pm-lwmstb](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-lwmstb.toon))
15
+ - GH-925: package manage diagnostics reject universal read-output controls ([pm-479ggz](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-479ggz.toon))
16
+ - Surface replication gate activates unrelated sets through shared required members ([pm-kmnvug](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-kmnvug.toon))
17
+ - GH-924: closed completed plans still recommend pm close ([pm-ltlcsw](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-ltlcsw.toon))
18
+ - Merge direction decides which agent's value survives: the same two branches converge to different item state depending on which side merges, and nothing reports the divergence ([pm-dlx7v7](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-dlx7v7.toon))
19
+ - GH-931: linked-test detector misclassifies unrelated node dist/cli.js commands as pm ([pm-u3o3ur](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-u3o3ur.toon))
20
+ - Release candidate acceptance hard-codes the pre-bump CLI version and blocks the daily cut ([pm-7ipajv](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-7ipajv.toon))
21
+
22
+ ## 2026.8.8 - 2026-08-08
23
+
24
+ ### Added
25
+
26
+ - The CLI has 195 error codes and contracts none of them: the surface agents read when they are wrong is the only one with no enumeration, no stability promise, and no gate ([pm-x4nn3z](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/features/pm-x4nn3z.toon))
27
+
28
+ ### Fixed
29
+
30
+ - PR \#935 review remediation: executable gate registry and fail-closed runtime context parsing ([pm-n41vay](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-n41vay.toon))
31
+ - GH-926: warn before a stale pm binary mutates a project pinned to a newer CLI/SDK ([pm-1eted6](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-1eted6.toon))
32
+ - PR \#935 CI: preserve dependency-free fast-version startup and regenerate runtime contracts ([pm-dskxwf](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-dskxwf.toon))
33
+ - Make stale-runtime compatibility classification action-aware across mixed CLI commands ([pm-zjelve](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-zjelve.toon))
34
+ - CLI and SDK refusal contracts now preserve consistent codes and recovery semantics ([pm-0xmajx](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-0xmajx.toon))
35
+ - Sentry exception capture never writes the pm.error_code and pm.exit_code tags the release gate reads, so every unexpected runtime error is unclassifiable by construction and blocks the daily cut for the full rolling window ([pm-qxo5iu](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-qxo5iu.toon))
36
+ - Sentry PM-CLI-2S: resource-exhausted copy reports a high handled error without actionable storage guidance ([pm-4odf0c](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-4odf0c.toon))
37
+ - Sentry PM-CLI-2Q: expected snapshot-name validation is captured as a high production error ([pm-qyg51h](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-qyg51h.toon))
38
+ - The release gate classifies production errors by message prose and reads none of the 236 error codes the product declares, so every waiver is a latent re-block and a broad substring is a silent waiver ([pm-dqtzva](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-dqtzva.toon))
39
+ - The mandatory command-wiring replication set is enforced only by a prose checklist, and the census shows partial application is the single largest recurring defect class in the record ([pm-7rrqsk](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-7rrqsk.toon))
40
+ - pm get silently discards --output-include field names because entity reads bind the flag to sections while collection reads bind it to fields, and the omission receipt reports no omissions either way ([pm-0k19l7](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-0k19l7.toon))
41
+ - GH-919: \_workspace author-attribution coordinates cannot be acknowledged ([pm-ety1qc](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-ety1qc.toon))
42
+ - pm comments write response replays the entire accumulated history, so one append can emit hundreds of comments ([pm-9stazf](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-9stazf.toon))
43
+ - GH-457: pm health hangs during vectorization check with no output (never-block violation) ([pm-tu71](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-tu71.toon))
44
+
45
+ ### Security
46
+
47
+ - GHSA-2v37-7h3g-55p8: pin patched nanoid in the Vite/PostCSS development graph ([pm-5dwz1a](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-5dwz1a.toon))
48
+ - GH-933: nested PM writes in non-PM linked tests can mutate the source project ([pm-alhqbz](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/issues/pm-alhqbz.toon))
49
+
50
+ ### Other
51
+
52
+ - One governed verification plan now drives local preflight and maps hosted release gates ([pm-ei6x66](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/tasks/pm-ei6x66.toon))
53
+ - Every command declares its exit-code set, and the code distinguishes applied from applied-to-nothing ([pm-hqa8g1](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/tasks/pm-hqa8g1.toon))
54
+ - Floor polarity for the tracker measurement ratchet, with graph edge and node floors declared ([pm-z0cfor](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/tasks/pm-z0cfor.toon))
55
+ - Refresh tsx to 4.23.11 with full release-gate proof ([pm-nw1y14](https://github.com/unbraind/pm-cli/blob/main/.agents/pm/chores/pm-nw1y14.toon))
56
+
3
57
  ## 2026.8.7 - 2026-08-07
4
58
 
5
59
  ### Added
package/dist/cli/main.js CHANGED
@@ -3,7 +3,7 @@
3
3
  * @module cli/main
4
4
  */
5
5
 
6
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="bb6049e8-1185-5702-b8c1-3a30a98db516")}catch(e){}}();
6
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="52c705ab-a5c4-5b94-b806-4eaac31b6e9c")}catch(e){}}();
7
7
  import { Command } from "commander";
8
8
  import { activateExtensions, clearActiveExtensionHooks, createCoreCommandHookContext, resetActiveExtensionRuntimeState, createEmptyExtensionRegistrationRegistry, discoverExtensions, getActiveCommandResult, getActiveExtensionRegistrations, loadExtensions, consumeAfterCommandAffectedItems, runActiveCommandHandler, runActiveParserOverride, runActivePreflightOverride, runAfterCommandHooks, runBeforeCommandHooks, setActiveCommandResult, setActiveCommandContext, setActiveExtensionCommands, setActiveExtensionHooks, setActiveExtensionParsers, setActiveExtensionPreflight, setActiveExtensionRegistrations, setActiveExtensionRenderers, setActiveExtensionServices, pathExists, resolvePmCliVersion, resolvePmPackageRootFromModule, resolveItemTypeRegistry, resolveRuntimeFieldRegistry, EXIT_CODE, resolveTelemetryErrorCategory, PmCliError, asRecordOrNull, printError, printResult, maybeRunFirstUseTelemetryPrompt, emitTelemetryErrorEvent, startTelemetryCommand, deriveTelemetryCommandResolution, sentryCaptureCliError, sentryFinishCommandSpan, sentryFlush, sentryLogCliUsageError, sentrySetCommandContext, sentryStartCommandSpan, ensureSentryInit, getSettingsPath, resolvePmRoot, readSettings, readSettingsWithMetadata, runWithWorkspaceHarnessSignalDescriptors, createLazyModule, } from "../sdk/runtime-primitives.js";
9
9
  import { resolveSubcommandFlagContractsForCommand } from "../sdk/cli-contracts.js";
@@ -29,6 +29,7 @@ import { attachOutputTokenAccounting } from "../sdk/output-token-accounting.js";
29
29
  import { runWithDiscoveredContextIntentContracts } from "../sdk/context-intent-runtime.js";
30
30
  import { validateReadOutputOptions } from "../sdk/read-output-contracts.js";
31
31
  import { loadContextIntentSnapshotForInvocation } from "./context-intent-invocation.js";
32
+ import { isPmSuccessfulExitCode } from "../sdk/cli-contracts/command-exit-contracts.js";
32
33
  const PM_PACKAGE_ROOT_ENV = "PM_CLI_PACKAGE_ROOT";
33
34
  function resolvePmPackageRoot() {
34
35
  return resolvePmPackageRootFromModule(import.meta.url, ["../.."]);
@@ -332,7 +333,7 @@ function buildPostActionTelemetryOutcome() {
332
333
  const processExitCode = typeof process.exitCode === "number" && Number.isFinite(process.exitCode) ? Math.max(0, Math.trunc(process.exitCode)) : undefined;
333
334
  const resultExitCode = readRecordNumber(result, "exit_code", "exitCode");
334
335
  const exitCode = processExitCode ?? resultExitCode ?? EXIT_CODE.SUCCESS;
335
- const ok = exitCode === EXIT_CODE.SUCCESS;
336
+ const ok = isPmSuccessfulExitCode(exitCode);
336
337
  const errorCode = readRecordString(result, "error_code", "errorCode") ?? inferPostActionErrorCode(ok, exitCode);
337
338
  const errorCategory = normalizeTelemetryErrorCategory(readRecordString(result, "error_category", "errorCategory")) ??
338
339
  (!ok ? resolveTelemetryErrorCategory(errorCode) : undefined);
@@ -2453,4 +2454,4 @@ export const _testOnly = {
2453
2454
  wrapThrownErrorForSentry,
2454
2455
  };
2455
2456
  //# sourceMappingURL=main.js.map
2456
- //# debugId=bb6049e8-1185-5702-b8c1-3a30a98db516
2457
+ //# debugId=52c705ab-a5c4-5b94-b806-4eaac31b6e9c
@@ -0,0 +1,11 @@
1
+ /**
2
+ * @module cli/register-annotations
3
+ *
4
+ * Registers comment, note, and learning adapters around the shared bounded
5
+ * annotation SDK contract.
6
+ */
7
+ import type { Command } from "commander";
8
+ /** Converts a Commander token into a positive annotation index. */
9
+ export type PositiveIntegerOptionParser = (value: string, previous: number | undefined) => number;
10
+ /** Register bounded annotation commands on the root Commander program. */
11
+ export declare function registerAnnotationCommands(program: Command, parsePositiveInteger: (flag: string) => PositiveIntegerOptionParser): void;
@@ -0,0 +1,195 @@
1
+
2
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="0977d72e-6e4d-5ece-bfaf-eb24a4e9982c")}catch(e){}}();
3
+ import { EXIT_CODE, PmCliError, } from "../sdk/runtime-primitives.js";
4
+ import { runComments } from "./commands/comments.js";
5
+ import { runLearnings } from "./commands/learnings.js";
6
+ import { runNotes } from "./commands/notes.js";
7
+ import { addHiddenOption, getGlobalOptions, invalidateSearchCachesForMutation, printError, printResult, readOptionString, } from "./registration-helpers.js";
8
+ function resolveCommentSources(text, options) {
9
+ const editIndex = typeof options.edit === "number" ? options.edit : undefined;
10
+ const deleteIndex = typeof options.delete === "number" ? options.delete : undefined;
11
+ const addFromOption = readOptionString(options, "add") ??
12
+ readOptionString(options, "body") ??
13
+ readOptionString(options, "comment");
14
+ const addFromPositional = typeof text === "string" ? text : undefined;
15
+ const readFromStdin = options.stdin === true;
16
+ const readFromFile = readOptionString(options, "file");
17
+ const sourceCount = Number(addFromOption !== undefined) +
18
+ Number(addFromPositional !== undefined) +
19
+ Number(readFromStdin) +
20
+ Number(readFromFile !== undefined);
21
+ if (sourceCount > 1) {
22
+ if (addFromOption !== undefined &&
23
+ addFromPositional !== undefined &&
24
+ !readFromStdin &&
25
+ readFromFile === undefined) {
26
+ throw new PmCliError("Specify comment text either as positional [text] or with --add, not both", EXIT_CODE.USAGE);
27
+ }
28
+ throw new PmCliError("Specify comment text with exactly one source: positional [text], --add, --stdin, or --file", EXIT_CODE.USAGE);
29
+ }
30
+ const add = addFromOption ?? addFromPositional;
31
+ return {
32
+ add,
33
+ readFromStdin,
34
+ readFromFile,
35
+ editIndex,
36
+ deleteIndex,
37
+ isMutation: typeof add === "string" ||
38
+ readFromStdin ||
39
+ readFromFile !== undefined ||
40
+ editIndex !== undefined ||
41
+ deleteIndex !== undefined,
42
+ };
43
+ }
44
+ function resolveSingleTextSource(label, positional, options) {
45
+ const addFromOption = readOptionString(options, "add");
46
+ const addFromPositional = typeof positional === "string" ? positional : undefined;
47
+ if (addFromOption !== undefined && addFromPositional !== undefined) {
48
+ throw new PmCliError(`Specify ${label} text either as positional [text] or with --add, not both`, EXIT_CODE.USAGE);
49
+ }
50
+ return addFromOption ?? addFromPositional;
51
+ }
52
+ async function runCommentsAction(id, text, options, command) {
53
+ const globalOptions = getGlobalOptions(command);
54
+ const startedAt = Date.now();
55
+ const sources = resolveCommentSources(text, options);
56
+ const result = await runComments(id, {
57
+ add: sources.add,
58
+ stdin: sources.readFromStdin,
59
+ file: sources.readFromFile,
60
+ edit: sources.editIndex,
61
+ delete: sources.deleteIndex,
62
+ limit: readOptionString(options, "limit"),
63
+ fullHistory: options.fullHistory === true,
64
+ author: readOptionString(options, "author"),
65
+ message: readOptionString(options, "message"),
66
+ ownershipAppendBypass: options.ownershipAppendBypass === true,
67
+ force: Boolean(options.force),
68
+ }, globalOptions);
69
+ if (sources.isMutation) {
70
+ await invalidateSearchCachesForMutation(globalOptions, result);
71
+ }
72
+ printAnnotationResult("comments", result, globalOptions, startedAt);
73
+ }
74
+ async function runNotesAction(id, text, options, command) {
75
+ const globalOptions = getGlobalOptions(command);
76
+ const startedAt = Date.now();
77
+ const add = resolveSingleTextSource("note", text, options);
78
+ const result = await runNotes(id, {
79
+ add,
80
+ addJson: readOptionString(options, "addJson"),
81
+ stdin: options.stdin === true,
82
+ file: readOptionString(options, "file"),
83
+ edit: typeof options.edit === "number" ? options.edit : undefined,
84
+ delete: typeof options.delete === "number" ? options.delete : undefined,
85
+ limit: readOptionString(options, "limit"),
86
+ since: readOptionString(options, "since"),
87
+ eventType: readOptionString(options, "eventType"),
88
+ includeMeta: options.includeMeta === true,
89
+ fullHistory: options.fullHistory === true,
90
+ author: readOptionString(options, "author"),
91
+ message: readOptionString(options, "message"),
92
+ ownershipAppendBypass: options.ownershipAppendBypass === true,
93
+ force: Boolean(options.force),
94
+ }, globalOptions);
95
+ if (typeof add === "string" ||
96
+ typeof options.addJson === "string" ||
97
+ options.stdin === true ||
98
+ typeof options.file === "string" ||
99
+ typeof options.edit === "number" ||
100
+ typeof options.delete === "number") {
101
+ await invalidateSearchCachesForMutation(globalOptions, result);
102
+ }
103
+ printAnnotationResult("notes", result, globalOptions, startedAt);
104
+ }
105
+ async function runLearningsAction(id, text, options, command) {
106
+ const globalOptions = getGlobalOptions(command);
107
+ const startedAt = Date.now();
108
+ const add = resolveSingleTextSource("learning", text, options);
109
+ const result = await runLearnings(id, {
110
+ add,
111
+ stdin: options.stdin === true,
112
+ file: readOptionString(options, "file"),
113
+ edit: typeof options.edit === "number" ? options.edit : undefined,
114
+ delete: typeof options.delete === "number" ? options.delete : undefined,
115
+ limit: readOptionString(options, "limit"),
116
+ fullHistory: options.fullHistory === true,
117
+ author: readOptionString(options, "author"),
118
+ message: readOptionString(options, "message"),
119
+ ownershipAppendBypass: options.ownershipAppendBypass === true,
120
+ force: Boolean(options.force),
121
+ }, globalOptions);
122
+ if (typeof add === "string" ||
123
+ options.stdin === true ||
124
+ typeof options.file === "string" ||
125
+ typeof options.edit === "number" ||
126
+ typeof options.delete === "number") {
127
+ await invalidateSearchCachesForMutation(globalOptions, result);
128
+ }
129
+ printAnnotationResult("learnings", result, globalOptions, startedAt);
130
+ }
131
+ function printAnnotationResult(command, result, globalOptions, startedAt) {
132
+ printResult(result, globalOptions);
133
+ if (globalOptions.profile) {
134
+ printError(`profile:command=${command} took_ms=${Date.now() - startedAt}`);
135
+ }
136
+ }
137
+ /** Register bounded annotation commands on the root Commander program. */
138
+ export function registerAnnotationCommands(program, parsePositiveInteger) {
139
+ const commentsCommand = program
140
+ .command("comments")
141
+ .argument("<id>", "Item id")
142
+ .argument("[text]", "Optional comment text shorthand (equivalent to --add)")
143
+ .option("--add <text>", "Add one comment entry (plain text fallback, text=<value>, markdown pairs, or - for stdin; CSV-like key fragments are preserved as plain text unless text is explicit)")
144
+ .option("--stdin", "Read comment text from stdin (supports multiline markdown)")
145
+ .option("--file <path>", "Read comment text from file (supports multiline markdown)")
146
+ .option("--edit <index>", "Replace the comment at 1-based <index> (replacement text from positional [text], --add, --stdin, or --file)", parsePositiveInteger("--edit"))
147
+ .option("--delete <index>", "Delete the comment at 1-based <index>", parsePositiveInteger("--delete"))
148
+ .option("--limit <n>", "Return only latest n comments")
149
+ .option("--full-history", "Return the complete post-mutation comment history instead of a bounded receipt")
150
+ .option("--author [value]", "Comment author (optional; falls back to PM_AUTHOR/settings)")
151
+ .option("--message <value>", "History message")
152
+ .option("--force", "Force ownership override")
153
+ .description("List, add, edit, or delete comments for an item.")
154
+ .action(runCommentsAction);
155
+ addHiddenOption(commentsCommand, "--body <text>", "Alias for --add", false);
156
+ addHiddenOption(commentsCommand, "--comment <text>", "Alias for --add", false);
157
+ program
158
+ .command("notes")
159
+ .argument("<id>", "Item id")
160
+ .argument("[text]", "Optional note text shorthand (equivalent to --add; use - for stdin)")
161
+ .option("--add <text>", "Add a text note (- reads stdin)")
162
+ .option("--add-json <json>", "Append a merge-safe JSON event")
163
+ .option("--stdin", "Read note text from stdin")
164
+ .option("--file <path>", "Read note text from a UTF-8 file")
165
+ .option("--edit <index>", "Replace a 1-based note using the selected text input", parsePositiveInteger("--edit"))
166
+ .option("--delete <index>", "Delete the note at 1-based <index>", parsePositiveInteger("--delete"))
167
+ .option("--limit <n>", "Return only latest n notes")
168
+ .option("--since <timestamp>", "Filter JSON events from this ISO time")
169
+ .option("--event-type <value>", "Filter JSON events by top-level type")
170
+ .option("--include-meta", "Include count and truncation metadata")
171
+ .option("--full-history", "Return the complete post-mutation note history instead of a bounded receipt")
172
+ .option("--author [value]", "Author; defaults to PM_AUTHOR/settings")
173
+ .option("--message <value>", "History message")
174
+ .option("--force", "Force ownership override")
175
+ .description("Manage merge-safe text notes and JSON context events.")
176
+ .action(runNotesAction);
177
+ program
178
+ .command("learnings")
179
+ .argument("<id>", "Item id")
180
+ .argument("[text]", "Optional learning text shorthand (equivalent to --add; use - for stdin)")
181
+ .option("--add <text>", "Add one learning entry (plain text fallback, text=<value>, markdown pairs, or - for stdin; CSV-like key fragments are preserved as plain text unless text is explicit)")
182
+ .option("--stdin", "Read learning text from stdin (supports multiline markdown)")
183
+ .option("--file <path>", "Read learning text from file (supports multiline markdown)")
184
+ .option("--edit <index>", "Replace the learning at 1-based <index> (replacement text from positional [text], --add, --stdin, or --file)", parsePositiveInteger("--edit"))
185
+ .option("--delete <index>", "Delete the learning at 1-based <index>", parsePositiveInteger("--delete"))
186
+ .option("--limit <n>", "Return only latest n learnings")
187
+ .option("--full-history", "Return the complete post-mutation learning history instead of a bounded receipt")
188
+ .option("--author [value]", "Learning author (optional; falls back to PM_AUTHOR/settings)")
189
+ .option("--message <value>", "History message")
190
+ .option("--force", "Force ownership override")
191
+ .description("List, add, edit, or delete learnings for an item.")
192
+ .action(runLearningsAction);
193
+ }
194
+ //# sourceMappingURL=register-annotations.js.map
195
+ //# debugId=0977d72e-6e4d-5ece-bfaf-eb24a4e9982c
@@ -1,40 +1,17 @@
1
1
 
2
- !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="d04ac41f-796d-5ccb-9e8e-cfa82c845f25")}catch(e){}}();
3
- import { EXIT_CODE, PmCliError, resolvePmRoot, } from "../sdk/runtime-primitives.js";
4
- import { acknowledgeUnknownAuthorHistoryEvents } from "../sdk/author-attribution.js";
2
+ !function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="50a7ce23-2abf-5240-b426-b73cb704e329")}catch(e){}}();
3
+ import { resolvePmRoot } from "../sdk/runtime-primitives.js";
4
+ import { acknowledgeUnknownAuthorHistoryEvents, resolveUnknownAuthorAcknowledgmentSelector, } from "../sdk/author-attribution.js";
5
5
  import { collect, getGlobalOptions, printResult, readOptionString, } from "./registration-helpers.js";
6
6
  async function runHistoryAuthorAcknowledgeAction(options, command) {
7
7
  const globalOptions = getGlobalOptions(command);
8
8
  const rawEvents = Array.isArray(options.event)
9
9
  ? options.event
10
10
  : [];
11
- const allActionable = options.allActionable === true;
12
- const hasExplicitEvents = rawEvents.length > 0;
13
- if (hasExplicitEvents === allActionable) {
14
- throw new PmCliError("Specify exactly one selector: repeat --event or pass --all-actionable.", EXIT_CODE.USAGE, {
15
- code: "history_author_acknowledge_selector_required",
16
- required: "Exactly one of --event or --all-actionable",
17
- examples: [
18
- 'pm history-author-acknowledge --event pm-a1b2:4 --attributed-author agent --reviewer maintainer --reason "Verified provenance"',
19
- 'pm history-author-acknowledge --all-actionable --attributed-author import-agent --reviewer maintainer --reason "Reviewed the complete actionable set"',
20
- ],
21
- });
22
- }
23
- const events = rawEvents.map((value) => {
24
- const separator = value.lastIndexOf(":");
25
- const itemId = value.slice(0, separator).trim();
26
- const line = Number(value.slice(separator + 1));
27
- if (separator < 1 ||
28
- !/^[a-z0-9][a-z0-9-]*$/iu.test(itemId) ||
29
- !Number.isSafeInteger(line) ||
30
- line < 1) {
31
- throw new PmCliError(`history-author-acknowledge --event expects <item-id>:<one-based-line>, received "${value}".`, EXIT_CODE.USAGE);
32
- }
33
- return { item_id: itemId, line };
34
- });
11
+ const selector = resolveUnknownAuthorAcknowledgmentSelector(rawEvents, options.allActionable === true);
35
12
  const result = await acknowledgeUnknownAuthorHistoryEvents(resolvePmRoot(process.cwd(), globalOptions.path), {
36
- events,
37
- all_actionable: allActionable,
13
+ events: selector.events,
14
+ all_actionable: selector.all_actionable,
38
15
  attributed_author: readOptionString(options, "attributedAuthor"),
39
16
  reviewer: readOptionString(options, "reviewer"),
40
17
  reason: readOptionString(options, "reason"),
@@ -54,4 +31,4 @@ export function registerHistoryAuthorAcknowledgeCommand(program) {
54
31
  .action(runHistoryAuthorAcknowledgeAction);
55
32
  }
56
33
  //# sourceMappingURL=register-history-author.js.map
57
- //# debugId=d04ac41f-796d-5ccb-9e8e-cfa82c845f25
34
+ //# debugId=50a7ce23-2abf-5240-b426-b73cb704e329