@bastani/atomic 0.10.5 → 0.10.6

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 (315) hide show
  1. package/CHANGELOG.md +58 -0
  2. package/dist/THIRD_PARTY_NOTICES.md +1 -1
  3. package/dist/_shared/APEv2Parser-APXNTTFS.js.map +1 -1
  4. package/dist/_shared/AsfParser-AP272OWG.js +1 -1
  5. package/dist/_shared/DsfParser-FTOZZCZP.js +2 -2
  6. package/dist/_shared/FlacParser-WJATCQT6.js +2 -2
  7. package/dist/_shared/FlacParser-WJATCQT6.js.map +1 -1
  8. package/dist/_shared/ID3v1Parser-XVX6XPGB.js +1 -1
  9. package/dist/_shared/ID3v2Parser-DB2T4Z6M.js +2 -2
  10. package/dist/_shared/MP4Parser-2TZWZV4K.js +3 -3
  11. package/dist/_shared/MP4Parser-2TZWZV4K.js.map +1 -1
  12. package/dist/_shared/MatroskaParser-V22CGP72.js.map +1 -1
  13. package/dist/_shared/MusepackParser-XEUVYWNQ.js +2 -2
  14. package/dist/_shared/MusepackParser-XEUVYWNQ.js.map +1 -1
  15. package/dist/_shared/OggParser-Y7FSZNTO.js +1 -1
  16. package/dist/_shared/OggParser-Y7FSZNTO.js.map +1 -1
  17. package/dist/_shared/ParseError-VXOGXIIE.js +2 -2
  18. package/dist/_shared/ParseError-VXOGXIIE.js.map +1 -1
  19. package/dist/_shared/WavPackParser-ZYK4CLSW.js +1 -1
  20. package/dist/_shared/WaveParser-VA3P7P3H.js +2 -2
  21. package/dist/_shared/dist-KOELCESV.js +55 -63
  22. package/dist/_shared/dist-KOELCESV.js.map +1 -1
  23. package/dist/_shared/fork-row-index-UAUAQRD5.js +3 -3
  24. package/dist/_shared/full.umd-CBF7UGXV.js +7 -6
  25. package/dist/_shared/full.umd-CBF7UGXV.js.map +1 -1
  26. package/dist/_shared/http-YFAPTIZD.js +2 -2
  27. package/dist/_shared/http-YFAPTIZD.js.map +1 -1
  28. package/dist/_shared/http-undici-FVPTZA4G.js +19 -20
  29. package/dist/_shared/http-undici-FVPTZA4G.js.map +1 -1
  30. package/dist/_shared/lib-4PES5P4V.js +8 -8
  31. package/dist/_shared/lib-4PES5P4V.js.map +1 -1
  32. package/dist/_shared/mode-interactive-sdk-7KXUFI2F.js +5 -4
  33. package/dist/_shared/mode-interactive-sdk-7KXUFI2F.js.map +1 -1
  34. package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js +20 -20
  35. package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js.map +1 -1
  36. package/dist/_shared/mode-shared-2QJSCUM6.js +441 -341
  37. package/dist/_shared/mode-shared-2QJSCUM6.js.map +1 -1
  38. package/dist/_shared/p0-cli-BB45ZQY6.js +8 -12
  39. package/dist/_shared/p0-cli-BB45ZQY6.js.map +1 -1
  40. package/dist/_shared/p1a-prewarm-UQY3X2UK.js +8 -8
  41. package/dist/_shared/p1b-elig-ENCUPKKJ.js +17 -17
  42. package/dist/_shared/p1b-elig-ENCUPKKJ.js.map +1 -1
  43. package/dist/_shared/p2-shell-TJBYQMCJ.js +27 -28
  44. package/dist/_shared/p2-shell-TJBYQMCJ.js.map +1 -1
  45. package/dist/_shared/p2-shell-main-B2WIALFD.js +44 -47
  46. package/dist/_shared/p2-shell-main-B2WIALFD.js.map +1 -1
  47. package/dist/_shared/rolldown-runtime-BGM3D5V3.js +4 -4
  48. package/dist/_shared/runtime-O4KCSG4C.js +7 -7
  49. package/dist/_shared/runtime-O4KCSG4C.js.map +1 -1
  50. package/dist/_shared/sdk-WQIOHVKO.js +24 -24
  51. package/dist/_shared/sdk-WQIOHVKO.js.map +1 -1
  52. package/dist/_shared/session-data-AHTU7IS6.js +4 -4
  53. package/dist/_shared/session-manager-list-2BLEEZVG.js +3 -3
  54. package/dist/_shared/{settings-startup-65YEWRV2.js → settings-startup-4QCVCI53.js} +2 -32
  55. package/dist/_shared/settings-startup-4QCVCI53.js.map +1 -0
  56. package/dist/_shared/settings-startup-8-DNZ2RIHM.js +35 -0
  57. package/dist/_shared/settings-startup-8-DNZ2RIHM.js.map +1 -0
  58. package/dist/_shared/sql-session-store-5FD3WBMZ.js +12 -12
  59. package/dist/_shared/startup-0-0-TYUFUOJZ.js +143 -115
  60. package/dist/_shared/startup-0-0-TYUFUOJZ.js.map +1 -1
  61. package/dist/_shared/{startup-0-1-D4LGGINF.js → startup-0-1-W2G2UY7R.js} +365 -27
  62. package/dist/_shared/startup-0-1-W2G2UY7R.js.map +1 -0
  63. package/dist/_shared/startup-0-2-SZGQIWHI.js +19 -24
  64. package/dist/_shared/startup-0-2-SZGQIWHI.js.map +1 -1
  65. package/dist/_shared/startup-0-3-T4DVFYWX.js +7 -7
  66. package/dist/_shared/startup-0-3-T4DVFYWX.js.map +1 -1
  67. package/dist/_shared/startup-0-4-HN5EB4K7.js +7 -7
  68. package/dist/_shared/startup-0-4-HN5EB4K7.js.map +1 -1
  69. package/dist/_shared/startup-0-5-OHJNE6JH.js +157 -92
  70. package/dist/_shared/startup-0-5-OHJNE6JH.js.map +1 -1
  71. package/dist/_shared/startup-10-0-TDQNBDDL.js +4 -4
  72. package/dist/_shared/startup-10-0-TDQNBDDL.js.map +1 -1
  73. package/dist/_shared/startup-14-0-MLX36RBG.js +19 -19
  74. package/dist/_shared/startup-14-0-MLX36RBG.js.map +1 -1
  75. package/dist/_shared/startup-15-0-YUKGAC63.js +17 -16
  76. package/dist/_shared/startup-15-0-YUKGAC63.js.map +1 -1
  77. package/dist/_shared/startup-15-1-4S7FLMNG.js +5 -5
  78. package/dist/_shared/startup-15-1-4S7FLMNG.js.map +1 -1
  79. package/dist/_shared/startup-8-0-34CBHPZH.js +23 -23
  80. package/dist/_shared/startup-8-0-34CBHPZH.js.map +1 -1
  81. package/dist/_shared/startup-8-1-SJW2GMAM.js +113 -114
  82. package/dist/_shared/startup-8-1-SJW2GMAM.js.map +1 -1
  83. package/dist/_shared/storage-command-7MGXLJGZ.js +15 -14
  84. package/dist/_shared/storage-command-7MGXLJGZ.js.map +1 -1
  85. package/dist/_shared/task-reference-stream-JWMUZSJX.js +7 -7
  86. package/dist/_shared/task-reference-stream-JWMUZSJX.js.map +1 -1
  87. package/dist/_shared/task-unsaved-answer-VJ2KTB4V.js +2 -2
  88. package/dist/_shared/tree-outline-MUEPK5B7.js +4 -4
  89. package/dist/_shared/turndown.cjs-7Z43JOED.js +7 -10
  90. package/dist/_shared/turndown.cjs-7Z43JOED.js.map +1 -1
  91. package/dist/builtin/intercom/CHANGELOG.md +12 -0
  92. package/dist/builtin/intercom/index.bundle.mjs +2 -2
  93. package/dist/builtin/intercom/package.json +1 -1
  94. package/dist/builtin/mcp/index.bundle.mjs +1 -1
  95. package/dist/builtin/mcp/package.json +1 -1
  96. package/dist/builtin/subagents/CHANGELOG.md +12 -0
  97. package/dist/builtin/subagents/package.json +1 -1
  98. package/dist/builtin/subagents/src/extension/index.bundle.mjs +15 -12
  99. package/dist/builtin/web-access/index.bundle.mjs +1 -1
  100. package/dist/builtin/web-access/package.json +1 -1
  101. package/dist/cli/args.js +1 -1
  102. package/dist/cli/auth-cli.code.js +10 -13
  103. package/dist/cli/auth-cli.code.js.map +1 -1
  104. package/dist/cli/auth-cli.impl.js +3 -3
  105. package/dist/cli/auth-cli.js +3 -3
  106. package/dist/cli/blueprint-command.code.js +8 -8
  107. package/dist/cli/blueprint-command.impl.js +3 -3
  108. package/dist/cli/blueprint-command.js +3 -3
  109. package/dist/cli/intercom-command.code.js +2 -2
  110. package/dist/cli/intercom-command.impl.js +3 -3
  111. package/dist/cli/intercom-command.js +3 -3
  112. package/dist/cli/list-models.code.js +3 -3
  113. package/dist/cli/list-models.impl.js +3 -3
  114. package/dist/cli/list-models.js +3 -3
  115. package/dist/cli/session-picker.code.js +3 -3
  116. package/dist/cli/session-picker.impl.js +3 -3
  117. package/dist/cli/session-picker.js +3 -3
  118. package/dist/cli/settings-startup.js +1 -1
  119. package/dist/cli/startup-ui.impl.js +3 -3
  120. package/dist/cli/startup-ui.js +3 -3
  121. package/dist/cli/storage-command.impl.js +3 -3
  122. package/dist/cli/storage-command.js +3 -3
  123. package/dist/cli/storage-search-session.code.js +4 -4
  124. package/dist/cli/storage-search-session.impl.js +3 -3
  125. package/dist/cli/storage-search-session.js +3 -3
  126. package/dist/cli/team-command.code.js +3 -3
  127. package/dist/cli/team-command.impl.js +3 -3
  128. package/dist/cli/team-command.js +3 -3
  129. package/dist/cli.js +2 -2
  130. package/dist/cli.js.map +1 -1
  131. package/dist/core/debug.impl.js +3 -3
  132. package/dist/core/debug.js +3 -3
  133. package/dist/core/export-html/card-projection.code.js +2 -2
  134. package/dist/core/export-html/card-projection.code.js.map +1 -1
  135. package/dist/core/export-html/card-projection.impl.js +3 -3
  136. package/dist/core/export-html/card-projection.js +3 -3
  137. package/dist/core/export-html/index.code.js +9 -9
  138. package/dist/core/export-html/index.code.js.map +1 -1
  139. package/dist/core/export-html/index.impl.js +3 -3
  140. package/dist/core/export-html/index.js +3 -3
  141. package/dist/core/export-html/json-spans.impl.js +3 -3
  142. package/dist/core/export-html/json-spans.js +3 -3
  143. package/dist/core/export-html/oversized-render-inputs.code.js +1 -1
  144. package/dist/core/export-html/oversized-render-inputs.impl.js +3 -3
  145. package/dist/core/export-html/oversized-render-inputs.js +3 -3
  146. package/dist/core/export-html/tool-renderer.code.js +1 -1
  147. package/dist/core/export-html/tool-renderer.impl.js +3 -3
  148. package/dist/core/export-html/tool-renderer.js +3 -3
  149. package/dist/core/extensions/jiti-loader.impl.js +3 -3
  150. package/dist/core/extensions/jiti-loader.js +3 -3
  151. package/dist/core/extensions/jiti-static-loader.impl.js +3 -3
  152. package/dist/core/extensions/jiti-static-loader.js +3 -3
  153. package/dist/core/extensions/loader-host-modules.code.js +1 -1
  154. package/dist/core/extensions/loader-host-modules.impl.js +3 -3
  155. package/dist/core/extensions/loader-host-modules.js +3 -3
  156. package/dist/core/extensions/loader-virtual-modules.js +1 -1
  157. package/dist/core/extensions/runner-context.js +5 -5
  158. package/dist/core/extensions/runner-context.js.map +1 -1
  159. package/dist/core/http-dispatcher.js +2 -0
  160. package/dist/core/intercom-broker-control-host.impl.js +3 -3
  161. package/dist/core/intercom-broker-control-host.js +3 -3
  162. package/dist/core/intercom-broker-control.code.js +3 -3
  163. package/dist/core/intercom-broker-control.impl.js +3 -3
  164. package/dist/core/intercom-broker-control.js +3 -3
  165. package/dist/core/package-manager-storage-adapters.impl.js +3 -3
  166. package/dist/core/package-manager-storage-adapters.js +3 -3
  167. package/dist/core/sdk.code.js +1 -1
  168. package/dist/core/sdk.impl.js +3 -3
  169. package/dist/core/sdk.js +3 -3
  170. package/dist/core/session-manager-core.js +15 -15
  171. package/dist/core/session-manager-core.js.map +1 -1
  172. package/dist/core/session-manager-list.impl.js +3 -3
  173. package/dist/core/session-manager-list.js +3 -3
  174. package/dist/core/session-manager.code.js +1 -1
  175. package/dist/core/session-manager.impl.js +3 -3
  176. package/dist/core/session-manager.js +3 -3
  177. package/dist/core/session-storage.impl.js +3 -3
  178. package/dist/core/session-storage.js +3 -3
  179. package/dist/core/storage/index.js +2 -2
  180. package/dist/core/storage/node-sqlite-thread.js +2 -2
  181. package/dist/core/storage/node-sqlite.js +2 -2
  182. package/dist/core/storage/offline-snapshot-file.code.js +1 -1
  183. package/dist/core/storage/offline-snapshot-file.impl.js +3 -3
  184. package/dist/core/storage/offline-snapshot-file.js +3 -3
  185. package/dist/core/storage/provider.js +2 -2
  186. package/dist/core/storage/selection.js +2 -2
  187. package/dist/core/storage/session/branch-fork-source.code.js +3 -3
  188. package/dist/core/storage/session/branch-fork-source.impl.js +3 -3
  189. package/dist/core/storage/session/branch-fork-source.js +3 -3
  190. package/dist/core/storage/session/card-view.impl.js +3 -3
  191. package/dist/core/storage/session/card-view.js +3 -3
  192. package/dist/core/storage/session/child-reader.code.js +5 -4
  193. package/dist/core/storage/session/child-reader.code.js.map +1 -1
  194. package/dist/core/storage/session/child-reader.impl.js +3 -3
  195. package/dist/core/storage/session/child-reader.js +3 -3
  196. package/dist/core/storage/session/chunked-resume-projection.impl.js +3 -3
  197. package/dist/core/storage/session/chunked-resume-projection.js +3 -3
  198. package/dist/core/storage/session/errors.js +1 -0
  199. package/dist/core/storage/session/errors.js.map +1 -1
  200. package/dist/core/storage/session/expanded-child-details.code.js +4 -4
  201. package/dist/core/storage/session/expanded-child-details.impl.js +3 -3
  202. package/dist/core/storage/session/expanded-child-details.js +3 -3
  203. package/dist/core/storage/session/fork-row-bytes.impl.js +3 -3
  204. package/dist/core/storage/session/fork-row-bytes.js +3 -3
  205. package/dist/core/storage/session/fork-row-index.impl.js +3 -3
  206. package/dist/core/storage/session/fork-row-index.js +3 -3
  207. package/dist/core/storage/session/fork-staging.code.js +5 -4
  208. package/dist/core/storage/session/fork-staging.code.js.map +1 -1
  209. package/dist/core/storage/session/fork-staging.impl.js +3 -3
  210. package/dist/core/storage/session/fork-staging.js +3 -3
  211. package/dist/core/storage/session/fork-window.code.js +3 -3
  212. package/dist/core/storage/session/fork-window.impl.js +3 -3
  213. package/dist/core/storage/session/fork-window.js +3 -3
  214. package/dist/core/storage/session/history-pages.impl.js +3 -3
  215. package/dist/core/storage/session/history-pages.js +3 -3
  216. package/dist/core/storage/session/jsonl-entry-projection.impl.js +3 -3
  217. package/dist/core/storage/session/jsonl-entry-projection.js +3 -3
  218. package/dist/core/storage/session/jsonl-session-store.impl.js +3 -3
  219. package/dist/core/storage/session/jsonl-session-store.js +3 -3
  220. package/dist/core/storage/session/memory-session-store.impl.js +3 -3
  221. package/dist/core/storage/session/memory-session-store.js +3 -3
  222. package/dist/core/storage/session/pinned-branch-resume.code.js +2 -2
  223. package/dist/core/storage/session/pinned-branch-resume.impl.js +3 -3
  224. package/dist/core/storage/session/pinned-branch-resume.js +3 -3
  225. package/dist/core/storage/session/released-history-files.code.js +12 -12
  226. package/dist/core/storage/session/released-history-files.code.js.map +1 -1
  227. package/dist/core/storage/session/released-history-files.impl.js +3 -3
  228. package/dist/core/storage/session/released-history-files.js +3 -3
  229. package/dist/core/storage/session/resident-fork-rows.code.js +1 -1
  230. package/dist/core/storage/session/resident-fork-rows.impl.js +3 -3
  231. package/dist/core/storage/session/resident-fork-rows.js +3 -3
  232. package/dist/core/storage/session/session-resume.impl.js +3 -3
  233. package/dist/core/storage/session/session-resume.js +3 -3
  234. package/dist/core/storage/session/snapshot-cut.impl.js +3 -3
  235. package/dist/core/storage/session/snapshot-cut.js +3 -3
  236. package/dist/core/storage/session/snapshot-history.code.js +3 -3
  237. package/dist/core/storage/session/snapshot-history.impl.js +3 -3
  238. package/dist/core/storage/session/snapshot-history.js +3 -3
  239. package/dist/core/storage/session/sql-session-store.impl.js +3 -3
  240. package/dist/core/storage/session/sql-session-store.js +3 -3
  241. package/dist/core/storage/session/tree-outline.impl.js +3 -3
  242. package/dist/core/storage/session/tree-outline.js +3 -3
  243. package/dist/core/storage/session/tree-presentation.impl.js +3 -3
  244. package/dist/core/storage/session/tree-presentation.js +3 -3
  245. package/dist/core/storage/storage-status.impl.js +3 -3
  246. package/dist/core/storage/storage-status.js +3 -3
  247. package/dist/core/storage/team.impl.js +3 -3
  248. package/dist/core/storage/team.js +3 -3
  249. package/dist/core/structured-output/index.impl.js +3 -3
  250. package/dist/core/structured-output/index.js +3 -3
  251. package/dist/core/tasks/task-completion-entry.impl.js +3 -3
  252. package/dist/core/tasks/task-completion-entry.js +3 -3
  253. package/dist/core/tasks/task-file-history.code.js +5 -5
  254. package/dist/core/tasks/task-file-history.code.js.map +1 -1
  255. package/dist/core/tasks/task-file-history.impl.js +3 -3
  256. package/dist/core/tasks/task-file-history.js +3 -3
  257. package/dist/core/tasks/task-reference-archive.code.js +11 -11
  258. package/dist/core/tasks/task-reference-archive.code.js.map +1 -1
  259. package/dist/core/tasks/task-reference-archive.js +3 -3
  260. package/dist/core/tasks/task-reference-identity.code.js +2 -2
  261. package/dist/core/tasks/task-reference-identity.js +3 -3
  262. package/dist/core/tasks/task-reference-stream.impl.js +3 -3
  263. package/dist/core/tasks/task-reference-stream.js +3 -3
  264. package/dist/core/tasks/task-unsaved-answer.impl.js +3 -3
  265. package/dist/core/tasks/task-unsaved-answer.js +3 -3
  266. package/dist/core/tasks/task-view-source.impl.js +3 -3
  267. package/dist/core/tasks/task-view-source.js +3 -3
  268. package/dist/core/tools/read-url.code.js +9 -9
  269. package/dist/core/tools/read-url.impl.js +3 -3
  270. package/dist/core/tools/read-url.js +3 -3
  271. package/dist/core/worktree-snapshot/blob-store.js +2 -2
  272. package/dist/core/worktree-snapshot/errors.code.js +1 -1
  273. package/dist/core/worktree-snapshot/errors.impl.js +3 -3
  274. package/dist/core/worktree-snapshot/errors.js +3 -3
  275. package/dist/core/worktree-snapshot/session-index-reset.impl.js +3 -3
  276. package/dist/core/worktree-snapshot/session-index-reset.js +3 -3
  277. package/dist/extensions/codemode/execute.code.js +3 -3
  278. package/dist/extensions/codemode/execute.impl.js +3 -3
  279. package/dist/extensions/codemode/execute.js +3 -3
  280. package/dist/extensions/codemode/renderer.code.js +1 -1
  281. package/dist/extensions/codemode/renderer.impl.js +3 -3
  282. package/dist/extensions/codemode/renderer.js +3 -3
  283. package/dist/extensions/mcp/cli.code.js +7 -7
  284. package/dist/extensions/mcp/cli.impl.js +3 -3
  285. package/dist/extensions/mcp/cli.js +3 -3
  286. package/dist/extensions/mcp/cli.lazy.code.js +2 -2
  287. package/dist/extensions/mcp/cli.lazy.impl.js +3 -3
  288. package/dist/extensions/mcp/cli.lazy.js +3 -3
  289. package/dist/extensions/mcp/runtime.impl.js +3 -3
  290. package/dist/extensions/mcp/runtime.js +3 -3
  291. package/dist/index.js +2 -2
  292. package/dist/main-first-time-setup.impl.js +3 -3
  293. package/dist/main-first-time-setup.js +3 -3
  294. package/dist/modes/interactive/components/stored-tree-view.code.js +2 -2
  295. package/dist/modes/interactive/components/stored-tree-view.impl.js +3 -3
  296. package/dist/modes/interactive/components/stored-tree-view.js +3 -3
  297. package/dist/modes/interactive/components/task-inspector.d.ts +10 -2
  298. package/dist/modes/interactive/components/user-message-selector-archive.impl.js +3 -3
  299. package/dist/modes/interactive/components/user-message-selector-archive.js +3 -3
  300. package/dist/package-manager-cli.code.js +14 -14
  301. package/dist/package-manager-cli.impl.js +3 -3
  302. package/dist/package-manager-cli.js +3 -3
  303. package/dist/rpc-entry.js +3 -3
  304. package/dist/startup-files.json +1 -1
  305. package/dist/startup-stages/7.js +1 -1
  306. package/dist/utils/startup-database-spare.code.js +5 -5
  307. package/dist/utils/startup-database-spare.impl.js +3 -3
  308. package/dist/utils/startup-database-spare.js +3 -3
  309. package/dist/utils/tools-manager.code.js +1 -1
  310. package/dist/utils/tools-manager.impl.js +3 -3
  311. package/dist/utils/tools-manager.js +3 -3
  312. package/docs/background-tasks.md +2 -2
  313. package/package.json +9 -9
  314. package/dist/_shared/settings-startup-65YEWRV2.js.map +0 -1
  315. package/dist/_shared/startup-0-1-D4LGGINF.js.map +0 -1
