stim 1.25.0 → 1.27.0

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 (182) hide show
  1. package/README.md +1 -1
  2. package/dist/{acquire-artifact-zA4S7RHE.mjs → acquire-artifact-BKN2Yuhg.mjs} +2 -2
  3. package/dist/{act-BbHS3oV8.mjs → act-ROviTF_t.mjs} +415 -118
  4. package/dist/{activity-BpjwrQXU.mjs → activity-Cd-ysFes.mjs} +6 -7
  5. package/dist/{agent-device-usage-output-Bnkerfod.mjs → agent-device-usage-output-C5nCKWp9.mjs} +5 -5
  6. package/dist/{android-CNZgRC-4.mjs → android--HBgpvpW.mjs} +5 -5
  7. package/dist/{android-BGwuK3Mc.mjs → android-Cd6w7_qw.mjs} +134 -57
  8. package/dist/{android-saBeB4lr.mjs → android-Deb9X3_Y.mjs} +37 -15
  9. package/dist/{android-Cjcj8MCw.mjs → android-DriNoAVy.mjs} +99 -47
  10. package/dist/{android-cas-BVqh2Zep.mjs → android-cas-D5e6ecUg.mjs} +4 -4
  11. package/dist/android-cas-compiler.mjs +1 -1
  12. package/dist/{android-project-CTYaETc0.d.mts → android-project-DUGMbq28.d.mts} +55 -1
  13. package/dist/api.d.mts +20 -7
  14. package/dist/api.mjs +42 -32
  15. package/dist/apk-signed-tail-BHQHx3Rm.mjs +142 -0
  16. package/dist/{artifact-Co8zixVx.mjs → artifact-0AGJYB9O.mjs} +28 -28
  17. package/dist/{artifact-DN8JNwqS.mjs → artifact-faemIZv5.mjs} +40 -30
  18. package/dist/{artifact-platform-CMRc0M_r.mjs → artifact-platform-BO2Uvk_A.mjs} +1 -1
  19. package/dist/{attempt-DW-mQqM7.mjs → attempt-ClyJlZPT.mjs} +4 -2
  20. package/dist/auto-placement-z-H5pJza.mjs +350 -0
  21. package/dist/{browser-web-CCgZsHmI.mjs → browser-web-slD8AvLp.mjs} +16 -17
  22. package/dist/{build-cache-CKCzxzxA.mjs → build-cache-gBJ-WKzA.mjs} +141 -37
  23. package/dist/{build-CAiw8Ezm.mjs → build-hS0QyFlQ.mjs} +38 -31
  24. package/dist/{build-plan-zCuHGlA8.mjs → build-plan-CBqYbzYM.mjs} +7 -6
  25. package/dist/{cache-manifest-BPXRONJz.mjs → cache-manifest-DEjqGGat.mjs} +1 -1
  26. package/dist/cache-manifest.mjs +1 -1
  27. package/dist/{budget-HyShrIpL.mjs → ccache-BWTze1Ls.mjs} +634 -1514
  28. package/dist/{cdp-BG3FJCCx.mjs → cdp-C3svvXiE.mjs} +1 -1
  29. package/dist/{chrome-BvV8ssI3.mjs → chrome-DyDWurWG.mjs} +1 -1
  30. package/dist/{cli-C4w607Pz.mjs → cli-ftXDLto1.mjs} +24 -23
  31. package/dist/cli.mjs +1 -1
  32. package/dist/{client-BQsmyp_-.mjs → client-xsdxrhWA.mjs} +77 -116
  33. package/dist/collector-run.d.mts +10 -9
  34. package/dist/collector-run.mjs +42 -27
  35. package/dist/{command-output-BBvS1H6v.mjs → command-output-Dj-WT4BP.mjs} +1 -1
  36. package/dist/{config-BZhXY15H.mjs → config-Cn94Jc0g.mjs} +343 -18
  37. package/dist/{launch-DscF1QfM.mjs → dependencies-BGokZ-Ng.mjs} +330 -279
  38. package/dist/{dependency-state-BwNCYG5Q.mjs → dependency-state-C3OtgG94.mjs} +14 -7
  39. package/dist/{detached-entry-KmieOKgN.mjs → detached-entry-BPlSaCwC.mjs} +1 -1
  40. package/dist/{dev-client-CHoXXZeg.mjs → dev-client-BMca82xo.mjs} +2 -2
  41. package/dist/{device-F5-4z9ef.mjs → device-BJm0irrq.mjs} +16 -16
  42. package/dist/{device-capacity-ZYaRALv5.mjs → device-capacity-6LP7QsaA.mjs} +103 -25
  43. package/dist/device-host-worker.mjs +19 -21
  44. package/dist/{device-ios-DkHBrmvH.mjs → device-ios-534c14fz.mjs} +288 -28
  45. package/dist/{device-lease-run-ogEeJ62K.mjs → device-lease-run-DwsGfjUN.mjs} +5 -5
  46. package/dist/{device-pool-BIg8MU8l.mjs → device-pool-BnQqvs6o.mjs} +3 -3
  47. package/dist/{device-B9FqTBYW.mjs → device-tM41-TUq.mjs} +25 -24
  48. package/dist/{doctor-A_Nr_fDe.mjs → doctor-Dbx1ZpD2.mjs} +1 -1
  49. package/dist/{doctor-k3P3PizH.mjs → doctor-DyqE9n1J.mjs} +28 -16
  50. package/dist/{doctor-Bm8TVpGn.mjs → doctor-F-3VUUyN.mjs} +128 -35
  51. package/dist/{doctor-fingerprint-zlujA1Gs.mjs → doctor-fingerprint-o7ZI9YLn.mjs} +9 -3
  52. package/dist/doctor-fingerprint.mjs +1 -1
  53. package/dist/{doctor-watchman-BovI1y3-.mjs → doctor-watchman-CxDbyrrt.mjs} +5 -5
  54. package/dist/{eas-build-CyDKNTBP.mjs → eas-build-CjNSWmjo.mjs} +4 -4
  55. package/dist/eas-fallback-9fqb46kW.mjs +87 -0
  56. package/dist/{eas-session-ledger-BMCA1gdO.mjs → eas-session-ledger-DrP4OuuM.mjs} +6 -6
  57. package/dist/{error-diagnostics-B1Mj_-7h.mjs → error-diagnostics-snej9k4j.mjs} +51 -25
  58. package/dist/{exec-VFRpu1iA.mjs → exec-aULwtNly.mjs} +57 -6
  59. package/dist/{gc-eaz403W6.mjs → gc-BRwAY3qT.mjs} +2 -2
  60. package/dist/{gc-B9jcnmIk.mjs → gc-CGZ1Yg88.mjs} +218 -72
  61. package/dist/{guide-DR0K0xW9.mjs → guide-_rfEh_zM.mjs} +839 -222
  62. package/dist/{hosted-android-Bvb2-ZxD.mjs → hosted-android-BMKzUNnY.mjs} +4 -4
  63. package/dist/{hosted-client-rsRqysJc.mjs → hosted-client-D7Pk_Oo1.mjs} +13 -9
  64. package/dist/{hosted-logs-CWKGYWNX.mjs → hosted-logs-B1gqQuva.mjs} +18 -12
  65. package/dist/hosted-logs-sync-Dg3qrZmV.mjs +195 -0
  66. package/dist/{hosted-macos-d0pv9Tth.mjs → hosted-macos-B9w4H8hc.mjs} +6 -6
  67. package/dist/{hosted-native-BxTizGU2.mjs → hosted-native-CdgaiuyP.mjs} +17 -17
  68. package/dist/{idle-shutdown-BIyfl0Zj.mjs → idle-shutdown-Cbvo5KEh.mjs} +21 -9
  69. package/dist/{ios-BRVM8b0P.mjs → ios-B5HlVMhQ.mjs} +138 -55
  70. package/dist/{ios-Dvt97HgQ.mjs → ios-Bk4mWbtS.mjs} +8 -8
  71. package/dist/{ios-ENC4sRPA.mjs → ios-CsRVik64.mjs} +7 -1
  72. package/dist/{ios-BQzvJlzw.mjs → ios-E26qSpkb.mjs} +94 -11
  73. package/dist/{ios-device-CKSvk0bu.mjs → ios-device-C_QkIf1Z.mjs} +3 -3
  74. package/dist/{ios-device-B6HK951C.mjs → ios-device-CiBA-er9.mjs} +1 -1
  75. package/dist/{ios-project-DCUDo06I.mjs → ios-project-D8Jcy_br.mjs} +22 -9
  76. package/dist/{ios-signing-4c_qXvQm.mjs → ios-signing-BJzvDPfU.mjs} +2 -2
  77. package/dist/{ios-state-CT9nV5SP.mjs → ios-state-BZ03NFgF.mjs} +1 -1
  78. package/dist/{js-swap-Z9HbC4cj.mjs → js-swap-Dg2a945i.mjs} +8 -7
  79. package/dist/{launch-D0lPvFFu.mjs → launch-CRyBeNsA.mjs} +53 -44
  80. package/dist/lightened-BCsdAGj_.mjs +171 -0
  81. package/dist/{logs-BsIRre8x.mjs → logs-CC_-ZzEE.mjs} +10 -174
  82. package/dist/{logs-Crs9y34Z.mjs → logs-aJQb-RDg.mjs} +112 -38
  83. package/dist/{macos-CcUlJPMu.mjs → macos-BGmTpnv9.mjs} +1 -1
  84. package/dist/{macos-D477nfzH.mjs → macos-DlCBhMw5.mjs} +73 -39
  85. package/dist/macos-run.mjs +1 -1
  86. package/dist/maintenance-run.mjs +30 -13
  87. package/dist/{metro-1pJgCX4U.mjs → metro-CvyD-xwe.mjs} +4 -4
  88. package/dist/{metro-gateway-Bp9gJQAN.mjs → metro-gateway-BnHdqMO_.mjs} +3 -4
  89. package/dist/{named-ports-BVbn8SvC.mjs → named-ports-BCyMWA6b.mjs} +3 -3
  90. package/dist/{native-android-BvMizJn1.mjs → native-android-DlpxCyOP.mjs} +17 -18
  91. package/dist/{native-gradle-artifact-inputs-BJscK4vN.mjs → native-gradle-artifact-inputs-C13qT7R_.mjs} +5 -5
  92. package/dist/{native-runtime-B9w_Qyz3.mjs → native-runtime-DqaIBO5w.mjs} +9 -9
  93. package/dist/{native-source-D-4Dh4JU.mjs → native-source-D1AzWiuP.mjs} +1 -1
  94. package/dist/{native-xcode-inputs-Cv4l-obn.mjs → native-xcode-inputs-B1W8SrxB.mjs} +3 -3
  95. package/dist/{native-xcode-ios-DGrg90hE.mjs → native-xcode-ios-QPP0Rm68.mjs} +17 -18
  96. package/dist/{ndjson-CgE_o3Dl.mjs → ndjson-Dy2W4vRa.mjs} +2 -2
  97. package/dist/offload-worker.d.mts +3 -1
  98. package/dist/offload-worker.mjs +34 -25
  99. package/dist/{operation-exec-CUZifp6Z.mjs → operation-exec-Dp4FuIGR.mjs} +1 -1
  100. package/dist/{ownership-jxxz-19m.mjs → ownership-Bx-0cku-.mjs} +3 -3
  101. package/dist/{page-CzEA_-5_.mjs → page-CQJlcj3x.mjs} +2 -2
  102. package/dist/{phone-reverses-CYb7RRAx.mjs → phone-reverses-C9yAaKEv.mjs} +18 -4
  103. package/dist/{placement-log-DjOXJRIH.mjs → placement-log-BXUbiZM6.mjs} +3 -3
  104. package/dist/{plan-placement-BqKgKHCi.mjs → plan-placement-UxnQjv5Z.mjs} +36 -10
  105. package/dist/{ports-DtS1Amb0.mjs → ports-uUrghqWN.mjs} +3 -3
  106. package/dist/prebuild-BDpToDgR.mjs +1246 -0
  107. package/dist/{project-BiC68mIp.mjs → project-DYj-HVx6.mjs} +17 -18
  108. package/dist/{pull-request-CbNlkFok.mjs → pull-request-BzLmzAIQ.mjs} +2 -2
  109. package/dist/pull-requests.mjs +1 -1
  110. package/dist/{react-native-android-DRYqoJc4.mjs → react-native-android-DDBccgJw.mjs} +56 -36
  111. package/dist/{react-native-build-CwZB-agu.mjs → react-native-build-DaK2IFyP.mjs} +9 -9
  112. package/dist/{react-native-doctor-BCrytK7h.mjs → react-native-doctor-B-Mw6DcR.mjs} +50 -9
  113. package/dist/{react-native-ios-Cr1buNFo.mjs → react-native-ios-DjYwUF9U.mjs} +45 -25
  114. package/dist/{recordings-BaoQ0t-J.mjs → recordings-C20iUZfp.mjs} +1 -1
  115. package/dist/{registration-CN6nlhcD.mjs → registration-BwCe64PH.mjs} +1 -1
  116. package/dist/{reload-Beftw2X3.mjs → reload-DJBeF_rC.mjs} +1 -1
  117. package/dist/{reload-FbSgMF8x.mjs → reload-fUdkH2_p.mjs} +16 -16
  118. package/dist/{remote-BuZj6AyU.mjs → remote-y6n99WMW.mjs} +22 -9
  119. package/dist/{result-CR2vk2cj.mjs → result-CTqBw2Te.mjs} +32 -21
  120. package/dist/{run-BtzE09Dl.mjs → run-DaCeNKRm.mjs} +3 -3
  121. package/dist/{selection-D5cxEl3t.mjs → selection-Bs8phwhN.mjs} +183 -62
  122. package/dist/{server-bare-CH9X0RLn.mjs → server-bare-BOh-iZEj.mjs} +2 -2
  123. package/dist/{server-command-CaBbDNU2.mjs → server-command-8CuA51Cv.mjs} +6 -6
  124. package/dist/{server-expo-Ck8EIidM.mjs → server-expo-ABQs2XFA.mjs} +4 -4
  125. package/dist/server-expo-Ba_Y21vB.mjs +2 -0
  126. package/dist/{settings-B5tCoq9N.mjs → settings-BDVI8Ivc.mjs} +331 -62
  127. package/dist/{settings-DzH9mGQZ.mjs → settings-CMHhQNwI.mjs} +24 -3
  128. package/dist/settings-payload-cm60Zhib.mjs +257 -0
  129. package/dist/settings-write-BdNRLlBn.mjs +185 -0
  130. package/dist/settings.schema.json +84 -39
  131. package/dist/{simslim-BjxszUAb.mjs → simslim-DCQwzoPy.mjs} +4 -3
  132. package/dist/{slot-launch-QeuJMlnJ.mjs → slot-launch-0l7RqSpr.mjs} +6 -6
  133. package/dist/{stage-D8xlRU2D.mjs → stage-F4cAfJGi.mjs} +2 -2
  134. package/dist/{start-C1JLjkNw.mjs → start-DcqnF9p8.mjs} +1 -1
  135. package/dist/{start-YMpNwLhh.mjs → start-DrPwER_2.mjs} +27 -23
  136. package/dist/{state-DMRNP7-4.mjs → state-BX1y5syV.mjs} +4 -5
  137. package/dist/{state-DPaM3u5K.mjs → state-CZxLyetD.mjs} +2 -3
  138. package/dist/{stats-CP7STzZw.mjs → stats-GxuCbles.mjs} +5 -5
  139. package/dist/{stats-report-n2U5plhk.mjs → stats-report-B86Cv7Uc.mjs} +1 -1
  140. package/dist/{status-Fect2w9R.mjs → status-7ULDEJ1e.mjs} +1 -1
  141. package/dist/{status-CRLiJ-O_.mjs → status-BfnK9pUd.mjs} +25 -26
  142. package/dist/{status-cNw6i0_t.mjs → status-Bj7ZYvvc.mjs} +1 -1
  143. package/dist/{status-watch-Bc2J4TZn.mjs → status-watch-BfabQn03.mjs} +5 -5
  144. package/dist/status-worker.mjs +1 -1
  145. package/dist/{stim-desktop-DS0mzR8U.mjs → stim-desktop-CbWo21kb.mjs} +2 -2
  146. package/dist/{stop-COP6PQqw.mjs → stop-CH79S3IZ.mjs} +5 -6
  147. package/dist/{stop-Db9Kh-UA.mjs → stop-D-EAr25B.mjs} +25 -22
  148. package/dist/{stop-Br7LKxBE.mjs → stop-x1Yu3He4.mjs} +2 -2
  149. package/dist/supervisor-run.d.mts +1 -0
  150. package/dist/supervisor-run.mjs +17 -18
  151. package/dist/{support-qKcbgmI5.mjs → support-Be0UeVZU.mjs} +10 -10
  152. package/dist/{support-Cxj9CmII.mjs → support-CNg_YsOk.mjs} +6 -6
  153. package/dist/{swiftpm-artifact-inputs-iY9fsmOc.mjs → swiftpm-artifact-inputs-uPqYvGBv.mjs} +4 -4
  154. package/dist/{swiftpm-macos-Bp_sn9P4.mjs → swiftpm-macos-Ch4YjY_A.mjs} +11 -12
  155. package/dist/toolchain-CbCG6C5Z.mjs +2413 -0
  156. package/dist/toolchain-JYAOquPg.mjs +2 -0
  157. package/dist/{trigger-CBMe2YLH.mjs → trigger-DMou-X7j.mjs} +3 -3
  158. package/dist/trigger-qp2ji5wE.mjs +2 -0
  159. package/dist/{warm-progress-BV3ZPmcY.mjs → warm-progress-C0RsbngN.mjs} +731 -728
  160. package/dist/{web-B4Yjyt1G.mjs → web-Cq_AQ4DK.mjs} +9 -10
  161. package/dist/web-Je6abcpz.mjs +2 -0
  162. package/dist/web-run.mjs +9 -9
  163. package/dist/windows-report.mjs +1 -1
  164. package/dist/{workspace-state-CPSp3mav.mjs → workspace-state-BjqdjnJR.mjs} +46 -8
  165. package/dist/{workspaces-C9w4aeXF.mjs → workspaces-DFbj07jp.mjs} +1801 -76
  166. package/dist/{worktree-CclFIe1Z.mjs → worktree-COAJ3-OD.mjs} +934 -511
  167. package/dist/{worktree-Ct9Gk3KL.mjs → worktree-JGUd_53L.mjs} +1 -1
  168. package/package.json +8 -8
  169. package/dist/ccache-h1FKhZeg.mjs +0 -143
  170. package/dist/created-devices-D2Aca-xu.mjs +0 -52
  171. package/dist/eas-fallback-gaZi-dJL.mjs +0 -381
  172. package/dist/hosted-ios-RtVcJH3u.mjs +0 -15
  173. package/dist/native-run-D5OJsGwA.mjs +0 -276
  174. package/dist/paths-DQtTgsBf.mjs +0 -42
  175. package/dist/prebuild-JUaqOLpc.mjs +0 -501
  176. package/dist/server-expo-C16Zf2k7.mjs +0 -2
  177. package/dist/settings-write-n0zwfohx.mjs +0 -360
  178. package/dist/toolchain-DB1aeqxO.mjs +0 -2
  179. package/dist/toolchain-VzLJzZ7O.mjs +0 -908
  180. package/dist/trigger-BLsHgAGR.mjs +0 -2
  181. package/dist/web-DS4UDWvf.mjs +0 -2
  182. package/dist/xcode-CiIIDnuD.mjs +0 -910
