stim 1.24.0 → 1.25.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.
- package/dist/{acquire-artifact-CEs02U2o.mjs → acquire-artifact-zA4S7RHE.mjs} +1 -1
- package/dist/{act-Cyvm8xYc.mjs → act-BbHS3oV8.mjs} +12 -12
- package/dist/{activity-Dq3ZcdD8.mjs → activity-BpjwrQXU.mjs} +3 -3
- package/dist/{agent-device-usage-output-CccomeE0.mjs → agent-device-usage-output-Bnkerfod.mjs} +3 -3
- package/dist/{android-BZppyPe_.mjs → android-BGwuK3Mc.mjs} +41 -36
- package/dist/{android-DcztblCT.mjs → android-CNZgRC-4.mjs} +5 -5
- package/dist/{android-882m4hxX.mjs → android-Cjcj8MCw.mjs} +2 -2
- package/dist/{android-cas-BtCOrNqb.mjs → android-cas-BVqh2Zep.mjs} +1 -1
- package/dist/{android-project-DVWyCbWU.d.mts → android-project-CTYaETc0.d.mts} +6 -2
- package/dist/{android-CX5IcRuf.mjs → android-saBeB4lr.mjs} +1 -1
- package/dist/api.d.mts +1 -1
- package/dist/api.mjs +22 -22
- package/dist/{artifact-BR5VNArK.mjs → artifact-Co8zixVx.mjs} +14 -13
- package/dist/{artifact-Bdt_n9Jc.mjs → artifact-DN8JNwqS.mjs} +13 -13
- package/dist/{browser-web-ycg9qWB8.mjs → browser-web-CCgZsHmI.mjs} +10 -10
- package/dist/{budget-dPGuhNai.mjs → budget-HyShrIpL.mjs} +62 -21
- package/dist/{build-CaF574eS.mjs → build-CAiw8Ezm.mjs} +22 -21
- package/dist/{build-cache-HFUQ9eLz.mjs → build-cache-CKCzxzxA.mjs} +22 -4
- package/dist/{build-plan-JsDUq4w1.mjs → build-plan-zCuHGlA8.mjs} +5 -5
- package/dist/{ccache-CCn1S6qG.mjs → ccache-h1FKhZeg.mjs} +3 -3
- package/dist/{cli-xqAidP7O.mjs → cli-C4w607Pz.mjs} +17 -17
- package/dist/cli.mjs +1 -1
- package/dist/{client-18-ZowoT.mjs → client-BQsmyp_-.mjs} +26 -17
- package/dist/collector-run.mjs +2 -2
- package/dist/{command-output-DxC0k2rk.mjs → command-output-BBvS1H6v.mjs} +1 -1
- package/dist/{dependency-state-C56ll9hY.mjs → dependency-state-BwNCYG5Q.mjs} +1 -1
- package/dist/{dev-client-w_fok0Ek.mjs → dev-client-CHoXXZeg.mjs} +2 -2
- package/dist/{device-BktRGdjS.mjs → device-B9FqTBYW.mjs} +64 -33
- package/dist/{device-4RUugw5X.mjs → device-F5-4z9ef.mjs} +13 -13
- package/dist/{device-capacity-Ic-kdmEV.mjs → device-capacity-ZYaRALv5.mjs} +7 -7
- package/dist/device-host-worker.mjs +10 -10
- package/dist/{device-ios-DzpSlZyd.mjs → device-ios-DkHBrmvH.mjs} +27 -16
- package/dist/{device-lease-run-DUtkbqBQ.mjs → device-lease-run-ogEeJ62K.mjs} +4 -4
- package/dist/{device-pool-CgBHk401.mjs → device-pool-BIg8MU8l.mjs} +2 -2
- package/dist/{doctor-BZ6oxNum.mjs → doctor-A_Nr_fDe.mjs} +1 -1
- package/dist/{doctor-C33AzVfR.mjs → doctor-Bm8TVpGn.mjs} +27 -21
- package/dist/doctor-fingerprint.mjs +1 -1
- package/dist/{doctor-DZgpqR6J.mjs → doctor-k3P3PizH.mjs} +12 -12
- package/dist/{doctor-watchman-B453A231.mjs → doctor-watchman-BovI1y3-.mjs} +3 -3
- package/dist/{eas-build-CxKUNHsb.mjs → eas-build-CyDKNTBP.mjs} +2 -2
- package/dist/{eas-fallback-LMxk9Kw0.mjs → eas-fallback-gaZi-dJL.mjs} +12 -11
- package/dist/{eas-session-ledger-Ck6YXPAO.mjs → eas-session-ledger-BMCA1gdO.mjs} +3 -3
- package/dist/{error-diagnostics-BkKCZq4P.mjs → error-diagnostics-B1Mj_-7h.mjs} +7 -7
- package/dist/{errors-ccaPc4ox.mjs → errors-DHm_U5gv.mjs} +2 -1
- package/dist/{gc-yVKpAOKM.mjs → gc-B9jcnmIk.mjs} +15 -15
- package/dist/{gc-DDWEAj0w.mjs → gc-eaz403W6.mjs} +2 -2
- package/dist/{guide-Bggftwc5.mjs → guide-DR0K0xW9.mjs} +113 -37
- package/dist/{hosted-android-D4dweBof.mjs → hosted-android-Bvb2-ZxD.mjs} +3 -3
- package/dist/{hosted-client-BBTVe3X6.mjs → hosted-client-rsRqysJc.mjs} +2 -2
- package/dist/{hosted-ios-Sn0djzg8.mjs → hosted-ios-RtVcJH3u.mjs} +1 -1
- package/dist/{hosted-logs-CYIZ5ubJ.mjs → hosted-logs-CWKGYWNX.mjs} +4 -4
- package/dist/{hosted-macos-CXjsUNBR.mjs → hosted-macos-d0pv9Tth.mjs} +5 -5
- package/dist/{hosted-native-Doxbfzem.mjs → hosted-native-BxTizGU2.mjs} +6 -6
- package/dist/{idle-shutdown-BInjLKqm.mjs → idle-shutdown-BIyfl0Zj.mjs} +6 -6
- package/dist/{ios-CVUFFZ6C.mjs → ios-BQzvJlzw.mjs} +59 -11
- package/dist/{ios-B1FXRCMX.mjs → ios-BRVM8b0P.mjs} +37 -32
- package/dist/{ios-BItP6lkn.mjs → ios-Dvt97HgQ.mjs} +8 -8
- package/dist/{ios-device-BI38NFFH.mjs → ios-device-CKSvk0bu.mjs} +1 -1
- package/dist/{ios-project-KYqeJURj.mjs → ios-project-DCUDo06I.mjs} +4 -4
- package/dist/{ios-state-DlElquYD.mjs → ios-state-CT9nV5SP.mjs} +1 -1
- package/dist/{js-swap-BvrQvXHY.mjs → js-swap-Z9HbC4cj.mjs} +4 -4
- package/dist/{launch-SfzGH_s9.mjs → launch-D0lPvFFu.mjs} +16 -16
- package/dist/{launch-BVlyQw3T.mjs → launch-DscF1QfM.mjs} +35 -35
- package/dist/{logs-DXE32kyb.mjs → logs-BsIRre8x.mjs} +7 -7
- package/dist/{logs-ovlU7m7N.mjs → logs-Crs9y34Z.mjs} +5 -5
- package/dist/{macos-B3BveDrU.mjs → macos-CcUlJPMu.mjs} +1 -1
- package/dist/{macos-CCfhb-jT.mjs → macos-D477nfzH.mjs} +17 -17
- package/dist/macos-run.mjs +1 -1
- package/dist/maintenance-run.mjs +5 -5
- package/dist/{metro-Bu8LBfzS.mjs → metro-1pJgCX4U.mjs} +1 -1
- package/dist/{metro-gateway-DtsOy-0P.mjs → metro-gateway-Bp9gJQAN.mjs} +1 -1
- package/dist/{named-ports-BWDuU5oQ.mjs → named-ports-BVbn8SvC.mjs} +1 -1
- package/dist/{native-android-96BBizbq.mjs → native-android-BvMizJn1.mjs} +14 -14
- package/dist/{native-gradle-artifact-inputs-BcLYBZil.mjs → native-gradle-artifact-inputs-BJscK4vN.mjs} +3 -3
- package/dist/{native-run-BmH7U8pr.mjs → native-run-D5OJsGwA.mjs} +2 -2
- package/dist/{native-runtime-DgtJkzIa.mjs → native-runtime-B9w_Qyz3.mjs} +6 -6
- package/dist/{native-xcode-inputs-irplbQb0.mjs → native-xcode-inputs-Cv4l-obn.mjs} +1 -1
- package/dist/{native-xcode-ios-BY-6hh6M.mjs → native-xcode-ios-DGrg90hE.mjs} +17 -16
- package/dist/offload-worker.d.mts +5 -2
- package/dist/offload-worker.mjs +21 -20
- package/dist/{ownership-DxlZGDcV.mjs → ownership-jxxz-19m.mjs} +2 -2
- package/dist/{phone-reverses-BdsdesVF.mjs → phone-reverses-CYb7RRAx.mjs} +2 -2
- package/dist/{placement-log-DUvqqsB-.mjs → placement-log-DjOXJRIH.mjs} +1 -1
- package/dist/{plan-placement-4axc0Hs7.mjs → plan-placement-BqKgKHCi.mjs} +3 -3
- package/dist/{ports-D-E_OiAO.mjs → ports-DtS1Amb0.mjs} +2 -2
- package/dist/{prebuild-DmVCf5xb.mjs → prebuild-JUaqOLpc.mjs} +6 -6
- package/dist/{project-Dz-hWkb-.mjs → project-BiC68mIp.mjs} +14 -14
- package/dist/{react-native-android-DOinxgwB.mjs → react-native-android-DRYqoJc4.mjs} +23 -22
- package/dist/{react-native-build-AuCu-aAP.mjs → react-native-build-CwZB-agu.mjs} +6 -6
- package/dist/{react-native-doctor-2ivJUmwZ.mjs → react-native-doctor-BCrytK7h.mjs} +6 -6
- package/dist/{react-native-ios-D5zTIuH8.mjs → react-native-ios-Cr1buNFo.mjs} +18 -17
- package/dist/{recordings-CdPwYwvs.mjs → recordings-BaoQ0t-J.mjs} +1 -1
- package/dist/{reload-Ck9RJeSq.mjs → reload-Beftw2X3.mjs} +1 -1
- package/dist/{reload-C1TTVesC.mjs → reload-FbSgMF8x.mjs} +13 -13
- package/dist/{remote-DEZ7AOVq.mjs → remote-BuZj6AyU.mjs} +15 -6
- package/dist/{result-DqBrb12U.mjs → result-CR2vk2cj.mjs} +14 -14
- package/dist/{run-BIwoU44q.mjs → run-BtzE09Dl.mjs} +1 -1
- package/dist/{selection-BLtvaqxc.mjs → selection-D5cxEl3t.mjs} +2 -2
- package/dist/{server-bare-Z1ToVLPn.mjs → server-bare-CH9X0RLn.mjs} +55 -3
- package/dist/{server-command-C0pmjNdG.mjs → server-command-CaBbDNU2.mjs} +4 -4
- package/dist/server-expo-C16Zf2k7.mjs +2 -0
- package/dist/{server-expo-Tt_hLRpy.mjs → server-expo-Ck8EIidM.mjs} +8 -6
- package/dist/{settings-RKwY33wv.mjs → settings-B5tCoq9N.mjs} +58 -60
- package/dist/{settings-kkt0vP4w.mjs → settings-DzH9mGQZ.mjs} +1 -1
- package/dist/{settings-write--gj6MACV.mjs → settings-write-n0zwfohx.mjs} +3 -3
- package/dist/settings.schema.json +38 -0
- package/dist/{simslim-CdWKT3vA.mjs → simslim-BjxszUAb.mjs} +20 -5
- package/dist/{slot-launch-A1BgotaM.mjs → slot-launch-QeuJMlnJ.mjs} +5 -5
- package/dist/{stage-ERTMh88n.mjs → stage-D8xlRU2D.mjs} +1 -1
- package/dist/{start-Bmg_qmHi.mjs → start-C1JLjkNw.mjs} +1 -1
- package/dist/{start-BKGrEhzG.mjs → start-YMpNwLhh.mjs} +7 -7
- package/dist/{state-B1ig0Kqy.mjs → state-DMRNP7-4.mjs} +2 -2
- package/dist/{state-BfAltYJP.mjs → state-DPaM3u5K.mjs} +1 -1
- package/dist/{stats-B-ckuiUg.mjs → stats-CP7STzZw.mjs} +3 -3
- package/dist/{status-DfFp6a76.mjs → status-CRLiJ-O_.mjs} +19 -19
- package/dist/{status-Pw-807f0.mjs → status-cNw6i0_t.mjs} +1 -1
- package/dist/{status-watch-XC7F-AMf.mjs → status-watch-Bc2J4TZn.mjs} +4 -4
- package/dist/status-worker.mjs +1 -1
- package/dist/{stop-BFu7X_Do.mjs → stop-Br7LKxBE.mjs} +2 -2
- package/dist/{stop-DhclRwOO.mjs → stop-COP6PQqw.mjs} +4 -4
- package/dist/{stop-CL1kDHds.mjs → stop-Db9Kh-UA.mjs} +69 -50
- package/dist/supervisor-run.mjs +13 -13
- package/dist/{support-B3tzVhKn.mjs → support-Cxj9CmII.mjs} +4 -4
- package/dist/{support-B1W-hmC2.mjs → support-qKcbgmI5.mjs} +14 -11
- package/dist/{swiftpm-artifact-inputs-BWYPj9Sn.mjs → swiftpm-artifact-inputs-iY9fsmOc.mjs} +1 -1
- package/dist/{swiftpm-macos-BVCP5mO4.mjs → swiftpm-macos-Bp_sn9P4.mjs} +8 -8
- package/dist/{toolchain-BjgKdoEf.mjs → toolchain-DB1aeqxO.mjs} +1 -1
- package/dist/{toolchain-D3bmRMia.mjs → toolchain-VzLJzZ7O.mjs} +14 -3
- package/dist/{warm-progress-ol0ZypEu.mjs → warm-progress-BV3ZPmcY.mjs} +3 -3
- package/dist/{web-BH7peScT.mjs → web-B4Yjyt1G.mjs} +6 -6
- package/dist/web-DS4UDWvf.mjs +2 -0
- package/dist/web-run.mjs +3 -3
- package/dist/{workspace-state-CeBpIZgr.mjs → workspace-state-CPSp3mav.mjs} +1 -1
- package/dist/{workspaces-CSV2Orf4.mjs → workspaces-C9w4aeXF.mjs} +10 -10
- package/dist/{worktree-Dw8kfacb.mjs → worktree-CclFIe1Z.mjs} +25 -25
- package/dist/{worktree-DEDUzO_L.mjs → worktree-Ct9Gk3KL.mjs} +1 -1
- package/dist/{xcode-DHu41qQ4.mjs → xcode-CiIIDnuD.mjs} +4 -4
- package/package.json +7 -7
- package/shim/bundle-response.cjs +53 -1
- package/shim/bundle-response.d.cts +1 -1
- package/shim/expo-metro-config.cjs +23 -1
- package/dist/server-expo-CEntXzRw.mjs +0 -2
- package/dist/web-BdOFlTJr.mjs +0 -2
|
@@ -1,20 +1,24 @@
|
|
|
1
1
|
import { D as ownership_claim_exports, t as getExecutor } from "./exec-VFRpu1iA.mjs";
|
|
2
|
-
import { D as withConfigLock, G as projectDeviceSlots, H as deviceSlotPlatforms, O as withConfigLockAsync, _ as loadConfig, a as clearDevice, b as releaseAndroidConsolePort, i as clearAndroidBootPending, j as acquireAvdClaim, t as allConsolePortsAndSerials, w as setDevice } from "./config-BZhXY15H.mjs";
|
|
3
|
-
import { l as phaseLine } from "./command-output-
|
|
4
|
-
import { l as androidDataPartitionSizeGbSetting, o as androidAvdConfigSetting } from "./settings-
|
|
5
|
-
import { s as ownedDeviceLabel } from "./project-
|
|
6
|
-
import { A as listAdbDevices, B as ownedAvdDeviceProfile, F as listAvdsAsync, H as ownedAvdMatchesConfiguration, I as listInstalledSystemImages, K as ownedAvdSystemImage, O as getAvdNameForSerialAsync, U as ownedAvdName, X as pickDefaultSystemImage, _ as avdPoolConfiguration, b as configureNewOwnedAvd, ct as waitForBoot, f as assertOwnedAvdStopped, gt as isLegacyDeletionClaim, j as listAdbDevicesAsync, n as OWNED_AVD_CONFIG_DEFAULTS, nt as resolveOwnedAvdSerialAsync, pt as adoptParked, t as DEFAULT_AVD_DEVICE_PROFILE, vt as parkedMaxSetting, x as createOwnedAvd, y as bootAndroidEmulator, yt as readParked, z as nextConsolePort } from "./android-
|
|
7
|
-
import { c as pidExists } from "./metro-
|
|
8
|
-
import { O as teardownOwnedAvd, j as teardownParkedAvd } from "./workspaces-
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import { i as
|
|
13
|
-
import {
|
|
2
|
+
import { D as withConfigLock$1, G as projectDeviceSlots, H as deviceSlotPlatforms, O as withConfigLockAsync$1, _ as loadConfig$1, a as clearDevice, b as releaseAndroidConsolePort, i as clearAndroidBootPending, j as acquireAvdClaim, t as allConsolePortsAndSerials, w as setDevice } from "./config-BZhXY15H.mjs";
|
|
3
|
+
import { l as phaseLine } from "./command-output-BBvS1H6v.mjs";
|
|
4
|
+
import { l as androidDataPartitionSizeGbSetting, o as androidAvdConfigSetting } from "./settings-B5tCoq9N.mjs";
|
|
5
|
+
import { s as ownedDeviceLabel } from "./project-BiC68mIp.mjs";
|
|
6
|
+
import { A as listAdbDevices, B as ownedAvdDeviceProfile, F as listAvdsAsync, H as ownedAvdMatchesConfiguration, I as listInstalledSystemImages, K as ownedAvdSystemImage, O as getAvdNameForSerialAsync, U as ownedAvdName, X as pickDefaultSystemImage, _ as avdPoolConfiguration, b as configureNewOwnedAvd, ct as waitForBoot, f as assertOwnedAvdStopped, gt as isLegacyDeletionClaim, j as listAdbDevicesAsync, n as OWNED_AVD_CONFIG_DEFAULTS, nt as resolveOwnedAvdSerialAsync, pt as adoptParked, t as DEFAULT_AVD_DEVICE_PROFILE, vt as parkedMaxSetting, x as createOwnedAvd, y as bootAndroidEmulator, yt as readParked, z as nextConsolePort } from "./android-Cjcj8MCw.mjs";
|
|
7
|
+
import { c as pidExists } from "./metro-1pJgCX4U.mjs";
|
|
8
|
+
import { O as teardownOwnedAvd, j as teardownParkedAvd } from "./workspaces-C9w4aeXF.mjs";
|
|
9
|
+
import { h as tailLines } from "./activity-BpjwrQXU.mjs";
|
|
10
|
+
import { F as memoryCulpritsUnderAsync, I as readHostMemoryPressure, R as reportMemoryCulprits, d as listAllIosSims, z as memoryCulpritAdvice } from "./ios-BQzvJlzw.mjs";
|
|
11
|
+
import { t as clearDeviceIdleShutdown } from "./idle-shutdown-BIyfl0Zj.mjs";
|
|
12
|
+
import { i as countLiveOwnedDevices, m as withDeviceBootAdmission, n as DeviceAdmissionRefusal } from "./device-capacity-ZYaRALv5.mjs";
|
|
13
|
+
import { i as ensureOwnedIosDevice, r as ensureIosBooted } from "./device-ios-DkHBrmvH.mjs";
|
|
14
|
+
import { t as reconcileSimSlim } from "./simslim-BjxszUAb.mjs";
|
|
14
15
|
import { claimRemoveCommand, clearClaimChild, markClaimChildPending, processGroupAlive, releaseClaim, setClaimChild } from "@stim-cli/core/ownership-claim";
|
|
15
16
|
import { randomUUID } from "node:crypto";
|
|
16
17
|
import { existsSync } from "node:fs";
|
|
17
18
|
import { isDeepStrictEqual } from "node:util";
|
|
19
|
+
import { dirname, join, resolve, sep } from "node:path";
|
|
20
|
+
import { rotatedLogPath } from "@stim-cli/core";
|
|
21
|
+
import { acceptsShape, settingDefinition } from "@stim-cli/core/state";
|
|
18
22
|
import { fileURLToPath } from "node:url";
|
|
19
23
|
import { captureProcessIdentity } from "@stim-cli/core/process-identity";
|
|
20
24
|
import chalk from "chalk";
|
|
@@ -26,7 +30,7 @@ async function requestLocal(url, platform, prefetch) {
|
|
|
26
30
|
const req = request(url, { headers: {
|
|
27
31
|
accept: "application/json",
|
|
28
32
|
"expo-platform": platform,
|
|
29
|
-
|
|
33
|
+
"x-stim-metro-warmup": "1"
|
|
30
34
|
} });
|
|
31
35
|
const timer = setTimeout(() => req.destroy(), WARMUP_TIMEOUT_MS);
|
|
32
36
|
timer.unref();
|
|
@@ -48,7 +52,33 @@ async function requestLocal(url, platform, prefetch) {
|
|
|
48
52
|
req.end();
|
|
49
53
|
});
|
|
50
54
|
}
|
|
51
|
-
|
|
55
|
+
const ENTRY_EXTENSIONS = [
|
|
56
|
+
"",
|
|
57
|
+
".js",
|
|
58
|
+
".jsx",
|
|
59
|
+
".ts",
|
|
60
|
+
".tsx"
|
|
61
|
+
];
|
|
62
|
+
function entryExists(bundlePath, root) {
|
|
63
|
+
const entry = decodeURIComponent(bundlePath.replace(/\.bundle\/*$/, ""));
|
|
64
|
+
if (entry.startsWith("/.expo/")) return true;
|
|
65
|
+
for (let dir = resolve(root);; dir = dirname(dir)) {
|
|
66
|
+
const file = resolve(dir, `.${entry}`);
|
|
67
|
+
if (file.startsWith(dir + sep) && ENTRY_EXTENSIONS.some((ext) => existsSync(file + ext))) return true;
|
|
68
|
+
if (dirname(dir) === dir) return false;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
function recordedBundleUrl(logsDir, root, platform) {
|
|
72
|
+
const setting = settingDefinition(`metro.warmupUrl.${platform}`);
|
|
73
|
+
if (!logsDir || !root || !setting) return null;
|
|
74
|
+
const log = join(logsDir, "metro.ndjson");
|
|
75
|
+
for (const file of [log, rotatedLogPath(log)]) for (const line of (tailLines(file) ?? []).toReversed()) try {
|
|
76
|
+
const record = JSON.parse(line);
|
|
77
|
+
if (record?.event === "bundle_response_started" && record.platform === platform && acceptsShape(setting, record.url) && entryExists(new URL(record.url, "http://localhost").pathname, root)) return record.url;
|
|
78
|
+
} catch {}
|
|
79
|
+
return null;
|
|
80
|
+
}
|
|
81
|
+
async function warmMetro({ port, platform, isExpo, appId, bundleUrl, logsDir, root }) {
|
|
52
82
|
try {
|
|
53
83
|
const origin = `http://127.0.0.1:${port}`;
|
|
54
84
|
if (await requestLocal(new URL("/_stim/metro-warmup", origin), platform, false) !== "ready") return;
|
|
@@ -65,6 +95,7 @@ async function warmMetro({ port, platform, isExpo, appId, bundleUrl }) {
|
|
|
65
95
|
sourcePaths: "url-server",
|
|
66
96
|
...appId ? { app: appId } : {}
|
|
67
97
|
}).toString();
|
|
98
|
+
bundleUrl ||= recordedBundleUrl(logsDir, root, platform);
|
|
68
99
|
if (!bundleUrl && isExpo) {
|
|
69
100
|
const body = await requestLocal(new URL(origin), platform, false);
|
|
70
101
|
if (body === null) return;
|
|
@@ -91,12 +122,12 @@ var AvdBootError = class extends Error {
|
|
|
91
122
|
};
|
|
92
123
|
var AvdRecoveryError = class extends AvdBootError {};
|
|
93
124
|
function findOtherOwner(avdName, projectPath, selectedSlot = "default") {
|
|
94
|
-
for (const [path, project] of Object.entries(loadConfig()?.projects ?? {})) if (projectDeviceSlots(project).some(({ slot, platforms }) => (path !== projectPath || slot !== selectedSlot) && platforms.android?.avdName?.toLowerCase() === avdName.toLowerCase())) return path;
|
|
125
|
+
for (const [path, project] of Object.entries(loadConfig$1()?.projects ?? {})) if (projectDeviceSlots(project).some(({ slot, platforms }) => (path !== projectPath || slot !== selectedSlot) && platforms.android?.avdName?.toLowerCase() === avdName.toLowerCase())) return path;
|
|
95
126
|
return null;
|
|
96
127
|
}
|
|
97
128
|
async function prepareOwnedAvd({ projectPath, slot, label, previousAvdName, systemImage, deviceProfile, configuration, configure, teardown = teardownOwnedAvd }) {
|
|
98
|
-
const { claim, reservation, previous, avdName } = await withConfigLockAsync(() => {
|
|
99
|
-
const previous = deviceSlotPlatforms(loadConfig()?.projects?.[projectPath], slot)?.android;
|
|
129
|
+
const { claim, reservation, previous, avdName } = await withConfigLockAsync$1(() => {
|
|
130
|
+
const previous = deviceSlotPlatforms(loadConfig$1()?.projects?.[projectPath], slot)?.android;
|
|
100
131
|
if (previous?.avdName && previous.avdName !== previousAvdName) throw new Error(`Another Stim run assigned AVD ${previous.avdName} to this workspace. Retry to use it.`);
|
|
101
132
|
if (readParked("android").some((entry) => entry.name === ownedAvdName(label)) || findOtherOwner(ownedAvdName(label), projectPath, slot)) label = `${label}-${randomUUID().slice(0, 8)}`;
|
|
102
133
|
const avdName = ownedAvdName(label);
|
|
@@ -121,7 +152,7 @@ async function prepareOwnedAvd({ projectPath, slot, label, previousAvdName, syst
|
|
|
121
152
|
throw error;
|
|
122
153
|
}
|
|
123
154
|
});
|
|
124
|
-
const currentRecord = () => deviceSlotPlatforms(loadConfig()?.projects?.[projectPath], slot)?.android;
|
|
155
|
+
const currentRecord = () => deviceSlotPlatforms(loadConfig$1()?.projects?.[projectPath], slot)?.android;
|
|
125
156
|
const assertReservation = () => {
|
|
126
157
|
if (readParked("android").some((entry) => entry.name === avdName)) throw new Error(`AVD ${avdName} was parked by another Stim run. Retry to adopt it safely.`);
|
|
127
158
|
const owner = findOtherOwner(avdName, projectPath, slot);
|
|
@@ -168,7 +199,7 @@ async function prepareOwnedAvd({ projectPath, slot, label, previousAvdName, syst
|
|
|
168
199
|
if (!message.includes("already exists")) throw error;
|
|
169
200
|
try {
|
|
170
201
|
if (!(await listAvdsAsync()).includes(avdName)) throw new AvdRecoveryError(`AVD ${avdName} already exists on disk but is not listed by the emulator. ${message}`, "Run `npx stim gc` to inspect orphaned owned AVDs, then `npx stim gc --delete` to reclaim those safe to delete. Retry `stim android` after cleanup; keep any AVD that GC cannot verify.", error);
|
|
171
|
-
await withConfigLockAsync(assertReservation);
|
|
202
|
+
await withConfigLockAsync$1(assertReservation);
|
|
172
203
|
const resolved = await resolveOwnedAvdSerialAsync(avdName);
|
|
173
204
|
if (resolved.missing || resolved.notOwned) throw new Error(`AVD ${avdName} could not be verified for recovery. Retry after checking its registration.`, { cause: error });
|
|
174
205
|
if (!resolved.serial) assertOwnedAvdStopped(avdName);
|
|
@@ -183,7 +214,7 @@ async function prepareOwnedAvd({ projectPath, slot, label, previousAvdName, syst
|
|
|
183
214
|
} : {}
|
|
184
215
|
};
|
|
185
216
|
} catch (recoveryError) {
|
|
186
|
-
await withConfigLockAsync(() => {
|
|
217
|
+
await withConfigLockAsync$1(() => {
|
|
187
218
|
if (!isDeepStrictEqual(currentRecord(), reservation)) return;
|
|
188
219
|
if (previous) setDevice(projectPath, "android", previous, slot);
|
|
189
220
|
else clearDevice(projectPath, "android", slot, avdName);
|
|
@@ -197,7 +228,7 @@ async function prepareOwnedAvd({ projectPath, slot, label, previousAvdName, syst
|
|
|
197
228
|
} catch (error) {
|
|
198
229
|
configurationFailure = { error };
|
|
199
230
|
}
|
|
200
|
-
if (!configurationFailure) await withConfigLockAsync(() => {
|
|
231
|
+
if (!configurationFailure) await withConfigLockAsync$1(() => {
|
|
201
232
|
assertReservation();
|
|
202
233
|
setDevice(projectPath, "android", {
|
|
203
234
|
avdName,
|
|
@@ -227,7 +258,7 @@ async function prepareOwnedAvd({ projectPath, slot, label, previousAvdName, syst
|
|
|
227
258
|
slot,
|
|
228
259
|
expectedRecord: reservation
|
|
229
260
|
},
|
|
230
|
-
onRemoved: () => withConfigLockAsync(() => clearDevice(projectPath, "android", slot, avdName))
|
|
261
|
+
onRemoved: () => withConfigLockAsync$1(() => clearDevice(projectPath, "android", slot, avdName))
|
|
231
262
|
});
|
|
232
263
|
const orphan = cleanup.status === "failed" || cleanup.status === "skipped" ? ` The owned AVD remains tracked for cleanup (${cleanup.reason || cleanup.status}); fix the cause, then retry or run \`stim gc --delete\`.` : "";
|
|
233
264
|
throw new Error(`Created owned AVD ${avdName}, but could not configure its AVD settings: ${String(error?.message || error)}${orphan}`, { cause: error });
|
|
@@ -255,7 +286,7 @@ async function ensureOwnedAndroidDevice({ record, projectPath, slot, settingsRoo
|
|
|
255
286
|
slot,
|
|
256
287
|
expectedRecord: record
|
|
257
288
|
},
|
|
258
|
-
onRemoved: () => withConfigLockAsync(() => clearDevice(projectPath, "android", slot, avdName))
|
|
289
|
+
onRemoved: () => withConfigLockAsync$1(() => clearDevice(projectPath, "android", slot, avdName))
|
|
259
290
|
});
|
|
260
291
|
if (cleanup.status === "failed" || cleanup.status === "skipped") throw new AvdRecoveryError(`Owned AVD ${record.avdName} has incomplete setup and could not be deleted (${cleanup.reason || cleanup.status}). Fix the cause, then retry; Stim kept the device record for cleanup.`, "Wait for any active AVD operation to finish. If the refusal names an unresolved claim, inspect its creator and native processes before removing only that claim. Retry `stim android` to reconcile the incomplete device.");
|
|
261
292
|
record = null;
|
|
@@ -273,7 +304,7 @@ async function ensureOwnedAndroidDevice({ record, projectPath, slot, settingsRoo
|
|
|
273
304
|
slot,
|
|
274
305
|
expectedRecord: record
|
|
275
306
|
},
|
|
276
|
-
onRemoved: () => withConfigLockAsync(() => clearDevice(projectPath, "android", slot, avdName))
|
|
307
|
+
onRemoved: () => withConfigLockAsync$1(() => clearDevice(projectPath, "android", slot, avdName))
|
|
277
308
|
});
|
|
278
309
|
if (cleanup.status === "failed" || cleanup.status === "skipped") throw new AvdRecoveryError(`Owned AVD ${avdName} never finished a boot, but could not be deleted to create one on ${requestedImage} (${cleanup.reason || cleanup.status}). Stim kept the device record.`, "Fix the cause, then retry, or pass `--slot <name>` to create the requested emulator beside it.");
|
|
279
310
|
out(phaseLine("device", `deleted ${avdName}, which never finished a boot, to create one on ${requestedImage}`));
|
|
@@ -298,7 +329,7 @@ async function ensureOwnedAndroidDevice({ record, projectPath, slot, settingsRoo
|
|
|
298
329
|
owned: true,
|
|
299
330
|
deviceName: record.deviceName ?? record.avdName
|
|
300
331
|
};
|
|
301
|
-
await withConfigLockAsync(() => setDevice(projectPath, "android", updated, slot));
|
|
332
|
+
await withConfigLockAsync$1(() => setDevice(projectPath, "android", updated, slot));
|
|
302
333
|
return {
|
|
303
334
|
...updated,
|
|
304
335
|
systemImage: ownedAvdSystemImage(record.avdName),
|
|
@@ -438,7 +469,7 @@ async function ensureOwnedAndroidDevice({ record, projectPath, slot, settingsRoo
|
|
|
438
469
|
deviceProfile: created.deviceProfile
|
|
439
470
|
};
|
|
440
471
|
}
|
|
441
|
-
function claimAndroidConsolePort({ projectPath, slot, avdName, deviceName, livePorts = [], metadata }, { lock = withConfigLock, recordedPorts = () => allConsolePortsAndSerials().androidConsolePorts, record = setDevice } = {}) {
|
|
472
|
+
function claimAndroidConsolePort({ projectPath, slot, avdName, deviceName, livePorts = [], metadata }, { lock = withConfigLock$1, recordedPorts = () => allConsolePortsAndSerials().androidConsolePorts, record = setDevice } = {}) {
|
|
442
473
|
return lock(() => {
|
|
443
474
|
const consolePort = nextConsolePort([...recordedPorts(), ...livePorts]);
|
|
444
475
|
const claim = {
|
|
@@ -464,7 +495,7 @@ async function bootOwnedAvdOnFreshPort({ avdName, deviceSlotWait, metadata, proj
|
|
|
464
495
|
key: avdName
|
|
465
496
|
}, async () => {
|
|
466
497
|
const livePorts = liveAndroidConsolePorts();
|
|
467
|
-
const claim = await withConfigLockAsync(() => claimAndroidConsolePort({
|
|
498
|
+
const claim = await withConfigLockAsync$1(() => claimAndroidConsolePort({
|
|
468
499
|
projectPath,
|
|
469
500
|
slot,
|
|
470
501
|
avdName,
|
|
@@ -487,7 +518,7 @@ async function bootOwnedAvdOnFreshPort({ avdName, deviceSlotWait, metadata, proj
|
|
|
487
518
|
if (result.failed) throw new AvdBootError(result.reason, result.remedy);
|
|
488
519
|
const running = await getAvdNameForSerialAsync(serial);
|
|
489
520
|
if (running && running !== avdName) throw new Error(`${serial} is running AVD ${running}, not this workspace's owned AVD ${avdName}; refusing to use it.`);
|
|
490
|
-
await withConfigLockAsync(() => clearAndroidBootPending(projectPath, avdName, slot));
|
|
521
|
+
await withConfigLockAsync$1(() => clearAndroidBootPending(projectPath, avdName, slot));
|
|
491
522
|
await muteBootedEmulator(serial, avdName, out);
|
|
492
523
|
const { bootPending: _booted, ...booted } = claim;
|
|
493
524
|
return {
|
|
@@ -496,7 +527,7 @@ async function bootOwnedAvdOnFreshPort({ avdName, deviceSlotWait, metadata, proj
|
|
|
496
527
|
setup: true
|
|
497
528
|
};
|
|
498
529
|
} catch (error) {
|
|
499
|
-
await withConfigLockAsync(() => releaseAndroidConsolePort(projectPath, claim.consolePort, slot));
|
|
530
|
+
await withConfigLockAsync$1(() => releaseAndroidConsolePort(projectPath, claim.consolePort, slot));
|
|
500
531
|
throw error;
|
|
501
532
|
}
|
|
502
533
|
}, {
|
|
@@ -639,7 +670,7 @@ async function ensureAndroidBooted({ device, deviceSlotWait, projectPath, slot,
|
|
|
639
670
|
};
|
|
640
671
|
const avdName = device.avdName;
|
|
641
672
|
const booted = async (result) => {
|
|
642
|
-
if (!result.failed) await withConfigLockAsync(() => clearAndroidBootPending(projectPath, avdName, slot));
|
|
673
|
+
if (!result.failed) await withConfigLockAsync$1(() => clearAndroidBootPending(projectPath, avdName, slot));
|
|
643
674
|
return result;
|
|
644
675
|
};
|
|
645
676
|
if (resolved.serial) return booted(await waitForAndroidBoot({
|
|
@@ -655,7 +686,7 @@ async function ensureAndroidBooted({ device, deviceSlotWait, projectPath, slot,
|
|
|
655
686
|
}));
|
|
656
687
|
const boot = async () => {
|
|
657
688
|
const livePorts = liveAndroidConsolePorts();
|
|
658
|
-
const claim = await withConfigLockAsync(() => claimAndroidConsolePort({
|
|
689
|
+
const claim = await withConfigLockAsync$1(() => claimAndroidConsolePort({
|
|
659
690
|
projectPath,
|
|
660
691
|
slot,
|
|
661
692
|
avdName,
|
|
@@ -670,7 +701,7 @@ async function ensureAndroidBooted({ device, deviceSlotWait, projectPath, slot,
|
|
|
670
701
|
try {
|
|
671
702
|
pid = await bootAndroidEmulator(avdName, claim.consolePort, { logFile });
|
|
672
703
|
} catch (e) {
|
|
673
|
-
await withConfigLockAsync(() => releaseAndroidConsolePort(projectPath, claim.consolePort, slot));
|
|
704
|
+
await withConfigLockAsync$1(() => releaseAndroidConsolePort(projectPath, claim.consolePort, slot));
|
|
674
705
|
return {
|
|
675
706
|
failed: true,
|
|
676
707
|
reason: `Could not start emulator for AVD ${avdName}: ${e?.message || e}`
|
|
@@ -683,7 +714,7 @@ async function ensureAndroidBooted({ device, deviceSlotWait, projectPath, slot,
|
|
|
683
714
|
alive,
|
|
684
715
|
out
|
|
685
716
|
});
|
|
686
|
-
if (result.failed) await withConfigLockAsync(() => releaseAndroidConsolePort(projectPath, claim.consolePort, slot));
|
|
717
|
+
if (result.failed) await withConfigLockAsync$1(() => releaseAndroidConsolePort(projectPath, claim.consolePort, slot));
|
|
687
718
|
else await muteBootedEmulator(serial, avdName, out);
|
|
688
719
|
return booted(result);
|
|
689
720
|
};
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { b as operationState, t as getExecutor } from "./exec-VFRpu1iA.mjs";
|
|
2
2
|
import { G as projectDeviceSlots, V as deviceSlotKey, W as parseDeviceSlotOption, _ as loadConfig$1, p as getProject } from "./config-BZhXY15H.mjs";
|
|
3
3
|
import { t as createLineReader } from "./process-output-Fpl8PYi8.mjs";
|
|
4
|
-
import { r as clockTime } from "./command-output-
|
|
5
|
-
import {
|
|
6
|
-
import { f as projectRegistry, g as selectNativeXcodeProject, i as findProjectRoot$1, p as NativeXcodeError, t as NO_PROJECT_REFUSAL } from "./project-
|
|
7
|
-
import { A as listAdbDevices, O as getAvdNameForSerialAsync, R as memoizeEmulatorProbe, Y as physicalDeviceModel, Z as probeEmulatorSerial, c as androidPoolNoCandidatesRefusal, rt as resolvePhysicalDevice, s as androidPoolCandidates } from "./android-
|
|
8
|
-
import {
|
|
9
|
-
import { C as parseLeaseDuration, D as releaseWorkspaceLeases, j as takeLease, y as fileLeaseIo } from "./activity-
|
|
10
|
-
import { m as resolveScheme, v as xcodebuildArgs } from "./xcode-
|
|
11
|
-
import { a as discoverXcodeProject } from "./react-native-build-
|
|
12
|
-
import { l as parseDeviceWait, p as waitForDevice } from "./device-lease-run-
|
|
13
|
-
import { m as resolveConfiguration, y as resolveSchemeSelection } from "./support-
|
|
4
|
+
import { r as clockTime } from "./command-output-BBvS1H6v.mjs";
|
|
5
|
+
import { J as resolveProjectSettings, Ut as makeTemporaryDirectory, Wt as removeTemporaryEntry, nt as settingValueAt, q as resolveIosProjectDir } from "./settings-B5tCoq9N.mjs";
|
|
6
|
+
import { f as projectRegistry, g as selectNativeXcodeProject, i as findProjectRoot$1, p as NativeXcodeError, t as NO_PROJECT_REFUSAL } from "./project-BiC68mIp.mjs";
|
|
7
|
+
import { A as listAdbDevices, O as getAvdNameForSerialAsync, R as memoizeEmulatorProbe, Y as physicalDeviceModel, Z as probeEmulatorSerial, c as androidPoolNoCandidatesRefusal, rt as resolvePhysicalDevice, s as androidPoolCandidates } from "./android-Cjcj8MCw.mjs";
|
|
8
|
+
import { zn as runProcessOperation } from "./budget-HyShrIpL.mjs";
|
|
9
|
+
import { C as parseLeaseDuration, D as releaseWorkspaceLeases, j as takeLease, y as fileLeaseIo } from "./activity-BpjwrQXU.mjs";
|
|
10
|
+
import { m as resolveScheme, v as xcodebuildArgs } from "./xcode-CiIIDnuD.mjs";
|
|
11
|
+
import { a as discoverXcodeProject } from "./react-native-build-CwZB-agu.mjs";
|
|
12
|
+
import { l as parseDeviceWait, p as waitForDevice } from "./device-lease-run-ogEeJ62K.mjs";
|
|
13
|
+
import { m as resolveConfiguration, y as resolveSchemeSelection } from "./support-qKcbgmI5.mjs";
|
|
14
14
|
import { n as findSigningIdentities, o as parsePlist, s as parseProvisioningProfilePlist, t as decodeProvisioningProfile } from "./ios-signing-4c_qXvQm.mjs";
|
|
15
|
-
import { t as selectFromPool } from "./device-pool-
|
|
16
|
-
import { a as iosPoolCandidates, c as isWirelessIosDevice, f as resolveIosPhysicalDevice, l as listIosDevices, o as iosPoolNoCandidatesRefusal } from "./ios-device-
|
|
17
|
-
import { i as nativeXcodePackages, t as nativeXcodeHasPackages } from "./native-xcode-inputs-
|
|
15
|
+
import { t as selectFromPool } from "./device-pool-BIg8MU8l.mjs";
|
|
16
|
+
import { a as iosPoolCandidates, c as isWirelessIosDevice, f as resolveIosPhysicalDevice, l as listIosDevices, o as iosPoolNoCandidatesRefusal } from "./ios-device-CKSvk0bu.mjs";
|
|
17
|
+
import { i as nativeXcodePackages, t as nativeXcodeHasPackages } from "./native-xcode-inputs-Cv4l-obn.mjs";
|
|
18
18
|
import { existsSync, readdirSync, realpathSync, statSync } from "node:fs";
|
|
19
19
|
import { homedir } from "node:os";
|
|
20
20
|
import { join } from "node:path";
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { D as ownership_claim_exports, d as workspaceProcessLockError, u as withWorkspaceProcessLock } from "./exec-VFRpu1iA.mjs";
|
|
2
2
|
import { m as workspaceLogsDir$1 } from "./paths-DQtTgsBf.mjs";
|
|
3
3
|
import { G as projectDeviceSlots, H as deviceSlotPlatforms, O as withConfigLockAsync$1, _ as loadConfig$1, d as getConfigDir, u as getConcurrencyLimits } from "./config-BZhXY15H.mjs";
|
|
4
|
-
import { a as formatElapsed, l as phaseLine } from "./command-output-
|
|
5
|
-
import { g as deviceReclaimIdleMinutesSetting } from "./settings-
|
|
6
|
-
import { A as listAdbDevices, j as listAdbDevicesAsync } from "./android-
|
|
4
|
+
import { a as formatElapsed, l as phaseLine } from "./command-output-BBvS1H6v.mjs";
|
|
5
|
+
import { g as deviceReclaimIdleMinutesSetting } from "./settings-B5tCoq9N.mjs";
|
|
6
|
+
import { A as listAdbDevices, j as listAdbDevicesAsync } from "./android-Cjcj8MCw.mjs";
|
|
7
7
|
import { r as createNdjsonWriter } from "./ndjson-CgE_o3Dl.mjs";
|
|
8
|
-
import { J as recordCapacityRefusal, Y as recordCapacityWait } from "./budget-
|
|
8
|
+
import { J as recordCapacityRefusal, Y as recordCapacityWait } from "./budget-HyShrIpL.mjs";
|
|
9
9
|
import { t as canonicalPath } from "./paths-BsJMoPP2.mjs";
|
|
10
|
-
import { p as withIdleWorkspace } from "./workspaces-
|
|
11
|
-
import { d as listAllIosSims, f as listAllIosSimsAsync, l as iosRuntimeMatches, y as parseRuntimeVersion } from "./ios-
|
|
12
|
-
import { n as dueIdleDevices, r as shutDownIdleDevices } from "./idle-shutdown-
|
|
10
|
+
import { p as withIdleWorkspace } from "./workspaces-C9w4aeXF.mjs";
|
|
11
|
+
import { d as listAllIosSims, f as listAllIosSimsAsync, l as iosRuntimeMatches, y as parseRuntimeVersion } from "./ios-BQzvJlzw.mjs";
|
|
12
|
+
import { n as dueIdleDevices, r as shutDownIdleDevices } from "./idle-shutdown-BIyfl0Zj.mjs";
|
|
13
13
|
import { realpathSync } from "node:fs";
|
|
14
14
|
import { basename, join } from "node:path";
|
|
15
15
|
import { LOG_ROTATE_BYTES, workspaceId } from "@stim-cli/core";
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { t as getExecutor } from "./exec-VFRpu1iA.mjs";
|
|
2
2
|
import { n as ensureWorkspaceStorage } from "./paths-DQtTgsBf.mjs";
|
|
3
3
|
import { O as withConfigLockAsync$1, _ as loadConfig$1, c as ensureConfig } from "./config-BZhXY15H.mjs";
|
|
4
|
-
import { d as writeWorkspaceState } from "./workspace-state-
|
|
5
|
-
import { i as macosProcess, o as requiredMacosRecord } from "./state-
|
|
6
|
-
import { A as listAdbDevices, D as getAvdNameForSerial, F as listAvdsAsync, I as listInstalledSystemImages, K as ownedAvdSystemImage, M as listAvdDeviceProfiles, O as getAvdNameForSerialAsync, U as ownedAvdName, X as pickDefaultSystemImage, a as androidDeviceAbi, ct as waitForBoot, d as androidToolPath, f as assertOwnedAvdStopped, g as avdPathExists, k as hostSystemImageArch, nt as resolveOwnedAvdSerialAsync, t as DEFAULT_AVD_DEVICE_PROFILE, tt as resetAdoptedAvd, v as avdStorageRoots, x as createOwnedAvd, y as bootAndroidEmulator } from "./android-
|
|
4
|
+
import { d as writeWorkspaceState } from "./workspace-state-CPSp3mav.mjs";
|
|
5
|
+
import { i as macosProcess, o as requiredMacosRecord } from "./state-DPaM3u5K.mjs";
|
|
6
|
+
import { A as listAdbDevices, D as getAvdNameForSerial, F as listAvdsAsync, I as listInstalledSystemImages, K as ownedAvdSystemImage, M as listAvdDeviceProfiles, O as getAvdNameForSerialAsync, U as ownedAvdName, X as pickDefaultSystemImage, a as androidDeviceAbi, ct as waitForBoot, d as androidToolPath, f as assertOwnedAvdStopped, g as avdPathExists, k as hostSystemImageArch, nt as resolveOwnedAvdSerialAsync, t as DEFAULT_AVD_DEVICE_PROFILE, tt as resetAdoptedAvd, v as avdStorageRoots, x as createOwnedAvd, y as bootAndroidEmulator } from "./android-Cjcj8MCw.mjs";
|
|
7
7
|
import { n as forgetCreatedDeviceAsync } from "./created-devices-D2Aca-xu.mjs";
|
|
8
|
-
import { a as parsePidof, i as parseLogcatLine, t as androidClockOffset } from "./android-
|
|
8
|
+
import { a as parsePidof, i as parseLogcatLine, t as androidClockOffset } from "./android-saBeB4lr.mjs";
|
|
9
9
|
import { r as createNdjsonWriter } from "./ndjson-CgE_o3Dl.mjs";
|
|
10
|
-
import { An as
|
|
11
|
-
import { A as teardownOwnedIosSim, O as teardownOwnedAvd } from "./workspaces-
|
|
12
|
-
import { C as resetIosKeychain,
|
|
13
|
-
import { r as stopMacosAppHeld } from "./stop-
|
|
10
|
+
import { An as reverseMetroPorts, Dn as launchAndroidReleaseApp, En as launchAndroidApp, On as launchIosApp, Sn as installAndroidApp, Tn as iosAppProcess, jn as writeDebugHttpHost, mn as androidAppProcess, wn as installIosApp } from "./budget-HyShrIpL.mjs";
|
|
11
|
+
import { A as teardownOwnedIosSim, O as teardownOwnedAvd } from "./workspaces-C9w4aeXF.mjs";
|
|
12
|
+
import { C as resetIosKeychain, I as readHostMemoryPressure, T as resolveIosCreation, a as createOwnedIosSim, d as listAllIosSims, g as listUserApps, k as uninstallIosApp, n as bootIosSim, w as resetIosPrivacy } from "./ios-BQzvJlzw.mjs";
|
|
13
|
+
import { r as stopMacosAppHeld } from "./stop-COP6PQqw.mjs";
|
|
14
14
|
import { t as spawnEntry } from "./spawn-entry-jw19m8Nl.mjs";
|
|
15
|
-
import { i as countLiveOwnedDevices } from "./device-capacity-
|
|
16
|
-
import { _ as findAapt } from "./support-
|
|
15
|
+
import { i as countLiveOwnedDevices } from "./device-capacity-ZYaRALv5.mjs";
|
|
16
|
+
import { _ as findAapt } from "./support-Cxj9CmII.mjs";
|
|
17
17
|
import { t as waitForMacosRegistration } from "./registration-CN6nlhcD.mjs";
|
|
18
18
|
import { n as parseLogStreamLine } from "./ios-ENC4sRPA.mjs";
|
|
19
19
|
import { createHash, randomUUID } from "node:crypto";
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { D as ownership_claim_exports, o as cancellableSleep, t as getExecutor, u as withWorkspaceProcessLock } from "./exec-VFRpu1iA.mjs";
|
|
2
2
|
import { f as workspaceId$1 } from "./paths-DQtTgsBf.mjs";
|
|
3
3
|
import { C as saveConfig, G as projectDeviceSlots, H as deviceSlotPlatforms, O as withConfigLockAsync$1, _ as loadConfig$1, a as clearDevice, d as getConfigDir, w as setDevice } from "./config-BZhXY15H.mjs";
|
|
4
|
-
import { l as phaseLine } from "./command-output-
|
|
5
|
-
import {
|
|
6
|
-
import { mt as dropParked, pt as adoptParked, vt as parkedMaxSetting, xt as selectParked, yt as readParked } from "./android-
|
|
7
|
-
import { M as teardownParkedIosSim } from "./workspaces-
|
|
8
|
-
import { A as
|
|
9
|
-
import { l as runtimeMismatch, m as withDeviceBootAdmission, n as DeviceAdmissionRefusal, o as deviceTypeMismatch } from "./device-capacity-
|
|
4
|
+
import { l as phaseLine } from "./command-output-BBvS1H6v.mjs";
|
|
5
|
+
import { E as iosSimSlimProfileSetting, T as iosSimSlimDefaultSetting } from "./settings-B5tCoq9N.mjs";
|
|
6
|
+
import { mt as dropParked, pt as adoptParked, vt as parkedMaxSetting, xt as selectParked, yt as readParked } from "./android-Cjcj8MCw.mjs";
|
|
7
|
+
import { M as teardownParkedIosSim } from "./workspaces-C9w4aeXF.mjs";
|
|
8
|
+
import { A as waitForSpringBoard, C as resetIosKeychain, E as resolveOwnedIosSim, I as readHostMemoryPressure, N as hostMemoryPressureAdvice, R as reportMemoryCulprits, S as renameIosSim, T as resolveIosCreation, _ as ownedSimName, a as createOwnedIosSim, d as listAllIosSims, f as listAllIosSimsAsync, h as listIosRuntimesAsync, j as configuredIosSimulatorViewer, n as bootIosSim, p as listIosDeviceTypesAsync, u as iosSimulatorFailureAdvice, w as resetIosPrivacy, y as parseRuntimeVersion } from "./ios-BQzvJlzw.mjs";
|
|
9
|
+
import { l as runtimeMismatch, m as withDeviceBootAdmission, n as DeviceAdmissionRefusal, o as deviceTypeMismatch } from "./device-capacity-ZYaRALv5.mjs";
|
|
10
10
|
import { ambientContext } from "@stim-cli/core";
|
|
11
11
|
import { isJsonObject } from "@stim-cli/core/state";
|
|
12
12
|
import chalk from "chalk";
|
|
@@ -17,13 +17,14 @@ function startIosBoot(udid, configure, label, out, simulatorApp, root, deviceSlo
|
|
|
17
17
|
key: udid
|
|
18
18
|
}, async () => {
|
|
19
19
|
out(chalk.dim(phaseLine("device", `booting ${label} (${udid})`)));
|
|
20
|
-
await
|
|
20
|
+
await bootIosSim(udid, {
|
|
21
21
|
label,
|
|
22
22
|
out,
|
|
23
23
|
simulatorApp,
|
|
24
24
|
env: ambientContext()?.env
|
|
25
|
-
})
|
|
25
|
+
});
|
|
26
26
|
await configure();
|
|
27
|
+
await muteBootedSimulator(udid, out);
|
|
27
28
|
}, {
|
|
28
29
|
...deviceSlotWait,
|
|
29
30
|
root,
|
|
@@ -35,9 +36,12 @@ function startIosBoot(udid, configure, label, out, simulatorApp, root, deviceSlo
|
|
|
35
36
|
done
|
|
36
37
|
};
|
|
37
38
|
}
|
|
38
|
-
|
|
39
|
+
const SPRINGBOARD_MUTE_WAIT_MS = 6e4;
|
|
40
|
+
async function muteBootedSimulator(udid, out) {
|
|
39
41
|
try {
|
|
40
|
-
|
|
42
|
+
const springBoard = await waitForSpringBoard(udid, Date.now() + SPRINGBOARD_MUTE_WAIT_MS);
|
|
43
|
+
if (springBoard.state === "unreadable") throw new Error(springBoard.reason);
|
|
44
|
+
if (springBoard.state === "timed-out") throw new Error(`SpringBoard did not finish starting within ${SPRINGBOARD_MUTE_WAIT_MS / 1e3}s.`);
|
|
41
45
|
const response = JSON.parse(await getExecutor().runFileAsync("xcrun", [
|
|
42
46
|
"devicectl",
|
|
43
47
|
"device",
|
|
@@ -65,6 +69,7 @@ async function ensureOwnedIosDevice({ record, projectPath, slot, settingsRoot, l
|
|
|
65
69
|
if (memoryAdvice) out(chalk.yellow(phaseLine("memory", memoryAdvice)));
|
|
66
70
|
reportMemoryCulprits(pressure, (named) => out(chalk.yellow(phaseLine("memory", named))));
|
|
67
71
|
const simslimProfile = iosSimSlimProfileSetting(settings, settingsRoot);
|
|
72
|
+
const simslimDefault = iosSimSlimDefaultSetting(settings);
|
|
68
73
|
if (record?.deviceUdid) {
|
|
69
74
|
if (record.owned) {
|
|
70
75
|
const listed = simSnapshot ? simSnapshot.read() : listAllIosSims({ includeUnavailable: true });
|
|
@@ -73,10 +78,10 @@ async function ensureOwnedIosDevice({ record, projectPath, slot, settingsRoot, l
|
|
|
73
78
|
else if (resolved.missing) {} else {
|
|
74
79
|
const sim = resolved.sim;
|
|
75
80
|
const wantedType = flags.deviceType || settings?.ios?.deviceType;
|
|
76
|
-
const deviceTypes = await listIosDeviceTypesAsync();
|
|
81
|
+
const deviceTypes = await listIosDeviceTypesAsync({ snapshot: simSnapshot });
|
|
77
82
|
const mismatch = deviceTypeMismatch(sim.deviceTypeIdentifier, wantedType, deviceTypes);
|
|
78
83
|
if (mismatch) throw new IosDeviceMismatchError(`${mismatch}. Stim will not silently boot a different model.`);
|
|
79
|
-
const versionMismatch = flags.runtimeFlag ? runtimeMismatch(sim.runtime, flags.runtimeFlag, await listIosRuntimesAsync()) : null;
|
|
84
|
+
const versionMismatch = flags.runtimeFlag ? runtimeMismatch(sim.runtime, flags.runtimeFlag, await listIosRuntimesAsync({ snapshot: simSnapshot })) : null;
|
|
80
85
|
if (versionMismatch) throw new IosDeviceMismatchError(`${versionMismatch}. Stim will not silently boot a different iOS version.`);
|
|
81
86
|
const model = {
|
|
82
87
|
model: deviceTypes.find((d) => d.identifier === sim.deviceTypeIdentifier)?.name ?? null,
|
|
@@ -100,6 +105,7 @@ async function ensureOwnedIosDevice({ record, projectPath, slot, settingsRoot, l
|
|
|
100
105
|
projectPath,
|
|
101
106
|
slot,
|
|
102
107
|
profile: simslimProfile,
|
|
108
|
+
slimByDefault: simslimDefault,
|
|
103
109
|
out,
|
|
104
110
|
reconcileIosSimulator
|
|
105
111
|
});
|
|
@@ -155,6 +161,7 @@ async function ensureOwnedIosDevice({ record, projectPath, slot, settingsRoot, l
|
|
|
155
161
|
projectPath,
|
|
156
162
|
slot,
|
|
157
163
|
profile: simslimProfile,
|
|
164
|
+
slimByDefault: simslimDefault,
|
|
158
165
|
out,
|
|
159
166
|
reconcileIosSimulator
|
|
160
167
|
});
|
|
@@ -189,6 +196,7 @@ async function ensureOwnedIosDevice({ record, projectPath, slot, settingsRoot, l
|
|
|
189
196
|
projectPath,
|
|
190
197
|
slot,
|
|
191
198
|
profile: simslimProfile,
|
|
199
|
+
slimByDefault: simslimDefault,
|
|
192
200
|
out,
|
|
193
201
|
reconcileIosSimulator
|
|
194
202
|
}), created.name, out, flags.simulatorApp, projectPath, flags.deviceSlotWait);
|
|
@@ -294,11 +302,12 @@ function clearIosAdoptionPending(projectPath, slot = "default") {
|
|
|
294
302
|
saveConfig(cfg);
|
|
295
303
|
});
|
|
296
304
|
}
|
|
297
|
-
async function configureOwnedIosSim({ record, projectPath, slot, profile, out, reconcileIosSimulator }) {
|
|
305
|
+
async function configureOwnedIosSim({ record, projectPath, slot, profile, slimByDefault, out, reconcileIosSimulator }) {
|
|
298
306
|
if (profile) out(chalk.dim(phaseLine("device", `applying the SimSlim profile to ${record.deviceUdid}`)));
|
|
307
|
+
else if (slimByDefault) out(chalk.dim(phaseLine("device", `applying SimSlim's default services to ${record.deviceUdid}`)));
|
|
299
308
|
else if (record.simslimManaged) out(chalk.dim(phaseLine("device", `restoring stock simulator services on ${record.deviceUdid}`)));
|
|
300
309
|
const previouslyManaged = Boolean(record.simslimManaged);
|
|
301
|
-
if (profile && !record.simslimManaged) {
|
|
310
|
+
if ((profile || slimByDefault) && !record.simslimManaged) {
|
|
302
311
|
const pending = {
|
|
303
312
|
...record,
|
|
304
313
|
simslimManaged: true
|
|
@@ -310,6 +319,7 @@ async function configureOwnedIosSim({ record, projectPath, slot, profile, out, r
|
|
|
310
319
|
context: ambientContext(),
|
|
311
320
|
udid: record.deviceUdid,
|
|
312
321
|
profile,
|
|
322
|
+
slimByDefault,
|
|
313
323
|
previouslyManaged,
|
|
314
324
|
out
|
|
315
325
|
});
|
|
@@ -389,13 +399,14 @@ async function ensureIosBooted({ device, projectPath, deviceSlotWait, simulatorA
|
|
|
389
399
|
key: udid
|
|
390
400
|
}, async () => {
|
|
391
401
|
out(chalk.dim(phaseLine("device", `booting ${sim.name} (${udid})`)));
|
|
392
|
-
await
|
|
402
|
+
await bootIosSim(udid, {
|
|
393
403
|
timeoutMs,
|
|
394
404
|
label: sim.name,
|
|
395
405
|
out,
|
|
396
406
|
simulatorApp,
|
|
397
407
|
env: ambientContext()?.env
|
|
398
|
-
})
|
|
408
|
+
});
|
|
409
|
+
await muteBootedSimulator(udid, out);
|
|
399
410
|
}, {
|
|
400
411
|
...deviceSlotWait,
|
|
401
412
|
root: projectPath,
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { b as operationState } from "./exec-VFRpu1iA.mjs";
|
|
2
2
|
import { V as deviceSlotKey } from "./config-BZhXY15H.mjs";
|
|
3
|
-
import { a as formatElapsed, r as clockTime } from "./command-output-
|
|
4
|
-
import {
|
|
5
|
-
import { E as releaseRunLease, S as parseLease, T as raiseLease, b as leaseIsExpired, j as takeLease, v as deviceLeasePath, y as fileLeaseIo } from "./activity-
|
|
3
|
+
import { a as formatElapsed, r as clockTime } from "./command-output-BBvS1H6v.mjs";
|
|
4
|
+
import { Qt as MANIFEST_VERIFY_TIMEOUT_MS, ln as APP_READINESS_TIMEOUT_MS } from "./budget-HyShrIpL.mjs";
|
|
5
|
+
import { E as releaseRunLease, S as parseLease, T as raiseLease, b as leaseIsExpired, j as takeLease, v as deviceLeasePath, y as fileLeaseIo } from "./activity-BpjwrQXU.mjs";
|
|
6
6
|
//#region src/engine/device-lease-run.ts
|
|
7
7
|
const LEASE_STEP_FLOOR_MS = 6e4;
|
|
8
|
-
const DEBUG_VERIFY_STEP_MS =
|
|
8
|
+
const DEBUG_VERIFY_STEP_MS = MANIFEST_VERIFY_TIMEOUT_MS + APP_READINESS_TIMEOUT_MS;
|
|
9
9
|
const DEVICE_WAIT_POLL_MS = 2e3;
|
|
10
10
|
const DEVICE_WAIT_LINE_MS = 3e4;
|
|
11
11
|
const DEVICE_BUSY = "STIM_DEVICE_BUSY";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { V as deviceSlotKey } from "./config-BZhXY15H.mjs";
|
|
2
|
-
import { A as selectPoolDevice, S as parseLease, b as leaseIsExpired, v as deviceLeasePath, y as fileLeaseIo } from "./activity-
|
|
3
|
-
import { i as DEVICE_WAIT_POLL_MS, n as DEVICE_BUSY, o as leaseExpiryText } from "./device-lease-run-
|
|
2
|
+
import { A as selectPoolDevice, S as parseLease, b as leaseIsExpired, v as deviceLeasePath, y as fileLeaseIo } from "./activity-BpjwrQXU.mjs";
|
|
3
|
+
import { i as DEVICE_WAIT_POLL_MS, n as DEVICE_BUSY, o as leaseExpiryText } from "./device-lease-run-ogEeJ62K.mjs";
|
|
4
4
|
//#region src/engine/device-pool.ts
|
|
5
5
|
function heldPoolId(root, platform, now, io = fileLeaseIo, slot = "default") {
|
|
6
6
|
const record = io.readHolder(root)[deviceSlotKey(platform, slot)];
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as readDoctorReport, i as parseDoctorPlatform, n as doctorCommand, o as shadowedStimFinding, r as doctorSuccessLines, s as toolchainReport, t as applySandboxFix } from "./doctor-
|
|
1
|
+
import { a as readDoctorReport, i as parseDoctorPlatform, n as doctorCommand, o as shadowedStimFinding, r as doctorSuccessLines, s as toolchainReport, t as applySandboxFix } from "./doctor-k3P3PizH.mjs";
|
|
2
2
|
export { applySandboxFix, doctorCommand as default, doctorSuccessLines, parseDoctorPlatform, readDoctorReport, shadowedStimFinding, toolchainReport };
|
|
@@ -1,29 +1,29 @@
|
|
|
1
1
|
import { C as reportSignal, T as trackReportResource, t as getExecutor } from "./exec-VFRpu1iA.mjs";
|
|
2
2
|
import { i as sharedBuildCache, u as workspaceDerivedData } from "./paths-DQtTgsBf.mjs";
|
|
3
3
|
import { _ as loadConfig$1, nt as realIo, s as configCorruptRepair, u as getConcurrencyLimits } from "./config-BZhXY15H.mjs";
|
|
4
|
-
import { d as quotedPath, u as plural } from "./command-output-
|
|
4
|
+
import { d as quotedPath, u as plural } from "./command-output-BBvS1H6v.mjs";
|
|
5
5
|
import { l as gitQuietAsync, o as git } from "./operation-exec-CUZifp6Z.mjs";
|
|
6
|
-
import { r as readWorkspaceState$1 } from "./workspace-state-
|
|
7
|
-
import {
|
|
8
|
-
import { C as resolvePackageJson, _ as appProjectProblem, b as isPackageResolvable, v as detectIsExpo } from "./project-
|
|
9
|
-
import { ft as POOL_SETTING_REMEDY, k as hostSystemImageArch, o as androidHome, vt as parkedMaxSetting } from "./android-
|
|
10
|
-
import {
|
|
11
|
-
import { R as listBuildSlots } from "./workspaces-
|
|
12
|
-
import { N as listBuildLocks } from "./activity-
|
|
13
|
-
import { d as fingerprintProject, o as diffFingerprintSources } from "./build-cache-
|
|
14
|
-
import {
|
|
15
|
-
import { p as resolveOptimizations, u as compilerCacheFallbackMessage } from "./errors-
|
|
16
|
-
import { i as projectCmakeLauncher } from "./ccache-
|
|
17
|
-
import { x as podInstallCommand } from "./xcode-
|
|
18
|
-
import { g as androidPathRoomRemedy, i as ccacheEnabled, l as androidSdkRefusal, m as androidPathRoomMessage, p as androidPathRoom, t as apkOutputsDir } from "./react-native-build-
|
|
19
|
-
import { a as countLiveOwnedDevicesAsync, i as countLiveOwnedDevices } from "./device-capacity-
|
|
6
|
+
import { r as readWorkspaceState$1 } from "./workspace-state-CPSp3mav.mjs";
|
|
7
|
+
import { $ as settingOrigin, Dt as listWorktreesAsync, E as iosSimSlimProfileSetting, G as resolveAndroidLayout, H as remoteAndroidSetting, Ht as filesystemDevice, Kt as temporaryRoot, L as projectSettingsContext, Lt as resolveSourceCheckoutAsync, Nt as repoRoot, O as mergeSettingsLayers, Pt as repoRootAsync, T as iosSimSlimDefaultSetting, Ut as makeTemporaryDirectory, W as remoteIosSetting, X as resolveSettings, a as SETTING_SHAPE_REMEDY, at as unknownSettingKeys, gt as dirtyFingerprintFiles, i as SETTINGS_WITH_RESOLVE_TIME_FALLBACK, kt as locallyKnownUpstreamAsync, m as defaultAndroidLayout, nt as settingValueAt, ot as webSettings, q as resolveIosProjectDir, r as PATH_SETTINGS, rt as settingsLayers, tt as settingShapeErrors, yt as gitCommonDirAsync } from "./settings-B5tCoq9N.mjs";
|
|
8
|
+
import { C as resolvePackageJson, _ as appProjectProblem, b as isPackageResolvable, v as detectIsExpo } from "./project-BiC68mIp.mjs";
|
|
9
|
+
import { ft as POOL_SETTING_REMEDY, k as hostSystemImageArch, o as androidHome, vt as parkedMaxSetting } from "./android-Cjcj8MCw.mjs";
|
|
10
|
+
import { Jn as providerFromConfig, Un as checkEasAuth$1, Wt as readInstalledEasCliVersionAsync, Xn as resolveEasCliBin, ar as easCliUpgradeRemedy, ir as easCliSupport, qn as ownerFromConfig, rr as MIN_EAS_CLI_SIMULATOR_VERSION } from "./budget-HyShrIpL.mjs";
|
|
11
|
+
import { R as listBuildSlots } from "./workspaces-C9w4aeXF.mjs";
|
|
12
|
+
import { N as listBuildLocks } from "./activity-BpjwrQXU.mjs";
|
|
13
|
+
import { d as fingerprintProject, o as diffFingerprintSources } from "./build-cache-CKCzxzxA.mjs";
|
|
14
|
+
import { L as readHostMemoryPressureAsync, N as hostMemoryPressureAdvice } from "./ios-BQzvJlzw.mjs";
|
|
15
|
+
import { p as resolveOptimizations, u as compilerCacheFallbackMessage } from "./errors-DHm_U5gv.mjs";
|
|
16
|
+
import { i as projectCmakeLauncher } from "./ccache-h1FKhZeg.mjs";
|
|
17
|
+
import { x as podInstallCommand } from "./xcode-CiIIDnuD.mjs";
|
|
18
|
+
import { g as androidPathRoomRemedy, i as ccacheEnabled, l as androidSdkRefusal, m as androidPathRoomMessage, p as androidPathRoom, t as apkOutputsDir } from "./react-native-build-CwZB-agu.mjs";
|
|
19
|
+
import { a as countLiveOwnedDevicesAsync, i as countLiveOwnedDevices } from "./device-capacity-ZYaRALv5.mjs";
|
|
20
20
|
import { t as readDoctorFingerprint } from "./doctor-fingerprint-zlujA1Gs.mjs";
|
|
21
21
|
import { i as probeSigningIdentities } from "./ios-signing-4c_qXvQm.mjs";
|
|
22
22
|
import { a as findChrome, t as CHROME_INSTALL_REMEDY } from "./chrome-BvV8ssI3.mjs";
|
|
23
|
-
import { i as installedNpmTreeIsValidAsync, n as hasInstalledDependencies, t as dependencyState } from "./dependency-state-
|
|
24
|
-
import { n as simslimIsOnPath } from "./simslim-
|
|
25
|
-
import { t as MIN_EAS_CLI_BUILD_DOWNLOAD_VERSION } from "./eas-build-
|
|
26
|
-
import { r as resolveAndroidCompilerCache, t as readAndroidCasToolchain } from "./android-cas-
|
|
23
|
+
import { i as installedNpmTreeIsValidAsync, n as hasInstalledDependencies, t as dependencyState } from "./dependency-state-BwNCYG5Q.mjs";
|
|
24
|
+
import { n as simslimIsOnPath } from "./simslim-BjxszUAb.mjs";
|
|
25
|
+
import { t as MIN_EAS_CLI_BUILD_DOWNLOAD_VERSION } from "./eas-build-CyDKNTBP.mjs";
|
|
26
|
+
import { r as resolveAndroidCompilerCache, t as readAndroidCasToolchain } from "./android-cas-BVqh2Zep.mjs";
|
|
27
27
|
import { existsSync, lstatSync, readFileSync, readdirSync, realpathSync, rmSync } from "node:fs";
|
|
28
28
|
import { basename, dirname, isAbsolute, join, relative, resolve, sep } from "node:path";
|
|
29
29
|
import { LAST_BUILD_KEYS, isJsonObject, readBuildHistory, readJsonObject, readStats, settingDefinition } from "@stim-cli/core/state";
|
|
@@ -706,8 +706,12 @@ async function projectEasBuildDownloadFinding(projectRoot, remoteBackends, looku
|
|
|
706
706
|
readEasCliVersion: () => version
|
|
707
707
|
});
|
|
708
708
|
}
|
|
709
|
-
function checkSimSlim({ configured = false, profileError = null, onPath = false } = {}) {
|
|
709
|
+
function checkSimSlim({ configured = false, slimByDefault = false, profileError = null, onPath = false } = {}) {
|
|
710
710
|
if (profileError) return finding("cost", "The SimSlim profile is invalid", profileError, "Set ios.simslimProfile to a readable JSON profile inside the repository.");
|
|
711
|
+
if (!configured && slimByDefault) {
|
|
712
|
+
if (onPath) return null;
|
|
713
|
+
return finding("cost", "ios.simslim is on, but SimSlim is not installed", "`stim ios` boots owned simulators without SimSlim until the `simslim` command is installed.", "brew install mobai-app/tap/simslim");
|
|
714
|
+
}
|
|
711
715
|
if (!configured) return finding("note", "SimSlim is recommended for parallel iOS simulator work", "A reviewed profile can reduce background simulator services and memory use. It is optional: disabling services can affect tests that depend on them, and installing the binary alone does not apply a profile.", "Run `stim guide lifecycle simslim` to install SimSlim and configure ios.simslimProfile. Stim does not enable a profile through doctor --fix.");
|
|
712
716
|
if (onPath) return null;
|
|
713
717
|
return finding("cost", "A SimSlim profile is configured, but SimSlim is not installed", "`stim ios` needs the `simslim` command to apply the profile to its owned simulator.", "brew install mobai-app/tap/simslim");
|
|
@@ -780,10 +784,12 @@ async function runDoctor(projectRoot, options = {}, inspectors = []) {
|
|
|
780
784
|
} catch (error) {
|
|
781
785
|
simslimProfileError = String(error?.message || error);
|
|
782
786
|
}
|
|
787
|
+
const simslimByDefault = localIos && iosSimSlimDefaultSetting(projectSettings);
|
|
783
788
|
const simslimFinding = !localIos || !simslimProfile && !simslimProfileError && remoteIosSetting(projectSettings) ? null : checkSimSlim({
|
|
784
789
|
configured: Boolean(simslimProfile),
|
|
790
|
+
slimByDefault: simslimByDefault,
|
|
785
791
|
profileError: simslimProfileError,
|
|
786
|
-
onPath: simslimProfile ? lookupSimSlim ? lookupSimSlim() : simslimIsOnPath() : false
|
|
792
|
+
onPath: simslimProfile || simslimByDefault ? lookupSimSlim ? lookupSimSlim() : simslimIsOnPath() : false
|
|
787
793
|
});
|
|
788
794
|
const memoryAdvice = localIos && !remoteIosSetting(projectSettings) ? hostMemoryPressureAdvice(await memoryPressure()) : null;
|
|
789
795
|
const shared = [
|