@@ -1,12 +1,12 @@
1
1
  import { __commonJSMin, __name, __require, __toESM } from "./rolldown-runtime-BGM3D5V3.js";
2
2
  import { APP_NAME, BLUEPRINT_FILE_NAME, CONFIG_DIR_NAME, ENV_MODEL_CATALOG_URL, canonicalizePath as canonicalizePath$1, canonicalizePathAsync as canonicalizePathAsync$1, createChildProcessEnvironment, createModuleRequire, findHelperExecutableAsync, getAgentDir, getAgentDirs, getBinDir, getDocsPath, getEnvValue, getExamplesPath, getExtensionTranspileCacheDir, getPathComparisonKey, getProjectConfigDirs, getReadmePath, isBunBinary, isBundledBuild, isLocalPath, isPathWithin, markPathIgnoredByCloudSync, moduleDirFromMetaUrl, normalizePath, pathsEqual, processLaunch, processLaunchAsync, rehydrateDebugError, resolutionBaseUrl, resolvePath, resolveSafeWindowsWorkingDirectoryAsync, spawnLaunchedProcess, spawnLaunchedProcessSync, stripBom, updatedInstallError } from "./p0-cli-BB45ZQY6.js";
3
3
  import { BUILTIN_PATH_PREFIX, BlueprintInvalidError, COMMAND_DETAIL_TAIL_BYTES, DEFAULT_THINKING_LEVEL, FILE_KINDS, FILE_PATTERNS, FORKED_PACKAGE_WORKSPACE_DIRS, GitUnavailableError, HOST, NETWORK_TIMEOUT_MS, POST_LOGOUT_AUTH_CHECK_TIMEOUT_MS, RESOURCE_TYPES, ROW_INTENT_META, THINKING_LEVELS, TYPEBOX_SUBPATHS, TaskCleanupError, VisualLinePreview, asyncScope, bindSavedReadLines, cancelReasonText, containProcessTree, conventionDirsForResource, createBatchedCanonicalizePathAsync, createGitEnvironment, createSyntheticSourceInfo, createTypeScriptSourceSpecifierTransform, emitProgress, experimentalToolSamplingProperty, findPreferredAvailableModel, forkedPackageExportAliases, formatNoApiKeyFoundMessage, formatSize, formatTimeoutSeconds, formatTokenCount, formatToolCallWithArgs, getDefaultSessionDirPath, getHostQuestionnaire, getManifestFromPackageJson, getResourcePathKey, getTextOutput, holdProcessDescendants, holdProcessDescendantsResult, holderRuns as holderRuns$1, isCodexTokenInvalidationError, isGitProvisionError, isGitUnavailableError, isSerializedMissingSessionCwdError, isStaleExtensionContextError, isStdoutTakenOver, isSyntheticPath, legacyWorkflowFilePaths, legacyWorkflowFilePatterns, loadConfig, loadedConfig, lockShared, longerRunAdvice, operationSignal, parseSlashCommand, raceWithAbortSignal, readTaskOutputTail, redactCredentials, redactOAuthErrorText, rehydrateMissingSessionCwdError, removedProviderMessage, replaceTabs, require_applyReviver, require_constants, require_debug, require_errors, require_identifiers, require_identity, require_ignore, require_line_counter, require_parse_options, require_resolve_end, require_resolve_props, require_stringifyComment, require_util_contains_newline, resolvePhysicalPath, resolvePhysicalPathAsync, resolveSchemaRef, resourceInternals, sanitizeMcpServers, sentinelsToAppend, serializeSessionMutation, sharedClockNow, sleep, spanElapsedMs, spawnHostProcess, taskOutcomeStatus, taskOutputText, taskStoppedForResume, thisProcess, truncateMiddle, validateGuidanceFields, windowsTemporaryFiles, withInstallLock, withLegacyPackageNames, withProgress, writeOutputFile, yieldToEventLoopIfSlow } from "./startup-0-0-TYUFUOJZ.js";