@@ -1,4 +1,4 @@
1
- import { c as throwIfCancelled, s as cancelledError } from "./exec-VFRpu1iA.mjs";
1
+ import { c as throwIfCancelled, s as cancelledError } from "./exec-aULwtNly.mjs";
2
2
  import { WebSocket } from "ws";
3
3
  //#region src/web/cdp.ts
4
4
  const COMMAND_TIMEOUT_MS = 15e3;
@@ -1,4 +1,4 @@
1
- import { t as getExecutor } from "./exec-VFRpu1iA.mjs";
1
+ import { t as getExecutor } from "./exec-aULwtNly.mjs";
2
2
  import { existsSync } from "node:fs";
3
3
  import { homedir } from "node:os";
4
4
  import { join } from "node:path";
@@ -1,27 +1,27 @@
1
- import { E as debugLog } from "./exec-VFRpu1iA.mjs";
2
- import { y as refuseRelativeStimPaths } from "./config-BZhXY15H.mjs";
1
+ import { E as debugLog } from "./exec-aULwtNly.mjs";
2
+ import { y as refuseRelativeStimPaths } from "./config-Cn94Jc0g.mjs";
3
3
  import { readFileSync } from "node:fs";
4
- import { runId } from "@stim-cli/core/state";
4
+ import { runId, trace } from "@stim-cli/core/state";
5
5
  import { Command } from "commander";
