@smoothbricks/nx-plugin 0.4.26 → 0.4.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (343) hide show
  1. package/README.md +994 -117
  2. package/dist/bin/smoo-nx-bound-failures.d.ts +3 -0
  3. package/dist/bin/smoo-nx-bound-failures.d.ts.map +1 -0
  4. package/dist/bin/smoo-nx-bound-failures.js +31 -0
  5. package/dist/bin/smoo-nx-cargo-hash.js +28 -3
  6. package/dist/bin/smoo-nx-exec.js +15 -73
  7. package/dist/bin/smoo-nx-failures.d.ts +3 -0
  8. package/dist/bin/smoo-nx-failures.d.ts.map +1 -0
  9. package/dist/bin/smoo-nx-failures.js +3 -0
  10. package/dist/bin/smoo-nx-nextest-extract.js +3 -2
  11. package/dist/bin/smoo-nx-test-walks.d.ts +3 -0
  12. package/dist/bin/smoo-nx-test-walks.d.ts.map +1 -0
  13. package/dist/bin/smoo-nx-test-walks.js +34 -0
  14. package/dist/bounded-test-policy.d.ts +7 -1
  15. package/dist/bounded-test-policy.d.ts.map +1 -1
  16. package/dist/bounded-test-policy.js +101 -40
  17. package/dist/build-state-output-policy.d.ts +25 -0
  18. package/dist/build-state-output-policy.d.ts.map +1 -0
  19. package/dist/build-state-output-policy.js +64 -0
  20. package/dist/cargo-closure-input.d.ts +3 -2
  21. package/dist/cargo-closure-input.d.ts.map +1 -1
  22. package/dist/cargo-closure-input.js +16 -15
  23. package/dist/cargo-dev-profile.d.ts +37 -0
  24. package/dist/cargo-dev-profile.d.ts.map +1 -0
  25. package/dist/cargo-dev-profile.js +108 -0
  26. package/dist/cargo-source-hash.d.ts +43 -6
  27. package/dist/cargo-source-hash.d.ts.map +1 -1
  28. package/dist/cargo-source-hash.js +309 -73
  29. package/dist/cargo-toolchain-policy.d.ts +4 -0
  30. package/dist/cargo-toolchain-policy.d.ts.map +1 -1
  31. package/dist/cargo-toolchain-policy.js +5 -0
  32. package/dist/cargo-workspace.d.ts +101 -5
  33. package/dist/cargo-workspace.d.ts.map +1 -1
  34. package/dist/cargo-workspace.js +291 -10
  35. package/dist/cross-check-policy.d.ts +21 -3
  36. package/dist/cross-check-policy.d.ts.map +1 -1
  37. package/dist/cross-check-policy.js +24 -6
  38. package/dist/disk-command-policy.d.ts +7 -0
  39. package/dist/disk-command-policy.d.ts.map +1 -0
  40. package/dist/disk-command-policy.js +98 -0
  41. package/dist/ensure-built-receipt.d.ts +25 -0
  42. package/dist/ensure-built-receipt.d.ts.map +1 -0
  43. package/dist/ensure-built-receipt.js +261 -0
  44. package/dist/ensure-built-witness.d.ts +57 -0
  45. package/dist/ensure-built-witness.d.ts.map +1 -0
  46. package/dist/ensure-built-witness.js +412 -0
  47. package/dist/ensure-built.d.ts +207 -12
  48. package/dist/ensure-built.d.ts.map +1 -1
  49. package/dist/ensure-built.js +576 -202
  50. package/dist/eslint-file-set.d.ts +7 -0
  51. package/dist/eslint-file-set.d.ts.map +1 -0
  52. package/dist/eslint-file-set.js +12 -0
  53. package/dist/executors/bounded-exec/cpu-pool.d.ts +63 -0
  54. package/dist/executors/bounded-exec/cpu-pool.d.ts.map +1 -0
  55. package/dist/executors/bounded-exec/cpu-pool.js +379 -0
  56. package/dist/executors/bounded-exec/cpu-tokens.d.ts +82 -0
  57. package/dist/executors/bounded-exec/cpu-tokens.d.ts.map +1 -0
  58. package/dist/executors/bounded-exec/cpu-tokens.js +114 -0
  59. package/dist/executors/bounded-exec/disk-lease.d.ts +61 -0
  60. package/dist/executors/bounded-exec/disk-lease.d.ts.map +1 -0
  61. package/dist/executors/bounded-exec/disk-lease.js +91 -0
  62. package/dist/executors/bounded-exec/executor.d.ts +45 -2
  63. package/dist/executors/bounded-exec/executor.d.ts.map +1 -1
  64. package/dist/executors/bounded-exec/executor.js +447 -52
  65. package/dist/executors/bounded-exec/gateway-lease.d.ts +52 -0
  66. package/dist/executors/bounded-exec/gateway-lease.d.ts.map +1 -0
  67. package/dist/executors/bounded-exec/gateway-lease.js +143 -0
  68. package/dist/executors/bounded-exec/hang-diagnostics.d.ts +35 -0
  69. package/dist/executors/bounded-exec/hang-diagnostics.d.ts.map +1 -0
  70. package/dist/executors/bounded-exec/hang-diagnostics.js +231 -0
  71. package/dist/executors/bounded-exec/progress.d.ts +35 -0
  72. package/dist/executors/bounded-exec/progress.d.ts.map +1 -0
  73. package/dist/executors/bounded-exec/progress.js +79 -0
  74. package/dist/executors/bounded-exec/ram-temp-fixtures.d.ts +3 -0
  75. package/dist/executors/bounded-exec/ram-temp-fixtures.d.ts.map +1 -0
  76. package/dist/executors/bounded-exec/ram-temp-fixtures.js +12 -0
  77. package/dist/executors/bounded-exec/ram-temp-held.d.ts +91 -0
  78. package/dist/executors/bounded-exec/ram-temp-held.d.ts.map +1 -0
  79. package/dist/executors/bounded-exec/ram-temp-held.js +152 -0
  80. package/dist/executors/bounded-exec/ram-temp.d.ts +223 -0
  81. package/dist/executors/bounded-exec/ram-temp.d.ts.map +1 -0
  82. package/dist/executors/bounded-exec/ram-temp.js +1528 -0
  83. package/dist/executors/bounded-exec/schema.d.ts +29 -11
  84. package/dist/executors/bounded-exec/schema.d.ts.map +1 -1
  85. package/dist/executors/bounded-exec/verdict.d.ts +162 -0
  86. package/dist/executors/bounded-exec/verdict.d.ts.map +1 -0
  87. package/dist/executors/bounded-exec/verdict.js +318 -0
  88. package/dist/executors/shard-timings/executor.d.ts +14 -0
  89. package/dist/executors/shard-timings/executor.d.ts.map +1 -0
  90. package/dist/executors/shard-timings/executor.js +25 -0
  91. package/dist/executors/shard-timings/schema.d.ts +4 -0
  92. package/dist/executors/shard-timings/schema.d.ts.map +1 -0
  93. package/dist/executors/shard-timings/schema.js +1 -0
  94. package/dist/failure-summary.d.ts +5 -0
  95. package/dist/failure-summary.d.ts.map +1 -0
  96. package/dist/failure-summary.js +118 -0
  97. package/dist/generators/create-package/generator.d.ts.map +1 -1
  98. package/dist/generators/create-package/generator.js +6 -2
  99. package/dist/index.d.ts +14 -2
  100. package/dist/index.d.ts.map +1 -1
  101. package/dist/index.js +370 -138
  102. package/dist/managed-files/ci-workflow.d.ts +13 -0
  103. package/dist/managed-files/ci-workflow.d.ts.map +1 -1
  104. package/dist/managed-files/ci-workflow.js +44 -13
  105. package/dist/managed-files/files.d.ts +7 -1
  106. package/dist/managed-files/files.d.ts.map +1 -1
  107. package/dist/managed-files/files.js +62 -8
  108. package/dist/managed-files/json-edit.d.ts +21 -0
  109. package/dist/managed-files/json-edit.d.ts.map +1 -0
  110. package/dist/managed-files/json-edit.js +295 -0
  111. package/dist/managed-files/managed-format.d.ts +33 -1
  112. package/dist/managed-files/managed-format.d.ts.map +1 -1
  113. package/dist/managed-files/managed-format.js +82 -2
  114. package/dist/managed-files/pr-preview-cleanup-workflow.d.ts +7 -0
  115. package/dist/managed-files/pr-preview-cleanup-workflow.d.ts.map +1 -1
  116. package/dist/managed-files/pr-preview-cleanup-workflow.js +68 -4
  117. package/dist/managed-files/publish-workflow.d.ts.map +1 -1
  118. package/dist/managed-files/publish-workflow.js +231 -48
  119. package/dist/managed-files/tree.d.ts +5 -0
  120. package/dist/managed-files/tree.d.ts.map +1 -1
  121. package/dist/managed-files/tree.js +5 -3
  122. package/dist/manifest-hash.d.ts.map +1 -1
  123. package/dist/manifest-hash.js +2 -5
  124. package/dist/nextest-code-bound.d.ts +62 -0
  125. package/dist/nextest-code-bound.d.ts.map +1 -0
  126. package/dist/nextest-code-bound.js +154 -0
  127. package/dist/nextest-extraction.d.ts +24 -8
  128. package/dist/nextest-extraction.d.ts.map +1 -1
  129. package/dist/nextest-extraction.js +42 -7
  130. package/dist/package-target-policy.d.ts.map +1 -1
  131. package/dist/package-target-policy.js +3 -5
  132. package/dist/release-config-policy.d.ts.map +1 -1
  133. package/dist/release-config-policy.js +3 -5
  134. package/dist/runtime-input.d.ts +14 -0
  135. package/dist/runtime-input.d.ts.map +1 -0
  136. package/dist/runtime-input.js +15 -0
  137. package/dist/rust-tokens.d.ts +11 -0
  138. package/dist/rust-tokens.d.ts.map +1 -0
  139. package/dist/rust-tokens.js +81 -0
  140. package/dist/task-results.d.ts +6 -0
  141. package/dist/task-results.d.ts.map +1 -0
  142. package/dist/task-results.js +61 -0
  143. package/dist/test-program.d.ts +54 -0
  144. package/dist/test-program.d.ts.map +1 -0
  145. package/dist/test-program.js +292 -0
  146. package/dist/test-timings.d.ts +71 -0
  147. package/dist/test-timings.d.ts.map +1 -0
  148. package/dist/test-timings.js +393 -0
  149. package/dist/test-walk-policy.d.ts +103 -0
  150. package/dist/test-walk-policy.d.ts.map +1 -0
  151. package/dist/test-walk-policy.js +657 -0
  152. package/dist/testing.d.ts +177 -0
  153. package/dist/testing.d.ts.map +1 -0
  154. package/dist/testing.js +824 -0
  155. package/dist/type-guards.d.ts +3 -0
  156. package/dist/type-guards.d.ts.map +1 -0
  157. package/dist/type-guards.js +4 -0
  158. package/dist/typecheck-test-policy.d.ts +8 -5
  159. package/dist/typecheck-test-policy.d.ts.map +1 -1
  160. package/dist/typecheck-test-policy.js +113 -100
  161. package/dist/workspace-config-policy.d.ts +8 -0
  162. package/dist/workspace-config-policy.d.ts.map +1 -1
  163. package/dist/workspace-config-policy.js +175 -63
  164. package/dist/workspace-index.d.ts +12 -0
  165. package/dist/workspace-index.d.ts.map +1 -0
  166. package/dist/workspace-index.js +17 -0
  167. package/dist/workspace-manifest.d.ts +37 -0
  168. package/dist/workspace-manifest.d.ts.map +1 -1
  169. package/executors.json +5 -0
  170. package/loader.js +13 -11
  171. package/managed/raw/envrc +33 -67
  172. package/managed/raw/git-format-staged.yml +30 -35
  173. package/managed/raw/patches/nx@23.2.1.patch +3484 -0
  174. package/managed/raw/tooling/direnv/apple-developer.sh +83 -0
  175. package/managed/raw/tooling/direnv/developer-links.ts +569 -11
  176. package/managed/raw/tooling/direnv/devenv.smoo.nix +314 -93
  177. package/managed/raw/tooling/direnv/github-actions-bootstrap.sh +20 -11
  178. package/managed/raw/tooling/direnv/linked-snapshots.ts +845 -0
  179. package/managed/raw/tooling/direnv/nx-socket-dir.sh +82 -0
  180. package/managed/raw/tooling/direnv/repo-path +14 -2
  181. package/managed/raw/tooling/direnv/setup-environment.ts +1146 -159
  182. package/managed/raw/tooling/direnv/toolchain-stamp.ts +45 -3
  183. package/managed/raw/tooling/direnv/ttsc-env.sh +39 -0
  184. package/managed/raw/tooling/git-hooks/commit-msg.sh +5 -6
  185. package/managed/raw/tooling/git-hooks/pre-commit.sh +7 -6
  186. package/managed/raw/tooling/git-hooks/pre-push.sh +20 -15
  187. package/managed/templates/github/actions/cache-nix-devenv/action.yml +6 -6
  188. package/managed/templates/github/actions/cache-node-modules/action.yml +6 -4
  189. package/managed/templates/github/actions/cache-nx/action.yml +1 -1
  190. package/managed/templates/github/actions/cache-ttsc-plugins/action.yml +1 -1
  191. package/managed/templates/github/actions/forgejo-artifact.cjs +99 -0
  192. package/managed/templates/github/actions/forgejo-download-artifact/action.yml +49 -0
  193. package/managed/templates/github/actions/forgejo-download-artifact/index.cjs +7 -0
  194. package/managed/templates/github/actions/forgejo-upload-artifact/action.yml +65 -0
  195. package/managed/templates/github/actions/forgejo-upload-artifact/index.cjs +7 -0
  196. package/managed/templates/github/actions/setup-devenv/action.yml +21 -3
  197. package/managed/templates/github/workflows/managed-files.yml +1 -2
  198. package/nextest.toml +8 -41
  199. package/package.json +74 -12
  200. package/runtime-input.sh +81 -0
  201. package/src/__tests__/counted-cargo.ts +33 -14
  202. package/src/__tests__/fixture-nx-env.ts +111 -46
  203. package/src/__tests__/progress-clock.ts +43 -0
  204. package/src/__tests__/runtime-input.ts +23 -0
  205. package/src/bin/smoo-nx-bound-failures.test.ts +127 -0
  206. package/src/bin/smoo-nx-bound-failures.ts +33 -0
  207. package/src/bin/smoo-nx-cargo-hash.ts +28 -3
  208. package/src/bin/smoo-nx-exec.ts +16 -74
  209. package/src/bin/smoo-nx-failures.ts +4 -0
  210. package/src/bin/smoo-nx-nextest-extract.ts +3 -2
  211. package/src/bin/smoo-nx-test-walks.ts +42 -0
  212. package/src/bounded-test-policy.test.ts +268 -21
  213. package/src/bounded-test-policy.ts +114 -42
  214. package/src/build-state-output-policy.test.ts +115 -0
  215. package/src/build-state-output-policy.ts +90 -0
  216. package/src/bun-bootstrap.test.ts +57 -3
  217. package/src/bun-file-packages.test.ts +47 -0
  218. package/src/cargo-closure-input.test.ts +138 -66
  219. package/src/cargo-closure-input.ts +17 -15
  220. package/src/cargo-dev-profile.ts +137 -0
  221. package/src/cargo-resolve-cache.test.ts +70 -1
  222. package/src/cargo-source-hash.test.ts +193 -97
  223. package/src/cargo-source-hash.ts +345 -68
  224. package/src/cargo-toolchain-policy.ts +6 -0
  225. package/src/cargo-workspace.test.ts +320 -0
  226. package/src/cargo-workspace.ts +336 -10
  227. package/src/cross-check-policy.test.ts +59 -1
  228. package/src/cross-check-policy.ts +25 -6
  229. package/src/disk-command-policy.test.ts +61 -0
  230. package/src/disk-command-policy.ts +107 -0
  231. package/src/ensure-built-receipt.test.ts +184 -0
  232. package/src/ensure-built-receipt.ts +263 -0
  233. package/src/ensure-built-witness.test.ts +344 -0
  234. package/src/ensure-built-witness.ts +252 -0
  235. package/src/ensure-built.test.ts +1036 -578
  236. package/src/ensure-built.ts +820 -224
  237. package/src/eslint-file-set.ts +9 -0
  238. package/src/executors/bounded-exec/cpu-pool.test.ts +454 -0
  239. package/src/executors/bounded-exec/cpu-pool.ts +417 -0
  240. package/src/executors/bounded-exec/cpu-tokens.test.ts +269 -0
  241. package/src/executors/bounded-exec/cpu-tokens.ts +177 -0
  242. package/src/executors/bounded-exec/disk-lease.test.ts +185 -0
  243. package/src/executors/bounded-exec/disk-lease.ts +139 -0
  244. package/src/executors/bounded-exec/executor-host.test.ts +778 -0
  245. package/src/executors/bounded-exec/executor.test.ts +1116 -63
  246. package/src/executors/bounded-exec/executor.ts +565 -67
  247. package/src/executors/bounded-exec/gateway-lease.ts +176 -0
  248. package/src/executors/bounded-exec/hang-diagnostics.test.ts +285 -0
  249. package/src/executors/bounded-exec/hang-diagnostics.ts +283 -0
  250. package/src/executors/bounded-exec/progress.test.ts +79 -0
  251. package/src/executors/bounded-exec/progress.ts +118 -0
  252. package/src/executors/bounded-exec/ram-temp-fixtures.ts +12 -0
  253. package/src/executors/bounded-exec/ram-temp-held.test.ts +264 -0
  254. package/src/executors/bounded-exec/ram-temp-held.ts +242 -0
  255. package/src/executors/bounded-exec/ram-temp-host.test.ts +605 -0
  256. package/src/executors/bounded-exec/ram-temp.test.ts +674 -0
  257. package/src/executors/bounded-exec/ram-temp.ts +1918 -0
  258. package/src/executors/bounded-exec/schema.json +11 -5
  259. package/src/executors/bounded-exec/schema.ts +27 -11
  260. package/src/executors/bounded-exec/verdict.test.ts +440 -0
  261. package/src/executors/bounded-exec/verdict.ts +433 -0
  262. package/src/executors/shard-timings/executor.ts +36 -0
  263. package/src/executors/shard-timings/schema.json +21 -0
  264. package/src/executors/shard-timings/schema.ts +4 -0
  265. package/src/failure-summary.ts +119 -0
  266. package/src/generators/bounded-test-targets/generator.test.ts +4 -4
  267. package/src/generators/bun-test-tracing/generator.test.ts +2 -2
  268. package/src/generators/create-package/generator.test.ts +6 -0
  269. package/src/generators/create-package/generator.ts +6 -2
  270. package/src/host-controller-wiring.test.ts +31 -0
  271. package/src/index.test.ts +909 -295
  272. package/src/index.ts +441 -143
  273. package/src/linked-snapshots.nx.test.ts +172 -0
  274. package/src/managed-files/ci-workflow.ts +54 -13
  275. package/src/managed-files/files.ts +65 -9
  276. package/src/managed-files/forgejo-artifact.test.ts +395 -0
  277. package/src/managed-files/generator.test.ts +60 -1
  278. package/src/managed-files/json-edit.test.ts +216 -0
  279. package/src/managed-files/json-edit.ts +290 -0
  280. package/src/managed-files/managed-format-json.test.ts +308 -0
  281. package/src/managed-files/managed-format.ts +90 -2
  282. package/src/managed-files/pr-preview-cleanup-workflow.ts +69 -3
  283. package/src/managed-files/publish-workflow.ts +285 -67
  284. package/src/managed-files/repo-path.test.ts +129 -0
  285. package/src/managed-files/trace-db-artifact.test.ts +7 -0
  286. package/src/managed-files/tree.ts +11 -3
  287. package/src/manifest-hash.ts +2 -6
  288. package/src/nextest-code-bound.test.ts +155 -0
  289. package/src/nextest-code-bound.ts +195 -0
  290. package/src/nextest-extraction.test.ts +37 -5
  291. package/src/nextest-extraction.ts +51 -9
  292. package/src/nextest-partitions.test.ts +427 -82
  293. package/src/nx-cache-bound.test.ts +5 -10
  294. package/src/nx-cache-restore-mtime.test.ts +170 -0
  295. package/src/nx-daemon-claim.test.ts +277 -0
  296. package/src/nx-daemon-idle-cpu.test.ts +81 -0
  297. package/src/nx-daemon-idle-policy.test.ts +51 -0
  298. package/src/nx-daemon-ignore-files.test.ts +210 -0
  299. package/src/nx-daemon-root-normalization.test.ts +105 -0
  300. package/src/nx-daemon-validity.test.ts +925 -0
  301. package/src/nx-dot-input-policy.test.ts +353 -0
  302. package/src/nx-failure-life-cycles.test.ts +207 -0
  303. package/src/nx-files-archive-racy.test.ts +97 -0
  304. package/src/nx-foreign-workspace-env.test.ts +329 -0
  305. package/src/nx-incomplete-run-summary.test.ts +70 -0
  306. package/src/nx-plugin-load-errors.test.ts +120 -0
  307. package/src/nx-project-resolution-cache.test.ts +176 -0
  308. package/src/nx-raw-inputs.test.ts +166 -0
  309. package/src/nx-resident-graph-workers.test.ts +7 -16
  310. package/src/nx-run-information.test.ts +118 -0
  311. package/src/nx-skipped-task-exit.test.ts +180 -0
  312. package/src/nx-state-location.test.ts +63 -0
  313. package/src/nx-store-resolution.test.ts +26 -25
  314. package/src/nx-task-graph-cycles.test.ts +148 -0
  315. package/src/nx-task-output-lease.test.ts +414 -0
  316. package/src/nx-use-local.test.ts +103 -0
  317. package/src/package-target-policy.ts +3 -6
  318. package/src/release-config-policy.ts +3 -6
  319. package/src/runtime-input.test.ts +215 -0
  320. package/src/runtime-input.ts +17 -0
  321. package/src/rust-tokens.ts +78 -0
  322. package/src/serial-group-wiring.test.ts +326 -0
  323. package/src/task-history-namespace.test.ts +87 -89
  324. package/src/task-results.test.ts +226 -0
  325. package/src/task-results.ts +75 -0
  326. package/src/test-program.test.ts +303 -0
  327. package/src/test-program.ts +341 -0
  328. package/src/test-timings.test.ts +240 -0
  329. package/src/test-timings.ts +311 -0
  330. package/src/test-walk-policy.test.ts +585 -0
  331. package/src/test-walk-policy.ts +731 -0
  332. package/src/testing.test.ts +509 -0
  333. package/src/testing.ts +922 -0
  334. package/src/type-guards.ts +4 -0
  335. package/src/typecheck-test-policy.test.ts +496 -11
  336. package/src/typecheck-test-policy.ts +137 -103
  337. package/src/workspace-config-policy.test.ts +212 -13
  338. package/src/workspace-config-policy.ts +101 -73
  339. package/src/workspace-index.ts +18 -0
  340. package/src/workspace-manifest.ts +41 -0
  341. package/test-timings.json +85 -30
  342. package/managed/raw/tooling/direnv/inherited-devenv.ts +0 -665
  343. package/managed/raw/tooling/direnv/shared-caches.sh +0 -53
