@holmes-lab/holmes-kit 0.39.0 → 0.40.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (325) hide show
  1. package/CHANGELOG.md +578 -6
  2. package/README.md +120 -41
  3. package/dist/.build-id +1 -1
  4. package/dist/holmes/admission/core/admission-policy.d.ts +37 -0
  5. package/dist/holmes/admission/core/admission-policy.js +147 -0
  6. package/dist/holmes/admission/core/bounded-reader.d.ts +56 -0
  7. package/dist/holmes/admission/core/bounded-reader.js +135 -0
  8. package/dist/holmes/admission/core/change-classifier.d.ts +34 -0
  9. package/dist/holmes/admission/core/change-classifier.js +278 -0
  10. package/dist/holmes/admission/core/config-loader.d.ts +30 -0
  11. package/dist/holmes/admission/core/config-loader.js +145 -0
  12. package/dist/holmes/admission/core/event-judgement.d.ts +37 -0
  13. package/dist/holmes/admission/core/event-judgement.js +251 -0
  14. package/dist/holmes/admission/core/path-rules.d.ts +35 -0
  15. package/dist/holmes/admission/core/path-rules.js +88 -0
  16. package/dist/holmes/admission/core/pin.d.ts +7 -0
  17. package/dist/holmes/admission/core/pin.js +29 -0
  18. package/dist/holmes/admission/core/ports.d.ts +48 -0
  19. package/dist/holmes/admission/core/ports.js +11 -0
  20. package/dist/holmes/admission/core/range-resolver.d.ts +32 -0
  21. package/dist/holmes/admission/core/range-resolver.js +51 -0
  22. package/dist/holmes/admission/core/self-containment.d.ts +1 -0
  23. package/dist/holmes/admission/core/self-containment.js +125 -0
  24. package/dist/holmes/admission/core/signature-source.d.ts +9 -0
  25. package/dist/holmes/admission/core/signature-source.js +4 -0
  26. package/dist/holmes/admission/core/transition-planner.d.ts +15 -0
  27. package/dist/holmes/admission/core/transition-planner.js +14 -0
  28. package/dist/holmes/admission/core/verdict.d.ts +38 -0
  29. package/dist/holmes/admission/core/verdict.js +17 -0
  30. package/dist/holmes/admission/core/wiring.d.ts +44 -0
  31. package/dist/holmes/admission/core/wiring.js +618 -0
  32. package/dist/holmes/admission/forge/git-object-port.d.ts +4 -0
  33. package/dist/holmes/admission/forge/git-object-port.js +132 -0
  34. package/dist/holmes/assoc/assoc-arm.d.ts +1 -1
  35. package/dist/holmes/assoc/assoc-arm.js +1 -1
  36. package/dist/holmes/cli/agents.d.ts +8 -0
  37. package/dist/holmes/cli/agents.js +9 -5
  38. package/dist/holmes/cli/approve-cli.d.ts +2 -0
  39. package/dist/holmes/cli/approve-cli.js +392 -0
  40. package/dist/holmes/cli/approve-ref.d.ts +13 -7
  41. package/dist/holmes/cli/approve-ref.js +30 -10
  42. package/dist/holmes/cli/approve-status.d.ts +26 -2
  43. package/dist/holmes/cli/approve-status.js +98 -18
  44. package/dist/holmes/cli/approve-watch.d.ts +5 -0
  45. package/dist/holmes/cli/approve-watch.js +10 -5
  46. package/dist/holmes/cli/approve.d.ts +49 -13
  47. package/dist/holmes/cli/approve.js +249 -67
  48. package/dist/holmes/cli/attest.js +2 -1
  49. package/dist/holmes/cli/autonomy.d.ts +4 -1
  50. package/dist/holmes/cli/autonomy.js +17 -10
  51. package/dist/holmes/cli/codex-oracle.d.ts +11 -0
  52. package/dist/holmes/cli/codex-oracle.js +5 -1
  53. package/dist/holmes/cli/codex-toml.d.ts +10 -0
  54. package/dist/holmes/cli/codex-toml.js +36 -2
  55. package/dist/holmes/cli/doctor-boundary.d.ts +76 -0
  56. package/dist/holmes/cli/doctor-boundary.js +308 -0
  57. package/dist/holmes/cli/doctor-locks.d.ts +15 -0
  58. package/dist/holmes/cli/doctor-locks.js +119 -0
  59. package/dist/holmes/cli/doctor.d.ts +2 -0
  60. package/dist/holmes/cli/doctor.js +34 -5
  61. package/dist/holmes/cli/flags.d.ts +23 -0
  62. package/dist/holmes/cli/flags.js +89 -0
  63. package/dist/holmes/cli/index.d.ts +5 -1
  64. package/dist/holmes/cli/index.js +226 -442
  65. package/dist/holmes/cli/init.js +33 -0
  66. package/dist/holmes/cli/interactive-prompt.d.ts +39 -2
  67. package/dist/holmes/cli/interactive-prompt.js +98 -16
  68. package/dist/holmes/cli/lock-recover.d.ts +5 -0
  69. package/dist/holmes/cli/lock-recover.js +126 -0
  70. package/dist/holmes/cli/mcp-processes.js +1 -1
  71. package/dist/holmes/cli/release-docs.js +1 -1
  72. package/dist/holmes/cli/run-exec.d.ts +141 -0
  73. package/dist/holmes/cli/run-exec.js +1435 -0
  74. package/dist/holmes/cli/run-provision.d.ts +3 -1
  75. package/dist/holmes/cli/run-provision.js +255 -44
  76. package/dist/holmes/cli/run-wiring.d.ts +69 -0
  77. package/dist/holmes/cli/run-wiring.js +270 -0
  78. package/dist/holmes/cli/run.d.ts +21 -0
  79. package/dist/holmes/cli/run.js +341 -92
  80. package/dist/holmes/cli/runtime-binding-approval.js +32 -19
  81. package/dist/holmes/cli/screen-safe.d.ts +3 -92
  82. package/dist/holmes/cli/screen-safe.js +18 -756
  83. package/dist/holmes/config/config.d.ts +19 -0
  84. package/dist/holmes/config/config.js +18 -3
  85. package/dist/holmes/cpg/foundation/language-matrix.js +2 -2
  86. package/dist/holmes/cpg/import-resolver.js +1 -1
  87. package/dist/holmes/governance/approval-decisions.d.ts +47 -0
  88. package/dist/holmes/governance/approval-decisions.js +29 -0
  89. package/dist/holmes/governance/approval-grants.d.ts +220 -1
  90. package/dist/holmes/governance/approval-grants.js +612 -33
  91. package/dist/holmes/governance/approval-queue.d.ts +26 -0
  92. package/dist/holmes/governance/approval-queue.js +109 -11
  93. package/dist/holmes/governance/approval-spend.d.ts +95 -0
  94. package/dist/holmes/governance/approval-spend.js +191 -0
  95. package/dist/holmes/governance/autonomous-shell.d.ts +61 -0
  96. package/dist/holmes/governance/autonomous-shell.js +332 -0
  97. package/dist/holmes/governance/autonomy.d.ts +12 -0
  98. package/dist/holmes/governance/autonomy.js +51 -15
  99. package/dist/holmes/governance/constitution.d.ts +5 -0
  100. package/dist/holmes/governance/constitution.js +32 -12
  101. package/dist/holmes/governance/full-autonomy.d.ts +10 -0
  102. package/dist/holmes/governance/full-autonomy.js +103 -7
  103. package/dist/holmes/governance/harness-catalog.d.ts +103 -0
  104. package/dist/holmes/governance/harness-catalog.js +348 -0
  105. package/dist/holmes/governance/human-channel.d.ts +38 -0
  106. package/dist/holmes/governance/human-channel.js +49 -0
  107. package/dist/holmes/governance/install-manifest.d.ts +22 -0
  108. package/dist/holmes/governance/install-manifest.js +160 -0
  109. package/dist/holmes/governance/ledger-rechain.js +2 -0
  110. package/dist/holmes/governance/ledger-store.conformance.d.ts +7 -1
  111. package/dist/holmes/governance/ledger-store.conformance.js +66 -0
  112. package/dist/holmes/governance/ledger-store.d.ts +88 -11
  113. package/dist/holmes/governance/ledger-store.js +186 -8
  114. package/dist/holmes/governance/provenance-chain.d.ts +16 -4
  115. package/dist/holmes/governance/provenance-chain.js +19 -4
  116. package/dist/holmes/governance/provenance-ledger.d.ts +6 -3
  117. package/dist/holmes/governance/provenance-ledger.js +53 -18
  118. package/dist/holmes/governance/push-gate-runner.d.ts +2 -0
  119. package/dist/holmes/governance/push-gate-runner.js +50 -9
  120. package/dist/holmes/governance/push-gate.d.ts +13 -2
  121. package/dist/holmes/governance/push-gate.js +106 -14
  122. package/dist/holmes/governance/recorded-pairs.d.ts +96 -0
  123. package/dist/holmes/governance/recorded-pairs.js +522 -0
  124. package/dist/holmes/governance/replica-id.d.ts +1 -1
  125. package/dist/holmes/governance/replica-id.js +1 -1
  126. package/dist/holmes/governance/spec-seam.d.ts +59 -0
  127. package/dist/holmes/governance/spec-seam.js +587 -0
  128. package/dist/holmes/governance/spend-kinds.d.ts +16 -0
  129. package/dist/holmes/governance/spend-kinds.js +18 -0
  130. package/dist/holmes/guardrail/advisory-line.d.ts +102 -0
  131. package/dist/holmes/guardrail/advisory-line.js +718 -0
  132. package/dist/holmes/guardrail/decision-ledger.d.ts +2 -1
  133. package/dist/holmes/guardrail/decision-ledger.js +2 -1
  134. package/dist/holmes/guardrail/impact-gate.d.ts +7 -0
  135. package/dist/holmes/guardrail/impact-gate.js +33 -6
  136. package/dist/holmes/guardrail/line-continuation.d.ts +8 -0
  137. package/dist/holmes/guardrail/line-continuation.js +39 -0
  138. package/dist/holmes/guardrail/operator-person.d.ts +28 -4
  139. package/dist/holmes/guardrail/operator-person.js +57 -11
  140. package/dist/holmes/guardrail/refusal-codes.d.ts +8 -3
  141. package/dist/holmes/guardrail/refusal-codes.js +64 -10
  142. package/dist/holmes/guardrail/risk-classifier.d.ts +15 -9
  143. package/dist/holmes/guardrail/risk-classifier.js +228 -16
  144. package/dist/holmes/guardrail/risk-gate.d.ts +2 -8
  145. package/dist/holmes/guardrail/risk-gate.js +7 -34
  146. package/dist/holmes/guardrail/risk-types.d.ts +10 -0
  147. package/dist/holmes/guardrail/run-plan-scope.js +3 -1
  148. package/dist/holmes/guardrail/run-refusals.js +24 -8
  149. package/dist/holmes/guardrail/run-stages.d.ts +5 -0
  150. package/dist/holmes/guardrail/run-stages.js +25 -5
  151. package/dist/holmes/guardrail/scope-judgment.js +1 -1
  152. package/dist/holmes/guardrail/shell-words.js +24 -3
  153. package/dist/holmes/guardrail/unresolved-write.d.ts +40 -0
  154. package/dist/holmes/guardrail/unresolved-write.js +556 -0
  155. package/dist/holmes/guardrail/write-target.d.ts +3 -0
  156. package/dist/holmes/guardrail/write-target.js +26 -5
  157. package/dist/holmes/hooks/pre-tool-use.d.ts +116 -1
  158. package/dist/holmes/hooks/pre-tool-use.js +1176 -170
  159. package/dist/holmes/hooks/rtm-refresh-child.d.ts +1 -1
  160. package/dist/holmes/hooks/rtm-refresh-child.js +1 -1
  161. package/dist/holmes/hooks/session-start.js +17 -1
  162. package/dist/holmes/hooks/stop.d.ts +23 -0
  163. package/dist/holmes/hooks/stop.js +86 -33
  164. package/dist/holmes/mcp/approval-adapters.js +3 -1
  165. package/dist/holmes/mcp/approval-commit.js +3 -2
  166. package/dist/holmes/mcp/approval-policy.d.ts +2 -1
  167. package/dist/holmes/mcp/approval-policy.js +3 -1
  168. package/dist/holmes/mcp/handlers/adoption.d.ts +1 -1
  169. package/dist/holmes/mcp/handlers/approval-ask.d.ts +3 -0
  170. package/dist/holmes/mcp/handlers/approval-ask.js +18 -7
  171. package/dist/holmes/mcp/handlers/entity-integration.d.ts +3 -3
  172. package/dist/holmes/mcp/handlers/entity-integration.js +29 -11
  173. package/dist/holmes/mcp/handlers/entity-renumber.d.ts +4 -4
  174. package/dist/holmes/mcp/handlers/entity-renumber.js +29 -11
  175. package/dist/holmes/mcp/handlers/entity-store.d.ts +2 -2
  176. package/dist/holmes/mcp/handlers/entity-store.js +133 -59
  177. package/dist/holmes/mcp/handlers/maintenance-analysis.d.ts +13 -0
  178. package/dist/holmes/mcp/handlers/maintenance-analysis.js +59 -2
  179. package/dist/holmes/mcp/handlers/operator-inspection.d.ts +9 -5
  180. package/dist/holmes/mcp/handlers/operator-inspection.js +79 -16
  181. package/dist/holmes/mcp/handlers/phase-queries.d.ts +1 -1
  182. package/dist/holmes/mcp/handlers/requirement-triage.d.ts +4 -4
  183. package/dist/holmes/mcp/handlers/review-evidence.d.ts +2 -2
  184. package/dist/holmes/mcp/handlers/review-evidence.js +35 -11
  185. package/dist/holmes/mcp/handlers/review-queries.d.ts +5 -0
  186. package/dist/holmes/mcp/handlers/review-queries.js +8 -1
  187. package/dist/holmes/mcp/handlers/review-verdict.d.ts +3 -0
  188. package/dist/holmes/mcp/handlers/review-verdict.js +10 -3
  189. package/dist/holmes/mcp/handlers/risk-assessment.d.ts +7 -2
  190. package/dist/holmes/mcp/handlers/risk-assessment.js +34 -12
  191. package/dist/holmes/mcp/handlers/runtime-binding-tool.d.ts +2 -2
  192. package/dist/holmes/mcp/handlers/slice-orchestration.d.ts +6 -1
  193. package/dist/holmes/mcp/handlers/slice-orchestration.js +14 -1
  194. package/dist/holmes/mcp/handlers/spec-approval.d.ts +15 -3
  195. package/dist/holmes/mcp/handlers/spec-approval.js +32 -5
  196. package/dist/holmes/mcp/handlers/spec-authoring.d.ts +2 -2
  197. package/dist/holmes/mcp/handlers/spec-authoring.js +19 -2
  198. package/dist/holmes/mcp/handlers/spec-lifecycle.d.ts +11 -38
  199. package/dist/holmes/mcp/handlers/spec-lifecycle.js +441 -94
  200. package/dist/holmes/mcp/handlers/spec-queries.d.ts +2 -2
  201. package/dist/holmes/mcp/handlers/taint-screening.d.ts +1 -1
  202. package/dist/holmes/mcp/handlers/taint-screening.js +2 -2
  203. package/dist/holmes/mcp/handlers/test-execution.d.ts +471 -4
  204. package/dist/holmes/mcp/handlers/test-execution.js +199 -21
  205. package/dist/holmes/mcp/handlers/workspace-queries.d.ts +2 -2
  206. package/dist/holmes/mcp/handlers.d.ts +557 -82
  207. package/dist/holmes/mcp/handlers.js +74 -23
  208. package/dist/holmes/mcp/harness-attestation.d.ts +78 -5
  209. package/dist/holmes/mcp/harness-attestation.js +325 -53
  210. package/dist/holmes/mcp/maintenance-analyze.d.ts +6 -1
  211. package/dist/holmes/mcp/maintenance-analyze.js +13 -11
  212. package/dist/holmes/mcp/maintenance-evidence.d.ts +9 -0
  213. package/dist/holmes/mcp/maintenance-evidence.js +35 -3
  214. package/dist/holmes/mcp/requirement-triage-evidence.js +22 -13
  215. package/dist/holmes/mcp/server-staleness.js +1 -1
  216. package/dist/holmes/mcp/server.js +9 -8
  217. package/dist/holmes/mcp/spec-id-guard.js +1 -1
  218. package/dist/holmes/mcp/tool-schemas.d.ts +13 -0
  219. package/dist/holmes/mcp/tool-schemas.js +42 -9
  220. package/dist/holmes/project/act-root.d.ts +19 -0
  221. package/dist/holmes/project/act-root.js +100 -0
  222. package/dist/holmes/project/baseline.d.ts +15 -2
  223. package/dist/holmes/project/baseline.js +14 -8
  224. package/dist/holmes/project/bounded-group.d.ts +47 -0
  225. package/dist/holmes/project/bounded-group.js +140 -0
  226. package/dist/holmes/project/bounded-io.d.ts +51 -2
  227. package/dist/holmes/project/bounded-io.js +140 -6
  228. package/dist/holmes/project/change-source.d.ts +4 -0
  229. package/dist/holmes/project/change-source.js +14 -6
  230. package/dist/holmes/project/instance-id.d.ts +10 -0
  231. package/dist/holmes/project/instance-id.js +233 -0
  232. package/dist/holmes/project/machine-identity.d.ts +25 -0
  233. package/dist/holmes/project/machine-identity.js +133 -0
  234. package/dist/holmes/project/owned-lock.d.ts +84 -0
  235. package/dist/holmes/project/owned-lock.js +263 -0
  236. package/dist/holmes/project/plain-lock-fs.d.ts +2 -0
  237. package/dist/holmes/project/plain-lock-fs.js +126 -0
  238. package/dist/holmes/project/request-lock.d.ts +85 -0
  239. package/dist/holmes/project/request-lock.js +459 -0
  240. package/dist/holmes/project/root.d.ts +12 -4
  241. package/dist/holmes/project/root.js +29 -8
  242. package/dist/holmes/project/run-records.d.ts +19 -0
  243. package/dist/holmes/project/run-records.js +94 -12
  244. package/dist/holmes/project/screen-text.d.ts +94 -0
  245. package/dist/holmes/project/screen-text.js +763 -0
  246. package/dist/holmes/project/spend-lock.d.ts +82 -0
  247. package/dist/holmes/project/spend-lock.js +413 -0
  248. package/dist/holmes/refresh/freshness-coordinator.d.ts +1 -1
  249. package/dist/holmes/refresh/freshness-coordinator.js +1 -1
  250. package/dist/holmes/review/condition-hunk-replay.js +4 -2
  251. package/dist/holmes/review/confidence-calibration.d.ts +1 -1
  252. package/dist/holmes/review/confidence-calibration.js +1 -1
  253. package/dist/holmes/review/content-verify.js +1 -1
  254. package/dist/holmes/review/evidence-mode.d.ts +21 -0
  255. package/dist/holmes/review/evidence-mode.js +33 -0
  256. package/dist/holmes/review/head-worktree.d.ts +55 -0
  257. package/dist/holmes/review/head-worktree.js +329 -0
  258. package/dist/holmes/review/hop-ablation.d.ts +4 -4
  259. package/dist/holmes/review/hop-ablation.js +5 -5
  260. package/dist/holmes/review/mrp.js +13 -3
  261. package/dist/holmes/review/point-in-time-replay.js +12 -3
  262. package/dist/holmes/review/rank-diagnosis.d.ts +2 -2
  263. package/dist/holmes/review/rank-diagnosis.js +1 -1
  264. package/dist/holmes/review/replay-corpus.d.ts +10 -4
  265. package/dist/holmes/review/replay-corpus.js +25 -9
  266. package/dist/holmes/review/requirement-triage.js +2 -2
  267. package/dist/holmes/review/run-provenance.d.ts +45 -0
  268. package/dist/holmes/review/run-provenance.js +314 -0
  269. package/dist/holmes/review/semantic-arm.d.ts +3 -3
  270. package/dist/holmes/review/semantic-arm.js +3 -3
  271. package/dist/holmes/review/test-evidence.d.ts +174 -0
  272. package/dist/holmes/review/test-evidence.js +330 -2
  273. package/dist/holmes/review/test-outcomes.js +3 -1
  274. package/dist/holmes/review/test-reports.d.ts +94 -0
  275. package/dist/holmes/review/test-reports.js +382 -0
  276. package/dist/holmes/review/test-runner.d.ts +180 -58
  277. package/dist/holmes/review/test-runner.js +560 -324
  278. package/dist/holmes/review/test-selection-breadth.js +2 -2
  279. package/dist/holmes/review/test-units.d.ts +159 -0
  280. package/dist/holmes/review/test-units.js +814 -0
  281. package/dist/holmes/review/verdicts.d.ts +105 -8
  282. package/dist/holmes/review/verdicts.js +640 -36
  283. package/dist/holmes/rtm/anchor-census.d.ts +9 -0
  284. package/dist/holmes/rtm/anchor-census.js +151 -0
  285. package/dist/holmes/rtm/anchor-ids.d.ts +25 -1
  286. package/dist/holmes/rtm/anchor-ids.js +45 -2
  287. package/dist/holmes/rtm/comment-ranges.d.ts +2 -0
  288. package/dist/holmes/rtm/comment-ranges.js +104 -0
  289. package/dist/holmes/rtm/counted-tests.d.ts +1 -0
  290. package/dist/holmes/rtm/counted-tests.js +63 -0
  291. package/dist/holmes/rtm/impact-advisory.d.ts +1 -1
  292. package/dist/holmes/rtm/known-defects.js +1 -1
  293. package/dist/holmes/rtm/localize.js +1 -1
  294. package/dist/holmes/rtm/taint-benchmark.d.ts +1 -1
  295. package/dist/holmes/rtm/taint-vocabulary.d.ts +1 -1
  296. package/dist/holmes/rtm/test-scope.d.ts +31 -0
  297. package/dist/holmes/rtm/test-scope.js +166 -5
  298. package/dist/holmes/rtm/trace-gaps.js +1 -1
  299. package/dist/holmes/runtime/dispatch.d.ts +10 -0
  300. package/dist/holmes/runtime/dispatch.js +12 -1
  301. package/dist/holmes/semantic/cloud-usage.d.ts +1 -1
  302. package/dist/holmes/semantic/cloud-usage.js +1 -1
  303. package/dist/holmes/semantic/unreadable-paths.d.ts +1 -1
  304. package/dist/holmes/semantic/unreadable-paths.js +1 -1
  305. package/dist/holmes/spec/approval-blockers.js +1 -1
  306. package/dist/holmes/spec/entity-store.d.ts +6 -1
  307. package/dist/holmes/spec/entity-store.js +16 -2
  308. package/dist/holmes/spec/entity-transaction.d.ts +7 -2
  309. package/dist/holmes/spec/entity-transaction.js +87 -170
  310. package/dist/holmes/spec/spec-store.d.ts +12 -6
  311. package/dist/holmes/spec/spec-store.js +4 -2
  312. package/dist/holmes/spec/spec-types.js +1 -1
  313. package/dist/holmes/spec/succession-guard.d.ts +56 -0
  314. package/dist/holmes/spec/succession-guard.js +187 -0
  315. package/dist/holmes/spec/succession.d.ts +70 -0
  316. package/dist/holmes/spec/succession.js +171 -0
  317. package/dist/holmes/spec/transition-policy.d.ts +2 -2
  318. package/docs/install-guide.md +9 -3
  319. package/docs/language-support.md +78 -0
  320. package/package.json +4 -3
  321. package/playbooks/author-slice/PLAYBOOK.md +1 -1
  322. package/playbooks/promote-slice/PLAYBOOK.md +5 -1
  323. package/playbooks/publish/PLAYBOOK.md +47 -34
  324. package/dist/holmes/review/manual-baseline.d.ts +0 -209
  325. package/dist/holmes/review/manual-baseline.js +0 -2847