6
6
  //#region bin/cli.ts
7
7
  const commands = /* @__PURE__ */ new Map([
8
- ["doctor", () => import("./doctor-A_Nr_fDe.mjs")],
9
- ["worktree", () => import("./worktree-Ct9Gk3KL.mjs")],
10
- ["start", () => import("./start-C1JLjkNw.mjs")],
11
- ["ports", () => import("./ports-DtS1Amb0.mjs")],
12
- ["stop", () => import("./stop-Br7LKxBE.mjs")],
13
- ["ios", () => import("./ios-Dvt97HgQ.mjs")],
14
- ["android", () => import("./android-CNZgRC-4.mjs")],
15
- ["web", () => import("./web-DS4UDWvf.mjs")],
16
- ["macos", () => import("./macos-CcUlJPMu.mjs")],
17
- ["reload", () => import("./reload-Beftw2X3.mjs")],
18
- ["device", () => import("./device-F5-4z9ef.mjs")],
19
- ["logs", () => import("./logs-Crs9y34Z.mjs")],
20
- ["settings", () => import("./settings-DzH9mGQZ.mjs")],
21
- ["status", () => import("./status-cNw6i0_t.mjs")],
22
- ["stats", () => import("./stats-CP7STzZw.mjs")],
23
- ["gc", () => import("./gc-eaz403W6.mjs")],
24
- ["guide", () => import("./guide-DR0K0xW9.mjs")]
8
+ ["doctor", () => import("./doctor-Dbx1ZpD2.mjs")],
9
+ ["worktree", () => import("./worktree-JGUd_53L.mjs")],
10
+ ["start", () => import("./start-DcqnF9p8.mjs")],
11
+ ["ports", () => import("./ports-uUrghqWN.mjs")],
12
+ ["stop", () => import("./stop-x1Yu3He4.mjs")],
13
+ ["ios", () => import("./ios-Bk4mWbtS.mjs")],
14
+ ["android", () => import("./android--HBgpvpW.mjs")],
15
+ ["web", () => import("./web-Je6abcpz.mjs")],
16
+ ["macos", () => import("./macos-BGmTpnv9.mjs")],
17
+ ["reload", () => import("./reload-DJBeF_rC.mjs")],
18
+ ["device", () => import("./device-BJm0irrq.mjs")],
19
+ ["logs", () => import("./logs-aJQb-RDg.mjs")],
20
+ ["settings", () => import("./settings-CMHhQNwI.mjs")],
21
+ ["status", () => import("./status-Bj7ZYvvc.mjs")],
22
+ ["stats", () => import("./stats-GxuCbles.mjs")],
23
+ ["gc", () => import("./gc-BRwAY3qT.mjs")],
24
+ ["guide", () => import("./guide-_rfEh_zM.mjs")]
25
25
  ]);
