smol-symphony 0.3.0 → 0.3.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 (772) hide show
  1. package/dist/bin/symphony.js.map +1 -0
  2. package/dist/core/actions/context.js.map +1 -0
  3. package/dist/core/actions/parse.js.map +1 -0
  4. package/dist/core/actions/plan.js.map +1 -0
  5. package/dist/core/actions/predicates.js.map +1 -0
  6. package/dist/core/actions/run-fold.js.map +1 -0
  7. package/dist/core/actions/template.js.map +1 -0
  8. package/dist/core/cli/args.js.map +1 -0
  9. package/dist/core/coerce.js.map +1 -0
  10. package/dist/core/credential/account-id.js.map +1 -0
  11. package/dist/core/credential/adapter-config.js.map +1 -0
  12. package/dist/core/credential/availability.js.map +1 -0
  13. package/dist/core/credential/extract.js.map +1 -0
  14. package/dist/core/credential/fake-creds.js.map +1 -0
  15. package/dist/core/credential/identity.js.map +1 -0
  16. package/dist/core/credential/shape.js.map +1 -0
  17. package/dist/core/credential/strings.js.map +1 -0
  18. package/dist/core/doctor/checks.js.map +1 -0
  19. package/dist/core/git/result.js.map +1 -0
  20. package/dist/core/http/decisions.js.map +1 -0
  21. package/dist/core/http/render.js.map +1 -0
  22. package/dist/core/http/routes.js.map +1 -0
  23. package/dist/core/http/views.js.map +1 -0
  24. package/dist/core/image/managed-image.js.map +1 -0
  25. package/dist/core/issue/file.js.map +1 -0
  26. package/dist/core/issue/parse.js.map +1 -0
  27. package/dist/core/mcp/dispatch.js.map +1 -0
  28. package/dist/core/mcp/post-move.js.map +1 -0
  29. package/dist/core/mcp/protocol.js.map +1 -0
  30. package/dist/core/mcp/url.js.map +1 -0
  31. package/dist/core/path.js.map +1 -0
  32. package/dist/core/reconcile/image-decide.js.map +1 -0
  33. package/dist/core/reconcile/ledger.js.map +1 -0
  34. package/dist/core/reconcile/pr-classify.js.map +1 -0
  35. package/dist/core/reconcile/pr-decide.js.map +1 -0
  36. package/dist/core/reconcile/pr-loop.js.map +1 -0
  37. package/dist/core/reconcile/pr-notes.js.map +1 -0
  38. package/dist/core/reconcile/vm-decide.js.map +1 -0
  39. package/dist/core/reconcile/vm-reap.js.map +1 -0
  40. package/dist/core/reconcile/workspace-decide.js.map +1 -0
  41. package/dist/core/runlog/summary.js.map +1 -0
  42. package/dist/core/runner/dispatch-config.js.map +1 -0
  43. package/dist/core/runner/injection.js.map +1 -0
  44. package/dist/core/runner/mise.js.map +1 -0
  45. package/dist/core/runner/prompt.js.map +1 -0
  46. package/dist/core/runner/turn.js.map +1 -0
  47. package/dist/core/runner/vm-plan.js.map +1 -0
  48. package/dist/core/schedule/admission.js.map +1 -0
  49. package/dist/core/schedule/circuit-breaker.js.map +1 -0
  50. package/dist/core/schedule/eligibility.js.map +1 -0
  51. package/dist/core/schedule/reconcile-issue.js.map +1 -0
  52. package/dist/core/schedule/retry.js.map +1 -0
  53. package/dist/core/schedule/sleep-cycle.js.map +1 -0
  54. package/dist/core/schedule/slots.js.map +1 -0
  55. package/dist/core/schedule/tick.js.map +1 -0
  56. package/dist/core/schedule/token-fold.js.map +1 -0
  57. package/dist/core/state-resolve.js.map +1 -0
  58. package/dist/core/vm-guards.js.map +1 -0
  59. package/dist/core/workflow/derive.js.map +1 -0
  60. package/dist/core/workflow/parse.js.map +1 -0
  61. package/dist/core/workflow/prompt-probe.js.map +1 -0
  62. package/dist/core/workflow/validate.js.map +1 -0
  63. package/dist/core/workspace-key.js.map +1 -0
  64. package/dist/shell/actions-runner.js.map +1 -0
  65. package/dist/shell/adapter/adapter-registry.js.map +1 -0
  66. package/dist/shell/adapter/clock-random.js.map +1 -0
  67. package/dist/shell/adapter/gondolin-dispatch-helpers.js.map +1 -0
  68. package/dist/shell/adapter/gondolin-dispatch.js.map +1 -0
  69. package/dist/shell/adapter/gondolin-image-converter.js.map +1 -0
  70. package/dist/shell/adapter/gondolin-image-fetch.js.map +1 -0
  71. package/dist/shell/adapter/launcher-asset.js.map +1 -0
  72. package/dist/shell/adapter/mise-config-asset.js.map +1 -0
  73. package/dist/shell/adapter/workflow-loader.js.map +1 -0
  74. package/dist/shell/cli/doctor.js.map +1 -0
  75. package/dist/shell/effect-interpreter-families.js.map +1 -0
  76. package/dist/shell/effect-interpreter.js.map +1 -0
  77. package/dist/shell/interp/acp-frame.js.map +1 -0
  78. package/dist/shell/interp/acp-ws-conn.js.map +1 -0
  79. package/dist/shell/interp/acp-ws-frames.js.map +1 -0
  80. package/dist/shell/interp/acp-ws.js.map +1 -0
  81. package/dist/shell/interp/acp.js.map +1 -0
  82. package/dist/shell/interp/credential-defaults.js.map +1 -0
  83. package/dist/shell/interp/credential-hooks.js.map +1 -0
  84. package/dist/shell/interp/credential-registry.js.map +1 -0
  85. package/dist/shell/interp/credential.js.map +1 -0
  86. package/dist/shell/interp/gh.js.map +1 -0
  87. package/dist/shell/interp/git.js.map +1 -0
  88. package/dist/shell/interp/log.js.map +1 -0
  89. package/dist/shell/interp/process.js.map +1 -0
  90. package/dist/shell/interp/runlog.js.map +1 -0
  91. package/dist/shell/interp/timer.js.map +1 -0
  92. package/dist/shell/interp/tracker-disk.js.map +1 -0
  93. package/dist/shell/interp/tracker-parse.js.map +1 -0
  94. package/dist/shell/interp/tracker-scan.js.map +1 -0
  95. package/dist/shell/interp/tracker-write.js.map +1 -0
  96. package/dist/shell/interp/tracker.js.map +1 -0
  97. package/dist/shell/interp/tty.js.map +1 -0
  98. package/dist/shell/interp/vm.js.map +1 -0
  99. package/dist/shell/interp/workspace.js.map +1 -0
  100. package/dist/shell/main-acp.js.map +1 -0
  101. package/dist/shell/main-adapters.js.map +1 -0
  102. package/dist/shell/main-credential.js.map +1 -0
  103. package/dist/shell/main-doctor.js.map +1 -0
  104. package/dist/shell/main-entry.js.map +1 -0
  105. package/dist/shell/main-http-csrf.js.map +1 -0
  106. package/dist/shell/main-http-handler.js.map +1 -0
  107. package/dist/shell/main-http-mcp.js.map +1 -0
  108. package/dist/shell/main-http-views.js.map +1 -0
  109. package/dist/shell/main-http.js.map +1 -0
  110. package/dist/shell/main-loops.js.map +1 -0
  111. package/dist/shell/main-mcp.js.map +1 -0
  112. package/dist/shell/main-orchestrator.js.map +1 -0
  113. package/dist/shell/main-preflight.js.map +1 -0
  114. package/dist/shell/main-reconcilers-helpers.js.map +1 -0
  115. package/dist/shell/main-reconcilers-pr.js.map +1 -0
  116. package/dist/shell/main-reconcilers.js.map +1 -0
  117. package/dist/shell/main-runner.js.map +1 -0
  118. package/dist/shell/main-scaffold.js.map +1 -0
  119. package/dist/shell/main-shutdown.js.map +1 -0
  120. package/dist/shell/main-startup.js.map +1 -0
  121. package/dist/shell/main-substrates.js.map +1 -0
  122. package/dist/shell/main.js.map +1 -0
  123. package/dist/shell/orchestrator-feedback.js.map +1 -0
  124. package/dist/shell/orchestrator-image.js.map +1 -0
  125. package/dist/shell/orchestrator-loop.js.map +1 -0
  126. package/dist/shell/orchestrator-reconcile.js.map +1 -0
  127. package/dist/shell/reconciler-loop.js.map +1 -0
  128. package/dist/shell/runner-loop-turn.js.map +1 -0
  129. package/dist/shell/runner-loop.js.map +1 -0
  130. package/dist/shell/server/http.js.map +1 -0
  131. package/dist/shell/server/mcp-runtime-effects.js.map +1 -0
  132. package/dist/shell/server/mcp-runtime.js.map +1 -0
  133. package/dist/shell/workspace-key.js.map +1 -0
  134. package/dist/types/acp.js.map +1 -0
  135. package/dist/types/actions/plan.js.map +1 -0
  136. package/dist/types/actions/predicates.js.map +1 -0
  137. package/dist/types/actions/run-fold.js.map +1 -0
  138. package/dist/types/actions.js.map +1 -0
  139. package/dist/types/adapter/clock-random.js.map +1 -0
  140. package/dist/types/adapter/gondolin-image-converter.js.map +1 -0
  141. package/dist/types/adapter/gondolin-image-fetch.js.map +1 -0
  142. package/dist/types/adapter/workflow-loader.js.map +1 -0
  143. package/dist/types/cli/args.js.map +1 -0
  144. package/dist/types/config.js.map +1 -0
  145. package/dist/types/credential-interp.js.map +1 -0
  146. package/dist/types/credentials.js.map +1 -0
  147. package/dist/types/doctor.js.map +1 -0
  148. package/dist/types/domain.js.map +1 -0
  149. package/dist/types/effect.js.map +1 -0
  150. package/dist/types/errors.js.map +1 -0
  151. package/dist/types/http/decisions.js.map +1 -0
  152. package/dist/types/http/render.js.map +1 -0
  153. package/dist/types/http/views.js.map +1 -0
  154. package/dist/types/http.js.map +1 -0
  155. package/dist/types/image/managed-image.js.map +1 -0
  156. package/dist/types/interp/effect-interpreter.js.map +1 -0
  157. package/dist/types/interp/tracker.js.map +1 -0
  158. package/dist/types/issue/file.js.map +1 -0
  159. package/dist/types/issue/parse.js.map +1 -0
  160. package/dist/types/main-acp.js.map +1 -0
  161. package/dist/types/main-adapters.js.map +1 -0
  162. package/dist/types/main-credential.js.map +1 -0
  163. package/dist/types/main-doctor.js.map +1 -0
  164. package/dist/types/main-http-handler.js.map +1 -0
  165. package/dist/types/main-http.js.map +1 -0
  166. package/dist/types/main-loops.js.map +1 -0
  167. package/dist/types/main-mcp.js.map +1 -0
  168. package/dist/types/main-orchestrator.js.map +1 -0
  169. package/dist/types/main-reconcilers.js.map +1 -0
  170. package/dist/types/main-runner.js.map +1 -0
  171. package/dist/types/main-startup.js.map +1 -0
  172. package/dist/types/main-substrates.js.map +1 -0
  173. package/dist/types/mcp/dispatch.js.map +1 -0
  174. package/dist/types/mcp/post-move.js.map +1 -0
  175. package/dist/types/mcp.js.map +1 -0
  176. package/dist/types/ports.js.map +1 -0
  177. package/dist/types/reconcile/image-decide.js.map +1 -0
  178. package/dist/types/reconcile/ledger.js.map +1 -0
  179. package/dist/types/reconcile/pr-loop.js.map +1 -0
  180. package/dist/types/reconcile/vm-reap.js.map +1 -0
  181. package/dist/types/reconcile/workspace-decide.js.map +1 -0
  182. package/dist/types/reconcile.js.map +1 -0
  183. package/dist/types/runlog.js.map +1 -0
  184. package/dist/types/runner/actions-runner.js.map +1 -0
  185. package/dist/types/runner/gondolin-dispatch.js.map +1 -0
  186. package/dist/types/runner/injection.js.map +1 -0
  187. package/dist/types/runner/runner-loop.js.map +1 -0
  188. package/dist/types/runner/turn.js.map +1 -0
  189. package/dist/types/runner/vm-plan.js.map +1 -0
  190. package/dist/types/runtime.js.map +1 -0
  191. package/dist/types/schedule/admission.js.map +1 -0
  192. package/dist/types/schedule/circuit-breaker.js.map +1 -0
  193. package/dist/types/schedule/eligibility.js.map +1 -0
  194. package/dist/types/schedule/orchestrator-loop.js.map +1 -0
  195. package/dist/types/schedule/sleep-cycle.js.map +1 -0
  196. package/dist/types/schedule/slots.js.map +1 -0
  197. package/dist/types/schedule/tick.js.map +1 -0
  198. package/dist/types/server/mcp-runtime.js.map +1 -0
  199. package/dist/types/workflow/parse.js.map +1 -0
  200. package/package.json +3 -3
  201. package/dist/src/bin/symphony.js.map +0 -1
  202. package/dist/src/core/actions/context.js.map +0 -1
  203. package/dist/src/core/actions/parse.js.map +0 -1
  204. package/dist/src/core/actions/plan.js.map +0 -1
  205. package/dist/src/core/actions/predicates.js.map +0 -1
  206. package/dist/src/core/actions/run-fold.js.map +0 -1
  207. package/dist/src/core/actions/template.js.map +0 -1
  208. package/dist/src/core/cli/args.js.map +0 -1
  209. package/dist/src/core/coerce.js.map +0 -1
  210. package/dist/src/core/credential/account-id.js.map +0 -1
  211. package/dist/src/core/credential/adapter-config.js.map +0 -1
  212. package/dist/src/core/credential/availability.js.map +0 -1
  213. package/dist/src/core/credential/extract.js.map +0 -1
  214. package/dist/src/core/credential/fake-creds.js.map +0 -1
  215. package/dist/src/core/credential/identity.js.map +0 -1
  216. package/dist/src/core/credential/shape.js.map +0 -1
  217. package/dist/src/core/credential/strings.js.map +0 -1
  218. package/dist/src/core/doctor/checks.js.map +0 -1
  219. package/dist/src/core/git/result.js.map +0 -1
  220. package/dist/src/core/http/decisions.js.map +0 -1
  221. package/dist/src/core/http/render.js.map +0 -1
  222. package/dist/src/core/http/routes.js.map +0 -1
  223. package/dist/src/core/http/views.js.map +0 -1
  224. package/dist/src/core/image/managed-image.js.map +0 -1
  225. package/dist/src/core/issue/file.js.map +0 -1
  226. package/dist/src/core/issue/parse.js.map +0 -1
  227. package/dist/src/core/mcp/dispatch.js.map +0 -1
  228. package/dist/src/core/mcp/post-move.js.map +0 -1
  229. package/dist/src/core/mcp/protocol.js.map +0 -1
  230. package/dist/src/core/mcp/url.js.map +0 -1
  231. package/dist/src/core/path.js.map +0 -1
  232. package/dist/src/core/reconcile/image-decide.js.map +0 -1
  233. package/dist/src/core/reconcile/ledger.js.map +0 -1
  234. package/dist/src/core/reconcile/pr-classify.js.map +0 -1
  235. package/dist/src/core/reconcile/pr-decide.js.map +0 -1
  236. package/dist/src/core/reconcile/pr-loop.js.map +0 -1
  237. package/dist/src/core/reconcile/pr-notes.js.map +0 -1
  238. package/dist/src/core/reconcile/vm-decide.js.map +0 -1
  239. package/dist/src/core/reconcile/vm-reap.js.map +0 -1
  240. package/dist/src/core/reconcile/workspace-decide.js.map +0 -1
  241. package/dist/src/core/runlog/summary.js.map +0 -1
  242. package/dist/src/core/runner/dispatch-config.js.map +0 -1
  243. package/dist/src/core/runner/injection.js.map +0 -1
  244. package/dist/src/core/runner/mise.js.map +0 -1
  245. package/dist/src/core/runner/prompt.js.map +0 -1
  246. package/dist/src/core/runner/turn.js.map +0 -1
  247. package/dist/src/core/runner/vm-plan.js.map +0 -1
  248. package/dist/src/core/schedule/admission.js.map +0 -1
  249. package/dist/src/core/schedule/circuit-breaker.js.map +0 -1
  250. package/dist/src/core/schedule/eligibility.js.map +0 -1
  251. package/dist/src/core/schedule/reconcile-issue.js.map +0 -1
  252. package/dist/src/core/schedule/retry.js.map +0 -1
  253. package/dist/src/core/schedule/sleep-cycle.js.map +0 -1
  254. package/dist/src/core/schedule/slots.js.map +0 -1
  255. package/dist/src/core/schedule/tick.js.map +0 -1
  256. package/dist/src/core/schedule/token-fold.js.map +0 -1
  257. package/dist/src/core/state-resolve.js.map +0 -1
  258. package/dist/src/core/vm-guards.js.map +0 -1
  259. package/dist/src/core/workflow/derive.js.map +0 -1
  260. package/dist/src/core/workflow/parse.js.map +0 -1
  261. package/dist/src/core/workflow/prompt-probe.js.map +0 -1
  262. package/dist/src/core/workflow/validate.js.map +0 -1
  263. package/dist/src/core/workspace-key.js.map +0 -1
  264. package/dist/src/shell/actions-runner.js.map +0 -1
  265. package/dist/src/shell/adapter/adapter-registry.js.map +0 -1
  266. package/dist/src/shell/adapter/clock-random.js.map +0 -1
  267. package/dist/src/shell/adapter/gondolin-dispatch-helpers.js.map +0 -1
  268. package/dist/src/shell/adapter/gondolin-dispatch.js.map +0 -1
  269. package/dist/src/shell/adapter/gondolin-image-converter.js.map +0 -1
  270. package/dist/src/shell/adapter/gondolin-image-fetch.js.map +0 -1
  271. package/dist/src/shell/adapter/launcher-asset.js.map +0 -1
  272. package/dist/src/shell/adapter/mise-config-asset.js.map +0 -1
  273. package/dist/src/shell/adapter/workflow-loader.js.map +0 -1
  274. package/dist/src/shell/cli/doctor.js.map +0 -1
  275. package/dist/src/shell/effect-interpreter-families.js.map +0 -1
  276. package/dist/src/shell/effect-interpreter.js.map +0 -1
  277. package/dist/src/shell/interp/acp-frame.js.map +0 -1
  278. package/dist/src/shell/interp/acp-ws-conn.js.map +0 -1
  279. package/dist/src/shell/interp/acp-ws-frames.js.map +0 -1
  280. package/dist/src/shell/interp/acp-ws.js.map +0 -1
  281. package/dist/src/shell/interp/acp.js.map +0 -1
  282. package/dist/src/shell/interp/credential-defaults.js.map +0 -1
  283. package/dist/src/shell/interp/credential-hooks.js.map +0 -1
  284. package/dist/src/shell/interp/credential-registry.js.map +0 -1
  285. package/dist/src/shell/interp/credential.js.map +0 -1
  286. package/dist/src/shell/interp/gh.js.map +0 -1
  287. package/dist/src/shell/interp/git.js.map +0 -1
  288. package/dist/src/shell/interp/log.js.map +0 -1
  289. package/dist/src/shell/interp/process.js.map +0 -1
  290. package/dist/src/shell/interp/runlog.js.map +0 -1
  291. package/dist/src/shell/interp/timer.js.map +0 -1
  292. package/dist/src/shell/interp/tracker-disk.js.map +0 -1
  293. package/dist/src/shell/interp/tracker-parse.js.map +0 -1
  294. package/dist/src/shell/interp/tracker-scan.js.map +0 -1
  295. package/dist/src/shell/interp/tracker-write.js.map +0 -1
  296. package/dist/src/shell/interp/tracker.js.map +0 -1
  297. package/dist/src/shell/interp/tty.js.map +0 -1
  298. package/dist/src/shell/interp/vm.js.map +0 -1
  299. package/dist/src/shell/interp/workspace.js.map +0 -1
  300. package/dist/src/shell/main-acp.js.map +0 -1
  301. package/dist/src/shell/main-adapters.js.map +0 -1
  302. package/dist/src/shell/main-credential.js.map +0 -1
  303. package/dist/src/shell/main-doctor.js.map +0 -1
  304. package/dist/src/shell/main-entry.js.map +0 -1
  305. package/dist/src/shell/main-http-csrf.js.map +0 -1
  306. package/dist/src/shell/main-http-handler.js.map +0 -1
  307. package/dist/src/shell/main-http-mcp.js.map +0 -1
  308. package/dist/src/shell/main-http-views.js.map +0 -1
  309. package/dist/src/shell/main-http.js.map +0 -1
  310. package/dist/src/shell/main-loops.js.map +0 -1
  311. package/dist/src/shell/main-mcp.js.map +0 -1
  312. package/dist/src/shell/main-orchestrator.js.map +0 -1
  313. package/dist/src/shell/main-preflight.js.map +0 -1
  314. package/dist/src/shell/main-reconcilers-helpers.js.map +0 -1
  315. package/dist/src/shell/main-reconcilers-pr.js.map +0 -1
  316. package/dist/src/shell/main-reconcilers.js.map +0 -1
  317. package/dist/src/shell/main-runner.js.map +0 -1
  318. package/dist/src/shell/main-scaffold.js.map +0 -1
  319. package/dist/src/shell/main-shutdown.js.map +0 -1
  320. package/dist/src/shell/main-startup.js.map +0 -1
  321. package/dist/src/shell/main-substrates.js.map +0 -1
  322. package/dist/src/shell/main.js.map +0 -1
  323. package/dist/src/shell/orchestrator-feedback.js.map +0 -1
  324. package/dist/src/shell/orchestrator-image.js.map +0 -1
  325. package/dist/src/shell/orchestrator-loop.js.map +0 -1
  326. package/dist/src/shell/orchestrator-reconcile.js.map +0 -1
  327. package/dist/src/shell/reconciler-loop.js.map +0 -1
  328. package/dist/src/shell/runner-loop-turn.js.map +0 -1
  329. package/dist/src/shell/runner-loop.js.map +0 -1
  330. package/dist/src/shell/server/http.js.map +0 -1
  331. package/dist/src/shell/server/mcp-runtime-effects.js.map +0 -1
  332. package/dist/src/shell/server/mcp-runtime.js.map +0 -1
  333. package/dist/src/shell/workspace-key.js.map +0 -1
  334. package/dist/src/types/acp.js.map +0 -1
  335. package/dist/src/types/actions/plan.js.map +0 -1
  336. package/dist/src/types/actions/predicates.js.map +0 -1
  337. package/dist/src/types/actions/run-fold.js.map +0 -1
  338. package/dist/src/types/actions.js.map +0 -1
  339. package/dist/src/types/adapter/clock-random.js.map +0 -1
  340. package/dist/src/types/adapter/gondolin-image-converter.js.map +0 -1
  341. package/dist/src/types/adapter/gondolin-image-fetch.js.map +0 -1
  342. package/dist/src/types/adapter/workflow-loader.js.map +0 -1
  343. package/dist/src/types/cli/args.js.map +0 -1
  344. package/dist/src/types/config.js.map +0 -1
  345. package/dist/src/types/credential-interp.js.map +0 -1
  346. package/dist/src/types/credentials.js.map +0 -1
  347. package/dist/src/types/doctor.js.map +0 -1
  348. package/dist/src/types/domain.js.map +0 -1
  349. package/dist/src/types/effect.js.map +0 -1
  350. package/dist/src/types/errors.js.map +0 -1
  351. package/dist/src/types/http/decisions.js.map +0 -1
  352. package/dist/src/types/http/render.js.map +0 -1
  353. package/dist/src/types/http/views.js.map +0 -1
  354. package/dist/src/types/http.js.map +0 -1
  355. package/dist/src/types/image/managed-image.js.map +0 -1
  356. package/dist/src/types/interp/effect-interpreter.js.map +0 -1
  357. package/dist/src/types/interp/tracker.js.map +0 -1
  358. package/dist/src/types/issue/file.js.map +0 -1
  359. package/dist/src/types/issue/parse.js.map +0 -1
  360. package/dist/src/types/main-acp.js.map +0 -1
  361. package/dist/src/types/main-adapters.js.map +0 -1
  362. package/dist/src/types/main-credential.js.map +0 -1
  363. package/dist/src/types/main-doctor.js.map +0 -1
  364. package/dist/src/types/main-http-handler.js.map +0 -1
  365. package/dist/src/types/main-http.js.map +0 -1
  366. package/dist/src/types/main-loops.js.map +0 -1
  367. package/dist/src/types/main-mcp.js.map +0 -1
  368. package/dist/src/types/main-orchestrator.js.map +0 -1
  369. package/dist/src/types/main-reconcilers.js.map +0 -1
  370. package/dist/src/types/main-runner.js.map +0 -1
  371. package/dist/src/types/main-startup.js.map +0 -1
  372. package/dist/src/types/main-substrates.js.map +0 -1
  373. package/dist/src/types/mcp/dispatch.js.map +0 -1
  374. package/dist/src/types/mcp/post-move.js.map +0 -1
  375. package/dist/src/types/mcp.js.map +0 -1
  376. package/dist/src/types/ports.js.map +0 -1
  377. package/dist/src/types/reconcile/image-decide.js.map +0 -1
  378. package/dist/src/types/reconcile/ledger.js.map +0 -1
  379. package/dist/src/types/reconcile/pr-loop.js.map +0 -1
  380. package/dist/src/types/reconcile/vm-reap.js.map +0 -1
  381. package/dist/src/types/reconcile/workspace-decide.js.map +0 -1
  382. package/dist/src/types/reconcile.js.map +0 -1
  383. package/dist/src/types/runlog.js.map +0 -1
  384. package/dist/src/types/runner/actions-runner.js.map +0 -1
  385. package/dist/src/types/runner/gondolin-dispatch.js.map +0 -1
  386. package/dist/src/types/runner/injection.js.map +0 -1
  387. package/dist/src/types/runner/runner-loop.js.map +0 -1
  388. package/dist/src/types/runner/turn.js.map +0 -1
  389. package/dist/src/types/runner/vm-plan.js.map +0 -1
  390. package/dist/src/types/runtime.js.map +0 -1
  391. package/dist/src/types/schedule/admission.js.map +0 -1
  392. package/dist/src/types/schedule/circuit-breaker.js.map +0 -1
  393. package/dist/src/types/schedule/eligibility.js.map +0 -1
  394. package/dist/src/types/schedule/orchestrator-loop.js.map +0 -1
  395. package/dist/src/types/schedule/sleep-cycle.js.map +0 -1
  396. package/dist/src/types/schedule/slots.js.map +0 -1
  397. package/dist/src/types/schedule/tick.js.map +0 -1
  398. package/dist/src/types/server/mcp-runtime.js.map +0 -1
  399. package/dist/src/types/workflow/parse.js.map +0 -1
  400. package/dist/tests/core/account-id.test.js +0 -35
  401. package/dist/tests/core/account-id.test.js.map +0 -1
  402. package/dist/tests/core/actions-parse.test.js +0 -176
  403. package/dist/tests/core/actions-parse.test.js.map +0 -1
  404. package/dist/tests/core/adapter-config.test.js +0 -133
  405. package/dist/tests/core/adapter-config.test.js.map +0 -1
  406. package/dist/tests/core/admission.test.js +0 -215
  407. package/dist/tests/core/admission.test.js.map +0 -1
  408. package/dist/tests/core/args.test.js +0 -132
  409. package/dist/tests/core/args.test.js.map +0 -1
  410. package/dist/tests/core/availability.test.js +0 -62
  411. package/dist/tests/core/availability.test.js.map +0 -1
  412. package/dist/tests/core/checks.test.js +0 -395
  413. package/dist/tests/core/checks.test.js.map +0 -1
  414. package/dist/tests/core/circuit-breaker.test.js +0 -172
  415. package/dist/tests/core/circuit-breaker.test.js.map +0 -1
  416. package/dist/tests/core/coerce.test.js +0 -87
  417. package/dist/tests/core/coerce.test.js.map +0 -1
  418. package/dist/tests/core/context.test.js +0 -228
  419. package/dist/tests/core/context.test.js.map +0 -1
  420. package/dist/tests/core/decisions.test.js +0 -310
  421. package/dist/tests/core/decisions.test.js.map +0 -1
  422. package/dist/tests/core/derive.test.js +0 -205
  423. package/dist/tests/core/derive.test.js.map +0 -1
  424. package/dist/tests/core/dispatch-config.test.js +0 -164
  425. package/dist/tests/core/dispatch-config.test.js.map +0 -1
  426. package/dist/tests/core/dispatch.test.js +0 -302
  427. package/dist/tests/core/dispatch.test.js.map +0 -1
  428. package/dist/tests/core/eligibility.test.js +0 -163
  429. package/dist/tests/core/eligibility.test.js.map +0 -1
  430. package/dist/tests/core/extract.test.js +0 -139
  431. package/dist/tests/core/extract.test.js.map +0 -1
  432. package/dist/tests/core/fake-creds.test.js +0 -134
  433. package/dist/tests/core/fake-creds.test.js.map +0 -1
  434. package/dist/tests/core/file.test.js +0 -197
  435. package/dist/tests/core/file.test.js.map +0 -1
  436. package/dist/tests/core/git-result.test.js +0 -113
  437. package/dist/tests/core/git-result.test.js.map +0 -1
  438. package/dist/tests/core/identity.test.js +0 -180
  439. package/dist/tests/core/identity.test.js.map +0 -1
  440. package/dist/tests/core/image-decide.test.js +0 -59
  441. package/dist/tests/core/image-decide.test.js.map +0 -1
  442. package/dist/tests/core/injection.test.js +0 -163
  443. package/dist/tests/core/injection.test.js.map +0 -1
  444. package/dist/tests/core/ledger.test.js +0 -218
  445. package/dist/tests/core/ledger.test.js.map +0 -1
  446. package/dist/tests/core/managed-image.test.js +0 -68
  447. package/dist/tests/core/managed-image.test.js.map +0 -1
  448. package/dist/tests/core/mise.test.js +0 -138
  449. package/dist/tests/core/mise.test.js.map +0 -1
  450. package/dist/tests/core/parse.test.js +0 -174
  451. package/dist/tests/core/parse.test.js.map +0 -1
  452. package/dist/tests/core/path.test.js +0 -50
  453. package/dist/tests/core/path.test.js.map +0 -1
  454. package/dist/tests/core/plan.test.js +0 -218
  455. package/dist/tests/core/plan.test.js.map +0 -1
  456. package/dist/tests/core/post-move.test.js +0 -162
  457. package/dist/tests/core/post-move.test.js.map +0 -1
  458. package/dist/tests/core/pr-classify.test.js +0 -117
  459. package/dist/tests/core/pr-classify.test.js.map +0 -1
  460. package/dist/tests/core/pr-decide.test.js +0 -298
  461. package/dist/tests/core/pr-decide.test.js.map +0 -1
  462. package/dist/tests/core/pr-loop.test.js +0 -301
  463. package/dist/tests/core/pr-loop.test.js.map +0 -1
  464. package/dist/tests/core/pr-notes.test.js +0 -165
  465. package/dist/tests/core/pr-notes.test.js.map +0 -1
  466. package/dist/tests/core/predicates.test.js +0 -154
  467. package/dist/tests/core/predicates.test.js.map +0 -1
  468. package/dist/tests/core/prompt.test.js +0 -189
  469. package/dist/tests/core/prompt.test.js.map +0 -1
  470. package/dist/tests/core/protocol.test.js +0 -195
  471. package/dist/tests/core/protocol.test.js.map +0 -1
  472. package/dist/tests/core/reconcile-issue.test.js +0 -116
  473. package/dist/tests/core/reconcile-issue.test.js.map +0 -1
  474. package/dist/tests/core/render.test.js +0 -549
  475. package/dist/tests/core/render.test.js.map +0 -1
  476. package/dist/tests/core/retry.test.js +0 -186
  477. package/dist/tests/core/retry.test.js.map +0 -1
  478. package/dist/tests/core/routes.test.js +0 -247
  479. package/dist/tests/core/routes.test.js.map +0 -1
  480. package/dist/tests/core/run-fold.test.js +0 -299
  481. package/dist/tests/core/run-fold.test.js.map +0 -1
  482. package/dist/tests/core/shape.test.js +0 -185
  483. package/dist/tests/core/shape.test.js.map +0 -1
  484. package/dist/tests/core/sleep-cycle.test.js +0 -150
  485. package/dist/tests/core/sleep-cycle.test.js.map +0 -1
  486. package/dist/tests/core/slots.test.js +0 -201
  487. package/dist/tests/core/slots.test.js.map +0 -1
  488. package/dist/tests/core/state-resolve.test.js +0 -80
  489. package/dist/tests/core/state-resolve.test.js.map +0 -1
  490. package/dist/tests/core/summary.test.js +0 -200
  491. package/dist/tests/core/summary.test.js.map +0 -1
  492. package/dist/tests/core/template.test.js +0 -116
  493. package/dist/tests/core/template.test.js.map +0 -1
  494. package/dist/tests/core/tick.test.js +0 -558
  495. package/dist/tests/core/tick.test.js.map +0 -1
  496. package/dist/tests/core/token-fold.test.js +0 -176
  497. package/dist/tests/core/token-fold.test.js.map +0 -1
  498. package/dist/tests/core/turn.test.js +0 -388
  499. package/dist/tests/core/turn.test.js.map +0 -1
  500. package/dist/tests/core/url.test.js +0 -118
  501. package/dist/tests/core/url.test.js.map +0 -1
  502. package/dist/tests/core/validate.test.js +0 -247
  503. package/dist/tests/core/validate.test.js.map +0 -1
  504. package/dist/tests/core/views.test.js +0 -252
  505. package/dist/tests/core/views.test.js.map +0 -1
  506. package/dist/tests/core/vm-decide.test.js +0 -110
  507. package/dist/tests/core/vm-decide.test.js.map +0 -1
  508. package/dist/tests/core/vm-guards.test.js +0 -153
  509. package/dist/tests/core/vm-guards.test.js.map +0 -1
  510. package/dist/tests/core/vm-plan.test.js +0 -332
  511. package/dist/tests/core/vm-plan.test.js.map +0 -1
  512. package/dist/tests/core/vm-reap.test.js +0 -196
  513. package/dist/tests/core/vm-reap.test.js.map +0 -1
  514. package/dist/tests/core/workflow-parse.test.js +0 -493
  515. package/dist/tests/core/workflow-parse.test.js.map +0 -1
  516. package/dist/tests/core/workspace-decide.test.js +0 -236
  517. package/dist/tests/core/workspace-decide.test.js.map +0 -1
  518. package/dist/tests/helpers/fixtures.js +0 -167
  519. package/dist/tests/helpers/fixtures.js.map +0 -1
  520. package/dist/tests/shell/acp-substrate.test.js +0 -101
  521. package/dist/tests/shell/acp-substrate.test.js.map +0 -1
  522. package/dist/tests/shell/actions-runner-push.test.js +0 -203
  523. package/dist/tests/shell/actions-runner-push.test.js.map +0 -1
  524. package/dist/tests/shell/credential-hooks.test.js +0 -36
  525. package/dist/tests/shell/credential-hooks.test.js.map +0 -1
  526. package/dist/tests/shell/credential-registry.test.js +0 -165
  527. package/dist/tests/shell/credential-registry.test.js.map +0 -1
  528. package/dist/tests/shell/credential-substrate.test.js +0 -179
  529. package/dist/tests/shell/credential-substrate.test.js.map +0 -1
  530. package/dist/tests/shell/dockerfile-mise-pin.test.js +0 -51
  531. package/dist/tests/shell/dockerfile-mise-pin.test.js.map +0 -1
  532. package/dist/tests/shell/doctor.test.js +0 -101
  533. package/dist/tests/shell/doctor.test.js.map +0 -1
  534. package/dist/tests/shell/effect-vm-create.test.js +0 -52
  535. package/dist/tests/shell/effect-vm-create.test.js.map +0 -1
  536. package/dist/tests/shell/gh-port.test.js +0 -63
  537. package/dist/tests/shell/gh-port.test.js.map +0 -1
  538. package/dist/tests/shell/gondolin-dispatch-guard.test.js +0 -144
  539. package/dist/tests/shell/gondolin-dispatch-guard.test.js.map +0 -1
  540. package/dist/tests/shell/gondolin-dispatch-shquote.test.js +0 -168
  541. package/dist/tests/shell/gondolin-dispatch-shquote.test.js.map +0 -1
  542. package/dist/tests/shell/gondolin-image-converter.test.js +0 -208
  543. package/dist/tests/shell/gondolin-image-converter.test.js.map +0 -1
  544. package/dist/tests/shell/gondolin-image-fetch.test.js +0 -93
  545. package/dist/tests/shell/gondolin-image-fetch.test.js.map +0 -1
  546. package/dist/tests/shell/http-handler.test.js +0 -608
  547. package/dist/tests/shell/http-handler.test.js.map +0 -1
  548. package/dist/tests/shell/http-server.test.js +0 -53
  549. package/dist/tests/shell/http-server.test.js.map +0 -1
  550. package/dist/tests/shell/mcp-runtime.test.js +0 -366
  551. package/dist/tests/shell/mcp-runtime.test.js.map +0 -1
  552. package/dist/tests/shell/mise-config-asset.test.js +0 -87
  553. package/dist/tests/shell/mise-config-asset.test.js.map +0 -1
  554. package/dist/tests/shell/orchestrator-loop.test.js +0 -583
  555. package/dist/tests/shell/orchestrator-loop.test.js.map +0 -1
  556. package/dist/tests/shell/reconciler-passes.test.js +0 -314
  557. package/dist/tests/shell/reconciler-passes.test.js.map +0 -1
  558. package/dist/tests/shell/runner-loop-turn.test.js +0 -97
  559. package/dist/tests/shell/runner-loop-turn.test.js.map +0 -1
  560. package/dist/tests/shell/runner-slice.test.js +0 -536
  561. package/dist/tests/shell/runner-slice.test.js.map +0 -1
  562. package/dist/tests/shell/scaffold.test.js +0 -65
  563. package/dist/tests/shell/scaffold.test.js.map +0 -1
  564. package/dist/tests/shell/tick-config.test.js +0 -83
  565. package/dist/tests/shell/tick-config.test.js.map +0 -1
  566. package/dist/tests/shell/tracker-parse-dates.test.js +0 -44
  567. package/dist/tests/shell/tracker-parse-dates.test.js.map +0 -1
  568. package/dist/tests/shell/tracker-write-issue.test.js +0 -154
  569. package/dist/tests/shell/tracker-write-issue.test.js.map +0 -1
  570. package/dist/tests/shell/workflow-prompt-split.test.js +0 -208
  571. package/dist/tests/shell/workflow-prompt-split.test.js.map +0 -1
  572. package/dist/tests/shell/workspace-live-config.test.js +0 -140
  573. package/dist/tests/shell/workspace-live-config.test.js.map +0 -1
  574. /package/dist/{src/bin → bin}/symphony.js +0 -0
  575. /package/dist/{src/core → core}/actions/context.js +0 -0
  576. /package/dist/{src/core → core}/actions/parse.js +0 -0
  577. /package/dist/{src/core → core}/actions/plan.js +0 -0
  578. /package/dist/{src/core → core}/actions/predicates.js +0 -0
  579. /package/dist/{src/core → core}/actions/run-fold.js +0 -0
  580. /package/dist/{src/core → core}/actions/template.js +0 -0
  581. /package/dist/{src/core → core}/cli/args.js +0 -0
  582. /package/dist/{src/core → core}/coerce.js +0 -0
  583. /package/dist/{src/core → core}/credential/account-id.js +0 -0
  584. /package/dist/{src/core → core}/credential/adapter-config.js +0 -0
  585. /package/dist/{src/core → core}/credential/availability.js +0 -0
  586. /package/dist/{src/core → core}/credential/extract.js +0 -0
  587. /package/dist/{src/core → core}/credential/fake-creds.js +0 -0
  588. /package/dist/{src/core → core}/credential/identity.js +0 -0
  589. /package/dist/{src/core → core}/credential/shape.js +0 -0
  590. /package/dist/{src/core → core}/credential/strings.js +0 -0
  591. /package/dist/{src/core → core}/doctor/checks.js +0 -0
  592. /package/dist/{src/core → core}/git/result.js +0 -0
  593. /package/dist/{src/core → core}/http/decisions.js +0 -0
  594. /package/dist/{src/core → core}/http/render.js +0 -0
  595. /package/dist/{src/core → core}/http/routes.js +0 -0
  596. /package/dist/{src/core → core}/http/views.js +0 -0
  597. /package/dist/{src/core → core}/image/managed-image.js +0 -0
  598. /package/dist/{src/core → core}/issue/file.js +0 -0
  599. /package/dist/{src/core → core}/issue/parse.js +0 -0
  600. /package/dist/{src/core → core}/mcp/dispatch.js +0 -0
  601. /package/dist/{src/core → core}/mcp/post-move.js +0 -0
  602. /package/dist/{src/core → core}/mcp/protocol.js +0 -0
  603. /package/dist/{src/core → core}/mcp/url.js +0 -0
  604. /package/dist/{src/core → core}/path.js +0 -0
  605. /package/dist/{src/core → core}/reconcile/image-decide.js +0 -0
  606. /package/dist/{src/core → core}/reconcile/ledger.js +0 -0
  607. /package/dist/{src/core → core}/reconcile/pr-classify.js +0 -0
  608. /package/dist/{src/core → core}/reconcile/pr-decide.js +0 -0
  609. /package/dist/{src/core → core}/reconcile/pr-loop.js +0 -0
  610. /package/dist/{src/core → core}/reconcile/pr-notes.js +0 -0
  611. /package/dist/{src/core → core}/reconcile/vm-decide.js +0 -0
  612. /package/dist/{src/core → core}/reconcile/vm-reap.js +0 -0
  613. /package/dist/{src/core → core}/reconcile/workspace-decide.js +0 -0
  614. /package/dist/{src/core → core}/runlog/summary.js +0 -0
  615. /package/dist/{src/core → core}/runner/dispatch-config.js +0 -0
  616. /package/dist/{src/core → core}/runner/injection.js +0 -0
  617. /package/dist/{src/core → core}/runner/mise.js +0 -0
  618. /package/dist/{src/core → core}/runner/prompt.js +0 -0
  619. /package/dist/{src/core → core}/runner/turn.js +0 -0
  620. /package/dist/{src/core → core}/runner/vm-plan.js +0 -0
  621. /package/dist/{src/core → core}/schedule/admission.js +0 -0
  622. /package/dist/{src/core → core}/schedule/circuit-breaker.js +0 -0
  623. /package/dist/{src/core → core}/schedule/eligibility.js +0 -0
  624. /package/dist/{src/core → core}/schedule/reconcile-issue.js +0 -0
  625. /package/dist/{src/core → core}/schedule/retry.js +0 -0
  626. /package/dist/{src/core → core}/schedule/sleep-cycle.js +0 -0
  627. /package/dist/{src/core → core}/schedule/slots.js +0 -0
  628. /package/dist/{src/core → core}/schedule/tick.js +0 -0
  629. /package/dist/{src/core → core}/schedule/token-fold.js +0 -0
  630. /package/dist/{src/core → core}/state-resolve.js +0 -0
  631. /package/dist/{src/core → core}/vm-guards.js +0 -0
  632. /package/dist/{src/core → core}/workflow/derive.js +0 -0
  633. /package/dist/{src/core → core}/workflow/parse.js +0 -0
  634. /package/dist/{src/core → core}/workflow/prompt-probe.js +0 -0
  635. /package/dist/{src/core → core}/workflow/validate.js +0 -0
  636. /package/dist/{src/core → core}/workspace-key.js +0 -0
  637. /package/dist/{src/shell → shell}/actions-runner.js +0 -0
  638. /package/dist/{src/shell → shell}/adapter/adapter-registry.js +0 -0
  639. /package/dist/{src/shell → shell}/adapter/clock-random.js +0 -0
  640. /package/dist/{src/shell → shell}/adapter/gondolin-dispatch-helpers.js +0 -0
  641. /package/dist/{src/shell → shell}/adapter/gondolin-dispatch.js +0 -0
  642. /package/dist/{src/shell → shell}/adapter/gondolin-image-converter.js +0 -0
  643. /package/dist/{src/shell → shell}/adapter/gondolin-image-fetch.js +0 -0
  644. /package/dist/{src/shell → shell}/adapter/launcher-asset.js +0 -0
  645. /package/dist/{src/shell → shell}/adapter/mise-config-asset.js +0 -0
  646. /package/dist/{src/shell → shell}/adapter/workflow-loader.js +0 -0
  647. /package/dist/{src/shell → shell}/cli/doctor.js +0 -0
  648. /package/dist/{src/shell → shell}/effect-interpreter-families.js +0 -0
  649. /package/dist/{src/shell → shell}/effect-interpreter.js +0 -0
  650. /package/dist/{src/shell → shell}/interp/acp-frame.js +0 -0
  651. /package/dist/{src/shell → shell}/interp/acp-ws-conn.js +0 -0
  652. /package/dist/{src/shell → shell}/interp/acp-ws-frames.js +0 -0
  653. /package/dist/{src/shell → shell}/interp/acp-ws.js +0 -0
  654. /package/dist/{src/shell → shell}/interp/acp.js +0 -0
  655. /package/dist/{src/shell → shell}/interp/credential-defaults.js +0 -0
  656. /package/dist/{src/shell → shell}/interp/credential-hooks.js +0 -0
  657. /package/dist/{src/shell → shell}/interp/credential-registry.js +0 -0
  658. /package/dist/{src/shell → shell}/interp/credential.js +0 -0
  659. /package/dist/{src/shell → shell}/interp/gh.js +0 -0
  660. /package/dist/{src/shell → shell}/interp/git.js +0 -0
  661. /package/dist/{src/shell → shell}/interp/log.js +0 -0
  662. /package/dist/{src/shell → shell}/interp/process.js +0 -0
  663. /package/dist/{src/shell → shell}/interp/runlog.js +0 -0
  664. /package/dist/{src/shell → shell}/interp/timer.js +0 -0
  665. /package/dist/{src/shell → shell}/interp/tracker-disk.js +0 -0
  666. /package/dist/{src/shell → shell}/interp/tracker-parse.js +0 -0
  667. /package/dist/{src/shell → shell}/interp/tracker-scan.js +0 -0
  668. /package/dist/{src/shell → shell}/interp/tracker-write.js +0 -0
  669. /package/dist/{src/shell → shell}/interp/tracker.js +0 -0
  670. /package/dist/{src/shell → shell}/interp/tty.js +0 -0
  671. /package/dist/{src/shell → shell}/interp/vm.js +0 -0
  672. /package/dist/{src/shell → shell}/interp/workspace.js +0 -0
  673. /package/dist/{src/shell → shell}/main-acp.js +0 -0
  674. /package/dist/{src/shell → shell}/main-adapters.js +0 -0
  675. /package/dist/{src/shell → shell}/main-credential.js +0 -0
  676. /package/dist/{src/shell → shell}/main-doctor.js +0 -0
  677. /package/dist/{src/shell → shell}/main-entry.js +0 -0
  678. /package/dist/{src/shell → shell}/main-http-csrf.js +0 -0
  679. /package/dist/{src/shell → shell}/main-http-handler.js +0 -0
  680. /package/dist/{src/shell → shell}/main-http-mcp.js +0 -0
  681. /package/dist/{src/shell → shell}/main-http-views.js +0 -0
  682. /package/dist/{src/shell → shell}/main-http.js +0 -0
  683. /package/dist/{src/shell → shell}/main-loops.js +0 -0
  684. /package/dist/{src/shell → shell}/main-mcp.js +0 -0
  685. /package/dist/{src/shell → shell}/main-orchestrator.js +0 -0
  686. /package/dist/{src/shell → shell}/main-preflight.js +0 -0
  687. /package/dist/{src/shell → shell}/main-reconcilers-helpers.js +0 -0
  688. /package/dist/{src/shell → shell}/main-reconcilers-pr.js +0 -0
  689. /package/dist/{src/shell → shell}/main-reconcilers.js +0 -0
  690. /package/dist/{src/shell → shell}/main-runner.js +0 -0
  691. /package/dist/{src/shell → shell}/main-scaffold.js +0 -0
  692. /package/dist/{src/shell → shell}/main-shutdown.js +0 -0
  693. /package/dist/{src/shell → shell}/main-startup.js +0 -0
  694. /package/dist/{src/shell → shell}/main-substrates.js +0 -0
  695. /package/dist/{src/shell → shell}/main.js +0 -0
  696. /package/dist/{src/shell → shell}/orchestrator-feedback.js +0 -0
  697. /package/dist/{src/shell → shell}/orchestrator-image.js +0 -0
  698. /package/dist/{src/shell → shell}/orchestrator-loop.js +0 -0
  699. /package/dist/{src/shell → shell}/orchestrator-reconcile.js +0 -0
  700. /package/dist/{src/shell → shell}/reconciler-loop.js +0 -0
  701. /package/dist/{src/shell → shell}/runner-loop-turn.js +0 -0
  702. /package/dist/{src/shell → shell}/runner-loop.js +0 -0
  703. /package/dist/{src/shell → shell}/server/http.js +0 -0
  704. /package/dist/{src/shell → shell}/server/mcp-runtime-effects.js +0 -0
  705. /package/dist/{src/shell → shell}/server/mcp-runtime.js +0 -0
  706. /package/dist/{src/shell → shell}/workspace-key.js +0 -0
  707. /package/dist/{src/types → types}/acp.js +0 -0
  708. /package/dist/{src/types → types}/actions/plan.js +0 -0
  709. /package/dist/{src/types → types}/actions/predicates.js +0 -0
  710. /package/dist/{src/types → types}/actions/run-fold.js +0 -0
  711. /package/dist/{src/types → types}/actions.js +0 -0
  712. /package/dist/{src/types → types}/adapter/clock-random.js +0 -0
  713. /package/dist/{src/types → types}/adapter/gondolin-image-converter.js +0 -0
  714. /package/dist/{src/types → types}/adapter/gondolin-image-fetch.js +0 -0
  715. /package/dist/{src/types → types}/adapter/workflow-loader.js +0 -0
  716. /package/dist/{src/types → types}/cli/args.js +0 -0
  717. /package/dist/{src/types → types}/config.js +0 -0
  718. /package/dist/{src/types → types}/credential-interp.js +0 -0
  719. /package/dist/{src/types → types}/credentials.js +0 -0
  720. /package/dist/{src/types → types}/doctor.js +0 -0
  721. /package/dist/{src/types → types}/domain.js +0 -0
  722. /package/dist/{src/types → types}/effect.js +0 -0
  723. /package/dist/{src/types → types}/errors.js +0 -0
  724. /package/dist/{src/types → types}/http/decisions.js +0 -0
  725. /package/dist/{src/types → types}/http/render.js +0 -0
  726. /package/dist/{src/types → types}/http/views.js +0 -0
  727. /package/dist/{src/types → types}/http.js +0 -0
  728. /package/dist/{src/types → types}/image/managed-image.js +0 -0
  729. /package/dist/{src/types → types}/interp/effect-interpreter.js +0 -0
  730. /package/dist/{src/types → types}/interp/tracker.js +0 -0
  731. /package/dist/{src/types → types}/issue/file.js +0 -0
  732. /package/dist/{src/types → types}/issue/parse.js +0 -0
  733. /package/dist/{src/types → types}/main-acp.js +0 -0
  734. /package/dist/{src/types → types}/main-adapters.js +0 -0
  735. /package/dist/{src/types → types}/main-credential.js +0 -0
  736. /package/dist/{src/types → types}/main-doctor.js +0 -0
  737. /package/dist/{src/types → types}/main-http-handler.js +0 -0
  738. /package/dist/{src/types → types}/main-http.js +0 -0
  739. /package/dist/{src/types → types}/main-loops.js +0 -0
  740. /package/dist/{src/types → types}/main-mcp.js +0 -0
  741. /package/dist/{src/types → types}/main-orchestrator.js +0 -0
  742. /package/dist/{src/types → types}/main-reconcilers.js +0 -0
  743. /package/dist/{src/types → types}/main-runner.js +0 -0
  744. /package/dist/{src/types → types}/main-startup.js +0 -0
  745. /package/dist/{src/types → types}/main-substrates.js +0 -0
  746. /package/dist/{src/types → types}/mcp/dispatch.js +0 -0
  747. /package/dist/{src/types → types}/mcp/post-move.js +0 -0
  748. /package/dist/{src/types → types}/mcp.js +0 -0
  749. /package/dist/{src/types → types}/ports.js +0 -0
  750. /package/dist/{src/types → types}/reconcile/image-decide.js +0 -0
  751. /package/dist/{src/types → types}/reconcile/ledger.js +0 -0
  752. /package/dist/{src/types → types}/reconcile/pr-loop.js +0 -0
  753. /package/dist/{src/types → types}/reconcile/vm-reap.js +0 -0
  754. /package/dist/{src/types → types}/reconcile/workspace-decide.js +0 -0
  755. /package/dist/{src/types → types}/reconcile.js +0 -0
  756. /package/dist/{src/types → types}/runlog.js +0 -0
  757. /package/dist/{src/types → types}/runner/actions-runner.js +0 -0
  758. /package/dist/{src/types → types}/runner/gondolin-dispatch.js +0 -0
  759. /package/dist/{src/types → types}/runner/injection.js +0 -0
  760. /package/dist/{src/types → types}/runner/runner-loop.js +0 -0
  761. /package/dist/{src/types → types}/runner/turn.js +0 -0
  762. /package/dist/{src/types → types}/runner/vm-plan.js +0 -0
  763. /package/dist/{src/types → types}/runtime.js +0 -0
  764. /package/dist/{src/types → types}/schedule/admission.js +0 -0
  765. /package/dist/{src/types → types}/schedule/circuit-breaker.js +0 -0
  766. /package/dist/{src/types → types}/schedule/eligibility.js +0 -0
  767. /package/dist/{src/types → types}/schedule/orchestrator-loop.js +0 -0
  768. /package/dist/{src/types → types}/schedule/sleep-cycle.js +0 -0
  769. /package/dist/{src/types → types}/schedule/slots.js +0 -0
  770. /package/dist/{src/types → types}/schedule/tick.js +0 -0
  771. /package/dist/{src/types → types}/server/mcp-runtime.js +0 -0
  772. /package/dist/{src/types → types}/workflow/parse.js +0 -0