4
- import { NestedGitignore, NoUsableModelError, QuestionParamsSchema, STORAGE_JOIN_COMMAND, TaskToolError, WorkspaceBindingError, WorkspaceConfigError, WorkspaceDriftError, WorkspaceGitError, WorkspaceRestoreError, WorkspaceSandboxError, WorkspaceSnapshotError, WorkspaceTimeoutError, addResource, attachCleanupCause, cancelPausedOwnerTasks, cancelReceiptSentence, computeFocusedOptionHasPreview, createAccumulator, createProviderAlias, deferRestorePhase, formatAnswerScalar, getBuiltinExtensionEntryLabel, getCommandEnv, getLoaderAgentDirs, getToolEnv, getToolPath, getVirtualModules, gitInstallCommand, gitignoreMatcher, hasLazyBuiltinSpec, isContentFilterRefusal, isNativeBuiltinExtensionPath, isOfflineModeEnabled, isProviderCredentialRejection, isRetryableModelFailure, isRetryableSameModelFailure, isSafetyRefusalFailure, isSourceBuiltinExtensionPath, isUnrecognizedModelFailure, isWorkspaceBindingError, isWorkspaceError, isWorkspaceGitError, isWorkspaceRestoreError, isWorkspaceSnapshotError, loadVirtualModules, normalizeModelFailureSignal, normalizeModelProvider, normalizeProviderKeys, noteRestoreFetch, prewarmModelApi, readInlineCaret, readInlineDraft, registerLazyBuiltin, requestedThinkingLevelForModelSwitch, require_int as require_int$1, require_int$1 as require_int, require_log, require_re, require_timestamp, require_toJS, require_util_flow_indent_check, require_util_map_includes, require_visit, resolveResourcePath, routeKey, runCallback, sessionLifecycleCreation, settingsWriteOwner, startupRegistrationTokens, subagentsLazyBuiltinSpec, timeRestorePhase, toResolvedPaths, trackAdmittedAgentTask, trackTranspileCacheWrite, unreadablePathError, unwritablePathError, waitResultTail, withInlineDraft } from "./startup-0-1-D4LGGINF.js";
4
+ import { NestedGitignore, NoUsableModelError, QuestionParamsSchema, STORAGE_JOIN_COMMAND, TaskToolError, WorkspaceBindingError, WorkspaceConfigError, WorkspaceDriftError, WorkspaceGitError, WorkspaceRestoreError, WorkspaceSandboxError, WorkspaceSnapshotError, WorkspaceTimeoutError, addResource, attachCleanupCause, cancelPausedOwnerTasks, cancelReceiptSentence, computeFocusedOptionHasPreview, createAccumulator, createProviderAlias, deferRestorePhase, formatAnswerScalar, getBuiltinExtensionEntryLabel, getCommandEnv, getLoaderAgentDirs, getToolEnv, getToolPath, getVirtualModules, gitInstallCommand, gitignoreMatcher, hasLazyBuiltinSpec, isContentFilterRefusal, isNativeBuiltinExtensionPath, isOfflineModeEnabled, isProviderCredentialRejection, isRetryableModelFailure, isRetryableSameModelFailure, isSafetyRefusalFailure, isSourceBuiltinExtensionPath, isUnrecognizedModelFailure, isWorkspaceBindingError, isWorkspaceError, isWorkspaceGitError, isWorkspaceRestoreError, isWorkspaceSnapshotError, loadVirtualModules, normalizeModelFailureSignal, normalizeModelProvider, normalizeProviderKeys, noteRestoreFetch, prewarmModelApi, readInlineCaret, readInlineDraft, registerLazyBuiltin, requestedThinkingLevelForModelSwitch, require_int as require_int$1, require_int$1 as require_int, require_log, require_re, require_timestamp, require_toJS, require_trim_comparator_whitespace, require_util_flow_indent_check, require_util_map_includes, require_visit, resolveResourcePath, routeKey, runCallback, sessionLifecycleCreation, settingsWriteOwner, startupRegistrationTokens, subagentsLazyBuiltinSpec, timeRestorePhase, toResolvedPaths, trackAdmittedAgentTask, trackTranspileCacheWrite, unreadablePathError, unwritablePathError, waitResultTail, withInlineDraft } from "./startup-0-1-W2G2UY7R.js";
5
5
  import { TerminalTextSanitizer, graphemeAt, keyHint, loadThemeFromContent, resolveColorMode, singleLineDisplayText, terminalDisplayText } from "./p2-shell-main-B2WIALFD.js";