@@ -0,0 +1,152 @@
1
+ import { lstat } from 'node:fs/promises';
2
+ import { isRecord } from '../../type-guards.js';
3
+ export function heldProverOn(read) {
4
+ const key = async (candidate, ramDevice) => {
5
+ if (candidate.kind === 'image') {
6
+ return { kind: 'unkeyed' };
7
+ }
8
+ const { kind, mountpoint, description } = candidate;
9
+ let root;
10
+ try {
11
+ root = await read(mountpoint);
12
+ }
13
+ catch (error) {
14
+ const code = typeof error === 'object' && error !== null && 'code' in error ? error.code : undefined;
15
+ return code === 'ENOENT' || code === 'ENOTDIR'
16
+ ? { kind: 'unkeyed' }
17
+ : { kind: 'failed', error: `lstat ${mountpoint}: ${error instanceof Error ? error.message : String(error)}` };
18
+ }
19
+ if (!root.isDirectory() || root.dev.toString() === ramDevice) {
20
+ return { kind: 'unkeyed' };
21
+ }
22
+ return {
23
+ kind: 'keyed',
24
+ proof: {
25
+ kind,
26
+ mountpoint,
27
+ description,
28
+ root: { dev: root.dev.toString(), ino: root.ino.toString(), birthtimeNs: root.birthtimeNs.toString() },
29
+ },
30
+ };
31
+ };
32
+ /** Every candidate keyed, or why not: the first unreadable one, else `undefined` for no proof. */
33
+ const keyAll = async (candidates, ramDevice) => {
34
+ const keyed = await Promise.all(candidates.map((candidate) => key(candidate, ramDevice)));
35
+ const proofs = [];
36
+ for (const holder of keyed) {
37
+ if (holder.kind === 'failed') {
38
+ return { ok: false, error: holder.error };
39
+ }
40
+ if (holder.kind === 'keyed') {
41
+ proofs.push(holder.proof);
42
+ }
43
+ }
44
+ return { ok: true, value: proofs.length === keyed.length && nonEmpty(proofs) ? proofs : undefined };
45
+ };
46
+ return {
47
+ async capture(context, candidates) {
48
+ const proofs = await keyAll(candidates, context.ramDevice);
49
+ if (!proofs.ok) {
50
+ return proofs;
51
+ }
52
+ const { volumeKey, leaseKey, ramDevice } = context;
53
+ return {
54
+ ok: true,
55
+ value: proofs.value && { version: 1, context: { volumeKey, leaseKey, ramDevice }, holders: proofs.value },
56
+ };
57
+ },
58
+ async validate(verdict, context) {
59
+ const was = verdict.context;
60
+ const sameLease = was.volumeKey === context.volumeKey && was.leaseKey === context.leaseKey && was.ramDevice === context.ramDevice;
61
+ if (!sameLease) {
62
+ return { ok: true, value: false };
63
+ }
64
+ const proofs = await keyAll(verdict.holders, context.ramDevice);
65
+ if (!proofs.ok) {
66
+ return proofs;
67
+ }
68
+ const now = proofs.value;
69
+ return {
70
+ ok: true,
71
+ value: now !== undefined &&
72
+ verdict.holders.every(({ mountpoint, root }, index) => {
73
+ const again = now[index];
74
+ return (again !== undefined &&
75
+ again.mountpoint === mountpoint &&
76
+ again.root.dev === root.dev &&
77
+ again.root.ino === root.ino &&
78
+ again.root.birthtimeNs === root.birthtimeNs);
79
+ }),
80
+ };
81
+ },
82
+ };
83
+ }
84
+ const hostProver = heldProverOn((path) => lstat(path, { bigint: true }));
85
+ /**
86
+ * The verdict that `candidates`, the holders a fresh inventory found below the lease, still hold
87
+ * it; `undefined` when there are none or one cannot be keyed, an image always among them, which
88
+ * leaves the inventory's held result standing uncached. An unreadable holder is an error, not a
89
+ * verdict.
90
+ */
91
+ export function captureHeldVerdict(context, candidates) {
92
+ return hostProver.capture(context, candidates);
93
+ }
94
+ /**
95
+ * Whether `verdict` still proves its lease held in `context`: the same volume incarnation and
96
+ * lease, and every holder still mounted with the identity it was keyed by. `false` asks for a
97
+ * fresh inventory; it never says the lease is free.
98
+ */
99
+ export function validateHeldVerdict(verdict, context) {
100
+ return hostProver.validate(verdict, context);
101
+ }
102
+ /** A verdict from its JSON value; `undefined` for anything malformed, which asks for a fresh inventory. */
103
+ export function parseHeldVerdict(value) {
104
+ if (!isRecord(value) || value.version !== 1 || !Array.isArray(value.holders)) {
105
+ return undefined;
106
+ }
107
+ const context = parseContext(value.context);
108
+ const proofs = [];
109
+ for (const holder of value.holders) {
110
+ const proof = parseProof(holder);
111
+ if (!proof) {
112
+ return undefined;
113
+ }
114
+ proofs.push(proof);
115
+ }
116
+ const holders = nonEmpty(proofs) ? proofs : undefined;
117
+ return context && holders && { version: 1, context, holders };
118
+ }
119
+ function parseContext(value) {
120
+ if (!isRecord(value)) {
121
+ return undefined;
122
+ }
123
+ const volumeKey = text(value.volumeKey);
124
+ const leaseKey = text(value.leaseKey);
125
+ const ramDevice = decimal(value.ramDevice);
126
+ return volumeKey && leaseKey && ramDevice ? { volumeKey, leaseKey, ramDevice } : undefined;
127
+ }
128
+ /** A mount proof; any other kind, an image's among them, is malformed. */
129
+ function parseProof(value) {
130
+ if (!isRecord(value) || value.kind !== 'mount' || !isRecord(value.root)) {
131
+ return undefined;
132
+ }
133
+ const mountpoint = text(value.mountpoint);
134
+ const description = text(value.description);
135
+ const dev = decimal(value.root.dev);
136
+ const ino = decimal(value.root.ino);
137
+ const birthtimeNs = decimal(value.root.birthtimeNs);
138
+ return mountpoint && description && dev && ino && birthtimeNs
139
+ ? { kind: 'mount', mountpoint, description, root: { dev, ino, birthtimeNs } }
140
+ : undefined;
141
+ }
142
+ /** A nonempty string. */
143
+ function text(value) {
144
+ return typeof value === 'string' && value.length > 0 ? value : undefined;
145
+ }
146
+ /** An integer as `bigint.toString()` writes it: the only spelling that compares equal to a fresh read. */
147
+ function decimal(value) {
148
+ return typeof value === 'string' && /^(?:0|-?[1-9]\d*)$/.test(value) ? value : undefined;
149
+ }
150
+ function nonEmpty(items) {
151
+ return items.length > 0;
152
+ }
@@ -0,0 +1,223 @@
1
+ import { type ProcessEntry } from '../../testing.js';
2
+ import { type PhaseShare } from './disk-lease.js';
3
+ /**
4
+ * The volume's ceiling, plus the revision's sectors. Pages are allocated as they are written and
5
+ * returned when the volume detaches, so this bounds what a runaway suite can take, not what a gate
6
+ * costs. Measured 2026-10-04: a full parallel smoothbricks `lint test build host-controller-test`
7
+ * gate peaked at 1.61 GiB used with 18 concurrent leases; 8 GiB is five times that. That
8
+ * gate also staged cowshed's real-APFS fixture images on the volume, which now stay under
9
+ * /private/tmp, so the peak is an upper bound.
10
+ */
11
+ export declare const RAM_TEMP_CAPACITY_BYTES: number;
12
+ export interface CommandOutput {
13
+ status: number;
14
+ stdout: string;
15
+ stderr: string;
16
+ }
17
+ /** The host programs the volume lifecycle runs. A seam so the state machine is testable without DiskArbitration. */
18
+ export interface HostCommands {
19
+ run(file: string, args: readonly string[], deadlineMs?: number): Promise<CommandOutput>;
20
+ }
21
+ /**
22
+ * The processes still working in a lease directory once its task is over, and how they end. A
23
+ * seam so the volume's state machine is testable without any.
24
+ */
25
+ export interface LeaseProcesses {
26
+ /**
27
+ * End every process whose working directory is in `directory`, and everything those started,
28
+ * and answer each as `<pid> (<command>)`. Every one has exited when this settles; one that
29
+ * would not rejects with its name.
30
+ */
31
+ stopWorkingIn(directory: string): Promise<string[]>;
32
+ }
33
+ /** The host reads and signals cleanup uses; a seam for process ordering and signal failures. */
34
+ export interface ProcessHost {
35
+ /** The processes whose working directory is `directory` or lies beneath it. */
36
+ workingIn(directory: string): Promise<number[]>;
37
+ /** Every process on the host. */
38
+ table(): Promise<ProcessEntry[]>;
39
+ signal(pid: number, signal: NodeJS.Signals): void;
40
+ }
41
+ /**
42
+ * The processes `host` reads. A lease belongs to one task and its command is gone by the time the
43
+ * lease ends, so what still works in it is what the command left behind. A fixture's Nx daemon is
44
+ * the usual one: Nx detaches it into a session of its own, so the process-group kill that ends a
45
+ * timed-out command never reaches it, and a test process that is killed runs no teardown of its
46
+ * own. Deleting the lease asks such a daemon to leave only by deleting its record, which it
47
+ * notices within a second when it is idle and not at all while it is wedged; a signal does not
48
+ * depend on the daemon noticing, and a process left on the volume is what keeps it from
49
+ * detaching.
50
+ *
51
+ * A leftover keeps running while it is looked for, and a child it starts after the process table
52
+ * was read is in no table that was. So each one found is held with SIGSTOP and the table is read
53
+ * again, until a read names nothing that the read before did not already show stopped: a stopped
54
+ * process starts nothing, and whatever it started before it stopped is in every table read after.
55
+ * Discovery waits for stopped-census readiness; the exit grace starts only after SIGTERM.
56
+ * Only then does each get SIGTERM, and SIGCONT to act on it. A child whose parent exited before it
57
+ * could be held has lost its ancestry, so once the stopped-table barrier holds, the lease is asked
58
+ * again what works in it, including when that table names nothing, to recover reparented children.
59
+ */
60
+ export declare function leaseProcessesOn(host: ProcessHost): LeaseProcesses;
61
+ export declare const hostLeaseProcesses: LeaseProcesses;
62
+ export interface RamTempPaths {
63
+ /** Where DiskArbitration mounts the volume: `/Volumes/<volumeName>`. Short for sun_path (104 bytes). */
64
+ mountpoint: string;
65
+ lockFile: string;
66
+ /** APFS volume name; names the mountpoint. */
67
+ volumeName: string;
68
+ /** Where the volume is mounted to be marked before Disk Arbitration places it at `mountpoint`. */
69
+ staging: string;
70
+ /** Login name `hdiutil info` reports as the attaching user of this module's RAM disks. */
71
+ user: string;
72
+ }
73
+ export declare function ramTempPaths(user: {
74
+ uid: number;
75
+ username: string;
76
+ }): RamTempPaths;
77
+ /** An attached RAM disk, as `hdiutil info` lists it. */
78
+ export interface RamDisk {
79
+ /** The whole disk (`/dev/diskN`): detaching it removes its container and volumes. */
80
+ physical: string;
81
+ sectors: number;
82
+ /** Login name of the user that attached it. */
83
+ user: string;
84
+ /** Where its volumes are mounted, if anywhere. */
85
+ mountpoints: string[];
86
+ }
87
+ export interface RamTempLease {
88
+ /** The task's TMPDIR: a directory on the volume that only this task uses. */
89
+ directory: string;
90
+ mountpoint: string;
91
+ capacityBytes: number;
92
+ }
93
+ export type RamTempAcquisition =
94
+ /**
95
+ * `held`: dead leases that could not be reclaimed, each with what still holds it. `reaped`: the
96
+ * processes of dead leases that were still working there and were stopped before the lease went.
97
+ */
98
+ {
99
+ kind: 'leased';
100
+ lease: RamTempLease;
101
+ held: string[];
102
+ reaped: string[];
103
+ }
104
+ /** Inside a cowshed sandbox: /private/tmp is not writable and no image can attach. */
105
+ | {
106
+ kind: 'sandboxed';
107
+ detail: string;
108
+ };
109
+ /** A host command or filesystem step failed while the volume was being created, mounted or detached. */
110
+ type ProvisionFailed = {
111
+ kind: 'provision-failed';
112
+ step: string;
113
+ detail: string;
114
+ };
115
+ export type RamTempError = ProvisionFailed
116
+ /** A failed task left the volume (nearly) full: the likely cause of its failure. */
117
+ | {
118
+ kind: 'volume-full';
119
+ mountpoint: string;
120
+ capacityBytes: number;
121
+ freeBytes: number;
122
+ };
123
+ export type Result<T, E> = {
124
+ ok: true;
125
+ value: T;
126
+ } | {
127
+ ok: false;
128
+ error: E;
129
+ };
130
+ export declare function describeRamTempError(error: RamTempError): string;
131
+ export declare class RamTempVolume {
132
+ private readonly paths;
133
+ private readonly capacityBytes;
134
+ private readonly commands;
135
+ private readonly pid;
136
+ private readonly isAlive;
137
+ private readonly processes;
138
+ /** The RAM disk's size, which with the attaching user identifies this module's disks on the host. */
139
+ private readonly sectors;
140
+ /** The claims and held verdicts the lock admits changes to, beside the lock file. */
141
+ private readonly ledgerPath;
142
+ constructor(paths: RamTempPaths, capacityBytes: number, commands: HostCommands, pid?: number, isAlive?: (pid: number) => boolean, processes?: LeaseProcesses);
143
+ /** Take a lease: create the volume if no task holds one, and a private directory on it. */
144
+ acquire(): Promise<Result<RamTempAcquisition, RamTempError>>;
145
+ private make;
146
+ private undo;
147
+ private unmake;
148
+ private lease;
149
+ private create;
150
+ /**
151
+ * Stop what the task left working in its lease, before the lease ends: the processes whose
152
+ * working directory is in it and everything they started, answered as `<pid> (<command>)`.
153
+ * Runs outside the volume's lock, which one lease's leftovers must not hold up the others
154
+ * behind, and costs a scan of every process only when the lease still holds anything.
155
+ */
156
+ reap(lease: RamTempLease): Promise<Result<string[], RamTempError>>;
157
+ /** End a lease; the last lease detaches the volume, returning its RAM. */
158
+ release(lease: RamTempLease): Promise<Result<void, RamTempError>>;
159
+ private releaseLease;
160
+ private waitOut;
161
+ /** After a failed task: whether the volume ran out of space, which is then the error to report. */
162
+ fullness(lease: RamTempLease): Promise<RamTempError | null>;
163
+ private lock;
164
+ private end;
165
+ private locked;
166
+ private readLedger;
167
+ private observe;
168
+ private claim;
169
+ private settle;
170
+ private unchanged;
171
+ private provisionVolume;
172
+ private provision;
173
+ private expectMounted;
174
+ private attached;
175
+ private reclaimStrays;
176
+ private detach;
177
+ private readInventory;
178
+ /**
179
+ * The holder check of one creation pass. The first check reads the attachments and every later
180
+ * check in the pass reads the same ones, so a pass runs `ioreg` and `mount` once however many
181
+ * disks it visits. What is attached from below a prefix: images whose backing file is there,
182
+ * and mounts. `hdiutil info` omits attached images while another image attaches or detaches
183
+ * (measured by cowshed's scratch-root sweep), and tests attach images concurrently.
184
+ */
185
+ private holdersPass;
186
+ }
187
+ /**
188
+ * Every image in `ioreg` output whose `DiskImageURL` names a file under `prefix`, as
189
+ * `<backing file> (/dev/diskN)`.
190
+ */
191
+ export declare function imagesBackedUnder(registry: string, prefix: string): string[];
192
+ /** Mount points in `mount` output (`<device> on <path> (<options>)`) that lie under `prefix`. */
193
+ export declare function mountsBelow(table: string, prefix: string): string[];
194
+ /** The disk `diskutil apfs` reports it created: "Disk from APFS operation: disk271". */
195
+ export declare function operationDisk(stdout: string): string | null;
196
+ /**
197
+ * The RAM disks in `hdiutil info` output. Images are separated by a row of `=`; a RAM disk's
198
+ * `image-path` is `ram://<sectors>`, and its entity rows are `<dev>\t<content hint>\t<mountpoint>`,
199
+ * the whole disk first.
200
+ */
201
+ export declare function ramDisksIn(info: string): RamDisk[];
202
+ /** Disk tools delegate their lease and process lifetime to cowshed, with one image policy. */
203
+ export declare function diskCommand(file: string, args: readonly string[], deadlineMs: number): {
204
+ args: string[];
205
+ lifetime: 'stop-wait' | 'facade-owned';
206
+ } | null;
207
+ /**
208
+ * The variable naming the cowshed executable that runs `cowshed disk-command`. Unset, it is the installed `cowshed`
209
+ * on PATH. A repository that tests its own cowshed sets it, on the targets that test it, to that checkout's build:
210
+ * an installed cowshed that predates a command its own checkout added would fail the very code under test.
211
+ */
212
+ export declare const COWSHED_EXECUTABLE_ENV = "COWSHED_EXECUTABLE";
213
+ /**
214
+ * hdiutil and diskutil delegate process lifetime and disk leasing to cowshed: safe commands
215
+ * pass their total budget and wait for the facade's actual exit after child reap. Only image
216
+ * commands have a caller stop-wait deadline; killing an attach or detach can leak its kernel
217
+ * device until reboot. Never acquire a second lease around the facade. Other leased helpers
218
+ * take their lease here. Recorded lease waits ask for `alone`; an older gateway is asked
219
+ * shared at once, and for a minute after.
220
+ */
221
+ export declare function createHostCommands(defaultDeadlineMs?: number, gatewaySocket?: string, wantedShare?: PhaseShare, cowshed?: string): HostCommands;
222
+ export {};
223
+ //# sourceMappingURL=ram-temp.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ram-temp.d.ts","sourceRoot":"","sources":["../../../src/executors/bounded-exec/ram-temp.ts"],"names":[],"mappings":"AAqBA,OAAO,EAEL,KAAK,YAAY,EAKlB,MAAM,kBAAkB,CAAC;AAE1B,OAAO,EAAe,KAAK,UAAU,EAAgC,MAAM,iBAAiB,CAAC;AAiH7F;;;;;;;GAOG;AACH,eAAO,MAAM,uBAAuB,QAA6C,CAAC;AAOlF,MAAM,WAAW,aAAa;IAC5B,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,oHAAoH;AACpH,MAAM,WAAW,YAAY;IAC3B,GAAG,C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