26
26
  const pkg = JSON.parse(readFileSync(new URL("../package.json", import.meta.url), "utf-8"));
27
27
  const program = new Command();
@@ -37,9 +37,10 @@ try {
37
37
  for (const module of modules) module.default(program, pkg.version);
38
38
  }
39
39
  program.hook("preAction", async (_command, action) => {
40
+ const path = [];
41
+ for (let each = action; each?.parent; each = each.parent) path.unshift(each.name());
42
+ trace.command(`stim ${path.join(" ")}`, { version: pkg.version });
40
43
  if (debugLog.enabled()) {
41
- const path = [];
42
- for (let each = action; each?.parent; each = each.parent) path.unshift(each.name());
43
44
  const started = Date.now();
44
45
  debugLog.log("run_start", {
45
46
  version: pkg.version,
@@ -52,7 +53,7 @@ try {
52
53
  }));
53
54
  }
54
55
  try {
55
- const { triggerMaintenance } = await import("./trigger-BLsHgAGR.mjs");
56
+ const { triggerMaintenance } = await import("./trigger-qp2ji5wE.mjs");
56
57
  triggerMaintenance(action.name());
57
58
  } catch {}
58
59
  });
package/dist/cli.mjs CHANGED
@@ -4,6 +4,6 @@ const encode = (version) => version.split(".", 3).reduce((sum, part) => sum * 1e
4
4
  if (encode(process.versions.node) < encode("22.12.0")) {
5
5
  process.stderr.write(`STIM_NODE_UNSUPPORTED: Stim needs Node 22.12.0 or later; this is Node ${process.versions.node} at ${process.execPath}. To run Stim where a project pins an older Node, see https://stim.appandflow.com/docs/requirements#older-node-pins\n`);
6
6
  process.exitCode = 1;
7
- } else import("./cli-C4w607Pz.mjs");
7
+ } else import("./cli-ftXDLto1.mjs");
8
8
  //#endregion
9
9
  export {};
@@ -1,69 +1,22 @@
1
- import { C as reportSignal, E as debugLog, b as operationState, c as throwIfCancelled, t as getExecutor } from "./exec-VFRpu1iA.mjs";
2
- import { Q as openAuthenticated, _ as loadConfig$1, it as sayHello, rt as resolveEndpoint } from "./config-BZhXY15H.mjs";
3
- import { o as git, s as gitAsync } from "./operation-exec-CUZifp6Z.mjs";
4
- import { r as createNdjsonWriter } from "./ndjson-CgE_o3Dl.mjs";
5
- import { Cr as discoverCaches, Q as emptyCaches, it as planCacheEmptying } from "./budget-HyShrIpL.mjs";
1
+ import { C as reportSignal, E as debugLog, b as operationState, c as throwIfCancelled, t as getExecutor } from "./exec-aULwtNly.mjs";
2
+ import { _ as loadConfig$1, ot as resolveEndpoint, st as sayHello, tt as openAuthenticated } from "./config-Cn94Jc0g.mjs";
3
+ import { o as git, s as gitAsync } from "./operation-exec-Dp4FuIGR.mjs";
4
+ import { G as planCacheEmptying, R as maintenanceLogger, n as CCACHE_UNAVAILABLE, t as CCACHE_NOT_RUN, ur as discoverCaches, z as emptyCaches } from "./ccache-BWTze1Ls.mjs";
6
5
  import { t as canonicalPath } from "./paths-BsJMoPP2.mjs";