6
6
  import { failureDebugFields, redactUrlCredentials, releaseLock, renameReplacingAsync, renameWithRetry, reportDebugAsync, takeTakeoverMutexAsync } from "./p1b-elig-ENCUPKKJ.js";
7
7
  import { LONG_STREAM_CUT_ADVICE, ModelConfig, ResumePreconditionError, TaskSupervisor, assertSessionOpen, assertWorkspace, automaticWaitBudgetMs, buildFallbackModel, buildQuestionnaireResponse, buildToolResult, classifyRepository, findSourceInfoForPath, formatKillCall, getCallableTools, getDefaultSourceInfoForPath, getShellConfigAsync, getShellEnvAsync, importAfterEvaluation, installHostModuleBridge, isLongStreamCut, isWorkspace, nextRetryDecision, observeAccountCatalog, prepareSourceEntries, prepareSourceEntry, rebuildKillResult, recordProviderSuccess, recordedRepo, reduce, registerSourceBuiltinLoad, repeatsLongStreamCut, require_Node, require_anchors, require_directives, require_semver as require_semver$1, runCommand, runCommandCapture, runCommandSync, runWithConcurrency, sessionGenerationClosing, sessionLifetime, summarizeQuestions, taskOwnTranscriptEntries, trackSessionWork, transformTemplate, validateQuestionnaire, withDiscoveredModels, withPersonalizedCatalog, withRemoteCatalog, wrapToolDefinition } from "./startup-0-2-SZGQIWHI.js";
8
8
  import { DEFAULT_WORKTREE_SNAPSHOT_SETTINGS, FileModelsStore, InMemoryCodingAgentModelsStore, admitProviderStream, completeUtf8PrefixLength, computeEnvironmentHash, fallbackKey, getBaseDirForScope, getBaseDirsForScope, getConfigValueEnvVarNames, getGitInstallPath, getGitInstallRoot, getHomeDir, getInstalledGitInstallPath, getNpmInstallRoot, isCommandConfigValue, isConfigValueConfigured, llamaExtension, parseGitUrl, require_Alias, require_Scalar, require_compare, require_compare_build, require_inc, require_major, require_minor, require_parse, require_patch, resolveCliModel, resolveConfigValue, resolveFallbackModel as resolveFallbackModel$1, resolveFallbackModelWithoutCredentials, resolveHeadersOrThrow, resolveHeadersOrThrowAsync, resolveManagerPath, resolvePathFromBase, resolveWorktreeSnapshotSettings, sha256Hex as sha256Hex$1, snapshotBlob, splitFallbackModel, waitFor } from "./startup-0-3-T4DVFYWX.js";
9
- import { SESSION_HISTORY_PAGE_BYTES } from "./settings-startup-65YEWRV2.js";
9
+ import { SESSION_HISTORY_PAGE_BYTES } from "./settings-startup-4QCVCI53.js";
10
10
  import { AuthStorage, OutputAccumulator, ReadOnlyAuthStorage, TOOL_BLOCK_LIMITS, ToolBlock, ToolBlockMarkdown, ToolBlockRecords, accountSnapshotVersion, applyAutoloadDisabledNamePatterns, applyAutoloadDisabledPatterns, applyExtension, applyModelOverride, applyModelsJson, applyNamePatterns, applyPatterns, assertRestorePathBudget, assertWorkspaceGitAvailable, buildQuestionnaire, canonicalizeWorktreePathAsync, captureIndexPath, checkoutStoreIdOf, codemode_default, collapseToolBlockLines, composeApiKeyAuth, composeOAuthAuth, configuredApiKey, configuredHeaders, containsAuthConfig, containsCredential, containsCredentialValue, defaultWorktreeSnapshotStoreDir, formatModelLabel, formatModelReferenceLabel, gitOutput, hasGlobPattern, isEnabledByOverrides, isOverridePattern, jsonParser, pathExists as pathExists$1, rawModelHeaders, repositoryIdOf, repositoryIdsOf, require_bool as require_bool$1, require_bool$1 as require_bool, require_clean, require_coerce, require_compare_loose, require_createNode, require_diff, require_eq, require_float as require_float$1, require_float$1 as require_float, require_gt, require_gte, require_lt, require_lte, require_merge, require_neq, require_null, require_prerelease, require_rcompare, require_resolve_block_scalar, require_resolve_flow_scalar, require_rsort, require_sort, require_stringifyString, require_truncate, require_valid as require_valid$1, runWorkspaceGit, sameRemote, sharedRepositoryIdOf, sharedRepositoryIdsOf, splitPatterns, stagingWorktreeName, toLlmContent, toPosixPath as toPosixPath$2 } from "./startup-0-4-HN5EB4K7.js";
11
11
  import { SETTINGS_DEFAULTS } from "./p2-common-YLSYXMDQ.js";
12
12
  import { CODEX_FAST_ROUTE_HEADER, CODEX_FAST_ROUTE_ORIGINATOR, clearCodexFastRouteRequestMarker, installCodexFastRouteWebSocketIdentity, isFirstPartyCodexBaseUrl, markCodexFastRouteRequest, wrapCodexFastRouteFetch } from "./http-YFAPTIZD.js";
@@ -15,19 +15,19 @@ import { access, copyFile, link, lstat, mkdir, mkdtemp, open, opendir, readFile,
15
15
  import { existsSync, readFileSync, readdirSync, statSync } from "fs";
16
16
  import { basename, dirname, join, relative, resolve, sep } from "path";
17
17
  import { devNull, homedir, hostname, tmpdir } from "node:os";
18
- import * as path$1 from "node:path";
18
+ import * as path from "node:path";
19
19
  import { basename as basename$1, dirname as dirname$1, isAbsolute as isAbsolute$1, join as join$1, posix, relative as relative$1, resolve as resolve$1, sep as sep$1, toNamespacedPath } from "node:path";
20
20
  import { fileURLToPath, pathToFileURL } from "node:url";
21
21
  import { execFile, spawn } from "node:child_process";
22
22
  import { canonicalizePathAsync } from "../utils/canonical-path.js";
23
23
  import { pathExists } from "../utils/path-exists.js";
24
- import * as fs$1 from "node:fs";
24
+ import * as fs from "node:fs";
25
25
  import { constants as constants$2, existsSync as existsSync$1, readFileSync as readFileSync$1 } from "node:fs";
26
26
  import { ModelsError, Type, assertChatModel, classifierErrorResult, createModels, declarationsEqual, defaultProviderAuthContext, getCurrentSystemMessage, getCurrentTools, getOpenCodeSessionHeaders, getServiceTierCost, getSystemMessageText, imageErrorResult, isModelType, lazyStream, normalizeContext, normalizeProvider, normalizeProviderId } from "@bastani/atomic-ai";
27
27
  import { Container, Spacer, Text, decodeKittyPrintable, getKeybindings, stripTerminalSequences, truncateToWidth, visibleWidth, wrapTextWithAnsi } from "@bastani/atomic-tui";
28
28
  import chalk from "chalk";
29
29
  import { StorageAdapterLoadError, findStorageWriteLockTimeoutError } from "../core/storage/errors.js";
30
- import * as crypto$2 from "node:crypto";
30
+ import * as crypto$1 from "node:crypto";
31
31
  import { createHash, randomUUID } from "node:crypto";
32
32
  import { isDeepStrictEqual, promisify, stripVTControlCharacters } from "node:util";
33
33
  import { setTimeout as setTimeout$1 } from "node:timers/promises";
@@ -1276,7 +1276,7 @@ function objectIdBytes(head) {
1276
1276
  function indexHoldsSubmodule(bytes, oidBytes) {
1277
1277
  const view = new DataView(bytes.buffer, bytes.byteOffset, bytes.byteLength);
1278
1278
  const end = bytes.byteLength - oidBytes;
1279
- if (end < 12 || view.getUint32(0) !== 1145655875) return void 0;
1279
+ if (end < 12 || view.getUint32(0) !== 0x44495243) return void 0;
1280
1280
  const version = view.getUint32(4);
1281
1281
  if (version < 2 || version > 4) return void 0;
1282
1282
  let submodule = false;
@@ -11819,6 +11819,10 @@ function scheduleRetry(session, generation, run) {
11819
11819
  if (retryIsCurrent(session, generation)) run();
11820
11820
  }, 0);
11821
11821
  }
11822
+ /** Notify subagent drain waiters when a retry finishes outside an active prompt or interrupt wrapper. */
11823
+ function notifyRetryDrainedIfIdle(session) {
11824
+ if ((session._activePromptCount ?? 0) === 0 && (session._pendingInterruptDeliveries ?? 0) === 0 && !session.isStreaming && !session.isRetrying) session._subagentPolicy?.onTurnDrained?.();
11825
+ }
11822
11826
  function modelLabel(model) {
11823
11827
  return model ? `${model.provider}/${model.id}` : "unknown model";
11824
11828
  }
@@ -12108,8 +12112,17 @@ async function _trySwitchToFallbackModel(message) {
12108
12112
  continue;
12109
12113
  }
12110
12114
  const generation = this._retryGeneration;
12115
+ const createdRetryPromise = this._retryPromise === void 0;
12111
12116
  ensureRetryPromise(this);
12112
- await this._omitTrailingAssistantAttempt();
12117
+ try {
12118
+ await this._omitTrailingAssistantAttempt();
12119
+ } catch {
12120
+ if (createdRetryPromise && retryIsCurrent(this, generation)) {
12121
+ this._resolveRetry();
12122
+ notifyRetryDrainedIfIdle(this);
12123
+ }
12124
+ return false;
12125
+ }
12113
12126
  if (!retryIsCurrent(this, generation)) return true;
12114
12127
  await selectFallback(this, fromModel, currentThinkingLevel, nextModel, nextLevel, message.errorMessage || "Retryable model error", skipped, generation);
12115
12128
  const fallbackGeneration = this._fallbackOriginGeneration;
@@ -12132,6 +12145,7 @@ async function _trySwitchToFallbackModel(message) {
12132
12145
  this._retryAttempt = 0;
12133
12146
  this._longStreamCutRetries = 0;
12134
12147
  this._resolveRetry();
12148
+ notifyRetryDrainedIfIdle(this);
12135
12149
  }
12136
12150
  });