@@ -1,608 +0,0 @@
1
- // Integration test for the composed dashboard/REST `handle` (src/shell/main-http-handler).
2
- //
3
- // Drives `wireHttpHandler` with the REAL pure core http slice (routes + decisions
4
- // + views + render — exactly the bundle main.ts injects) over a FAKE orchestrator
5
- // read-surface + a FAKE in-memory tracker. Asserts the routes the composition root
6
- // now serves live (no 503): the dashboard HTML, the §9.3 state JSON, the disk
7
- // issue listing + issue-detail page, a CSRF-rejected POST, and a CSRF-accepted
8
- // POST that lands a write through the tracker.
9
- import { test } from 'node:test';
10
- import assert from 'node:assert/strict';
11
- import { wireHttpHandler } from '../../src/shell/main-http-handler.js';
12
- // The real pure core http functions (the composition root injects these verbatim).
13
- import { matchRoute, resolvePartialName, extractBearerToken, classifyContentType, checkSteeringCsrf, checkTriageCsrf, extractFormText, extractJsonText, } from '../../src/core/http/routes.js';
14
- import { decideCreateIssue, decideMoveTransition, buildIssueDetailDto } from '../../src/core/http/decisions.js';
15
- import { buildSnapshot, buildHealthRollup, buildSessionTotalsView } from '../../src/core/http/views.js';
16
- import { renderDashboardHtml, renderHeaderPartial, renderHealthPartial, renderAttentionPartial, renderBoardPartial, renderTotalsPartial, renderIssueDetailPage, renderIssueNotFoundPage, } from '../../src/core/http/render.js';
17
- const CORE = {
18
- matchRoute, resolvePartialName, extractBearerToken, classifyContentType,
19
- checkSteeringCsrf, checkTriageCsrf, extractFormText, extractJsonText,
20
- decideCreateIssue, decideMoveTransition, buildIssueDetailDto,
21
- buildSnapshot, buildHealthRollup, buildSessionTotalsView,
22
- renderDashboardHtml, renderHeaderPartial, renderHealthPartial, renderAttentionPartial,
23
- renderBoardPartial, renderTotalsPartial, renderIssueDetailPage, renderIssueNotFoundPage,
24
- };
25
- const CLOCK = { now: () => 1_700_000_000_000, iso: () => '2023-11-14T22:13:20.000Z' };
26
- /** A no-op LogSink (the handler only emits best-effort diagnostics). */
27
- function makeLog() {
28
- const sink = { emit: () => undefined, withIssue: () => sink };
29
- return sink;
30
- }
31
- const CFG = {
32
- workflow_path: '/repo/WORKFLOW.md',
33
- workflow_dir: '/repo',
34
- tracker: { kind: 'local', root: '/tracker', states: { Triage: { role: 'holding' }, Todo: { role: 'active' }, Done: { role: 'terminal' } } },
35
- prompt: { preamble_file: null, footer_file: null },
36
- polling: { interval_ms: 5000 },
37
- workspace: { root: '/ws', base_branch: 'main', github_repo: null },
38
- logs: { root: '/logs' },
39
- agent: { max_concurrent_agents: 3, max_turns: 20, max_retry_backoff_ms: 60000, memory_admission_enabled: false, host_memory_reserve_mib: 1024, circuit_breaker_threshold: 0 },
40
- acp: { adapter: 'claude', model: null, effort: null, shell: 'bash', prompt_timeout_ms: 0, read_timeout_ms: 0, stall_timeout_ms: 0, connect_timeout_ms: 0, heartbeat_interval_ms: 0, heartbeat_timeout_ms: 0 },
41
- gondolin: { image: 'sha256:deadbeefcafe', managed_image: false, oci_image: null, oci_pull_policy: 'if-not-present', oci_runtime: null, cpus: 2, mem_mib: 2048, rootfs_size: '3G', volumes: [], forward_env: [], guest_agent_path: '/opt/agent.mjs', node_bin: 'node', mise: { data_dir: '/home/test/.symphony/mise' } },
42
- egress: { allowed_hosts: [] },
43
- server: { port: null, host: '127.0.0.1' },
44
- mcp: { enabled: false, host: 'symphony-mcp', explicit_host_url: null },
45
- pr: { enabled: false, poll_interval_ms: 30000 },
46
- credentials: { ticker_interval_ms: 0, refresh_margin_ms: 300_000 },
47
- states: { Triage: { role: 'holding' }, Todo: { role: 'active' }, Done: { role: 'terminal' } },
48
- };
49
- /** A fake orchestrator + in-memory tracker. `disk` is the simulated tracker disk. */
50
- function makeDeps(opts) {
51
- const running = opts?.running ?? [];
52
- const retrying = opts?.retrying ?? [];
53
- let disk = opts?.disk ?? [];
54
- // readIssue resolves from `details` (the move tests' multi-issue disk) falling
55
- // back to the single `detail` (the issue-detail page test).
56
- const details = opts?.details ?? (opts?.detail ? [opts.detail] : []);
57
- const cfg = opts?.cfg ?? CFG;
58
- // Operator HTTP actions now fold an event through the single `dispatch` door
59
- // (no more `triggerRefresh` side-call). The poll-nudge is an `operator_nudge`
60
- // event; `refreshes()` counts those so the existing nudge-count assertions hold.
61
- const dispatched = [];
62
- const writes = [];
63
- const moves = [];
64
- const deps = {
65
- core: CORE,
66
- orchestrator: {
67
- runningEntries: () => running,
68
- retryEntries: () => retrying,
69
- claimedIds: () => new Set(),
70
- lastPollAtIso: () => '2023-11-14T22:13:10.000Z',
71
- ...(opts?.imageBuildState ? { imageBuildState: opts.imageBuildState } : {}),
72
- ...(opts?.imageFailureState ? { imageFailureState: opts.imageFailureState } : {}),
73
- dispatch: (event) => { dispatched.push(event); },
74
- },
75
- tracker: {
76
- listIssues: async () => disk,
77
- readIssue: async (_root, identifier) => details.find((d) => d.identifier === identifier) ?? null,
78
- writeIssue: async (effect) => {
79
- writes.push(effect);
80
- const newId = effect.identifier ?? String(disk.length + 1);
81
- // Mirror the real tracker adapter's create-409 contract: an EXPLICIT
82
- // identifier that already exists is a collision, not a silent overwrite.
83
- if (effect.identifier && disk.some((d) => d.identifier === effect.identifier)) {
84
- throw Object.assign(new Error(`issue ${effect.identifier} already exists`), { code: 'local_issue_target_exists' });
85
- }
86
- disk = [...disk, { identifier: newId, state: effect.state, title: effect.title, proposed_by: null, proposed_at: null }];
87
- return { kind: 'write_issue', path: `/tracker/${effect.state}/${newId}.md`, identifier: newId, state: effect.state };
88
- },
89
- // Echo the from-state the handler resolved (the file's actual directory) so
90
- // a test can assert the RIGHT file was moved — the issue-126 mis-routing fix.
91
- moveIssueToState: async (issueId, toState, o) => {
92
- moves.push({ issueId, toState, ...o });
93
- return { fromState: o?.fromState ?? '<unknown>', toState, newPath: `/tracker/${toState}/${issueId}.md` };
94
- },
95
- },
96
- clock: CLOCK,
97
- log: makeLog(),
98
- getLiveCfg: () => cfg,
99
- workflowPath: '/repo/WORKFLOW.md',
100
- ...(opts?.trackerWritable ? { trackerWritable: opts.trackerWritable } : {}),
101
- };
102
- return {
103
- deps,
104
- refreshes: () => dispatched.filter((e) => e.kind === 'operator_nudge').length,
105
- dispatched: () => dispatched,
106
- moveEvents: () => dispatched.filter((e) => e.kind === 'operator_move'),
107
- writes: () => writes,
108
- moves: () => moves,
109
- };
110
- }
111
- /** A workflow with two holding states + a transition graph, so the move tests can
112
- * exercise a holding→active move, off-flow, and the mis-routing fix. */
113
- const FLOW_CFG = {
114
- ...CFG,
115
- states: {
116
- Triage: { role: 'holding' },
117
- Parked: { role: 'holding' },
118
- Reflect: { role: 'active', allowed_transitions: ['Parked'] },
119
- Todo: { role: 'active', allowed_transitions: ['Review', 'Cancelled'] },
120
- Review: { role: 'active', allowed_transitions: ['Todo', 'Done'] },
121
- Done: { role: 'terminal' }, // open (null) ⇒ re-opening Done is in-flow
122
- Cancelled: { role: 'terminal', allowed_transitions: [] }, // dead-end ⇒ any move out is off-flow
123
- },
124
- };
125
- /** A DiskIssueDetail fixture for the move tests (only identifier + state matter). */
126
- function diskDetail(identifier, state) {
127
- return {
128
- identifier,
129
- state,
130
- filePath: `/tracker/${state}/${identifier}.md`,
131
- frontMatter: { title: identifier },
132
- body: '',
133
- };
134
- }
135
- /** An HTMX same-origin JSON-or-form move POST against the wired handler. */
136
- function movePost(deps, identifier, body) {
137
- return wireHttpHandler(deps)(req({
138
- method: 'POST',
139
- pathname: `/api/v1/issues/${identifier}/move`,
140
- headers: { 'content-type': 'application/json', host: 'symphony.local', 'hx-request': 'true' },
141
- rawBody: JSON.stringify(body),
142
- }));
143
- }
144
- function req(over) {
145
- return { method: 'GET', pathname: '/', headers: {}, rawBody: '', ...over };
146
- }
147
- test('GET / serves the dashboard HTML (200, not 503)', async () => {
148
- const { deps } = makeDeps({
149
- disk: [{ identifier: '7', state: 'Todo', title: 'wire the dashboard', proposed_by: null, proposed_at: null }],
150
- });
151
- const handle = wireHttpHandler(deps);
152
- const res = await handle(req({ pathname: '/' }));
153
- assert.equal(res.status, 200);
154
- assert.match(res.contentType, /text\/html/);
155
- assert.match(res.body, /<!doctype html>/i);
156
- assert.match(res.body, /symphony/);
157
- // The disk issue title flows into the board render.
158
- assert.match(res.body, /wire the dashboard/);
159
- });
160
- test('health strip reflects the injected tracker-writable probe (writable / unset)', async () => {
161
- // With the probe wired (true) the health strip renders `tracker=writable`.
162
- const writableDeps = makeDeps({ trackerWritable: () => true }).deps;
163
- const writableRes = await wireHttpHandler(writableDeps)(req({ pathname: '/api/v1/partials/health' }));
164
- assert.equal(writableRes.status, 200);
165
- assert.match(writableRes.body, /tracker=writable/);
166
- assert.doesNotMatch(writableRes.body, /tracker=unset/);
167
- // Without the probe (absent) it falls back to null → `tracker=unset` (the prior bug
168
- // was that this was the ONLY possible value — hardcoded null).
169
- const unsetRes = await wireHttpHandler(makeDeps().deps)(req({ pathname: '/api/v1/partials/health' }));
170
- assert.match(unsetRes.body, /tracker=unset/);
171
- // A read-only tracker root probes false → `tracker=readonly`.
172
- const roRes = await wireHttpHandler(makeDeps({ trackerWritable: () => false }).deps)(req({ pathname: '/api/v1/partials/health' }));
173
- assert.match(roRes.body, /tracker=readonly/);
174
- });
175
- test('health strip surfaces the one-time image build + failure banners through the handler (issue 206)', async () => {
176
- // The orchestrator tracks the OCI→gondolin build state; the read-surface must
177
- // FORWARD it so the `#health` strip actually renders the banner (the prior gap:
178
- // wireHttpHandler dropped the accessor, so the banner never reached the dashboard).
179
- const buildingRes = await wireHttpHandler(makeDeps({ imageBuildState: () => ({ ref: 'ghcr.io/acme/agent:1', since: '2026-06-04T00:00:00.000Z' }) }).deps)(req({ pathname: '/api/v1/partials/health' }));
180
- assert.equal(buildingRes.status, 200);
181
- assert.match(buildingRes.body, /building microVM image \(one-time setup\)/);
182
- assert.match(buildingRes.body, /ghcr\.io\/acme\/agent:1/);
183
- // A FAILED conversion stays visible while dispatch is held, with the error + remediation.
184
- const failedRes = await wireHttpHandler(makeDeps({
185
- imageFailureState: () => ({ ref: 'ghcr.io/acme/agent:1', since: '2026-06-04T00:00:00.000Z', message: 'manifest unknown' }),
186
- }).deps)(req({ pathname: '/api/v1/partials/health' }));
187
- assert.match(failedRes.body, /microVM image build failed \(VM dispatch held\)/);
188
- assert.match(failedRes.body, /manifest unknown/);
189
- assert.match(failedRes.body, /restart symphony to retry/);
190
- // Neither set ⇒ no banner (the accessors are optional; pre-206 back-compat).
191
- const plainRes = await wireHttpHandler(makeDeps().deps)(req({ pathname: '/api/v1/partials/health' }));
192
- assert.doesNotMatch(plainRes.body, /building microVM image/);
193
- assert.doesNotMatch(plainRes.body, /microVM image build failed/);
194
- });
195
- test('GET /api/v1/state returns the §9.3 snapshot JSON (200)', async () => {
196
- const running = [runningEntry({ identifier: '7' })];
197
- const { deps } = makeDeps({ running });
198
- const handle = wireHttpHandler(deps);
199
- const res = await handle(req({ pathname: '/api/v1/state' }));
200
- assert.equal(res.status, 200);
201
- assert.match(res.contentType, /application\/json/);
202
- const body = JSON.parse(res.body);
203
- assert.equal(body.running.length, 1);
204
- assert.equal(body.running[0].identifier, '7');
205
- assert.equal(body.health.running, 1);
206
- assert.equal(body.health.global_slots_total, 3);
207
- assert.equal(body.generated_at, '2023-11-14T22:13:20.000Z');
208
- });
209
- test('GET /api/v1/issues lists disk issues (200)', async () => {
210
- const { deps } = makeDeps({
211
- disk: [{ identifier: '3', state: 'Triage', title: 'proposal', proposed_by: 'agent', proposed_at: null }],
212
- });
213
- const handle = wireHttpHandler(deps);
214
- const res = await handle(req({ pathname: '/api/v1/issues' }));
215
- assert.equal(res.status, 200);
216
- const body = JSON.parse(res.body);
217
- assert.equal(body.issues.length, 1);
218
- assert.equal(body.issues[0].identifier, '3');
219
- });
220
- test('GET /issues/<id> renders the issue-detail page; missing → 404 page', async () => {
221
- const detail = {
222
- identifier: '7', state: 'Todo', filePath: '/tracker/Todo/7.md',
223
- frontMatter: { title: 'detail title' }, body: '# heading\n\nsome body',
224
- };
225
- const { deps } = makeDeps({ detail });
226
- const handle = wireHttpHandler(deps);
227
- const ok = await handle(req({ pathname: '/issues/7' }));
228
- assert.equal(ok.status, 200);
229
- assert.match(ok.contentType, /text\/html/);
230
- assert.match(ok.body, /detail title/);
231
- const missing = await handle(req({ pathname: '/issues/999' }));
232
- assert.equal(missing.status, 404);
233
- assert.match(missing.body, /issue not found/);
234
- });
235
- test('GET /issues/<id> exposes the move control for a terminal issue (off-board reachability)', async () => {
236
- // Terminal columns are kept off the board, so the detail page is where a Done /
237
- // Cancelled issue stays reachable for a move (issue 126 review follow-up). The
238
- // wired handler must serve the control + every non-terminal target.
239
- const detail = {
240
- identifier: 'fin-1', state: 'Done', filePath: '/tracker/Done/fin-1.md',
241
- frontMatter: { title: 'finished work' }, body: '',
242
- };
243
- const { deps } = makeDeps({ detail });
244
- const res = await wireHttpHandler(deps)(req({ pathname: '/issues/fin-1' }));
245
- assert.equal(res.status, 200);
246
- assert.match(res.body, /class="detail-move"/);
247
- assert.match(res.body, /id="detail-move-select"/);
248
- assert.match(res.body, /data-from="Done"/);
249
- // Done is open (null list) ⇒ moving out to any declared state is in-flow.
250
- assert.match(res.body, /<option value="Todo">Todo<\/option>/);
251
- assert.match(res.body, /<option value="Triage">Triage<\/option>/);
252
- });
253
- test('POST /api/v1/refresh dispatches an operator_nudge (coalesce an immediate poll)', async () => {
254
- const { deps, dispatched } = makeDeps();
255
- const res = await wireHttpHandler(deps)(req({ method: 'POST', pathname: '/api/v1/refresh' }));
256
- assert.equal(res.status, 204);
257
- // The operator refresh now folds a single nudge event through the dispatch door
258
- // (no imperative triggerRefresh side-call).
259
- assert.deepEqual(dispatched(), [{ kind: 'operator_nudge' }]);
260
- });
261
- test('POST /api/v1/issues is CSRF-REJECTED for a cross-origin form POST', async () => {
262
- const { deps, writes } = makeDeps();
263
- const handle = wireHttpHandler(deps);
264
- const res = await handle(req({
265
- method: 'POST',
266
- pathname: '/api/v1/issues',
267
- headers: { 'content-type': 'application/x-www-form-urlencoded', host: 'symphony.local', origin: 'https://evil.example' },
268
- rawBody: 'title=hijack',
269
- }));
270
- assert.equal(res.status, 403);
271
- const body = JSON.parse(res.body);
272
- assert.equal(body.error.code, 'forbidden');
273
- assert.equal(writes().length, 0, 'no write should land on a rejected POST');
274
- });
275
- test('POST /api/v1/issues is CSRF-ACCEPTED for an application/json POST and writes', async () => {
276
- const { deps, writes, refreshes, dispatched } = makeDeps();
277
- const handle = wireHttpHandler(deps);
278
- const res = await handle(req({
279
- method: 'POST',
280
- pathname: '/api/v1/issues',
281
- headers: { 'content-type': 'application/json', host: 'symphony.local', origin: 'https://evil.example' },
282
- rawBody: JSON.stringify({ title: 'legit new issue', state: 'Todo' }),
283
- }));
284
- assert.equal(res.status, 201);
285
- const body = JSON.parse(res.body);
286
- assert.equal(body.state, 'Todo');
287
- assert.equal(writes().length, 1);
288
- const effect = writes()[0];
289
- assert.equal(effect.title, 'legit new issue');
290
- assert.equal(effect.state, 'Todo');
291
- assert.equal(effect.trackerRoot, '/tracker');
292
- assert.equal(refreshes(), 1, 'a successful write coalesces a refresh poll');
293
- assert.deepEqual(dispatched(), [{ kind: 'operator_nudge' }], 'the create folds a nudge event');
294
- });
295
- test('POST /api/v1/issues with an OCCUPIED explicit identifier returns 409 (no overwrite)', async () => {
296
- // Seed an existing issue at identifier "5"; the create handler must surface the
297
- // tracker's local_issue_target_exists as HTTP 409, not a 500 write_failed.
298
- const { deps, writes } = makeDeps({
299
- disk: [{ identifier: '5', state: 'Todo', title: 'existing', proposed_by: null, proposed_at: null }],
300
- });
301
- const handle = wireHttpHandler(deps);
302
- const res = await handle(req({
303
- method: 'POST',
304
- pathname: '/api/v1/issues',
305
- headers: { 'content-type': 'application/json', host: 'symphony.local' },
306
- rawBody: JSON.stringify({ identifier: '5', title: 'attempted overwrite', state: 'Todo' }),
307
- }));
308
- assert.equal(res.status, 409);
309
- const body = JSON.parse(res.body);
310
- assert.equal(body.error.code, 'already_exists');
311
- // The write was attempted but rejected; no second disk entry landed.
312
- assert.equal(writes().length, 1);
313
- });
314
- test('POST /api/v1/issues rejects a bad body (no title) with 400', async () => {
315
- const { deps, writes } = makeDeps();
316
- const handle = wireHttpHandler(deps);
317
- const res = await handle(req({
318
- method: 'POST',
319
- pathname: '/api/v1/issues',
320
- headers: { 'content-type': 'application/json', host: 'symphony.local' },
321
- rawBody: JSON.stringify({ state: 'Todo' }),
322
- }));
323
- assert.equal(res.status, 400);
324
- assert.equal(writes().length, 0);
325
- });
326
- test('POST move: approve-equivalent (Triage → first active) moves with the actual from-state', async () => {
327
- const { deps, moves, refreshes, moveEvents } = makeDeps({ details: [diskDetail('3', 'Triage')] });
328
- const res = await movePost(deps, '3', { state: 'Todo', from_state: 'Triage' });
329
- assert.equal(res.status, 200);
330
- const body = JSON.parse(res.body);
331
- assert.equal(body.to_state, 'Todo');
332
- assert.equal(body.from_state, 'Triage');
333
- assert.equal(body.off_flow, false); // Triage's list is open (null) ⇒ in-flow
334
- assert.equal(moves().length, 1);
335
- assert.deepEqual(moves()[0], { issueId: '3', toState: 'Todo', fromState: 'Triage', actor: 'symphony/operator' });
336
- // The move folds a single operator_move event (issue 199): the active target's
337
- // immediate-pickup nudge is now the event's toActive flag, not a separate
338
- // operator_nudge, so refreshes() (which counts operator_nudge) is 0.
339
- assert.equal(refreshes(), 0, 'no separate operator_nudge — the nudge rides operator_move');
340
- assert.deepEqual(moveEvents(), [
341
- { kind: 'operator_move', issueId: '3', identifier: '3', toState: 'Todo', toTerminal: false, toActive: true },
342
- ]);
343
- });
344
- test('POST move: discard-equivalent (Todo → Cancelled terminal) dispatches operator_move (terminal, no nudge)', async () => {
345
- const { deps, moves, refreshes, moveEvents } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('4', 'Todo')] });
346
- const res = await movePost(deps, '4', { state: 'Cancelled', from_state: 'Todo' });
347
- assert.equal(res.status, 200);
348
- const body = JSON.parse(res.body);
349
- assert.equal(body.to_state, 'Cancelled');
350
- // A terminal target sets toTerminal (the reducer reaps the workspace) and clears
351
- // toActive (no redispatch nudge).
352
- assert.deepEqual(moveEvents(), [
353
- { kind: 'operator_move', issueId: '4', identifier: '4', toState: 'Cancelled', toTerminal: true, toActive: false },
354
- ]);
355
- assert.equal(refreshes(), 0, 'a terminal target needs no dispatch nudge');
356
- assert.equal(body.off_flow, false); // Cancelled ∈ Todo.allowed_transitions
357
- assert.equal(moves().length, 1);
358
- assert.equal(refreshes(), 0, 'a terminal target needs no dispatch nudge');
359
- });
360
- test('POST move: a holding → active move lands in the target (not Todo) and is NOT mis-routed', async () => {
361
- // The issue-122 mis-routing bug: clicking approve on a non-Triage holding issue
362
- // dispatched it into Todo. The general move lands it in the target active state
363
- // with the file's ACTUAL from_state — the right file, the right directory. The
364
- // target is active so it gets the nudge, but the move endpoint itself never
365
- // dispatches an agent (issue 126).
366
- const { deps, moves } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('reflect-1', 'Parked')] });
367
- const res = await movePost(deps, 'reflect-1', { state: 'Reflect', from_state: 'Parked' });
368
- assert.equal(res.status, 200);
369
- const body = JSON.parse(res.body);
370
- assert.equal(body.to_state, 'Reflect');
371
- assert.equal(body.from_state, 'Parked'); // NOT Todo — the mis-routing fix
372
- assert.equal(body.off_flow, false); // Parked's list is open ⇒ in-flow
373
- assert.deepEqual(moves()[0], {
374
- issueId: 'reflect-1',
375
- toState: 'Reflect',
376
- fromState: 'Parked',
377
- actor: 'symphony/operator',
378
- });
379
- });
380
- test('POST move: pulling Todo back to Triage works but is flagged off_flow', async () => {
381
- const { deps } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('5', 'Todo')] });
382
- const res = await movePost(deps, '5', { state: 'Triage', from_state: 'Todo' });
383
- assert.equal(res.status, 200);
384
- const body = JSON.parse(res.body);
385
- assert.equal(body.to_state, 'Triage');
386
- assert.equal(body.off_flow, true); // Triage ∉ Todo.allowed_transitions
387
- });
388
- test('POST move: Review → Done is an ordinary in-flow move', async () => {
389
- const { deps } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('6', 'Review')] });
390
- const res = await movePost(deps, '6', { state: 'Done', from_state: 'Review' });
391
- assert.equal(res.status, 200);
392
- const body = JSON.parse(res.body);
393
- assert.equal(body.to_state, 'Done');
394
- assert.equal(body.off_flow, false); // Done ∈ Review.allowed_transitions
395
- });
396
- test('POST move: an off-flow Review → Cancelled still applies and carries off_flow:true', async () => {
397
- const { deps, moves } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('7', 'Review')] });
398
- const res = await movePost(deps, '7', { state: 'Cancelled', from_state: 'Review' });
399
- assert.equal(res.status, 200, 'the operator move is never blocked, even off-flow');
400
- const body = JSON.parse(res.body);
401
- assert.equal(body.to_state, 'Cancelled');
402
- assert.equal(body.off_flow, true); // Cancelled ∉ Review.allowed_transitions
403
- assert.equal(moves().length, 1, 'the move was applied despite the off-flow warning');
404
- });
405
- test('POST move: a terminal Done issue can be re-opened to an active state (in-flow, nudged)', async () => {
406
- // Terminal issues are kept off the board but stay reachable via the detail-page
407
- // move control (issue 126). Re-opening Done → Todo applies, moves the RIGHT file
408
- // (from-state Done, not mis-routed), and earns approve's immediate-pickup nudge
409
- // since Todo is active.
410
- const { deps, moves, moveEvents } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('done-1', 'Done')] });
411
- const res = await movePost(deps, 'done-1', { state: 'Todo', from_state: 'Done' });
412
- assert.equal(res.status, 200);
413
- const body = JSON.parse(res.body);
414
- assert.equal(body.to_state, 'Todo');
415
- assert.equal(body.from_state, 'Done');
416
- assert.equal(body.off_flow, false); // Done's list is open (null) ⇒ in-flow
417
- assert.deepEqual(moves()[0], { issueId: 'done-1', toState: 'Todo', fromState: 'Done', actor: 'symphony/operator' });
418
- // Active target ⇒ the operator_move carries toActive (the immediate-pickup nudge).
419
- assert.deepEqual(moveEvents(), [
420
- { kind: 'operator_move', issueId: 'done-1', identifier: 'done-1', toState: 'Todo', toTerminal: false, toActive: true },
421
- ]);
422
- });
423
- test('POST move: a terminal Cancelled issue pulled back to an active state is off-flow but still applies', async () => {
424
- // Cancelled declares [] (a dead-end) ⇒ every move out is off-flow; the operator
425
- // is warned client-side but the server never blocks. The active target still
426
- // gets the nudge — moving OUT of a terminal state is the reachability the review
427
- // flagged was missing.
428
- const { deps, moves, moveEvents } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('cancel-1', 'Cancelled')] });
429
- const res = await movePost(deps, 'cancel-1', { state: 'Todo', from_state: 'Cancelled' });
430
- assert.equal(res.status, 200, 'the operator move is never blocked, even off-flow');
431
- const body = JSON.parse(res.body);
432
- assert.equal(body.to_state, 'Todo');
433
- assert.equal(body.from_state, 'Cancelled');
434
- assert.equal(body.off_flow, true); // Cancelled's list is [] ⇒ off-flow
435
- assert.equal(moves().length, 1, 'the move applied despite the off-flow warning');
436
- assert.equal(moveEvents()[0].toActive, true, 'an active target gets the nudge (toActive)');
437
- });
438
- test('POST move: a claimed from_state that disagrees with the file directory → 409', async () => {
439
- const { deps, moves } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('8', 'Todo')] });
440
- const res = await movePost(deps, '8', { state: 'Review', from_state: 'Triage' });
441
- assert.equal(res.status, 409);
442
- const body = JSON.parse(res.body);
443
- assert.equal(body.error.code, 'from_state_mismatch');
444
- assert.equal(moves().length, 0, 'no move on a from-state mismatch');
445
- });
446
- test('POST move: an issue not present on disk → 404', async () => {
447
- const { deps, moves } = makeDeps({ cfg: FLOW_CFG, details: [] });
448
- const res = await movePost(deps, '999', { state: 'Todo' });
449
- assert.equal(res.status, 404);
450
- assert.equal(moves().length, 0);
451
- });
452
- // ── operator move folds the cancel/cleanup/release decision into one event ────
453
- // The handler no longer pokes terminateRunning / cancelRetry inline (issue 199):
454
- // it dispatches a single operator_move event carrying the toTerminal / toActive
455
- // flags, and the reducer (tested in tests/core/tick.test.ts) turns those into a
456
- // worker.cancel effect (with cleanupWorkspace = toTerminal), a retry release, and
457
- // the active-target poll nudge. These handler tests assert the EVENT is dispatched
458
- // with the right flags regardless of whether a run / retry actually backs the issue
459
- // — the live-state decision is the reducer's, not the handler's.
460
- test('POST move: moving a LIVE issue to a terminal state dispatches operator_move (terminal ⇒ cancel-with-cleanup) (issue 199)', async () => {
461
- const live = runningEntry({ issue_id: 'run-1', identifier: 'run-1' });
462
- const { deps, moves, moveEvents, refreshes } = makeDeps({
463
- cfg: FLOW_CFG,
464
- details: [diskDetail('run-1', 'Todo')],
465
- running: [live],
466
- });
467
- const res = await movePost(deps, 'run-1', { state: 'Cancelled', from_state: 'Todo' });
468
- assert.equal(res.status, 200);
469
- assert.equal(moves().length, 1, 'the file still moves');
470
- // toTerminal:true ⇒ the reducer reaps the workspace; toActive:false ⇒ no nudge.
471
- assert.deepEqual(moveEvents(), [
472
- { kind: 'operator_move', issueId: 'run-1', identifier: 'run-1', toState: 'Cancelled', toTerminal: true, toActive: false },
473
- ]);
474
- assert.equal(refreshes(), 0, 'a terminal target needs no separate nudge');
475
- });
476
- test('POST move: moving a LIVE issue to an active state dispatches operator_move (active ⇒ cancel-without-cleanup + nudge) (issue 199)', async () => {
477
- const live = runningEntry({ issue_id: 'run-2', identifier: 'run-2' });
478
- const { deps, moveEvents } = makeDeps({
479
- cfg: FLOW_CFG,
480
- details: [diskDetail('run-2', 'Todo')],
481
- running: [live],
482
- });
483
- const res = await movePost(deps, 'run-2', { state: 'Review', from_state: 'Todo' });
484
- assert.equal(res.status, 200);
485
- // toTerminal:false ⇒ keep the workspace for the redispatch; toActive:true ⇒ nudge.
486
- assert.deepEqual(moveEvents(), [
487
- { kind: 'operator_move', issueId: 'run-2', identifier: 'run-2', toState: 'Review', toTerminal: false, toActive: true },
488
- ]);
489
- });
490
- test('POST move: the operator_move issueId is the canonical front-matter id, not the identifier (issue 199)', async () => {
491
- // The reducer matches the live running/retry entry by issue_id, so the handler
492
- // resolves the canonical id from the file's front-matter `id` (mirrors idOf),
493
- // falling back to the identifier only when absent.
494
- const detail = {
495
- identifier: 'run-3', state: 'Todo', filePath: '/tracker/Todo/run-3.md',
496
- frontMatter: { id: 'uuid-run-3', title: 'live attempt' }, body: '',
497
- };
498
- const { deps, moveEvents } = makeDeps({ cfg: FLOW_CFG, details: [detail] });
499
- const res = await movePost(deps, 'run-3', { state: 'Cancelled', from_state: 'Todo' });
500
- assert.equal(res.status, 200);
501
- assert.equal(moveEvents()[0].issueId, 'uuid-run-3', 'issueId derives from front-matter id');
502
- assert.equal(moveEvents()[0].identifier, 'run-3');
503
- });
504
- test('POST move: a settled / holding-target move still dispatches operator_move (no live-state peek) (issue 199)', async () => {
505
- // No running/retry fixtures, and Triage is a holding state ⇒ neither flag set.
506
- // The handler dispatches unconditionally; the reducer no-ops when nothing live
507
- // backs the issue. This documents that the handler does NOT consult live state.
508
- const { deps, moves, moveEvents, refreshes } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('5', 'Todo')] });
509
- const res = await movePost(deps, '5', { state: 'Triage', from_state: 'Todo' });
510
- assert.equal(res.status, 200);
511
- assert.equal(moves().length, 1);
512
- assert.deepEqual(moveEvents(), [
513
- { kind: 'operator_move', issueId: '5', identifier: '5', toState: 'Triage', toTerminal: false, toActive: false },
514
- ]);
515
- assert.equal(refreshes(), 0, 'a holding target needs no nudge');
516
- });
517
- test('POST move: moving a RETRYING issue dispatches operator_move (reducer releases the pending retry) (issue 199)', async () => {
518
- // A retrying row has no live worker; the reducer turns the operator_move into a
519
- // retry release (tested in tick.test.ts). The handler dispatches the same event
520
- // shape — an active target carries toActive so the freed claim is redispatched now.
521
- const retry = retryEntry({ issue_id: 'retry-1', identifier: 'retry-1' });
522
- const { deps, moves, moveEvents } = makeDeps({
523
- cfg: FLOW_CFG,
524
- details: [diskDetail('retry-1', 'Todo')],
525
- retrying: [retry],
526
- });
527
- const res = await movePost(deps, 'retry-1', { state: 'Review', from_state: 'Todo' });
528
- assert.equal(res.status, 200);
529
- assert.equal(moves().length, 1, 'the file still moves');
530
- assert.deepEqual(moveEvents(), [
531
- { kind: 'operator_move', issueId: 'retry-1', identifier: 'retry-1', toState: 'Review', toTerminal: false, toActive: true },
532
- ]);
533
- });
534
- test('POST move: an undeclared target → 400', async () => {
535
- const { deps, moves } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('9', 'Todo')] });
536
- const res = await movePost(deps, '9', { state: 'Nowhere', from_state: 'Todo' });
537
- assert.equal(res.status, 400);
538
- assert.equal(moves().length, 0);
539
- });
540
- test('POST move is CSRF-REJECTED for a cross-origin form POST', async () => {
541
- const { deps, moves } = makeDeps({ cfg: FLOW_CFG, details: [diskDetail('3', 'Triage')] });
542
- const res = await wireHttpHandler(deps)(req({
543
- method: 'POST',
544
- pathname: '/api/v1/issues/3/move',
545
- headers: { 'content-type': 'application/x-www-form-urlencoded', host: 'symphony.local', origin: 'https://evil.example' },
546
- rawBody: 'state=Todo',
547
- }));
548
- assert.equal(res.status, 403);
549
- assert.equal(moves().length, 0, 'no move should land on a rejected POST');
550
- });
551
- test('the MCP control-plane routes 503 when no runtime is wired (mcp-absent build)', async () => {
552
- // makeDeps omits the `mcp` surface (an mcp.enabled=false build), so the routes
553
- // fall back to an honest 503. The wired-runtime path is covered in mcp-runtime.test.ts.
554
- const { deps } = makeDeps();
555
- const handle = wireHttpHandler(deps);
556
- const mcp = await handle(req({ method: 'POST', pathname: '/api/v1/issues/3/mcp', rawBody: '{}' }));
557
- assert.equal(mcp.status, 503);
558
- assert.match(mcp.body, /mcp_not_wired/);
559
- const steering = await handle(req({
560
- method: 'POST', pathname: '/api/v1/issues/3/steering-reply',
561
- headers: { 'content-type': 'application/json' }, rawBody: '{}',
562
- }));
563
- assert.equal(steering.status, 503);
564
- });
565
- test('an unknown path 404s (never routes into product code)', async () => {
566
- const { deps } = makeDeps();
567
- const handle = wireHttpHandler(deps);
568
- const res = await handle(req({ pathname: '/nope' }));
569
- assert.equal(res.status, 404);
570
- });
571
- // ── a minimal RunningEntry fixture ───────────────────────────────────────────
572
- function runningEntry(over = {}) {
573
- return {
574
- issue_id: 'id-7',
575
- identifier: '7',
576
- issue: {
577
- id: 'id-7', identifier: '7', title: 'live attempt', description: 'doing work',
578
- priority: null, state: 'Todo', branch_name: null, url: null, labels: [],
579
- blocked_by: [], created_at: null, updated_at: null,
580
- },
581
- session_id: 'sess-1', thread_id: null, turn_id: null, adapter_pid: null,
582
- last_event: 'turn_started', last_event_at: '2023-11-14T22:13:15.000Z', last_message: 'working',
583
- input_tokens: 100, output_tokens: 50, total_tokens: 150,
584
- last_reported_input_tokens: 0, last_reported_output_tokens: 0, last_reported_total_tokens: 0,
585
- turn_count: 1, retry_attempt: null, started_at: '2023-11-14T22:13:00.000Z', workspace_path: '/ws/7',
586
- cancel: () => undefined, recent_events: [], last_error: null, cleanup_workspace_on_exit: false,
587
- mcp_token: null, tracker_root_at_dispatch: '/tracker', github_repo_at_dispatch: null,
588
- base_branch_at_dispatch: 'main', resolved_actor: 'claude/default', transitioned: false,
589
- steering_requested: false, steering_question: null, steering_context: null,
590
- active_tool_calls: new Set(), last_transition: null,
591
- ...over,
592
- };
593
- }
594
- // ── a minimal RetryEntry fixture (a pending backoff/continuation) ─────────────
595
- function retryEntry(over = {}) {
596
- return {
597
- issue_id: 'id-retry',
598
- identifier: 'retry-0',
599
- attempt: 1,
600
- due_at_ms: 1_700_000_000_000,
601
- timer_handle: null,
602
- error: null,
603
- kind: 'failure',
604
- target_state: 'Todo',
605
- ...over,
606
- };
607
- }
608
- //# sourceMappingURL=http-handler.test.js.map