@@ -43,6 +43,6 @@ export declare function createTaintScreeningHandlers(context: TaintScreeningCont
43
43
  truncated: number;
44
44
  pairs: import("../../rtm/taint").TaintPair[];
45
45
  ok?: undefined;
46
- reason?: undefined;
46
+ readonly reason?: undefined;
47
47
  }>;
48
48
  };
@@ -34,7 +34,7 @@ var __importStar = (this && this.__importStar) || (function () {
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.createTaintScreeningHandlers = createTaintScreeningHandlers;
37
- // @implements A-SPEC-611, A-SPEC-100.2, A-SPEC-128, A-SPEC-138, A-SPEC-140.2, A-SPEC-189, A-SPEC-461, A-SPEC-512.2, A-SPEC-513.1, A-SPEC-524.1
37
+ // @implements A-SPEC-611, A-SPEC-100.2, A-SPEC-128, A-SPEC-138, A-SPEC-140.2, A-SPEC-189, A-SPEC-461, A-SPEC-512.2, A-SPEC-513.1, A-SPEC-524.1, A-SPEC-794.56
38
38
  const fs = __importStar(require("node:fs"));
39
39
  const path = __importStar(require("node:path"));
40
40
  const rtm_graph_1 = require("../../rtm/rtm-graph");
@@ -79,7 +79,7 @@ function createTaintScreeningHandlers(context) {
79
79
  const { filterFindingsForFile } = require('../../rtm/reaching-def-filter');
80
80
  // @implements A-SPEC-513.1 — vocabulary is SELECTED per file language, never unioned:
81
81
  // Python's `input(` must not taint a TypeScript `input`, and `req.body` means nothing in
82
- // Python. Measured on jarvis: the shipped (JS) list missed `subprocess.run`, `os.environ`
82
+ // Python. Measured on the consumer corpus: the shipped (JS) list missed `subprocess.run`, `os.environ`
83
83
  // and `input(` entirely, so a Python repository could only ever report zero.
84
84
  const { vocabularyFor } = require('../../rtm/taint-vocabulary');
85
85
  const parser = new TreeSitterTsParser();
@@ -3,6 +3,8 @@ import { ScannedFile } from '../../cpg/cpg-scanner';
3
3
  import { ChangeSourceInfo } from '../../project/change-source';
4
4
  export interface TestExecutionContext {
5
5
  defaultBaseline: string;
6
+ /** @implements A-SPEC-466.2 — a deliberate refusal, so the caller gets a handler refusal, not an internal error. */
7
+ refusal(reason: string): Error;
6
8
  deriveChangedContext(root: string, args: {
7
9
  base?: string;
8
10
  head?: string;
@@ -23,11 +25,14 @@ export interface TestExecutionContext {
23
25
  export declare function createTestExecutionHandlers(context: TestExecutionContext): {
24
26
  test_run(a: {
25
27
  root: string;
26
- base?: string;
27
- head?: string;
28
+ base?: string | null;
29
+ head?: string | null;
28
30
  since?: string;
29
31
  mark?: string;
30
32
  mutate?: string;
33
+ workers?: number;
34
+ timeoutMinutes?: number | null;
35
+ full?: boolean;
31
36
  }): Promise<{
32
37
  mutate: {
33
38
  tspec: string;
@@ -41,7 +46,7 @@ export declare function createTestExecutionHandlers(context: TestExecutionContex
41
46
  applied: boolean;
42
47
  verdict?: "killed" | "survived";
43
48
  mutation: import("../../spec/kills").Mutation;
44
- reason?: undefined;
49
+ readonly reason?: undefined;
45
50
  })[];
46
51
  survivors: import("../../spec/kills").Mutation[];
47
52
  unapplied: {
@@ -49,7 +54,313 @@ export declare function createTestExecutionHandlers(context: TestExecutionContex
49
54
  reason: string;
50
55
  }[];
51
56
  };
57
+ workers: null;
58
+ workersIgnored: "mutate" | undefined;
59
+ timeoutMinutes: number;
60
+ } | {
61
+ worktreeLeft?: string | undefined;
62
+ anchorDiagnostics?: {
63
+ hint: string;
64
+ file: string;
65
+ line: number;
66
+ separator: string;
67
+ dropped: string[];
68
+ }[] | undefined;
69
+ calibrationClosed?: string[] | undefined;
70
+ nextCall?: string | undefined;
71
+ notFullBecause?: string | undefined;
72
+ excludeDirsIgnored?: {
73
+ entry: string;
74
+ reason: string;
75
+ }[] | undefined;
76
+ recordFailed?: string[] | undefined;
77
+ ranIn: "head-worktree";
78
+ worktree: {
79
+ createMs: number;
80
+ prepareMs: number;
81
+ runMs: number;
82
+ };
83
+ notBuilt?: string[] | undefined;
84
+ notDetected?: import("../../review/test-evidence").NotDetected[] | undefined;
85
+ untestedCode?: {
86
+ root: string;
87
+ sample: string[];
88
+ missingBuildFile?: string;
89
+ }[] | undefined;
90
+ notExecuted?: string[] | undefined;
91
+ notTests?: string[] | undefined;
92
+ implementationCount?: number | undefined;
93
+ environment?: {
94
+ ecosystem: string;
95
+ dir: string;
96
+ reason: string;
97
+ }[] | undefined;
98
+ units?: import("../../review/test-runner").UnitResult[] | undefined;
99
+ notRun?: import("../../review/test-evidence").NotRun[] | undefined;
100
+ detected?: string[] | undefined;
101
+ testsRun: number;
102
+ testsRunBy: Record<string, number>;
103
+ scopedEvidenceRecorded?: true | undefined;
104
+ baselineSkipped?: "not a full run" | undefined;
105
+ baselineRecorded?: string | undefined;
106
+ scopeFallback?: "full" | undefined;
107
+ timeoutMinutes: number;
108
+ unresolvedFiles: string[];
109
+ changeSource: ChangeSourceInfo;
110
+ workersIgnoredBy: string[];
111
+ workersIgnored: "nothing ran" | "no jest group";
112
+ tier: import("../../rtm/test-scope").RegressionTier;
113
+ mode: "full" | "scoped" | "noop";
114
+ passed: boolean;
115
+ skipped: boolean;
116
+ ranFiles: string[];
117
+ ranWith: string[];
118
+ executedByAspec: Record<string, number>;
119
+ tail: string;
120
+ workers: number | null;
121
+ mutate?: undefined;
122
+ } | {
123
+ worktreeLeft?: string | undefined;
124
+ anchorDiagnostics?: {
125
+ hint: string;
126
+ file: string;
127
+ line: number;
128
+ separator: string;
129
+ dropped: string[];
130
+ }[] | undefined;
131
+ calibrationClosed?: string[] | undefined;
132
+ nextCall?: string | undefined;
133
+ notFullBecause?: string | undefined;
134
+ excludeDirsIgnored?: {
135
+ entry: string;
136
+ reason: string;
137
+ }[] | undefined;
138
+ recordFailed?: string[] | undefined;
139
+ ranIn?: undefined;
140
+ worktree?: undefined;
141
+ notBuilt?: string[] | undefined;
142
+ notDetected?: import("../../review/test-evidence").NotDetected[] | undefined;
143
+ untestedCode?: {
144
+ root: string;
145
+ sample: string[];
146
+ missingBuildFile?: string;
147
+ }[] | undefined;
148
+ notExecuted?: string[] | undefined;
149
+ notTests?: string[] | undefined;
150
+ implementationCount?: number | undefined;
151
+ environment?: {
152
+ ecosystem: string;
153
+ dir: string;
154
+ reason: string;
155
+ }[] | undefined;
156
+ units?: import("../../review/test-runner").UnitResult[] | undefined;
157
+ notRun?: import("../../review/test-evidence").NotRun[] | undefined;
158
+ detected?: string[] | undefined;
159
+ testsRun: number;
160
+ testsRunBy: Record<string, number>;
161
+ scopedEvidenceRecorded?: true | undefined;
162
+ baselineSkipped?: "not a full run" | undefined;
163
+ baselineRecorded?: string | undefined;
164
+ scopeFallback?: "full" | undefined;
165
+ timeoutMinutes: number;
166
+ unresolvedFiles: string[];
167
+ changeSource: ChangeSourceInfo;
168
+ workersIgnoredBy: string[];
169
+ workersIgnored: "nothing ran" | "no jest group";
170
+ tier: import("../../rtm/test-scope").RegressionTier;
171
+ mode: "full" | "scoped" | "noop";
172
+ passed: boolean;
173
+ skipped: boolean;
174
+ ranFiles: string[];
175
+ ranWith: string[];
176
+ executedByAspec: Record<string, number>;
177
+ tail: string;
178
+ workers: number | null;
179
+ mutate?: undefined;
180
+ } | {
181
+ worktreeLeft?: string | undefined;
182
+ anchorDiagnostics?: {
183
+ hint: string;
184
+ file: string;
185
+ line: number;
186
+ separator: string;
187
+ dropped: string[];
188
+ }[] | undefined;
189
+ calibrationClosed?: string[] | undefined;
190
+ nextCall?: string | undefined;
191
+ notFullBecause?: string | undefined;
192
+ excludeDirsIgnored?: {
193
+ entry: string;
194
+ reason: string;
195
+ }[] | undefined;
196
+ recordFailed?: string[] | undefined;
197
+ ranIn: "head-worktree";
198
+ worktree: {
199
+ createMs: number;
200
+ prepareMs: number;
201
+ runMs: number;
202
+ };
203
+ notBuilt?: string[] | undefined;
204
+ notDetected?: import("../../review/test-evidence").NotDetected[] | undefined;
205
+ untestedCode?: {
206
+ root: string;
207
+ sample: string[];
208
+ missingBuildFile?: string;
209
+ }[] | undefined;
210
+ notExecuted?: string[] | undefined;
211
+ notTests?: string[] | undefined;
212
+ implementationCount?: number | undefined;
213
+ environment?: {
214
+ ecosystem: string;
215
+ dir: string;
216
+ reason: string;
217
+ }[] | undefined;
218
+ units?: import("../../review/test-runner").UnitResult[] | undefined;
219
+ notRun?: import("../../review/test-evidence").NotRun[] | undefined;
220
+ detected?: string[] | undefined;
221
+ testsRun: number;
222
+ testsRunBy: Record<string, number>;
223
+ scopedEvidenceRecorded?: true | undefined;
224
+ baselineSkipped?: "not a full run" | undefined;
225
+ baselineRecorded?: string | undefined;
226
+ scopeFallback?: "full" | undefined;
227
+ timeoutMinutes: number;
228
+ unresolvedFiles: string[];
229
+ changeSource: ChangeSourceInfo;
230
+ workersIgnoredBy?: undefined;
231
+ workersIgnored: "nothing ran" | "no jest group";
232
+ tier: import("../../rtm/test-scope").RegressionTier;
233
+ mode: "full" | "scoped" | "noop";
234
+ passed: boolean;
235
+ skipped: boolean;
236
+ ranFiles: string[];
237
+ ranWith: string[];
238
+ executedByAspec: Record<string, number>;
239
+ tail: string;
240
+ workers: number | null;
241
+ mutate?: undefined;
242
+ } | {
243
+ worktreeLeft?: string | undefined;
244
+ anchorDiagnostics?: {
245
+ hint: string;
246
+ file: string;
247
+ line: number;
248
+ separator: string;
249
+ dropped: string[];
250
+ }[] | undefined;
251
+ calibrationClosed?: string[] | undefined;
252
+ nextCall?: string | undefined;
253
+ notFullBecause?: string | undefined;
254
+ excludeDirsIgnored?: {
255
+ entry: string;
256
+ reason: string;
257
+ }[] | undefined;
258
+ recordFailed?: string[] | undefined;
259
+ ranIn?: undefined;
260
+ worktree?: undefined;
261
+ notBuilt?: string[] | undefined;
262
+ notDetected?: import("../../review/test-evidence").NotDetected[] | undefined;
263
+ untestedCode?: {
264
+ root: string;
265
+ sample: string[];
266
+ missingBuildFile?: string;
267
+ }[] | undefined;
268
+ notExecuted?: string[] | undefined;
269
+ notTests?: string[] | undefined;
270
+ implementationCount?: number | undefined;
271
+ environment?: {
272
+ ecosystem: string;
273
+ dir: string;
274
+ reason: string;
275
+ }[] | undefined;
276
+ units?: import("../../review/test-runner").UnitResult[] | undefined;
277
+ notRun?: import("../../review/test-evidence").NotRun[] | undefined;
278
+ detected?: string[] | undefined;
279
+ testsRun: number;
280
+ testsRunBy: Record<string, number>;
281
+ scopedEvidenceRecorded?: true | undefined;
282
+ baselineSkipped?: "not a full run" | undefined;
283
+ baselineRecorded?: string | undefined;
284
+ scopeFallback?: "full" | undefined;
285
+ timeoutMinutes: number;
286
+ unresolvedFiles: string[];
287
+ changeSource: ChangeSourceInfo;
288
+ workersIgnoredBy?: undefined;
289
+ workersIgnored: "nothing ran" | "no jest group";
290
+ tier: import("../../rtm/test-scope").RegressionTier;
291
+ mode: "full" | "scoped" | "noop";
292
+ passed: boolean;
293
+ skipped: boolean;
294
+ ranFiles: string[];
295
+ ranWith: string[];
296
+ executedByAspec: Record<string, number>;
297
+ tail: string;
298
+ workers: number | null;
299
+ mutate?: undefined;
300
+ } | {
301
+ worktreeLeft?: string | undefined;
302
+ anchorDiagnostics?: {
303
+ hint: string;
304
+ file: string;
305
+ line: number;
306
+ separator: string;
307
+ dropped: string[];
308
+ }[] | undefined;
309
+ calibrationClosed?: string[] | undefined;
310
+ nextCall?: string | undefined;
311
+ notFullBecause?: string | undefined;
312
+ excludeDirsIgnored?: {
313
+ entry: string;
314
+ reason: string;
315
+ }[] | undefined;
316
+ recordFailed?: string[] | undefined;
317
+ ranIn: "head-worktree";
318
+ worktree: {
319
+ createMs: number;
320
+ prepareMs: number;
321
+ runMs: number;
322
+ };
323
+ notBuilt?: string[] | undefined;
324
+ notDetected?: import("../../review/test-evidence").NotDetected[] | undefined;
325
+ untestedCode?: {
326
+ root: string;
327
+ sample: string[];
328
+ missingBuildFile?: string;
329
+ }[] | undefined;
330
+ notExecuted?: string[] | undefined;
331
+ notTests?: string[] | undefined;
332
+ implementationCount?: number | undefined;
333
+ environment?: {
334
+ ecosystem: string;
335
+ dir: string;
336
+ reason: string;
337
+ }[] | undefined;
338
+ units?: import("../../review/test-runner").UnitResult[] | undefined;
339
+ notRun?: import("../../review/test-evidence").NotRun[] | undefined;
340
+ detected?: string[] | undefined;
341
+ testsRun: number;
342
+ testsRunBy: Record<string, number>;
343
+ scopedEvidenceRecorded?: true | undefined;
344
+ baselineSkipped?: "not a full run" | undefined;
345
+ baselineRecorded?: string | undefined;
346
+ scopeFallback?: "full" | undefined;
347
+ timeoutMinutes: number;
348
+ unresolvedFiles: string[];
349
+ changeSource: ChangeSourceInfo;
350
+ workersIgnoredBy: string[];
351
+ workersIgnored?: undefined;
352
+ tier: import("../../rtm/test-scope").RegressionTier;
353
+ mode: "full" | "scoped" | "noop";
354
+ passed: boolean;
355
+ skipped: boolean;
356
+ ranFiles: string[];
357
+ ranWith: string[];
358
+ executedByAspec: Record<string, number>;
359
+ tail: string;
360
+ workers: number | null;
361
+ mutate?: undefined;
52
362
  } | {
363
+ worktreeLeft?: string | undefined;
53
364
  anchorDiagnostics?: {
54
365
  hint: string;
55
366
  file: string;
@@ -58,17 +369,173 @@ export declare function createTestExecutionHandlers(context: TestExecutionContex
58
369
  dropped: string[];
59
370
  }[] | undefined;
60
371
  calibrationClosed?: string[] | undefined;
372
+ nextCall?: string | undefined;
373
+ notFullBecause?: string | undefined;
374
+ excludeDirsIgnored?: {
375
+ entry: string;
376
+ reason: string;
377
+ }[] | undefined;
378
+ recordFailed?: string[] | undefined;
379
+ ranIn?: undefined;
380
+ worktree?: undefined;
381
+ notBuilt?: string[] | undefined;
382
+ notDetected?: import("../../review/test-evidence").NotDetected[] | undefined;
383
+ untestedCode?: {
384
+ root: string;
385
+ sample: string[];
386
+ missingBuildFile?: string;
387
+ }[] | undefined;
388
+ notExecuted?: string[] | undefined;
389
+ notTests?: string[] | undefined;
390
+ implementationCount?: number | undefined;
391
+ environment?: {
392
+ ecosystem: string;
393
+ dir: string;
394
+ reason: string;
395
+ }[] | undefined;
396
+ units?: import("../../review/test-runner").UnitResult[] | undefined;
397
+ notRun?: import("../../review/test-evidence").NotRun[] | undefined;
398
+ detected?: string[] | undefined;
399
+ testsRun: number;
400
+ testsRunBy: Record<string, number>;
401
+ scopedEvidenceRecorded?: true | undefined;
402
+ baselineSkipped?: "not a full run" | undefined;
61
403
  baselineRecorded?: string | undefined;
62
404
  scopeFallback?: "full" | undefined;
405
+ timeoutMinutes: number;
406
+ unresolvedFiles: string[];
407
+ changeSource: ChangeSourceInfo;
408
+ workersIgnoredBy: string[];
409
+ workersIgnored?: undefined;
63
410
  tier: import("../../rtm/test-scope").RegressionTier;
64
- mode: "full" | "noop" | "scoped";
411
+ mode: "full" | "scoped" | "noop";
65
412
  passed: boolean;
66
413
  skipped: boolean;
67
414
  ranFiles: string[];
415
+ ranWith: string[];
68
416
  executedByAspec: Record<string, number>;
69
417
  tail: string;
418
+ workers: number | null;
419
+ mutate?: undefined;
420
+ } | {
421
+ worktreeLeft?: string | undefined;
422
+ anchorDiagnostics?: {
423
+ hint: string;
424
+ file: string;
425
+ line: number;
426
+ separator: string;
427
+ dropped: string[];
428
+ }[] | undefined;
429
+ calibrationClosed?: string[] | undefined;
430
+ nextCall?: string | undefined;
431
+ notFullBecause?: string | undefined;
432
+ excludeDirsIgnored?: {
433
+ entry: string;
434
+ reason: string;
435
+ }[] | undefined;
436
+ recordFailed?: string[] | undefined;
437
+ ranIn: "head-worktree";
438
+ worktree: {
439
+ createMs: number;
440
+ prepareMs: number;
441
+ runMs: number;
442
+ };
443
+ notBuilt?: string[] | undefined;
444
+ notDetected?: import("../../review/test-evidence").NotDetected[] | undefined;
445
+ untestedCode?: {
446
+ root: string;
447
+ sample: string[];
448
+ missingBuildFile?: string;
449
+ }[] | undefined;
450
+ notExecuted?: string[] | undefined;
451
+ notTests?: string[] | undefined;
452
+ implementationCount?: number | undefined;
453
+ environment?: {
454
+ ecosystem: string;
455
+ dir: string;
456
+ reason: string;
457
+ }[] | undefined;
458
+ units?: import("../../review/test-runner").UnitResult[] | undefined;
459
+ notRun?: import("../../review/test-evidence").NotRun[] | undefined;
460
+ detected?: string[] | undefined;
461
+ testsRun: number;
462
+ testsRunBy: Record<string, number>;
463
+ scopedEvidenceRecorded?: true | undefined;
464
+ baselineSkipped?: "not a full run" | undefined;
465
+ baselineRecorded?: string | undefined;
466
+ scopeFallback?: "full" | undefined;
467
+ timeoutMinutes: number;
468
+ unresolvedFiles: string[];
469
+ changeSource: ChangeSourceInfo;
470
+ workersIgnoredBy?: undefined;
471
+ workersIgnored?: undefined;
472
+ tier: import("../../rtm/test-scope").RegressionTier;
473
+ mode: "full" | "scoped" | "noop";
474
+ passed: boolean;
475
+ skipped: boolean;
476
+ ranFiles: string[];
477
+ ranWith: string[];
478
+ executedByAspec: Record<string, number>;
479
+ tail: string;
480
+ workers: number | null;
481
+ mutate?: undefined;
482
+ } | {
483
+ worktreeLeft?: string | undefined;
484
+ anchorDiagnostics?: {
485
+ hint: string;
486
+ file: string;
487
+ line: number;
488
+ separator: string;
489
+ dropped: string[];
490
+ }[] | undefined;
491
+ calibrationClosed?: string[] | undefined;
492
+ nextCall?: string | undefined;
493
+ notFullBecause?: string | undefined;
494
+ excludeDirsIgnored?: {
495
+ entry: string;
496
+ reason: string;
497
+ }[] | undefined;
498
+ recordFailed?: string[] | undefined;
499
+ ranIn?: undefined;
500
+ worktree?: undefined;
501
+ notBuilt?: string[] | undefined;
502
+ notDetected?: import("../../review/test-evidence").NotDetected[] | undefined;
503
+ untestedCode?: {
504
+ root: string;
505
+ sample: string[];
506
+ missingBuildFile?: string;
507
+ }[] | undefined;
508
+ notExecuted?: string[] | undefined;
509
+ notTests?: string[] | undefined;
510
+ implementationCount?: number | undefined;
511
+ environment?: {
512
+ ecosystem: string;
513
+ dir: string;
514
+ reason: string;
515
+ }[] | undefined;
516
+ units?: import("../../review/test-runner").UnitResult[] | undefined;
517
+ notRun?: import("../../review/test-evidence").NotRun[] | undefined;
518
+ detected?: string[] | undefined;
519
+ testsRun: number;
520
+ testsRunBy: Record<string, number>;
521
+ scopedEvidenceRecorded?: true | undefined;
522
+ baselineSkipped?: "not a full run" | undefined;
523
+ baselineRecorded?: string | undefined;
524
+ scopeFallback?: "full" | undefined;
525
+ timeoutMinutes: number;
70
526
  unresolvedFiles: string[];
71
527
  changeSource: ChangeSourceInfo;
528
+ workersIgnoredBy?: undefined;
529
+ workersIgnored?: undefined;
530
+ tier: import("../../rtm/test-scope").RegressionTier;
531
+ mode: "full" | "scoped" | "noop";
532
+ passed: boolean;
533
+ skipped: boolean;
534
+ ranFiles: string[];
535
+ ranWith: string[];
536
+ executedByAspec: Record<string, number>;
537
+ tail: string;
538
+ workers: number | null;
72
539
  mutate?: undefined;
73
540
  }>;
74
541
  };