12137
12151
  });
@@ -12201,6 +12215,7 @@ async function _handleRetryableError(message) {
12201
12215
  this._retryAttempt = 0;
12202
12216
  this._longStreamCutRetries = 0;
12203
12217
  this._resolveRetry();
12218
+ notifyRetryDrainedIfIdle(this);
12204
12219
  return false;
12205
12220
  }
12206
12221
  ensureRetryPromise(this);
@@ -12217,6 +12232,7 @@ async function _handleRetryableError(message) {
12217
12232
  this._retryAttempt = 0;
12218
12233
  this._longStreamCutRetries = 0;
12219
12234
  this._resolveRetry();
12235
+ notifyRetryDrainedIfIdle(this);
12220
12236
  return false;
12221
12237
  }
12222
12238
  if (isLongStreamCut(message)) this._longStreamCutRetries += 1;
@@ -12230,7 +12246,25 @@ async function _handleRetryableError(message) {
12230
12246
  delayMs,
12231
12247
  errorMessage: message.errorMessage || "Unknown error"
12232
12248
  });
12233
- await this._omitTrailingAssistantAttempt();
12249
+ try {
12250
+ await this._omitTrailingAssistantAttempt();
12251
+ } catch (error) {
12252
+ if (this._retryAbortController === backoff) this._retryAbortController = void 0;
12253
+ if (retryIsCurrent(this, generation)) {
12254
+ const attempt = this._retryAttempt;
12255
+ this._retryAttempt = 0;
12256
+ this._longStreamCutRetries = 0;
12257
+ this._emit({
12258
+ type: "auto_retry_end",
12259
+ success: false,
12260
+ attempt,
12261
+ finalError: error instanceof Error ? error.message : String(error)
12262
+ });
12263
+ this._resolveRetry();
12264
+ notifyRetryDrainedIfIdle(this);
12265
+ }
12266
+ return false;
12267
+ }
12234
12268
  try {
12235
12269
  await sleep(delayMs, backoff.signal);
12236
12270
  } catch {
@@ -12238,8 +12272,37 @@ async function _handleRetryableError(message) {
12238
12272
  } finally {
12239
12273
  if (this._retryAbortController === backoff) this._retryAbortController = void 0;
12240
12274
  }
12275
+ const fallbackGeneration = this._fallbackOriginGeneration;
12241
12276
  scheduleRetry(this, generation, () => {
12242
- this.agent.continue().catch(() => {});
12277
+ this.agent.continue().catch(async (error) => {
12278
+ if (!retryIsCurrent(this, generation)) return;
12279
+ const attempt = this._retryAttempt;
12280
+ const finalError = error instanceof Error ? error.message : String(error);
12281
+ this._retryAttempt = 0;
12282
+ this._longStreamCutRetries = 0;
12283
+ this._emit({
12284
+ type: "auto_retry_end",
12285
+ success: false,
12286
+ attempt,
12287
+ finalError
12288
+ });
12289
+ if (fallbackGeneration !== void 0 && this._fallbackOriginGeneration === fallbackGeneration) {
12290
+ this._fallbackRestoreError = finalError;
12291
+ try {
12292
+ await this._settleFallbackModelScope();
12293
+ } catch {
12294
+ if (this._fallbackOriginGeneration === fallbackGeneration) finishFallbackModelScope.call(this, {
12295
+ success: false,
12296
+ from: modelLabel(this.agent.state.model ?? this.model),
12297
+ finalError
12298
+ });
12299
+ }
12300
+ }
12301
+ if (retryIsCurrent(this, generation)) {
12302
+ this._resolveRetry();
12303
+ notifyRetryDrainedIfIdle(this);
12304
+ }
12305
+ });
12243
12306
  });
12244
12307
  return true;
12245
12308
  }
@@ -12272,6 +12335,7 @@ function abortTurnRetries() {
12272
12335
  from: modelLabel(this.model)
12273
12336
  });
12274
12337
  this._resolveRetry();
12338
+ notifyRetryDrainedIfIdle(this);
12275
12339
  }
12276
12340
  /**
12277
12341
  * Wait for any in-progress retry to complete.
@@ -14682,7 +14746,7 @@ function* skip(first) {
14682
14746
  else if (name.startsWith("end")) depth--;
14683
14747
  }
14684
14748
  }
14685
- function* stringValue(limit = Infinity) {
14749
+ function* stringValue(limit = 1e400) {
14686
14750
  let value = "";
14687
14751
  for (let token = yield; token.name === "stringChunk"; token = yield) if (value.length < limit) value += token.value.slice(0, limit - value.length);
14688
14752
  return value;
@@ -14692,7 +14756,7 @@ function feed(reader) {
14692
14756
  packValues: false,
14693
14757
  packNumbers: true,
14694
14758
  streamNumbers: false,
14695
- maxDepth: Infinity
14759
+ maxDepth: 1e400
14696
14760
  });
14697
14761
  reader.next();
14698
14762
  return (text) => {
@@ -14754,7 +14818,7 @@ function* readValue(first, shape) {
14754
14818
  case "startObject": {
14755
14819
  const fields = shape === "child" ? childFields : shape === "usage" ? usageTotals : shape === "owner" ? { sessionId: true } : typeof shape === "object" ? shape : {};
14756
14820
  const allKeys = shape === "child" || shape === true;
14757
- const limit = allKeys ? Infinity : Math.max(0, ...Object.keys(fields).map((key) => key.length)) + 1;
14821
+ const limit = allKeys ? 1e400 : Math.max(0, ...Object.keys(fields).map((key) => key.length)) + 1;
14758
14822
  const out = Object.create(null);
14759
14823
  while ((yield).name !== "endObject") {
14760
14824
  const key = yield* stringValue(limit);
@@ -14841,7 +14905,7 @@ function* readValue(first, shape) {
14841
14905
  for (let token = yield; token.name === "stringChunk"; token = yield) present ||= token.value.trim().length > 0;
14842
14906
  return present;
14843
14907
  }
14844
- return yield* stringValue(shape === "short" ? 64 : shape === "hash" ? 65 : shape === "searchText" ? 65537 : Infinity);
14908
+ return yield* stringValue(shape === "short" ? 64 : shape === "hash" ? 65 : shape === "searchText" ? 65537 : 1e400);
14845
14909
  case "numberValue": return Number(first.value);
14846
14910
  case "trueValue":
14847
14911
  case "falseValue":
@@ -15739,7 +15803,7 @@ let createResolver;
15739
15803
  let settledPathImport;
15740
15804
  const runtimeResolvers = /* @__PURE__ */ new Map();