7
- import { d as runCancellationSignal } from "./native-run-D5OJsGwA.mjs";
8
- import { n as CCACHE_UNAVAILABLE, t as CCACHE_NOT_RUN } from "./ccache-h1FKhZeg.mjs";
9
- import { n as COMPILATION_CACHE_UNAVAILABLE, t as COMPILATION_CACHE_NOT_RUN } from "./xcode-CiIIDnuD.mjs";
6
+ import { A as COMPILATION_CACHE_UNAVAILABLE, E as readRubyVersion, a as cocoapodsDifference, k as COMPILATION_CACHE_NOT_RUN, ot as runCancellationSignal, s as iosToolchainAsync, v as toolchainMismatches, x as workerToolchain, y as toolchainNotes } from "./toolchain-CbCG6C5Z.mjs";
10
7
  import { t as resolveMaintenanceSettings } from "./settings-Djl-mpjX.mjs";
11
- import { a as iosToolchainAsync, d as toolchainMismatches, f as workerToolchain, g as readRubyVersion } from "./toolchain-VzLJzZ7O.mjs";
12
- import { i as namedBuildMachine, t as OffloadRefusal, u as pairedMachines } from "./selection-D5cxEl3t.mjs";
8
+ import { f as workerFailureReason, m as pairedMachines, o as namedBuildMachine, t as OffloadRefusal } from "./selection-Bs8phwhN.mjs";
13
9
  import { n as fingerprintNativeInputs, r as manifestDigest } from "./native-inputs-TRTTTRxt.mjs";
14
- import { a as sourceManifest, i as nativeTransferManifest, n as gitVisiblePaths, r as nativeFileDigest, t as checkNativeTransferMembership } from "./native-source-D-4Dh4JU.mjs";
10
+ import { a as sourceManifest, i as nativeTransferManifest, n as gitVisiblePaths, r as nativeFileDigest, t as checkNativeTransferMembership } from "./native-source-D1AzWiuP.mjs";
15
11
  import { createHash, webcrypto } from "node:crypto";
16
- import { closeSync, existsSync, lstatSync, mkdirSync, openSync, readFileSync, readdirSync, realpathSync, rmSync, statSync, unlinkSync, writeSync } from "node:fs";
12
+ import { closeSync, existsSync, lstatSync, mkdirSync, openSync, readFileSync, readdirSync, realpathSync, rmSync, writeSync } from "node:fs";
17
13
  import { isDeepStrictEqual } from "node:util";
18
14
  import { basename, dirname, isAbsolute, join, relative, resolve, sep } from "node:path";
19
- import { LOG_ROTATE_BYTES, ambientContext, dependencyLockfile, reactNativeArtifactIdentity, reactNativeArtifactQuery, rotatedLogPath, swiftpmArtifactQuery, withDirLock } from "@stim-cli/core";
20
- import { MAINTENANCE_LOG_NAME, OFFLOAD_MODES, automaticMachineEnabled, isJsonObject, maintenanceDir, maintenanceNdjsonFile, requireAutomaticMachine, runId, saturation, workspaceLogsDir } from "@stim-cli/core/state";
15
+ import { ambientContext, dependencyLockfile, reactNativeArtifactIdentity, reactNativeArtifactQuery, swiftpmArtifactQuery } from "@stim-cli/core";
16
+ import { automaticMachineEnabled, isJsonObject, maintenanceDir, mayRunHere, placementWord, requireAutomaticMachine, runId, saturation } from "@stim-cli/core/state";
21
17
  import { WebSocket } from "ws";
22
18
  import { setTimeout as setTimeout$1 } from "node:timers/promises";
23
19
  import { access, lstat, readFile, readlink, realpath } from "node:fs/promises";
24
- //#region src/maintenance/log.ts
25
- function maintenanceLogger(settings, pass, trigger) {
26
- const file = maintenanceNdjsonFile();
27
- const rotated = rotatedLogPath(file);
28
- withDirLock(`${file}.lock`, () => {
29
- try {
30
- if (Date.now() - statSync(rotated).mtimeMs > settings.logRetentionDays * 864e5) unlinkSync(rotated);
31
- } catch {}
32
- });
33
- const writer = createNdjsonWriter(file, { maxBytes: settings.logMaxMb * 1024 ** 2 });
34
- return {
35
- write(event, level, msg, fields = {}) {
36
- if (level === "debug" && !settings.logChecks) return null;
37
- const record = {
38
- ...fields,
39
- ts: Date.now(),
40
- src: "maintenance",
41
- level,
42
- msg,
43
- event,
44
- pass,
45
- trigger,
46
- mode: settings.mode === "on" ? "on" : "report"
47
- };
48
- if (!writer.write(record)) throw writer.lastError ?? /* @__PURE__ */ new Error(`Could not append ${file}`);
49
- if (typeof fields.workspace === "string" && [
50
- "maintenance_action",
51
- "maintenance_failure",
52
- "maintenance_skip"
53
- ].includes(event)) {
54
- const workspace = createNdjsonWriter(join(workspaceLogsDir(fields.workspace), MAINTENANCE_LOG_NAME), { maxBytes: LOG_ROTATE_BYTES });
55
- try {
56
- if (!workspace.write(record)) throw workspace.lastError ?? /* @__PURE__ */ new Error("Could not append workspace maintenance log");
57
- } finally {
58
- workspace.close();
59
- }
60
- }
61
- return record;
62
- },
63
- close: () => writer.close()
64
- };
65
- }
66
- //#endregion
67
20
  //#region src/cache/compilation-cache-corruption.ts
68
21
  const COMPILATION_CACHE_CORRUPT = "STIM_COMPILATION_CACHE_CORRUPT";