15741
15805
  function runtimeResolverFor(importer) {
15742
- const directory = path$1.dirname(importer);
15806
+ const directory = path.dirname(importer);
15743
15807
  let resolver = runtimeResolvers.get(directory);
15744
15808
  if (!resolver) {
15745
15809
  resolver = createResolver(pathToFileURL(importer).href);
@@ -15748,19 +15812,19 @@ function runtimeResolverFor(importer) {
15748
15812
  return resolver;
15749
15813
  }
15750
15814
  function isReloadableScriptPath(filePath) {
15751
- return SCRIPT_EXTENSIONS.has(path$1.extname(filePath));
15815
+ return SCRIPT_EXTENSIONS.has(path.extname(filePath));
15752
15816
  }
15753
15817
  function packageRootOf(filePath) {
15754
- const segments = path$1.normalize(filePath).split(path$1.sep);
15818
+ const segments = path.normalize(filePath).split(path.sep);
15755
15819
  const index = segments.lastIndexOf("node_modules");
15756
- return segments.slice(0, index + (segments[index + 1].startsWith("@") ? 3 : 2)).join(path$1.sep);
15820
+ return segments.slice(0, index + (segments[index + 1].startsWith("@") ? 3 : 2)).join(path.sep);
15757
15821
  }
15758
15822
  function loadContextOf(module) {
15759
15823
  let root = module;
15760
15824
  while (root.parent) root = root.parent;
15761
15825
  let context = loadContexts.get(root);
15762
15826
  if (!context) {
15763
- const filename = path$1.normalize(root.filename);
15827
+ const filename = path.normalize(root.filename);
15764
15828
  context = {
15765
15829
  entry: filename,
15766
15830
  cache: { [filename]: root },
@@ -15773,15 +15837,15 @@ function loadContextOf(module) {
15773
15837
  return context;
15774
15838
  }
15775
15839
  function isPathSpecifier(id) {
15776
- return id.startsWith("./") || id.startsWith("../") || id.startsWith("file:") || path$1.isAbsolute(id);
15840
+ return id.startsWith("./") || id.startsWith("../") || id.startsWith("file:") || path.isAbsolute(id);
15777
15841
  }
15778
15842
  function ownFile(id, require2, context) {
15779
- const resolved = path$1.normalize(require2.resolve(id.startsWith("file:") ? fileURLToPath(id) : id));
15843
+ const resolved = path.normalize(require2.resolve(id.startsWith("file:") ? fileURLToPath(id) : id));
15780
15844
  if (isReloadableScriptPath(resolved)) return packageRootOf(resolved) === context.packageRoot ? {
15781
15845
  kind: "script",
15782
15846
  filename: resolved
15783
15847
  } : void 0;
15784
- const json = path$1.extname(resolved) === ".json" ? ownJson(resolved, context) : void 0;
15848
+ const json = path.extname(resolved) === ".json" ? ownJson(resolved, context) : void 0;
15785
15849
  return json === void 0 ? void 0 : {
15786
15850
  kind: "json",
15787
15851
  filename: json
@@ -15789,8 +15853,8 @@ function ownFile(id, require2, context) {
15789
15853
  }
15790
15854
  function manifestDirOf(directory, context) {
15791
15855
  if (context.manifestDirs.has(directory)) return context.manifestDirs.get(directory);
15792
- const parent = path$1.dirname(directory);
15793
- const found = fsExports$1.existsSync(path$1.join(directory, "package.json")) ? directory : parent === directory ? void 0 : manifestDirOf(parent, context);
15856
+ const parent = path.dirname(directory);
15857
+ const found = fsExports$1.existsSync(path.join(directory, "package.json")) ? directory : parent === directory ? void 0 : manifestDirOf(parent, context);
15794
15858
  context.manifestDirs.set(directory, found);
15795
15859
  return found;
15796
15860
  }
@@ -15804,11 +15868,11 @@ function readUnrecorded(file) {
15804
15868
  }
15805
15869
  function jsonPackageOf(context) {
15806
15870
  if (context.jsonPackage) return context.jsonPackage;
15807
- const entryDir = path$1.normalize(fsExports$1.realpathSync(path$1.dirname(context.entry)));
15871
+ const entryDir = path.normalize(fsExports$1.realpathSync(path.dirname(context.entry)));
15808
15872
  const manifestDir = manifestDirOf(entryDir, context);
15809
15873
  let name;
15810
15874
  if (manifestDir !== void 0) try {
15811
- const declared = JSON.parse(readUnrecorded(path$1.join(manifestDir, "package.json"))).name;
15875
+ const declared = JSON.parse(readUnrecorded(path.join(manifestDir, "package.json"))).name;
15812
15876
  name = typeof declared === "string" ? declared : void 0;
15813
15877
  } catch {}
15814
15878
  context.jsonPackage = {
@@ -15819,19 +15883,19 @@ function jsonPackageOf(context) {
15819
15883
  return context.jsonPackage;
15820
15884
  }
15821
15885
  function isWithin(root, file) {
15822
- const relative = path$1.relative(root, file);
15823
- return relative !== ".." && !relative.startsWith(`..${path$1.sep}`) && !path$1.isAbsolute(relative);
15886
+ const relative = path.relative(root, file);
15887
+ return relative !== ".." && !relative.startsWith(`..${path.sep}`) && !path.isAbsolute(relative);
15824
15888
  }
15825
15889
  function ownJson(resolved, context) {
15826
15890
  let real;
15827
15891
  try {
15828
- real = path$1.normalize(fsExports$1.realpathSync(resolved));
15892
+ real = path.normalize(fsExports$1.realpathSync(resolved));
15829
15893
  } catch {
15830
15894
  return;
15831
15895
  }
15832
15896
  const own = jsonPackageOf(context);
15833
- if (manifestDirOf(path$1.dirname(real), context) !== own.manifestDir || !isWithin(own.root, real)) return void 0;
15834
- return path$1.relative(own.root, real).split(path$1.sep).includes("node_modules") ? void 0 : real;
15897
+ if (manifestDirOf(path.dirname(real), context) !== own.manifestDir || !isWithin(own.root, real)) return void 0;
15898
+ return path.relative(own.root, real).split(path.sep).includes("node_modules") ? void 0 : real;
15835
15899
  }
15836
15900
  function ownJsonByName(id, resolve, context) {
15837
15901
  const name = jsonPackageOf(context).name;
@@ -15842,14 +15906,14 @@ function ownJsonByName(id, resolve, context) {
15842
15906
  } catch {
15843
15907
  return;
15844
15908
  }
15845
- return path$1.extname(resolved) === ".json" ? ownJson(resolved, context) : void 0;
15909
+ return path.extname(resolved) === ".json" ? ownJson(resolved, context) : void 0;
15846
15910
  }
15847
15911
  const BUN_JSONC_NAME = /^(?:package|tsconfig(?:\..*)?|jsconfig(?:\..*)?)\.json$/;
15848
15912
  function parseJson(filename, content) {
15849
15913
  const text = content.toString("utf8");
15850
15914
  const json = text.charCodeAt(0) === 65279 ? text.slice(1) : text;
15851
15915
  const bun = globalThis.Bun;
15852
- return bun !== void 0 && BUN_JSONC_NAME.test(path$1.basename(filename)) ? bun.JSONC.parse(json) : JSON.parse(json);
15916
+ return bun !== void 0 && BUN_JSONC_NAME.test(path.basename(filename)) ? bun.JSONC.parse(json) : JSON.parse(json);
15853
15917
  }
15854
15918
  function requireAfresh(filename) {
15855
15919
  const runtimeRequire = createRequire(filename);
@@ -15944,12 +16008,12 @@ function bindReloadableScriptLoaders(module, require2, jitiImport) {
15944
16008
  }
15945
16009
  return import(__rewriteRelativeImportExtension$1(target));
15946
16010
  };
15947
- const filename = path$1.normalize(module.filename);
16011
+ const filename = path.normalize(module.filename);
15948
16012
  return [
15949
16013
  reloadableRequire,
15950
16014
  reloadableImport,
15951
16015
  filename,
15952
- path$1.dirname(filename)
16016
+ path.dirname(filename)
15953
16017
  ];
15954
16018
  }
15955
16019
  function observeJsonReads(jiti, onRead) {
@@ -15961,18 +16025,18 @@ function installReloadableScripts(createJiti, onSettledPathImport) {
15961
16025
  globalThis[BINDER_KEY] = bindReloadableScriptLoaders;
15962
16026
  }
15963
16027
  function packageTypeOf(filePath) {
15964
- for (let dir = path$1.dirname(filePath);; dir = path$1.dirname(dir)) {
15965
- const manifest = path$1.join(dir, "package.json");
16028
+ for (let dir = path.dirname(filePath);; dir = path.dirname(dir)) {
16029
+ const manifest = path.join(dir, "package.json");
15966
16030
  if (fsExports$1.existsSync(manifest)) try {
15967
16031
  return JSON.parse(fsExports$1.readFileSync(manifest, "utf8")).type;
15968
16032
  } catch {
15969
16033
  return;
15970
16034
  }
15971
- if (path$1.dirname(dir) === dir) return void 0;
16035
+ if (path.dirname(dir) === dir) return void 0;
15972
16036
  }
15973
16037
  }
15974
16038
  function isCommonJs(filename, source) {
15975
- const extension = path$1.extname(filename);
16039
+ const extension = path.extname(filename);
15976
16040
  if (extension === ".cjs") return true;
15977
16041
  return extension === ".js" && !ESM_SYNTAX.test(source) && packageTypeOf(filename) !== "module";
15978
16042
  }
@@ -16007,7 +16071,7 @@ const sharesHostTypeboxByDir = /* @__PURE__ */ new Map();
16007
16071
  function bunImportsNatively(extensionPath) {
16008
16072
  const bun = globalThis.Bun;
16009
16073
  if (bun === void 0 || isBunBinary || isBundledBuild || !isSourceBuiltinExtensionPath(extensionPath)) return Promise.resolve(false);
16010
- const dir = path$1.dirname(extensionPath);
16074
+ const dir = path.dirname(extensionPath);
16011
16075
  let shares = sharesHostTypeboxByDir.get(dir);
16012
16076
  if (shares === void 0) {
16013
16077
  const pending = Promise.all([bun.resolve(HOST_TYPEBOX, dir), bun.resolve(HOST_TYPEBOX, currentModuleDir())]).then(([fromPackage, fromHost]) => fromPackage === fromHost, () => {
@@ -16021,10 +16085,10 @@ function bunImportsNatively(extensionPath) {
16021
16085
  }
16022
16086
  async function mkdirBelowExisting(root, dir) {
16023
16087
  let current = root;
16024
- for (const segment of path$1.relative(root, dir).split(path$1.sep)) {
16025
- current = path$1.join(current, segment);
16088
+ for (const segment of path.relative(root, dir).split(path.sep)) {
16089
+ current = path.join(current, segment);
16026
16090
  try {
16027
- await fs$1.promises.mkdir(current);
16091
+ await fs.promises.mkdir(current);
16028
16092
  } catch (error) {
16029
16093
  if (error.code !== "EEXIST") return false;
16030
16094
  }
@@ -16032,7 +16096,7 @@ async function mkdirBelowExisting(root, dir) {
16032
16096
  return true;
16033
16097
  }
16034
16098
  async function resolveTranspileCacheDir(agentDir = getAgentDir()) {
16035
- const root = path$1.resolve(agentDir);
16099
+ const root = path.resolve(agentDir);
16036
16100
  const cacheDir = getExtensionTranspileCacheDir(root);
16037
16101
  if (!await mkdirBelowExisting(root, cacheDir)) return void 0;
16038
16102
  markTranspileCacheUsed(cacheDir);
@@ -16044,21 +16108,21 @@ function markTranspileCacheUsed(cacheDir) {
16044
16108
  if (now - (transpileCacheUseMarks.get(cacheDir) ?? Number.NEGATIVE_INFINITY) < TRANSPILE_CACHE_USE_MARK_MS) return;
16045
16109
  transpileCacheUseMarks.set(cacheDir, now);
16046
16110
  const time = new Date(now);
16047
- fs$1.promises.utimes(cacheDir, time, time).catch(() => {});
16111
+ fs.promises.utimes(cacheDir, time, time).catch(() => {});
16048
16112
  }
16049
16113
  const TRANSPILE_CACHE_DIR_NAME = /^\d+\.\d+\.\d+(?:-[0-9A-Za-z.-]+)?(?:\+[0-9A-Za-z.-]+)?$/;
16050
16114
  async function pruneUnusedTranspileCaches(currentDir) {
16051
- const parent = path$1.dirname(currentDir);
16115
+ const parent = path.dirname(currentDir);
16052
16116
  const unusedSince = Date.now() - UNUSED_TRANSPILE_CACHE_MS;
16053
- await Promise.all([parent, path$1.join(path$1.dirname(parent), "jiti")].map(async (dir) => {
16054
- const entries = await fs$1.promises.readdir(dir).catch(() => []);
16117
+ await Promise.all([parent, path.join(path.dirname(parent), "jiti")].map(async (dir) => {
16118
+ const entries = await fs.promises.readdir(dir).catch(() => []);
16055
16119
  await Promise.all(entries.map(async (entry) => {
16056
- const entryPath = path$1.join(dir, entry);
16120
+ const entryPath = path.join(dir, entry);
16057
16121
  if (entryPath === currentDir || !TRANSPILE_CACHE_DIR_NAME.test(entry)) return;
16058
16122
  try {
16059
- const stats = await fs$1.promises.lstat(entryPath);
16123
+ const stats = await fs.promises.lstat(entryPath);
16060
16124
  if (!stats.isDirectory() || stats.mtimeMs > unusedSince) return;
16061
- await fs$1.promises.rm(entryPath, {
16125
+ await fs.promises.rm(entryPath, {
16062
16126
  recursive: true,
16063
16127
  force: true
16064
16128
  });
@@ -16080,11 +16144,11 @@ const graphManifestFileExtensions = /* @__PURE__ */ new Set([
16080
16144
  ".json"
16081
16145
  ]);
16082
16146
  function graphManifestPath(extensionPath, cacheDir) {
16083
- const key = crypto$2.createHash("sha256").update(extensionPath).digest("hex").slice(0, 32);
16084
- return path$1.join(cacheDir, GRAPH_MANIFEST_DIR_NAME, `${key}.json`);
16147
+ const key = crypto$1.createHash("sha256").update(extensionPath).digest("hex").slice(0, 32);
16148
+ return path.join(cacheDir, GRAPH_MANIFEST_DIR_NAME, `${key}.json`);
16085
16149
  }
16086
16150
  function sha256Hex(content) {
16087
- return crypto$2.createHash("sha256").update(content).digest("hex");
16151
+ return crypto$1.createHash("sha256").update(content).digest("hex");
16088
16152
  }
16089
16153
  const fsExports = requireFromHere("node:fs");
16090
16154
  const activeGraphRecorders = /* @__PURE__ */ new Set();
@@ -16092,17 +16156,17 @@ let observedReadFileSync = null;
16092
16156
  function createGraphRecorder(cacheDir) {
16093
16157
  return {
16094
16158
  files: /* @__PURE__ */ new Map(),
16095
- cachePrefix: cacheDir === void 0 ? void 0 : (path$1.normalize(cacheDir) + path$1.sep).toLowerCase()
16159
+ cachePrefix: cacheDir === void 0 ? void 0 : (path.normalize(cacheDir) + path.sep).toLowerCase()
16096
16160
  };
16097
16161
  }
16098
16162
  function recordObservedRead(target, content) {
16099
- if (typeof target !== "string" || !path$1.isAbsolute(target)) return;
16100
- if (!graphManifestFileExtensions.has(path$1.extname(target).toLowerCase())) return;
16163
+ if (typeof target !== "string" || !path.isAbsolute(target)) return;
16164
+ if (!graphManifestFileExtensions.has(path.extname(target).toLowerCase())) return;
16101
16165
  recordObservedDigest(target, () => sha256Hex(content));
16102
16166
  }
16103
16167
  const CHANGED_WHILE_READ = "changed-while-read";
16104
16168
  function recordObservedDigest(target, digest) {
16105
- const normalizedTarget = path$1.normalize(target);
16169
+ const normalizedTarget = path.normalize(target);
16106
16170
  const comparableTarget = normalizedTarget.toLowerCase();
16107
16171
  let hash;
16108
16172
  for (const recorder of activeGraphRecorders) {
@@ -16130,16 +16194,16 @@ function uninstallReadFileSyncObserver() {
16130
16194
  async function persistGraphManifest(contents, manifestFile, cacheDir) {
16131
16195
  let tempFile;
16132
16196
  try {
16133
- if (!await mkdirBelowExisting(cacheDir, path$1.dirname(manifestFile))) throw new Error("transpile cache is gone");
16197
+ if (!await mkdirBelowExisting(cacheDir, path.dirname(manifestFile))) throw new Error("transpile cache is gone");
16134
16198
  tempFile = `${manifestFile}.${process.pid}.${Math.random().toString(36).slice(2)}.tmp`;
16135
- await fs$1.promises.writeFile(tempFile, contents);
16136
- await fs$1.promises.rename(tempFile, manifestFile);
16199
+ await fs.promises.writeFile(tempFile, contents);
16200
+ await fs.promises.rename(tempFile, manifestFile);
16137
16201
  } catch {
16138
16202
  try {
16139
- await fs$1.promises.rm(manifestFile, { force: true });
16203
+ await fs.promises.rm(manifestFile, { force: true });
16140
16204
  } catch {}
16141
16205
  try {
16142
- if (tempFile) await fs$1.promises.rm(tempFile, { force: true });
16206
+ if (tempFile) await fs.promises.rm(tempFile, { force: true });
16143
16207
  } catch {}
16144
16208
  }
16145
16209
  }
@@ -16160,14 +16224,14 @@ function isStringRecord(value) {
16160
16224
  return Object.values(value).every((entry) => typeof entry === "string");
16161
16225
  }
16162
16226
  function readExtensionGraphManifest(extensionPath, agentDir = getAgentDir()) {
16163
- return readGraphManifestIn(extensionPath, getExtensionTranspileCacheDir(path$1.resolve(agentDir)));
16227
+ return readGraphManifestIn(extensionPath, getExtensionTranspileCacheDir(path.resolve(agentDir)));
16164
16228
  }
16165
16229
  async function readGraphManifestIn(extensionPath, cacheDir) {
16166
16230
  if (cacheDir === void 0) return void 0;
16167
16231
  const manifestFile = graphManifestPath(extensionPath, cacheDir);
16168
16232
  await graphManifestWrites.get(manifestFile);
16169
16233
  try {
16170
- const parsed = JSON.parse(await fs$1.promises.readFile(manifestFile, "utf-8"));
16234
+ const parsed = JSON.parse(await fs.promises.readFile(manifestFile, "utf-8"));
16171
16235
  if (parsed.version !== GRAPH_MANIFEST_VERSION) return void 0;
16172
16236
  if (parsed.extensionPath !== extensionPath) return void 0;
16173
16237
  if (!isStringRecord(parsed.files)) return void 0;
@@ -16212,7 +16276,7 @@ async function graphUnchangedSince(manifest, cacheDir) {
16212
16276
  const entries = Object.entries(manifest.files);
16213
16277
  if (entries.length === 0) return false;
16214
16278
  for (const [filePath, hash] of entries) try {
16215
- if (sha256Hex(await fs$1.promises.readFile(filePath)) !== hash) return false;
16279
+ if (sha256Hex(await fs.promises.readFile(filePath)) !== hash) return false;
16216
16280
  } catch {
16217
16281
  return false;
16218
16282
  }
@@ -16249,7 +16313,7 @@ function recordLateModule(extensionPath, owner, filename, source) {
16249
16313
  }
16250
16314
  function recordLateDigest(extensionPath, owner, filename, hash) {
16251
16315
  if (retainedTransformedLoads.get(extensionPath) !== owner) return;
16252
- const file = path$1.normalize(filename);
16316
+ const file = path.normalize(filename);
16253
16317
  if (owner.manifest.files[file] === hash) return;
16254
16318
  owner.manifest.files[file] = hash;
16255
16319
  if (lateReadWrites.has(owner)) return;
@@ -16290,8 +16354,8 @@ async function resolveOptionalPackageRoot(packageName, searchPaths) {
16290
16354
  }
16291
16355
  const nativeBuiltinRootChecks = memoizeAsyncByKey(async (extensionPath) => {
16292
16356
  try {
16293
- const hostPackageRoot = path$1.resolve(currentModuleDir(), "../../..");
16294
- if (!await pathExists(path$1.join(hostPackageRoot, "dist", "index.js"))) return false;
16357
+ const hostPackageRoot = path.resolve(currentModuleDir(), "../../..");
16358
+ if (!await pathExists(path.join(hostPackageRoot, "dist", "index.js"))) return false;
16295
16359
  const hostAtomicReal = await realpathJs(hostPackageRoot);
16296
16360
  const requireFromExt = createRequire(extensionPath);
16297
16361
  const extAtomicReal = await resolveOptionalPackageRoot("@bastani/atomic", requireFromExt.resolve.paths("@bastani/atomic") ?? []);
@@ -16379,26 +16443,26 @@ function extensionImportSpecifier(extensionPath, cacheToken) {
16379
16443
  }
16380
16444
  async function findPackageRoot(packageName, searchPaths) {
16381
16445
  for (const base of searchPaths ?? requireFromHere.resolve.paths(packageName) ?? []) {
16382
- const candidate = path$1.join(base, packageName);
16383
- if (await pathExists(path$1.join(candidate, "package.json"))) return candidate;
16446
+ const candidate = path.join(base, packageName);
16447
+ if (await pathExists(path.join(candidate, "package.json"))) return candidate;
16384
16448
  }
16385
16449
  throw new Error(`Cannot locate package directory for "${packageName}"`);
16386
16450
  }
16387
- const realpathJs = promisify(fs$1.realpath);
16451
+ const realpathJs = promisify(fs.realpath);
16388
16452
  function currentModuleDir() {
16389
16453
  return moduleDirFromMetaUrl(__atomicDistModuleUrl$1, "dist", "core", "extensions");
16390
16454
  }
16391
16455
  const getAliases = memoizeAsync(() => computeAliases().then(normalizeJitiAliases));
16392
16456
  async function computeAliases() {
16393
16457
  const __dirname = currentModuleDir();
16394
- const packageIndex = path$1.resolve(__dirname, "../..", "index.js");
16395
- const packagesRoot = path$1.resolve(__dirname, "../../../../");
16458
+ const packageIndex = path.resolve(__dirname, "../..", "index.js");
16459
+ const packagesRoot = path.resolve(__dirname, "../../../../");
16396
16460
  const resolveWorkspaceOrImport = async (workspaceRelativePath, packageName) => {
16397
- const workspacePath = path$1.join(packagesRoot, workspaceRelativePath);
16461
+ const workspacePath = path.join(packagesRoot, workspaceRelativePath);
16398
16462
  if (await pathExists(workspacePath)) return workspacePath;
16399
16463
  const packageRoot = await findPackageRoot(packageName);
16400
16464
  const entryRelativePath = workspaceRelativePath.split("/").slice(1).join("/");
16401
- return path$1.join(packageRoot, entryRelativePath);
16465
+ return path.join(packageRoot, entryRelativePath);
16402
16466
  };
16403
16467
  const piCodingAgentEntry = packageIndex;
16404
16468
  const piAgentCoreEntry = await resolveWorkspaceOrImport("agent/dist/index.js", "@bastani/atomic-agent-core");
@@ -16427,15 +16491,15 @@ async function computeAliases() {
16427
16491
  const piAiTransformMessagesEntry = await resolveWorkspaceOrImport("ai/dist/api/transform-messages.js", "@bastani/atomic-ai");
16428
16492
  const forkedPackageAliases = {};
16429
16493
  for (const [name, dir] of Object.entries(FORKED_PACKAGE_WORKSPACE_DIRS)) {
16430
- const workspaceRoot = path$1.join(packagesRoot, dir);
16431
- const workspaceManifest = path$1.join(workspaceRoot, "package.json");
16432
- const packageRoot = await pathExists(workspaceManifest) && JSON.parse(await fs$1.promises.readFile(workspaceManifest, "utf8")).name === name ? workspaceRoot : await findPackageRoot(name);
16433
- const manifest = JSON.parse(await fs$1.promises.readFile(path$1.join(packageRoot, "package.json"), "utf8"));
16434
- Object.assign(forkedPackageAliases, forkedPackageExportAliases(name, packageRoot, manifest, path$1.join));
16494
+ const workspaceRoot = path.join(packagesRoot, dir);
16495
+ const workspaceManifest = path.join(workspaceRoot, "package.json");
16496
+ const packageRoot = await pathExists(workspaceManifest) && JSON.parse(await fs.promises.readFile(workspaceManifest, "utf8")).name === name ? workspaceRoot : await findPackageRoot(name);
16497
+ const manifest = JSON.parse(await fs.promises.readFile(path.join(packageRoot, "package.json"), "utf8"));
16498
+ Object.assign(forkedPackageAliases, forkedPackageExportAliases(name, packageRoot, manifest, path.join));
16435
16499
  }
16436
16500
  return withLegacyPackageNames({
16437
16501
  ...forkedPackageAliases,
16438
- "@bastani/atomic/storage": path$1.resolve(__dirname, "../storage/index.js"),
16502
+ "@bastani/atomic/storage": path.resolve(__dirname, "../storage/index.js"),
16439
16503
  "@bastani/atomic": piCodingAgentEntry,
16440
16504
  "@earendil-works/pi-coding-agent": piCodingAgentEntry,
16441
16505
  "@mariozechner/pi-coding-agent": piCodingAgentEntry,
@@ -16464,7 +16528,7 @@ async function computeAliases() {
16464
16528
  "@bastani/atomic-ai/api/anthropic-assistant-content": piAiAnthropicAssistantContentEntry,
16465
16529
  "@bastani/atomic-ai/api/transform-messages": piAiTransformMessagesEntry,
16466
16530
  "@bastani/atomic-ai": piAiEntry,
16467
- ...typeboxAliases(forkedPackageAliases, path$1.resolve(__dirname, "../..", "typebox"))
16531
+ ...typeboxAliases(forkedPackageAliases, path.resolve(__dirname, "../..", "typebox"))
16468
16532
  });
16469
16533
  }
16470
16534
  function typeboxAliases(forkedPackageAliases, sdkTypeboxDir) {
@@ -16472,8 +16536,8 @@ function typeboxAliases(forkedPackageAliases, sdkTypeboxDir) {
16472
16536
  if (aiUtils === void 0) throw new Error("@bastani/atomic-ai does not export ./utils/*");
16473
16537
  const aliases = {};
16474
16538
  for (const subpath of TYPEBOX_SUBPATHS) {
16475
- aliases[`typebox${subpath}`] = path$1.join(aiUtils, "typebox", `${subpath.slice(1) || "index"}.js`);
16476
- aliases[`@bastani/atomic/typebox${subpath}`] = path$1.join(sdkTypeboxDir, `${subpath.slice(1) || "index"}.js`);
16539
+ aliases[`typebox${subpath}`] = path.join(aiUtils, "typebox", `${subpath.slice(1) || "index"}.js`);
16540
+ aliases[`@bastani/atomic/typebox${subpath}`] = path.join(sdkTypeboxDir, `${subpath.slice(1) || "index"}.js`);
16477
16541
  }
16478
16542
  for (const subpath of [
16479
16543
  "",
@@ -16496,8 +16560,8 @@ const extensionLoaderTestHooks = {
16496
16560
  findPackageRoot,
16497
16561
  getTranspileCacheDir: (agentDir) => resolveTranspileCacheDir(agentDir),
16498
16562
  /** The removal of unused cache directories that setting up `agentDir`'s cache started, if any. */
16499
- transpileCachePrune: (agentDir) => transpileCachePrunes.get(getExtensionTranspileCacheDir(path$1.resolve(agentDir))),
16500
- graphManifestPath: (extensionPath, agentDir = getAgentDir()) => graphManifestPath(extensionPath, getExtensionTranspileCacheDir(path$1.resolve(agentDir))),
16563
+ transpileCachePrune: (agentDir) => transpileCachePrunes.get(getExtensionTranspileCacheDir(path.resolve(agentDir))),
16564
+ graphManifestPath: (extensionPath, agentDir = getAgentDir()) => graphManifestPath(extensionPath, getExtensionTranspileCacheDir(path.resolve(agentDir))),
16501
16565
  readExtensionGraphManifest,
16502
16566
  loadExtensionModuleTransformed: async (extensionPath, cacheToken, agentDir) => importExtensionModule(extensionPath, cacheToken, true, await resolveTranspileCacheDir(agentDir)),
16503
16567
  loadTransformedExtensionModule: async (extensionPath, cacheToken, agentDir) => loadTransformedExtensionModule(extensionPath, cacheToken, await resolveTranspileCacheDir(agentDir)),
@@ -19291,7 +19355,7 @@ const OUTPUT_TAIL_BYTES = 2048;
19291
19355
  const LINE_CHARS = 160;
19292
19356
  const TITLE_CHARS = 120;
19293
19357
  /** Longest delay a host timer accepts before it overflows to an immediate fire. */
19294
- const MAX_TIMER_DELAY_MS = 2147483647;
19358
+ const MAX_TIMER_DELAY_MS = 0x7fffffff;
19295
19359
  /** The owner's default cadence, or the built-in one when its setting cannot be read or is out of range. */
19296
19360
  function defaultTaskHeartbeatMs(delivery) {
19297
19361
  try {
@@ -21534,7 +21598,7 @@ var require_range = /* @__PURE__ */ __commonJSMin(((exports, module) => {
21534
21598
  const hr = loose ? re[t.HYPHENRANGELOOSE] : re[t.HYPHENRANGE];
21535
21599
  range = range.replace(hr, hyphenReplace(this.options.includePrerelease));
21536
21600
  debug("hyphen replace", range);
21537
- range = range.replace(re[t.COMPARATORTRIM], comparatorTrimReplace);
21601
+ range = trimComparatorWhitespace(range);
21538
21602
  debug("comparator trim", range);
21539
21603
  range = range.replace(re[t.TILDETRIM], tildeTrimReplace);
21540
21604
  debug("tilde trim", range);
@@ -21585,7 +21649,8 @@ var require_range = /* @__PURE__ */ __commonJSMin(((exports, module) => {
21585
21649
  const Comparator = require_comparator();
21586
21650
  const debug = require_debug();
21587
21651
  const SemVer = require_semver$1();
21588
- const { safeRe: re, src, t, comparatorTrimReplace, tildeTrimReplace, caretTrimReplace } = require_re();
21652
+ const trimComparatorWhitespace = require_trim_comparator_whitespace();
21653
+ const { safeRe: re, src, t, tildeTrimReplace, caretTrimReplace } = require_re();
21589
21654
  const { FLAG_INCLUDE_PRERELEASE, FLAG_LOOSE } = require_constants();
21590
21655
  const BUILDSTRIPRE = new RegExp(src[t.BUILD], "g");
21591
21656
  const isNullSet = (c) => c.value === "<0.0.0-0";
@@ -25772,7 +25837,7 @@ function shouldUseNativeFastRoute(model, options) {
25772
25837
  function codexEnvironmentScope(env) {
25773
25838
  if (!env) return "none";
25774
25839
  const serialized = JSON.stringify(Object.entries(env).sort(([left], [right]) => left.localeCompare(right)));
25775
- let hash = 2166136261;
25840
+ let hash = 0x811c9dc5;
25776
25841
  for (let index = 0; index < serialized.length; index += 1) hash = Math.imul(hash ^ serialized.charCodeAt(index), 16777619);
25777
25842
  return (hash >>> 0).toString(16);
25778
25843
  }
@@ -28131,7 +28196,7 @@ function __atomicOnDemandFailed(error, feature) {
28131
28196
  return (async () => {
28132
28197
  const root = new URL("../", import.meta.url);
28133
28198
  const releases = (globalThis[Symbol.for("atomic.in-place-update-release.v1")] ??= new Map());
28134
- const key = `${root.href}#0.10.5`;
28199
+ const key = `${root.href}#0.10.6`;
28135
28200
  let release = releases.get(key);
28136
28201
  if (release === undefined) {
28137
28202
  const current = (async () => {
@@ -28159,7 +28224,7 @@ function __atomicOnDemandFailed(error, feature) {
28159
28224
  } catch {
28160
28225
  // No installation to read, as in a bundle of the package: the release the process runs decides.
28161
28226
  }
28162
- const updatedTo = typeof installed === "string" && installed !== "0.10.5" ? installed : running !== undefined && running.version !== "0.10.5" ? "0.10.5" : undefined;
28227
+ const updatedTo = typeof installed === "string" && installed !== "0.10.6" ? installed : running !== undefined && running.version !== "0.10.6" ? "0.10.6" : undefined;
28163
28228
  if (updatedTo === undefined) throw error;
28164
28229
  const application = typeof running?.name === "string" ? running.name : "atomic";
28165
28230
  const restart = new Error(`${application} was updated to ${updatedTo} while this session was running; restart it to keep using ${feature}.`, {