69
22
  async function emptyCompilationCache(dir) {
@@ -438,16 +391,12 @@ const PAGE_BYTES = 49152;
438
391
  const CHUNK_BYTES = 61440;
439
392
  const MAX_BUFFERED = 8388608;
440
393
  const DIGEST_BYTES = 32;
441
- function offloadMode(env = ambientContext()?.env ?? process.env) {
442
- const raw = env.STIM_REMOTE_BUILD_MODE || loadConfig$1()?.remote?.buildMode;
443
- return OFFLOAD_MODES.includes(raw) ? raw : "auto";
444
- }
445
394
  function buildPlacementCandidates(selected) {
446
395
  const config = loadConfig$1();
396
+ const word = placementWord(selected);
447
397
  return {
448
- localEnabled: selected !== "auto" || automaticMachineEnabled("build", "local", config),
449
- mode: selected === "local" ? "off" : offloadMode(),
450
- machines: selected === "local" ? [] : namedBuildMachine(selected) ? pairedMachines([selected]).slice(0, 1) : pairedMachines().filter((entry) => automaticMachineEnabled("build", entry.machine, config))
398
+ localEnabled: word === null || word === "local" || mayRunHere(word) && automaticMachineEnabled("build", "local", config),
399
+ machines: word === "local" ? [] : word === null ? pairedMachines([selected]).slice(0, 1) : pairedMachines().filter((entry) => automaticMachineEnabled("build", entry.machine, config))
451
400
  };
452
401
  }
453
402
  function remotePhaseText(name, msg, machine) {
@@ -471,10 +420,12 @@ function placementLoad(choice) {
471
420
  /**
472
421
  * Whether a build may go to a remote machine at all, before any machine is asked. `auto` keeps the build here while
473
422
  * this machine has a free `concurrency.maxBuilds` slot and its load per core is under `server.maxLoadPerCore`.
474
- * A named selection ignores local capacity and mode, and refuses an unsupported build or missing pairing.
423
+ * `remote` always tries the remote machines first and `remote-only` never builds here. A named selection ignores
424
+ * local capacity, and refuses an unsupported build or missing pairing.
475
425
  */
476
- function offloadPlacement({ mode, machines, here, unsupported, localEnabled = true, selected = "auto" }) {
477
- if (namedBuildMachine(selected)) {
426
+ function offloadPlacement({ machines, here, unsupported, localEnabled = true, selected = "auto" }) {
427
+ const word = placementWord(selected);
428
+ if (word === null) {
478
429
  if (unsupported) throw new OffloadRefusal(selected, `${unsupported}, so a named remote machine cannot take it`);
479
430
  if (machines === 0) throw new OffloadRefusal(selected, "no remote machine is paired");
480
431
  return {
@@ -483,25 +434,21 @@ function offloadPlacement({ mode, machines, here, unsupported, localEnabled = tr
483
434
  reason: `selected with --remote-build ${selected}`
484
435
  };
485
436
  }
486
- if (selected === "local") return {
437
+ if (word === "local") return {
487
438
  offload: false,
488
439
  code: "local-selected",
489
440
  reason: "--remote-build local"
490
441
  };
491
- if (!localEnabled) {
492
- const reason = mode === "off" ? "remote.buildMode is off" : unsupported ?? (machines === 0 ? "no enabled remote machine is paired" : null);
493
- if (reason) throw new OffloadRefusal("auto", `${reason}; local is disabled in remote.buildPoolDisabled`);
442
+ if (!localEnabled || !mayRunHere(word)) {
443
+ const why = word === "remote-only" ? "remote-only never builds here" : "local is disabled in remote.buildPoolDisabled";
444
+ const reason = unsupported ?? (machines === 0 ? "no enabled remote machine is paired" : null);
445
+ if (reason) throw new OffloadRefusal(selected, `${reason}; ${why}`);
494
446
  return {
495
447
  offload: true,
496
- code: "local-disabled",
497
- reason: "local is disabled in remote.buildPoolDisabled"
448
+ code: word === "remote-only" ? "remote-only" : "local-disabled",
449
+ reason: why
498
450
  };
499
451
  }
500
- if (mode === "off") return {
501
- offload: false,
502
- code: "mode-off",
503
- reason: "remote.buildMode is off"
504
- };
505
452
  if (machines === 0) return {
506
453
  offload: false,
507
454
  code: "no-remote-mac",
@@ -512,10 +459,10 @@ function offloadPlacement({ mode, machines, here, unsupported, localEnabled = tr
512
459
  code: "unsupported",
513
460
  reason: unsupported
514
461
  };
515
- if (mode === "force") return {
462
+ if (word === "remote") return {
516
463
  offload: true,
517
- code: "forced",
518
- reason: "remote.buildMode is force"
464
+ code: "remote",
465
+ reason: "remote machines come first"
519
466
  };
520
467
  const busy = saturation(here);
521
468
  return busy ? {
@@ -541,8 +488,10 @@ function matchingArtifact(offer, identity) {
541
488
  }
542
489
  const gb = (bytes) => (bytes / 1024 ** 3).toFixed(1);
543
490
  /** Every reason a machine's offer cannot take this build, in either mode; empty when it can. */
544
- function offerProblems(offer, target) {
491
+ function offerProblems(offer, target, named = false) {
545
492
  const problems = toolchainMismatches(target, offer.toolchain);
493
+ const pods = !named && target.platform === "ios" && !problems.some(({ code }) => code === "platform") ? cocoapodsDifference(target, offer.toolchain) : null;
494
+ if (pods) problems.push(pods);
546
495
  const capacity = offer.capacity;
547
496
  const { running, max, diskFreeBytes, minDiskFreeBytes, declined } = capacity;
548
497
  if (diskFreeBytes !== null && diskFreeBytes < minDiskFreeBytes) problems.push({
@@ -564,14 +513,15 @@ function offerProblems(offer, target) {
564
513
  return problems;
565
514
  }
566
515
  /**
567
- * The asked machines that can take the build, best first, and one reason per machine that cannot. A machine with any
568
- * `offerProblems` never takes it. In `auto`, a machine must also be expected to build faster than this machine: while
569
- * every local build slot is busy any machine that accepts will do, otherwise its load per core must be lower than
570
- * this machine's. A named selection considers only that machine and skips this local-capacity gating.
571
- * A machine that reports no load (a stim-server older than capacity) takes an `auto` build only while
572
- * every local slot is busy. Matching dependency installations rank first, then load.
516
+ * The asked machines that can take the build, in the order they should be tried, and one reason per machine that
517
+ * cannot. A machine with any `offerProblems` never takes it, nor does one whose load per core is at or above its own
518
+ * `server.maxLoadPerCore` (this machine's setting stands in for a stim-server that does not report it). Machines that
519
+ * can take it keep the order of `remote.machines`, so the first one with a free slot under its load threshold gets
520
+ * the build; only a machine that already holds the exact completed artifact goes ahead of that order. A named
521
+ * selection considers only that machine. In `auto` a machine that reports no load (a stim-server older than capacity)
522
+ * takes the build only while every local slot is busy.
573
523
  */
574
- function pickOffer({ mode, here, offers, target, localEnabled = true, selected = "auto", artifact, cacheOnly = false }) {
524
+ function pickOffer({ here, offers, target, localEnabled = true, selected = "auto", artifact, cacheOnly = false }) {
575
525
  const slotsFull = here.maxBuilds > 0 && here.builds >= here.maxBuilds;
576
526
  const reasons = [];
577
527
  const candidates = [];
@@ -591,8 +541,7 @@ function pickOffer({ mode, here, offers, target, localEnabled = true, selected =
591
541
  if (matchingArtifact(offer, artifact) && (artifact !== "swiftpm" || toolchainMismatches(target, offer.toolchain).length === 0)) {
592
542
  ranked.push({
593
543
  index,
594
- score: Number.POSITIVE_INFINITY,
595
- load: 0
544
+ cached: true
596
545
  });
597
546
  candidates.push({
598
547
  machine,
@@ -602,26 +551,24 @@ function pickOffer({ mode, here, offers, target, localEnabled = true, selected =
602
551
  return;
603
552
  }
604
553
  if (cacheOnly) return skip(machine, "artifact-miss", "no matching completed artifact");
605
- const problems = offerProblems(offer, target);
554
+ const problems = offerProblems(offer, target, namedBuildMachine(selected));
606
555
  if (problems.length) return skip(machine, problemCode(problems[0]), problems.map((problem) => problem.reason).join("; "), problems.map((problem) => problem.code));
607
- const load = offer.capacity.loadPerCore;
608
- if (selected === "auto" && localEnabled && mode === "auto" && !slotsFull) {
609
- if (typeof load !== "number") return skip(machine, "load", "capacity unknown (older stim-server) while this machine has a free slot");
610
- if (load >= here.loadPerCore) return skip(machine, "load", `no less loaded (load ${load}/core there, ${here.loadPerCore}/core here)`);
611
- }
612
- const score = Number(offer.warm.dependencies);
556
+ const { loadPerCore: load, maxLoadPerCore } = offer.capacity;
557
+ const ceiling = maxLoadPerCore ?? here.maxLoadPerCore;
558
+ if (typeof load === "number" && !namedBuildMachine(selected) && load >= ceiling) return skip(machine, "load", `saturated: load ${load}/core there, at or above ${ceiling}/core`);
559
+ if (selected === "auto" && localEnabled && !slotsFull && typeof load !== "number") return skip(machine, "load", "capacity unknown (older stim-server) while this machine has a free slot");
613
560
  ranked.push({
614
561
  index,
615
- score,
616
- load: typeof load === "number" ? load : Number.POSITIVE_INFINITY
562
+ cached: false
617
563
  });
564
+ const notes = toolchainNotes(target, offer.toolchain).map((each) => each.reason);
618
565
  candidates.push({
619
566
  machine,
620
567
  code: "accepted",
621
- msg: typeof load === "number" ? `can take the build (load ${load}/core there)` : "can take the build"
568
+ msg: [typeof load === "number" ? `can take the build (load ${load}/core there)` : "can take the build", ...notes].join("; ")
622
569
  });
623
570
  });
624
- ranked.sort((a, b) => b.score - a.score || a.load - b.load);
571
+ ranked.sort((a, b) => Number(b.cached) - Number(a.cached));
625
572
  return {
626
573
  order: ranked.map((each) => each.index),
627
574
  reasons,
@@ -1004,7 +951,7 @@ async function probeMachine(credential, identity, { connectMs = CONNECT_TIMEOUT_
1004
951
  * Asks every paired machine for an offer in parallel and keeps the connection to the one `pickOffer` chooses, or
1005
952
  * returns why none takes the build. A named selection probes only its credential and skips auto load gating.
1006
953
  */
1007
- async function chooseBuildMachine({ projectRoot, target, mode, here, note, machines = pairedMachines(), selected = "auto", onCandidates, artifact, gradleArtifact, reactNativeArtifact, swiftpmArtifact, cacheOnly = false }) {
954
+ async function chooseBuildMachine({ projectRoot, target, here, note, machines = pairedMachines(), selected = "auto", onCandidates, artifact, gradleArtifact, reactNativeArtifact, swiftpmArtifact, cacheOnly = false }) {
1008
955
  const started = Date.now();
1009
956
  let identity;
1010
957
  try {
@@ -1043,9 +990,8 @@ async function chooseBuildMachine({ projectRoot, target, mode, here, note, machi
1043
990
  ...swiftpmQuery ? { swiftpmArtifact: swiftpmQuery } : {}
1044
991
  })));
1045
992
  const { order, reasons, candidates } = pickOffer({
1046
- localEnabled: selected !== "auto" || automaticMachineEnabled("build", "local"),
993
+ localEnabled: buildPlacementCandidates(selected).localEnabled,
1047
994
  selected,
1048
- mode,
1049
995
  here,
1050
996
  target,
1051
997
  artifact: swiftpmQuery ? "swiftpm" : reactNativeQuery ? `react-native-${reactNativeQuery.platform}` : gradleQuery ? "native-gradle" : artifact,
@@ -1073,19 +1019,22 @@ async function chooseBuildMachine({ projectRoot, target, mode, here, note, machi
1073
1019
  });
1074
1020
  return {
1075
1021
  ...first,
1076
- mode,
1022
+ selected,
1077
1023
  here,
1078
1024
  target,
1079
1025
  offerMs: Date.now() - started,
1080
1026
  identity,
1081
1027
  runnersUp: rest,
1082
- automatic: selected === "auto",
1083
1028
  cacheOnly,
1084
1029
  ...gradleQuery ? { gradleArtifact: gradleQuery } : {},
1085
1030
  ...reactNativeQuery ? { reactNativeArtifact: reactNativeQuery } : {},
1086
1031
  ...swiftpmQuery ? { swiftpmArtifact: swiftpmQuery } : {}
1087
1032
  };
1088
1033
  }
1034
+ function startJdk(choice) {
1035
+ const { target, connection } = choice;
1036
+ return target.platform === "android" && target.local.jdk && connection.supports("build-jdk") ? { jdk: target.local.jdk } : {};
1037
+ }
1089
1038
  function startCompat(choice) {
1090
1039
  return choice.connection.supports("build-compat") ? { compat: choice.target.local.compat } : {};
1091
1040
  }
@@ -1421,11 +1370,10 @@ async function offloadBuild(input) {
1421
1370
  });
1422
1371
  if ("failure" in probe) return fail(probe.failure);
1423
1372
  const placement = pickOffer({
1424
- mode: choice.mode,
1425
1373
  here: choice.here,
1426
1374
  target: choice.target,
1427
- selected: choice.automatic ? "auto" : choice.machine,
1428
- localEnabled: !choice.automatic || automaticMachineEnabled("build", "local"),
1375
+ selected: choice.selected,
1376
+ localEnabled: buildPlacementCandidates(choice.selected).localEnabled,
1429
1377
  offers: [{
1430
1378
  machine: choice.machine,
1431
1379
  offer: probe.offer
@@ -1501,7 +1449,7 @@ async function offloadBuild(input) {
1501
1449
  return true;
1502
1450
  };
1503
1451
  for (;;) {
1504
- if (choice.automatic && !automaticMachineEnabled("build", choice.machine)) {
1452
+ if (!namedBuildMachine(choice.selected) && !automaticMachineEnabled("build", choice.machine)) {
1505
1453
  const reason = `${choice.machine} is disabled in remote.buildPoolDisabled`;
1506
1454
  if (moveOn(reason)) continue;
1507
1455
  return fail(reason);
@@ -1536,7 +1484,7 @@ async function offloadBuild(input) {
1536
1484
  workerStarted = Date.now();
1537
1485
  early = [];
1538
1486
  choice.connection.onProgress((event) => job === null ? early.push(event) : handle(event));
1539
- if (choice.automatic) requireAutomaticMachine("build", choice.machine);
1487
+ if (!namedBuildMachine(choice.selected)) requireAutomaticMachine("build", choice.machine);
1540
1488
  checkCancelled();
1541
1489
  const reply = await choice.connection.request("build.start", {
1542
1490
  repo: identity.repo,
@@ -1570,7 +1518,8 @@ async function offloadBuild(input) {
1570
1518
  ...request.platform === "android" ? { android: request.android } : {}
1571
1519
  },
1572
1520
  stimBuild: choice.target.local.stimBuild,
1573
- ...startCompat(choice)
1521
+ ...startCompat(choice),
1522
+ ...startJdk(choice)
1574
1523
  });
1575
1524
  checkCancelled();
1576
1525
  if ("result" in reply) {
@@ -1594,7 +1543,7 @@ async function offloadBuild(input) {
1594
1543
  const { connection, machine } = choice;
1595
1544
  connection.onProgress(null);
1596
1545
  const workerMs = cacheHit ? 0 : Date.now() - workerStarted;
1597
- if (result.ok !== true) return keepCorruptCacheMessage(fail(`${String(result.code ?? "failed")}: ${String(result.message ?? "")}`), result);
1546
+ if (result.ok !== true) return keepCorruptCacheMessage(fail(workerFailureReason(result.code, result.message)), result);
1598
1547
  if (!cacheHit && native && (result.sourceDigest !== sourceDigest || result.fingerprint !== expectedFingerprint)) return fail("The worker returned a different native source or artifact identity.");
1599
1548
  if (native?.provider === "gradle" && !ANDROID_PACKAGE.test(String(result.androidPackage ?? ""))) return fail("The worker returned no verified native APK package.");
1600
1549
  const artifact = result.artifact;
@@ -1745,6 +1694,16 @@ function machineProblems(offer, targets) {
1745
1694
  }
1746
1695
  return problems;
1747
1696
  }
1697
+ /** What a build on a machine that would take it does beyond the match, for each of `targets`, labeled like `machineProblems`. */
1698
+ function machineNotes(offer, targets) {
1699
+ const notes = [];
1700
+ if (machineProblems(offer, targets).length) return notes;
1701
+ for (const target of targets) for (const note of toolchainNotes(target, offer.toolchain)) notes.push(targets.length > 1 ? {
1702
+ ...note,
1703
+ reason: `${PLATFORM_LABEL[target.platform]}: ${note.reason}`
1704
+ } : note);
1705
+ return notes;
1706
+ }
1748
1707
  const DOCTOR_CONNECT_MS = 5e3;
1749
1708
  const DOCTOR_OFFER_MS = 8e3;
1750
1709
  const PLATFORM_LABEL = {
@@ -1802,11 +1761,13 @@ function offloadCheck(projectRoot, targets) {
1802
1761
  };
1803
1762
  probe.connection.close();
1804
1763
  resolved ??= targets();
1764
+ const judged = await resolved;
1805
1765
  return {
1806
1766
  capacity: probe.offer.capacity,
1807
- problems: machineProblems(probe.offer, await resolved)
1767
+ problems: machineProblems(probe.offer, judged),
1768
+ notes: machineNotes(probe.offer, judged)
1808
1769
  };
1809
1770
  };
1810
1771
  }
1811
1772
  //#endregion
1812
- export { COMPILATION_CACHE_CORRUPT as C, setRemoteLogSink as S, maintenanceLogger as T, nativeGradleLocalSourceDigest as _, nativeTransferRefusal as a, validateGradleManifest as b, offloadPlacement as c, simulatorRuntime as d, reactNativeArtifactReceipt as f, gradleStateDirectories as g, gradleOffloadInputs as h, closeOffload as i, placementLoad as l, reactNativeBuildQuery as m, buildPlacementCandidates as n, offloadBuild as o, reactNativeArtifactToolchain as p, chooseBuildMachine as r, offloadCheck as s, BuildConnection as t, remotePhaseText as u, nativeGradleOutputs as v, clearCorruptCompilationCache as w, verifyGradleTransfer as x, nativeGradleTransfer as y };
1773
+ export { COMPILATION_CACHE_CORRUPT as C, setRemoteLogSink as S, nativeGradleLocalSourceDigest as _, nativeTransferRefusal as a, validateGradleManifest as b, offloadPlacement as c, simulatorRuntime as d, reactNativeArtifactReceipt as f, gradleStateDirectories as g, gradleOffloadInputs as h, closeOffload as i, placementLoad as l, reactNativeBuildQuery as m, buildPlacementCandidates as n, offloadBuild as o, reactNativeArtifactToolchain as p, chooseBuildMachine as r, offloadCheck as s, BuildConnection as t, remotePhaseText as u, nativeGradleOutputs as v, clearCorruptCompilationCache as w, verifyGradleTransfer as x, nativeGradleTransfer as y };
@@ -1,10 +1,6 @@
1
1
  import { n as NdjsonWriter, t as Executor } from "./exec-DnYc4HGH.mjs";
2
2
  import { ChildProcess } from "node:child_process";
3
3
  //#region src/collector/android.d.ts
4
- declare function androidClockOffset(serial: string, { exec, now }?: {
5
- exec?: Executor;
6
- now?: () => number;
7
- }): number | null;
8
4
  interface PidResolution {
9
5
  ok?: boolean;
10
6
  pid?: number;
@@ -13,19 +9,21 @@ interface PidResolution {
13
9
  }
14
10
  interface PidWatcher {
15
11
  stop(): void;
16
- probe(): number | null;
12
+ probe(): Promise<number | null>;
17
13
  readonly pid: number | null;
18
14
  }
19
- declare function watchAppPid({ serial, packageName, pid, intervalMs, exec, onChange, resolve, setTimer, clearTimer }: {
15
+ declare function watchAppPid({ serial, packageName, pid, intervalMs, exec, signal, onChange, resolve, setTimer, clearTimer }: {
20
16
  serial: string;
21
17
  packageName: string;
22
18
  pid: number | null;
23
19
  intervalMs?: number | null;
24
20
  exec?: Executor | null;
21
+ signal?: AbortSignal;
25
22
  onChange: (nextPid: number) => void | Promise<void>;
26
23
  resolve?: (serial: string, packageName: string, opts: {
27
24
  exec?: Executor | null;
28
- }) => number | null;
25
+ signal?: AbortSignal;
26
+ }) => number | null | Promise<number | null>;
29
27
  setTimer?: (fn: () => void, ms: number) => ReturnType<typeof setTimeout>;
30
28
  clearTimer?: (t: ReturnType<typeof setTimeout>) => void;
31
29
  }): PidWatcher;
@@ -83,10 +81,13 @@ interface RunCollectorOptions {
83
81
  pidTimeoutMs?: number;
84
82
  pidOf?: ((serial: string, packageName: string, opts: {
85
83
  exec?: Executor | null;
86
- }) => number | null) | null;
84
+ }) => number | null | Promise<number | null>) | null;
87
85
  pidWatchMs?: number | null;
88
86
  watchPid?: typeof watchAppPid;
89
- resolveClockOffset?: typeof androidClockOffset;
87
+ resolveClockOffset?: (serial: string, opts: {
88
+ now?: () => number;
89
+ signal?: AbortSignal;
90
+ }) => number | null | Promise<number | null>;
90
91
  now?: () => number;
91
92
  onExit?: (code: number) => void;
92
93
  attachSignals?: boolean;