stim 1.26.0 → 1.28.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-DVsvSwf7.mjs → acquire-artifact-CKByBnTD.mjs} +2 -2
- package/dist/{act-C-BqJEpu.mjs → act-8iswyfRa.mjs} +319 -126
- package/dist/{activity-Lnb_EoRY.mjs → activity-DRMg4_mD.mjs} +6 -6
- package/dist/{agent-device-usage-output-DbXy5tg8.mjs → agent-device-usage-output-tE90fDdo.mjs} +5 -5
- package/dist/{android-CiNQw3kq.mjs → android-CHmSU4B4.mjs} +101 -45
- package/dist/{android-DTAcRwBC.mjs → android-CsPs-7Mg.mjs} +23 -18
- package/dist/{android-B5P81yI-.mjs → android-D577ApKG.mjs} +37 -15
- package/dist/{android-CSbLRD53.mjs → android-YWCbmkVK.mjs} +5 -5
- package/dist/{android-cas-BTVhZ0Qs.mjs → android-cas-_aDifWW0.mjs} +4 -4
- package/dist/android-cas-compiler.mjs +1 -1
- package/dist/api.d.mts +14 -4
- package/dist/api.mjs +39 -29
- package/dist/{apk-signed-tail-B46U9hXc.mjs → apk-signed-tail-CQbwM0qO.mjs} +2 -2
- package/dist/{artifact-CsAP6AGK.mjs → artifact-DYtHjxsn.mjs} +19 -24
- package/dist/{artifact-BxREhAaV.mjs → artifact-bFkfD3vf.mjs} +18 -23
- package/dist/{artifact-platform-CMRc0M_r.mjs → artifact-platform-BO2Uvk_A.mjs} +1 -1
- package/dist/auto-placement-BVqs8AJi.mjs +350 -0
- package/dist/{browser-web-rYPyqhTf.mjs → browser-web-BUaLcafY.mjs} +16 -16
- package/dist/{build-DPhApsjV.mjs → build-cQURy_KW.mjs} +35 -31
- package/dist/{build-cache-DrXNCy3T.mjs → build-cache-CZULpXVl.mjs} +43 -21
- package/dist/{build-plan-DrMMdayj.mjs → build-plan-CxoYfxsc.mjs} +7 -6
- package/dist/{cache-manifest-BEZ9Bpl1.mjs → cache-manifest-DEjqGGat.mjs} +1 -1
- package/dist/cache-manifest.mjs +1 -1
- package/dist/{budget-k2mZGvvk.mjs → ccache-Bm_A1xX9.mjs} +562 -1604
- package/dist/{cdp-BG3FJCCx.mjs → cdp-C3svvXiE.mjs} +1 -1
- package/dist/{chrome-BvV8ssI3.mjs → chrome-DyDWurWG.mjs} +1 -1
- package/dist/{cli-BBKFGOFl.mjs → cli-CpbaLDa7.mjs} +24 -23
- package/dist/cli.mjs +1 -1
- package/dist/{client-D9CaRks-.mjs → client-YxCer6ab.mjs} +84 -65
- package/dist/collector-run.d.mts +10 -9
- package/dist/collector-run.mjs +42 -27
- package/dist/{command-output-BF5AR2dL.mjs → command-output-C8R1KIvi.mjs} +1 -1
- package/dist/{config-BktkY_zC.mjs → config-Cn94Jc0g.mjs} +23 -4
- package/dist/{dependencies-Dw6wfQdv.mjs → dependencies-DKeMzwXY.mjs} +108 -60
- package/dist/{dependency-state-DFB41vfr.mjs → dependency-state-CojA2o0t.mjs} +14 -7
- package/dist/{detached-entry-KmieOKgN.mjs → detached-entry-BPlSaCwC.mjs} +1 -1
- package/dist/{dev-client-DXR_tPVY.mjs → dev-client-D-BW5uiq.mjs} +2 -2
- package/dist/{device-BK-zwyd_.mjs → device-CgXfbcz5.mjs} +25 -24
- package/dist/{device-capacity-DCSvUF0l.mjs → device-capacity-Cd8lMSn3.mjs} +175 -22
- package/dist/{device-BcYeHSFu.mjs → device-eeK95Lir.mjs} +16 -16
- package/dist/device-host-worker.mjs +22 -20
- package/dist/{device-ios-BLGfXQeK.mjs → device-ios-Cc9ulihb.mjs} +251 -23
- package/dist/{device-lease-run-BmvIl7bI.mjs → device-lease-run-Mtzp4THX.mjs} +5 -5
- package/dist/{device-pool-Dluix4H3.mjs → device-pool-eRz6DtCg.mjs} +3 -3
- package/dist/{doctor-Bhg1ii70.mjs → doctor-Bz_ouYAW.mjs} +28 -16
- package/dist/{doctor-Cp-BhzTS.mjs → doctor-C2QyhejJ.mjs} +1 -1
- package/dist/{doctor-fingerprint-D3a04Mhu.mjs → doctor-fingerprint-o7ZI9YLn.mjs} +1 -1
- package/dist/doctor-fingerprint.mjs +1 -1
- package/dist/{doctor-watchman-BStK05nt.mjs → doctor-watchman-BTW82PDC.mjs} +5 -5
- package/dist/{doctor-OnwP94ne.mjs → doctor-xf7ht-5n.mjs} +76 -32
- package/dist/{eas-build-Dsj93iM9.mjs → eas-build-Dm6q68QY.mjs} +4 -4
- package/dist/eas-fallback-DajNpxf-.mjs +87 -0
- package/dist/{eas-session-ledger-B5vygTiD.mjs → eas-session-ledger-CBFo_Uo1.mjs} +37 -8
- package/dist/{error-diagnostics-BOOm9Db7.mjs → error-diagnostics-D1QfyJzQ.mjs} +51 -25
- package/dist/{exec-VFRpu1iA.mjs → exec-aULwtNly.mjs} +57 -6
- package/dist/{gc-ldgr-hXU.mjs → gc-DM5oMm-J.mjs} +161 -45
- package/dist/{gc-C_79zvz4.mjs → gc-PLFwb0k4.mjs} +2 -2
- package/dist/{guide-D7K0X6KG.mjs → guide-C4I46XAk.mjs} +674 -213
- package/dist/{hosted-android-Bk54ej6n.mjs → hosted-android-DlaKLbW0.mjs} +6 -7
- package/dist/{hosted-client-fHO8yqzc.mjs → hosted-client-DDRm9hPJ.mjs} +51 -20
- package/dist/{hosted-logs-BfbmDM4M.mjs → hosted-logs-bSebOKbz.mjs} +8 -8
- package/dist/{hosted-logs-sync-B0pvmOk-.mjs → hosted-logs-sync-B0c53W_c.mjs} +5 -5
- package/dist/{hosted-macos-CPl0OZ9h.mjs → hosted-macos-B7-8Pv4H.mjs} +6 -6
- package/dist/{hosted-native-CpDB3-PO.mjs → hosted-native-CDe33CSr.mjs} +22 -18
- package/dist/{idle-shutdown-FfxL1KdG.mjs → idle-shutdown-CQ0QwU9J.mjs} +7 -8
- package/dist/{ios-WxpDJ5T1.mjs → ios-B1DYuOjh.mjs} +27 -11
- package/dist/{ios-B7-lToDu.mjs → ios-B1HvafEG.mjs} +8 -8
- package/dist/{ios-ENC4sRPA.mjs → ios-CsRVik64.mjs} +7 -1
- package/dist/{ios-device-CsyryvpT.mjs → ios-device-B4elVFKi.mjs} +3 -3
- package/dist/{ios-device-B6HK951C.mjs → ios-device-CiBA-er9.mjs} +1 -1
- package/dist/{ios-project-Ty5pHl9O.mjs → ios-project-CR4mZ7CH.mjs} +22 -9
- package/dist/{ios-signing-4c_qXvQm.mjs → ios-signing-BJzvDPfU.mjs} +2 -2
- package/dist/{ios-state-Cw7-WQf2.mjs → ios-state-BPHqMDdZ.mjs} +1 -1
- package/dist/{ios-ftxdQbJS.mjs → ios-tg4tp3q1.mjs} +94 -37
- package/dist/{js-swap-BMhXYVDS.mjs → js-swap-CVpSW1fn.mjs} +8 -7
- package/dist/{launch-DOp8RjDz.mjs → launch-DoySmhjz.mjs} +42 -38
- package/dist/lightened-DFAJgfIk.mjs +171 -0
- package/dist/{logs-s1dRIG1E.mjs → logs-BGsW7iPe.mjs} +46 -21
- package/dist/{logs-dQDki6Tt.mjs → logs-DI5ILkYB.mjs} +7 -7
- package/dist/{macos-DBBPNnIA.mjs → macos-Bo9st9Di.mjs} +73 -38
- package/dist/{macos-B0VEV3Gf.mjs → macos-C12RMJQF.mjs} +1 -1
- package/dist/macos-run.mjs +1 -1
- package/dist/maintenance-run.mjs +7 -7
- package/dist/{metro-CjC10t6E.mjs → metro-BnhXV2Mj.mjs} +4 -4
- package/dist/{metro-gateway-B6_PgD0L.mjs → metro-request-DXyKjVDF.mjs} +26 -47
- package/dist/{named-ports-BG0j1X4g.mjs → named-ports-Phoi2POD.mjs} +3 -3
- package/dist/{native-android-CL2NGiik.mjs → native-android-vxgtLD7w.mjs} +17 -18
- package/dist/{native-gradle-artifact-inputs-btSUulme.mjs → native-gradle-artifact-inputs-BN96IVw8.mjs} +5 -5
- package/dist/{native-runtime-Dq3RBcON.mjs → native-runtime-DG4Rodzj.mjs} +9 -8
- package/dist/{native-source-D-4Dh4JU.mjs → native-source-D1AzWiuP.mjs} +1 -1
- package/dist/{native-xcode-inputs-BW7H8JGu.mjs → native-xcode-inputs-BKarCoKg.mjs} +3 -3
- package/dist/{native-xcode-ios-CBXJAxfC.mjs → native-xcode-ios-8A-efGa5.mjs} +17 -17
- package/dist/{ndjson-CgE_o3Dl.mjs → ndjson-Dy2W4vRa.mjs} +2 -2
- package/dist/offload-worker.mjs +23 -24
- package/dist/{operation-exec-CUZifp6Z.mjs → operation-exec-Dp4FuIGR.mjs} +1 -1
- package/dist/{ownership-BjYvMNX_.mjs → ownership-DJCq48IJ.mjs} +3 -3
- package/dist/{page-CzEA_-5_.mjs → page-CQJlcj3x.mjs} +2 -2
- package/dist/{phone-reverses-lmj6kcPm.mjs → phone-reverses-BzTa8g1F.mjs} +18 -4
- package/dist/{placement-log-DIFPQAXp.mjs → placement-log-Cvhta5ib.mjs} +3 -3
- package/dist/{plan-placement-IiiSQhtz.mjs → plan-placement-WkZdccuN.mjs} +36 -10
- package/dist/{ports-C2_w1Z0Z.mjs → ports-UV4mJgyC.mjs} +3 -3
- package/dist/{prebuild-gmouvmJZ.mjs → prebuild-k8d_tqOq.mjs} +16 -17
- package/dist/{project-BUu6Is4k.mjs → project-Sui52ywT.mjs} +17 -17
- package/dist/{pull-request-CbNlkFok.mjs → pull-request-BzLmzAIQ.mjs} +2 -2
- package/dist/pull-requests.mjs +1 -1
- package/dist/{react-native-android-Cgg99REN.mjs → react-native-android-DANlGGQf.mjs} +32 -26
- package/dist/{react-native-build-oNwqF5Wb.mjs → react-native-build-jUHnIfZ9.mjs} +9 -9
- package/dist/{react-native-doctor-BhA3KUte.mjs → react-native-doctor-DCWRjS7K.mjs} +6 -6
- package/dist/{react-native-ios-B-nf4rjN.mjs → react-native-ios-BwMsFMXi.mjs} +23 -17
- package/dist/{recordings-BldzVKq0.mjs → recordings-iy0mkm7b.mjs} +1 -1
- package/dist/{registration-CN6nlhcD.mjs → registration-BwCe64PH.mjs} +1 -1
- package/dist/{reload-C9OduiNc.mjs → reload-Bj7QyuDy.mjs} +1 -1
- package/dist/{reload-CCR7KC_l.mjs → reload-c_uEyc_X.mjs} +16 -16
- package/dist/{remote-C8S7FlPF.mjs → remote-DFlpAqdV.mjs} +23 -10
- package/dist/{result-7F5hEwQJ.mjs → result-BIcXREyC.mjs} +32 -21
- package/dist/{run-BqB0v3pt.mjs → run-y2HwyNvg.mjs} +3 -3
- package/dist/{selection-BNPBZ6T5.mjs → selection-CXgM_VK_.mjs} +37 -29
- package/dist/{server-bare-A75rDIdD.mjs → server-bare-2N4vSRZG.mjs} +2 -2
- package/dist/{server-command-CssKFOD7.mjs → server-command-qneHPcRI.mjs} +6 -6
- package/dist/{server-expo-eQfOdydb.mjs → server-expo-Ccm9zB0o.mjs} +4 -4
- package/dist/server-expo-WulkyAwT.mjs +2 -0
- package/dist/{settings-CosW5X-S.mjs → settings-CY5JZlNN.mjs} +375 -62
- package/dist/{settings-OaGQF-ri.mjs → settings-Cfd_Q6ys.mjs} +24 -3
- package/dist/settings-payload-DwQiEMCn.mjs +257 -0
- package/dist/settings-write-CJpjkeAd.mjs +185 -0
- package/dist/settings.schema.json +51 -33
- package/dist/{simslim-Bax1qcxu.mjs → simslim-DCQwzoPy.mjs} +2 -2
- package/dist/{slot-launch-CYCEhfBY.mjs → slot-launch-BpmanOnk.mjs} +6 -6
- package/dist/{stage-jKQ7CP_B.mjs → stage-CmugrSG5.mjs} +2 -2
- package/dist/{start-C_wefNKB.mjs → start-CHH3zgIU.mjs} +1 -1
- package/dist/{start-_BdJ32cZ.mjs → start-DYLk6GXn.mjs} +27 -22
- package/dist/{state-C1i2nMOP.mjs → state-B2QJbDwz.mjs} +4 -4
- package/dist/{state-C4OdpOTF.mjs → state-BXC1Lfxw.mjs} +2 -2
- package/dist/{stats-tEpEEH-u.mjs → stats-DxKqhcGp.mjs} +5 -5
- package/dist/{stats-report-n2U5plhk.mjs → stats-report-B86Cv7Uc.mjs} +1 -1
- package/dist/{status-CRXz-Gtj.mjs → status-7ULDEJ1e.mjs} +1 -1
- package/dist/{status-DQrqodLj.mjs → status-BHCkOZga.mjs} +51 -28
- package/dist/{status-B9M7x4CZ.mjs → status-D_Ljc89p.mjs} +1 -1
- package/dist/{status-watch-B5wDIH_o.mjs → status-watch-BmsPqYSU.mjs} +18 -7
- package/dist/status-worker.mjs +1 -1
- package/dist/{stim-desktop-6Dqp-gjX.mjs → stim-desktop-CbWo21kb.mjs} +2 -2
- package/dist/{stop-DRqQVqDJ.mjs → stop-D-dGE9gh.mjs} +21 -20
- package/dist/{stop-ySNQHXMG.mjs → stop-DQvE-P76.mjs} +10 -6
- package/dist/{stop-CmdNhGlC.mjs → stop-b2pouxAO.mjs} +2 -2
- package/dist/supervisor-run.mjs +237 -63
- package/dist/{support-BGSCBoib.mjs → support-04IhBUTT.mjs} +6 -6
- package/dist/{support-CVOCp0Ft.mjs → support-BtlJKjyQ.mjs} +12 -11
- package/dist/{swiftpm-artifact-inputs-CfUzt_0Z.mjs → swiftpm-artifact-inputs-Cj2UpmPN.mjs} +4 -4
- package/dist/{swiftpm-macos-x6HPpl_2.mjs → swiftpm-macos-BhF2stxY.mjs} +11 -12
- package/dist/{toolchain-J4J8MrAr.mjs → toolchain-mLA_km-b.mjs} +321 -15
- package/dist/{toolchain-DoavrvIA.mjs → toolchain-qktiV8xc.mjs} +1 -1
- package/dist/{trigger-KVaWWNyn.mjs → trigger-DMou-X7j.mjs} +2 -2
- package/dist/trigger-qp2ji5wE.mjs +2 -0
- package/dist/{warm-progress-DvhTX_eu.mjs → warm-progress-B0Vpuvpl.mjs} +731 -727
- package/dist/{web-Bihbf7-u.mjs → web-BYmK0TjL.mjs} +9 -9
- package/dist/web-CrVLVQZY.mjs +2 -0
- package/dist/web-run.mjs +9 -9
- package/dist/windows-report.mjs +1 -1
- package/dist/{workspace-state-pUg3_RRA.mjs → workspace-state-kIZrdlSg.mjs} +3 -3
- package/dist/{workspaces-g2lhdBXF.mjs → workspaces-CmOcceDN.mjs} +1879 -74
- package/dist/{worktree-BKuklFh_.mjs → worktree-2dk5edza.mjs} +933 -534
- package/dist/worktree-nliAoHxB.mjs +2 -0
- package/package.json +7 -7
- package/dist/ccache-Bx5TbxwG.mjs +0 -143
- package/dist/eas-fallback-FwkeqqGi.mjs +0 -381
- package/dist/hosted-ios-D55QhYaD.mjs +0 -15
- package/dist/native-run-BfIDFKLH.mjs +0 -275
- package/dist/server-expo-wvcj5tiZ.mjs +0 -2
- package/dist/settings-write-QjYfSrjF.mjs +0 -360
- package/dist/trigger-DzJu208Q.mjs +0 -2
- package/dist/web-BFLueSh-.mjs +0 -2
- package/dist/worktree-Bm4cb-nU.mjs +0 -2
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
import { C as reportSignal, T as trackReportResource, t as getExecutor } from "./exec-
|
|
2
|
-
import { T as workspaceDerivedData, r as readWorkspaceState$1, y as sharedBuildCache } from "./workspace-state-
|
|
3
|
-
import { _ as loadConfig$1,
|
|
4
|
-
import { d as quotedPath, u as plural } from "./command-output-
|
|
5
|
-
import { l as gitQuietAsync, o as git } from "./operation-exec-
|
|
6
|
-
import {
|
|
7
|
-
import { C as resolvePackageJson, _ as appProjectProblem, b as isPackageResolvable, v as detectIsExpo } from "./project-
|
|
8
|
-
import { ft as POOL_SETTING_REMEDY, k as hostSystemImageArch, o as androidHome, vt as parkedMaxSetting } from "./android-
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
1
|
+
import { C as reportSignal, T as trackReportResource, t as getExecutor } from "./exec-aULwtNly.mjs";
|
|
2
|
+
import { T as workspaceDerivedData, r as readWorkspaceState$1, y as sharedBuildCache } from "./workspace-state-kIZrdlSg.mjs";
|
|
3
|
+
import { _ as loadConfig$1, at as realIo, s as configCorruptRepair, u as getConcurrencyLimits } from "./config-Cn94Jc0g.mjs";
|
|
4
|
+
import { d as quotedPath, u as plural } from "./command-output-C8R1KIvi.mjs";
|
|
5
|
+
import { l as gitQuietAsync, o as git } from "./operation-exec-Dp4FuIGR.mjs";
|
|
6
|
+
import { Bt as repoRoot, D as iosSimSlimProfileSetting, E as iosSimSlimDefaultSetting, G as remoteIosSetting, Nt as locallyKnownUpstreamAsync, Q as resolveSettings, R as projectSettingsContext, St as gitCommonDirAsync, U as remoteAndroidSetting, V as readCommittedSettings, Vt as repoRootAsync, Wt as resolveSourceCheckoutAsync, Y as resolveIosProjectDir, a as SETTING_SHAPE_REMEDY, an as makeTemporaryDirectory, at as settingsLayers, cn as temporaryRoot, ct as webSettings, i as SETTINGS_WITH_RESOLVE_TIME_FALLBACK, in as filesystemDevice, it as settingValueAt, jt as listWorktreesAsync, k as mergeSettingsLayers, m as defaultAndroidLayout, q as resolveAndroidLayout, r as PATH_SETTINGS, rt as settingShapeErrors, st as unknownSettingKeys, tt as settingOrigin, yt as dirtyFingerprintFiles } from "./settings-CY5JZlNN.mjs";
|
|
7
|
+
import { C as resolvePackageJson, _ as appProjectProblem, b as isPackageResolvable, v as detectIsExpo } from "./project-Sui52ywT.mjs";
|
|
8
|
+
import { ft as POOL_SETTING_REMEDY, k as hostSystemImageArch, o as androidHome, vt as parkedMaxSetting } from "./android-CsPs-7Mg.mjs";
|
|
9
|
+
import { An as checkEasAuth$1, Fn as providerFromConfig, Gn as easCliSupport, Kn as easCliUpgradeRemedy, Ln as resolveEasCliBin, Pn as ownerFromConfig, Wn as MIN_EAS_CLI_SIMULATOR_VERSION, a as projectCmakeLauncher, i as ccacheInstallCommand, jt as readInstalledEasCliVersionAsync } from "./ccache-Bm_A1xX9.mjs";
|
|
10
|
+
import { wt as listBuildSlots } from "./workspaces-CmOcceDN.mjs";
|
|
11
|
+
import { Y as podInstallCommand } from "./toolchain-mLA_km-b.mjs";
|
|
12
|
+
import { N as listBuildLocks } from "./activity-DRMg4_mD.mjs";
|
|
13
|
+
import { m as fingerprintProject, o as diffFingerprintSources } from "./build-cache-CZULpXVl.mjs";
|
|
14
|
+
import { F as hostMemoryPressureAdvice, z as readHostMemoryPressureAsync } from "./ios-B1DYuOjh.mjs";
|
|
14
15
|
import { p as resolveOptimizations, u as compilerCacheFallbackMessage } from "./errors-DHm_U5gv.mjs";
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import { a as countLiveOwnedDevicesAsync, i as countLiveOwnedDevices } from "./device-capacity-
|
|
19
|
-
import { t as readDoctorFingerprint } from "./doctor-fingerprint-
|
|
20
|
-
import { i as probeSigningIdentities } from "./ios-signing-
|
|
21
|
-
import { a as findChrome, t as CHROME_INSTALL_REMEDY } from "./chrome-
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import { t as
|
|
25
|
-
import { r as resolveAndroidCompilerCache, t as readAndroidCasToolchain } from "./android-cas-BTVhZ0Qs.mjs";
|
|
16
|
+
import { n as hasInstalledDependencies, r as installedNpmTreeIsValidAsync, t as dependencyState } from "./dependency-state-CojA2o0t.mjs";
|
|
17
|
+
import { g as androidPathRoomRemedy, i as ccacheEnabled, l as androidSdkRefusal, m as androidPathRoomMessage, p as androidPathRoom, t as apkOutputsDir } from "./react-native-build-jUHnIfZ9.mjs";
|
|
18
|
+
import { a as envSettingRefusal, i as configSettingRefusal } from "./settings-payload-DwQiEMCn.mjs";
|
|
19
|
+
import { a as countLiveOwnedDevicesAsync, i as countLiveOwnedDevices } from "./device-capacity-Cd8lMSn3.mjs";
|
|
20
|
+
import { t as readDoctorFingerprint } from "./doctor-fingerprint-o7ZI9YLn.mjs";
|
|
21
|
+
import { i as probeSigningIdentities } from "./ios-signing-BJzvDPfU.mjs";
|
|
22
|
+
import { a as findChrome, t as CHROME_INSTALL_REMEDY } from "./chrome-DyDWurWG.mjs";
|
|
23
|
+
import { n as simslimIsOnPath } from "./simslim-DCQwzoPy.mjs";
|
|
24
|
+
import { t as MIN_EAS_CLI_BUILD_DOWNLOAD_VERSION } from "./eas-build-Dm6q68QY.mjs";
|
|
25
|
+
import { r as resolveAndroidCompilerCache, t as readAndroidCasToolchain } from "./android-cas-_aDifWW0.mjs";
|
|
26
26
|
import { existsSync, lstatSync, readFileSync, readdirSync, realpathSync, rmSync } from "node:fs";
|
|
27
27
|
import { basename, dirname, isAbsolute, join, relative, resolve, sep } from "node:path";
|
|
28
|
-
import { LAST_BUILD_KEYS, isJsonObject, readBuildHistory, readJsonObject, readStats, settingDefinition } from "@stim-cli/core/state";
|
|
28
|
+
import { LAST_BUILD_KEYS, REPLACED_SETTINGS, isJsonObject, readBuildHistory, readJsonObject, readStats, replacementAdvice, settingDefinition } from "@stim-cli/core/state";
|
|
29
29
|
import { basename as basename$1, dirname as dirname$1, isAbsolute as isAbsolute$1, join as join$1, relative as relative$1, resolve as resolve$1, sep as sep$1 } from "path";
|
|
30
30
|
import { existsSync as existsSync$1, lstatSync as lstatSync$1, readFileSync as readFileSync$1, readdirSync as readdirSync$1, realpathSync as realpathSync$1 } from "fs";
|
|
31
31
|
import * as expoFingerprint from "@expo/fingerprint";
|
|
@@ -35,9 +35,15 @@ import { createRequire } from "module";
|
|
|
35
35
|
function readMachineSettings(context) {
|
|
36
36
|
try {
|
|
37
37
|
const layers = settingsLayers(context);
|
|
38
|
+
const repositoryLayer = context.projectPath && context.repoRoot && context.repoRoot !== context.projectPath ? {
|
|
39
|
+
scope: "committed",
|
|
40
|
+
file: join(context.repoRoot, ".stim.json"),
|
|
41
|
+
settings: readCommittedSettings(context.repoRoot)
|
|
42
|
+
} : null;
|
|
38
43
|
return {
|
|
39
44
|
settings: mergeSettingsLayers(layers.map((layer) => layer.settings)),
|
|
40
45
|
layers,
|
|
46
|
+
repositoryLayer,
|
|
41
47
|
corrupt: null
|
|
42
48
|
};
|
|
43
49
|
} catch (error) {
|
|
@@ -55,7 +61,7 @@ function readMachineSettings(context) {
|
|
|
55
61
|
}
|
|
56
62
|
}
|
|
57
63
|
const PATH_SETTINGS_TRIMMED_BY_THEIR_CONSUMER = /* @__PURE__ */ new Set(["android.keystore"]);
|
|
58
|
-
function checkMachineSettings({ settings, layers, projectRoot, optimizations = null, reportedElsewhere = [], exists = existsSync, env = process.env }) {
|
|
64
|
+
function checkMachineSettings({ settings, layers, repositoryLayer = null, projectRoot, optimizations = null, reportedElsewhere = [], exists = existsSync, env = process.env, remoteBuild }) {
|
|
59
65
|
const findings = [];
|
|
60
66
|
const fallback = optimizations?.android.compilerCacheFallback ?? null;
|
|
61
67
|
const fallbackEntry = fallback ? settingOrigin(layers, fallback.key) : null;
|
|
@@ -94,13 +100,49 @@ function checkMachineSettings({ settings, layers, projectRoot, optimizations = n
|
|
|
94
100
|
optimizations,
|
|
95
101
|
file: fallbackEntry?.file ?? null
|
|
96
102
|
}));
|
|
97
|
-
|
|
98
|
-
|
|
103
|
+
const holders = repositoryLayer ? [...layers, repositoryLayer] : layers;
|
|
104
|
+
const unknownKeys = /* @__PURE__ */ new Set([...unknownSettingKeys(settings), ...repositoryLayer ? unknownSettingKeys(repositoryLayer.settings) : []]);
|
|
105
|
+
for (const key of unknownKeys) for (const holder of holders.filter((layer) => settingValueAt(layer.settings, key) !== void 0)) {
|
|
106
|
+
const file = holder.file;
|
|
107
|
+
const advice = replacementAdvice(key, settingValueAt(holder.settings, key));
|
|
108
|
+
if (advice) {
|
|
109
|
+
findings.push({
|
|
110
|
+
level: "note",
|
|
111
|
+
title: `${key} was replaced by ${advice.key}`,
|
|
112
|
+
detail: `${key} in ${file} is not read by Stim, so ${advice.key} decides placement and its default applies until you set it.`,
|
|
113
|
+
fix: `${advice.command ? `Run \`${advice.command}\`` : `Set ${advice.key}`}, then remove ${key} from ${file}.`
|
|
114
|
+
});
|
|
115
|
+
continue;
|
|
116
|
+
}
|
|
99
117
|
findings.push({
|
|
100
118
|
level: "note",
|
|
101
119
|
title: "A key in the config is inert",
|
|
102
|
-
detail: `${key}
|
|
103
|
-
fix: `Remove ${key}
|
|
120
|
+
detail: `${key} in ${file} is not read by Stim, so its value changes nothing.`,
|
|
121
|
+
fix: `Remove ${key} from ${file}, or run \`stim guide settings\` for the name that replaced it.`
|
|
122
|
+
});
|
|
123
|
+
}
|
|
124
|
+
const buildValueRefusal = configSettingRefusal("remote.build", remoteBuild);
|
|
125
|
+
if (buildValueRefusal) findings.push({
|
|
126
|
+
level: "cost",
|
|
127
|
+
title: "A setting has the wrong type",
|
|
128
|
+
detail: buildValueRefusal.message,
|
|
129
|
+
fix: buildValueRefusal.remedy
|
|
130
|
+
});
|
|
131
|
+
const buildEnvRefusal = envSettingRefusal("remote.build", env);
|
|
132
|
+
if (buildEnvRefusal) findings.push({
|
|
133
|
+
level: "cost",
|
|
134
|
+
title: "A setting has the wrong type",
|
|
135
|
+
detail: buildEnvRefusal.message,
|
|
136
|
+
fix: buildEnvRefusal.remedy
|
|
137
|
+
});
|
|
138
|
+
for (const [key, replaced] of Object.entries(REPLACED_SETTINGS)) {
|
|
139
|
+
if (!replaced.env || !env[replaced.env]?.trim()) continue;
|
|
140
|
+
const advice = replacementAdvice(key, env[replaced.env]);
|
|
141
|
+
findings.push({
|
|
142
|
+
level: "note",
|
|
143
|
+
title: `${replaced.env} was replaced by ${replaced.key}`,
|
|
144
|
+
detail: `${replaced.env} is not read by Stim, so ${replaced.key} decides placement and its default applies until you set it.`,
|
|
145
|
+
fix: `${advice?.command ? `Run \`${advice.command}\`` : `Set ${replaced.key}`}, then unset ${replaced.env}.`
|
|
104
146
|
});
|
|
105
147
|
}
|
|
106
148
|
return findings;
|
|
@@ -562,9 +604,9 @@ function checkChrome({ usesWeb, chrome = findChrome }) {
|
|
|
562
604
|
if (!usesWeb() || chrome()) return null;
|
|
563
605
|
return finding("cost", "No Chrome is installed, so `stim web` cannot open this app", "`stim web` drives the installed Google Chrome or Chromium with a Stim-owned profile, and found neither in /Applications, ~/Applications, Program Files or on PATH. This project renders on the web (web.url is set, app.json lists the web platform, or react-native-web is installed).", CHROME_INSTALL_REMEDY);
|
|
564
606
|
}
|
|
565
|
-
function checkCcacheInstalled(onPath) {
|
|
607
|
+
function checkCcacheInstalled(onPath, platform = process.platform) {
|
|
566
608
|
if (onPath) return null;
|
|
567
|
-
return finding("cost", "ccache is not on PATH, so Android C++ recompiles in every worktree", "Stim resolves the launcher with a PATH lookup for `ccache` -- the same lookup the build itself uses -- and found nothing, so it passes no CMAKE_C_COMPILER_LAUNCHER / CMAKE_CXX_COMPILER_LAUNCHER to Gradle and every AGP CMake task compiles without one. Those tasks are uncacheable by Gradle, so not one C++ object crosses a worktree. Measured on trailhead (arm64, fresh worktree): 49.6s without the launcher against 34.2s with it.",
|
|
609
|
+
return finding("cost", "ccache is not on PATH, so Android C++ recompiles in every worktree", "Stim resolves the launcher with a PATH lookup for `ccache` -- the same lookup the build itself uses -- and found nothing, so it passes no CMAKE_C_COMPILER_LAUNCHER / CMAKE_CXX_COMPILER_LAUNCHER to Gradle and every AGP CMake task compiles without one. Those tasks are uncacheable by Gradle, so not one C++ object crosses a worktree. Measured on trailhead (arm64, fresh worktree): 49.6s without the launcher against 34.2s with it.", `${ccacheInstallCommand(platform)}, then delete android/app/.cxx and node_modules/**/android/.cxx once so CMake reconfigures with the launcher. The shell that runs Stim must have the install location on PATH${platform === "darwin" ? " -- agent shells often lack /opt/homebrew/bin" : ""}.`);
|
|
568
610
|
}
|
|
569
611
|
function launcherPath(launcher) {
|
|
570
612
|
const command = launcher?.split(";")[0]?.trim();
|
|
@@ -809,9 +851,11 @@ async function runDoctor(projectRoot, options = {}, inspectors = []) {
|
|
|
809
851
|
...checkMachineSettings({
|
|
810
852
|
settings: projectSettings,
|
|
811
853
|
layers: machineSettings.layers,
|
|
854
|
+
repositoryLayer: machineSettings.repositoryLayer,
|
|
812
855
|
projectRoot,
|
|
813
856
|
optimizations,
|
|
814
857
|
env: options.operation?.env ?? options.remoteEnv ?? process.env,
|
|
858
|
+
remoteBuild: loadConfig$1()?.remote?.build,
|
|
815
859
|
reportedElsewhere: simslimProfileError ? ["ios.simslimProfile"] : []
|
|
816
860
|
})
|
|
817
861
|
].filter((f) => Boolean(f));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { D as ownership_claim_exports, c as throwIfCancelled, t as getExecutor } from "./exec-
|
|
2
|
-
import { a as killOnAbort, r as childEnvironment } from "./operation-exec-
|
|
3
|
-
import {
|
|
4
|
-
import { M as acquireBuildLock, P as releaseBuildLock } from "./activity-
|
|
1
|
+
import { D as ownership_claim_exports, c as throwIfCancelled, t as getExecutor } from "./exec-aULwtNly.mjs";
|
|
2
|
+
import { a as killOnAbort, r as childEnvironment } from "./operation-exec-Dp4FuIGR.mjs";
|
|
3
|
+
import { Gn as easCliSupport, Kn as easCliUpgradeRemedy, Ln as resolveEasCliBin, Vn as remoteCliInvocation } from "./ccache-Bm_A1xX9.mjs";
|
|
4
|
+
import { M as acquireBuildLock, P as releaseBuildLock } from "./activity-DRMg4_mD.mjs";
|
|
5
5
|
import { createHash } from "node:crypto";
|
|
6
6
|
import { existsSync, realpathSync, statSync } from "node:fs";
|
|
7
7
|
//#region src/engine/eas-build.ts
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { c as throwIfCancelled, t as getExecutor } from "./exec-aULwtNly.mjs";
|
|
2
|
+
import { p as getProject } from "./config-Cn94Jc0g.mjs";
|
|
3
|
+
import { r as childEnvironment } from "./operation-exec-Dp4FuIGR.mjs";
|
|
4
|
+
import { dt as detectProviders, ft as planMetroReach } from "./settings-CY5JZlNN.mjs";
|
|
5
|
+
import { M as readMetroTunnel, P as readRemoteSession } from "./project-Sui52ywT.mjs";
|
|
6
|
+
import { Gn as easCliSupport, Hn as remoteCommand, Ln as resolveEasCliBin, Mn as isEasAuthFailureText, Un as MIN_EAS_CLI_DEVICE_VERSION, Wn as MIN_EAS_CLI_SIMULATOR_VERSION, jt as readInstalledEasCliVersionAsync } from "./ccache-Bm_A1xX9.mjs";
|
|
7
|
+
//#region src/engine/eas-fallback.ts
|
|
8
|
+
const AVAILABILITY_TIMEOUT_MS = 3e4;
|
|
9
|
+
function unusable(code, reason) {
|
|
10
|
+
return {
|
|
11
|
+
usable: false,
|
|
12
|
+
code,
|
|
13
|
+
reason
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
/** Reads `eas simulator:availability --json`: `{"available": true, ...}` on stdout, or a failure on stderr. */
|
|
17
|
+
function parseSimulatorAvailability(outcome) {
|
|
18
|
+
if ("failure" in outcome) {
|
|
19
|
+
if (outcome.timedOut) return unusable("eas-unavailable", "eas simulator:availability timed out");
|
|
20
|
+
const detail = outcome.failure.split("\n").map((line) => line.trim()).find((line) => line && !/is now available\.$|^(To upgrade|npm install|Proceeding with|\(node:|\(Use `node)/.test(line));
|
|
21
|
+
if (isEasAuthFailureText(outcome.failure)) return unusable("eas-logged-out", "eas-cli is not logged in (run eas login or set EXPO_TOKEN)");
|
|
22
|
+
return unusable("eas-unavailable", `eas simulator:availability failed${detail ? `: ${detail}` : ""}`);
|
|
23
|
+
}
|
|
24
|
+
let data = null;
|
|
25
|
+
try {
|
|
26
|
+
data = JSON.parse(outcome.stdout.slice(outcome.stdout.indexOf("{")));
|
|
27
|
+
} catch {}
|
|
28
|
+
if (typeof data !== "object" || data === null || typeof data.available !== "boolean") return unusable("eas-unavailable", "eas simulator:availability printed no availability");
|
|
29
|
+
return data.available ? { usable: true } : unusable("eas-not-enabled", "EAS Simulator is not enabled for this EAS account");
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Whether this run could use an EAS Simulator the way `--remote eas` does, without starting a session or a build.
|
|
33
|
+
* Each refusal names what `--remote eas` would refuse later, so automatic placement falls through instead.
|
|
34
|
+
*/
|
|
35
|
+
async function checkEasFallback({ root, platform, slot, release, isExpo, tunnelMode, publicUrl, deviceTypeFlag, localOnlyFlags, env = process.env, resolveBin = resolveEasCliBin, readVersion = readInstalledEasCliVersionAsync, operation, onPath = (bin) => getExecutor().findExecutable(bin) !== null, readTunnel = readMetroTunnel, readSession = readRemoteSession, metroPort = () => getProject(root)?.metroPort ?? null, availability = async (bin) => {
|
|
36
|
+
try {
|
|
37
|
+
return { stdout: await remoteCommand({
|
|
38
|
+
operation,
|
|
39
|
+
easBin: bin
|
|
40
|
+
}, bin, [
|
|
41
|
+
"simulator:availability",
|
|
42
|
+
"--json",
|
|
43
|
+
"--non-interactive"
|
|
44
|
+
], {
|
|
45
|
+
cwd: root,
|
|
46
|
+
...childEnvironment(env),
|
|
47
|
+
timeoutMs: AVAILABILITY_TIMEOUT_MS
|
|
48
|
+
}) };
|
|
49
|
+
} catch (error) {
|
|
50
|
+
const err = error;
|
|
51
|
+
return {
|
|
52
|
+
failure: String(err.stderr || err.message || error),
|
|
53
|
+
timedOut: err.code === "ETIMEDOUT"
|
|
54
|
+
};
|
|
55
|
+
}
|
|
56
|
+
} }) {
|
|
57
|
+
if (slot !== "default") return unusable("eas-named-slot", `an EAS Simulator takes only the default slot, not ${slot}`);
|
|
58
|
+
if (localOnlyFlags.length) return unusable("eas-local-flags", `${localOnlyFlags.join(" and ")} applies only to a ${platform} device on a Mac`);
|
|
59
|
+
const session = readSession(root);
|
|
60
|
+
if (session && session.platform !== platform) return unusable("eas-session-busy", `this workspace's EAS Simulator session ${session.sessionId} runs ${session.platform ?? "another platform"}`);
|
|
61
|
+
if (session && deviceTypeFlag?.trim() && session.deviceType !== deviceTypeFlag.trim()) return unusable("eas-session-busy", `this workspace's EAS Simulator session ${session.sessionId} runs ${session.deviceType ?? "the model EAS chose"}, not ${deviceTypeFlag.trim()}`);
|
|
62
|
+
if (!onPath("agent-device")) return unusable("eas-no-agent-device", "agent-device is not on PATH");
|
|
63
|
+
throwIfCancelled(operation?.signal, "EAS availability");
|
|
64
|
+
const bin = resolveBin(root);
|
|
65
|
+
if (!bin) return unusable("eas-no-cli", "eas-cli is not installed for this project or on PATH");
|
|
66
|
+
const versionOutput = await readVersion(bin.file, root, operation);
|
|
67
|
+
const minimum = platform === "ios" && deviceTypeFlag?.trim() ? MIN_EAS_CLI_DEVICE_VERSION : MIN_EAS_CLI_SIMULATOR_VERSION;
|
|
68
|
+
const { supported, version } = easCliSupport(versionOutput, minimum);
|
|
69
|
+
if (!supported) return unusable("eas-cli-too-old", `eas-cli ${version ?? "(unknown version)"} is older than ${minimum}`);
|
|
70
|
+
if (!release) {
|
|
71
|
+
const mode = tunnelMode ?? "auto";
|
|
72
|
+
if (mode === "off") return unusable("eas-metro-unreachable", "metro.tunnel is off, so an EAS Simulator cannot reach Metro");
|
|
73
|
+
const plan = planMetroReach({
|
|
74
|
+
mode,
|
|
75
|
+
metroPort: metroPort() ?? "unknown",
|
|
76
|
+
publicUrl: env["STIM_METRO_PUBLIC_URL"]?.trim() || publicUrl,
|
|
77
|
+
isExpo,
|
|
78
|
+
available: detectProviders(onPath, mode)
|
|
79
|
+
});
|
|
80
|
+
if ("failed" in plan) return unusable("eas-metro-unreachable", plan.failed);
|
|
81
|
+
if ("start" in plan && plan.start === "tailscale") return unusable("eas-metro-unreachable", "metro.tunnel is tailscale, which an EAS Simulator cannot reach");
|
|
82
|
+
if ("expoTunnel" in plan && readTunnel(root)?.kind !== "expo") return unusable("eas-metro-unreachable", "Metro has no Expo tunnel; run stim start --remote first");
|
|
83
|
+
}
|
|
84
|
+
return parseSimulatorAvailability(await availability(bin.file));
|
|
85
|
+
}
|
|
86
|
+
//#endregion
|
|
87
|
+
export { checkEasFallback as t };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { C as reportSignal, t as getExecutor } from "./exec-
|
|
2
|
-
import { M as withDirLock$1, N as withDirLockAsync$1, w as workspaceAgentDeviceDir } from "./workspace-state-
|
|
3
|
-
import { G as projectDeviceSlots, V as deviceSlotKey } from "./config-
|
|
4
|
-
import { a as formatElapsed, o as formatLongDuration, r as clockTime, u as plural } from "./command-output-
|
|
5
|
-
import { n as isInsideProject } from "./metro-
|
|
6
|
-
import { r as cdpEndpoint } from "./state-
|
|
1
|
+
import { C as reportSignal, t as getExecutor } from "./exec-aULwtNly.mjs";
|
|
2
|
+
import { M as withDirLock$1, N as withDirLockAsync$1, w as workspaceAgentDeviceDir } from "./workspace-state-kIZrdlSg.mjs";
|
|
3
|
+
import { G as projectDeviceSlots, V as deviceSlotKey } from "./config-Cn94Jc0g.mjs";
|
|
4
|
+
import { a as formatElapsed, o as formatLongDuration, r as clockTime, u as plural } from "./command-output-C8R1KIvi.mjs";
|
|
5
|
+
import { n as isInsideProject } from "./metro-BnhXV2Mj.mjs";
|
|
6
|
+
import { r as cdpEndpoint } from "./state-B2QJbDwz.mjs";
|
|
7
7
|
import { accessSync, constants, existsSync, mkdirSync, realpathSync, renameSync, rmSync, statSync, writeFileSync } from "node:fs";
|
|
8
8
|
import { delimiter, dirname, join, resolve } from "node:path";
|
|
9
9
|
import { workspaceId } from "@stim-cli/core";
|
|
10
|
-
import { ACTIVITY_RECENCY_BASES, easMachineStateRoot, easMachineStateRoot as easMachineStateRoot$1, easSessionLedgerFile, easSessionLedgerLock, readEasSessionLedger, readEasSessionLedger as readEasSessionLedger$1, validEasSessionClaim } from "@stim-cli/core/state";
|
|
10
|
+
import { ACTIVITY_RECENCY_BASES, easMachineStateRoot, easMachineStateRoot as easMachineStateRoot$1, easSessionLedgerFile, easSessionLedgerLock, loadState, readEasSessionLedger, readEasSessionLedger as readEasSessionLedger$1, validEasSessionClaim } from "@stim-cli/core/state";
|
|
11
11
|
import { basename as basename$1, sep as sep$1 } from "path";
|
|
12
12
|
//#region src/status.ts
|
|
13
13
|
const IOS_SIM_MB = 1500;
|
|
@@ -348,6 +348,35 @@ function capacity(states, totalMemoryMb) {
|
|
|
348
348
|
overCapacity: Boolean(totalMemoryMb && committedMb > totalMemoryMb * .6)
|
|
349
349
|
};
|
|
350
350
|
}
|
|
351
|
+
/** `capacity.load` from a load reading, the `server.maxLoadPerCore` it is busy at, and the configured limit. */
|
|
352
|
+
function capacityLoad({ cpus, loadPerCore }, busyAt, limit) {
|
|
353
|
+
return {
|
|
354
|
+
cpus,
|
|
355
|
+
loadPerCore,
|
|
356
|
+
busyAt,
|
|
357
|
+
limit,
|
|
358
|
+
state: loadState(loadPerCore, busyAt, limit)
|
|
359
|
+
};
|
|
360
|
+
}
|
|
361
|
+
function loadLine({ loadPerCore, busyAt, limit }) {
|
|
362
|
+
return `load ${loadPerCore}/core (busy at ${busyAt}${limit === null ? "" : `, holding at ${limit}`})`;
|
|
363
|
+
}
|
|
364
|
+
/** The plain status lines for the `concurrency.maxBuilds` and `concurrency.maxDevices` caps that are set. */
|
|
365
|
+
function slotUsageLines({ builds, devices }) {
|
|
366
|
+
const lines = [];
|
|
367
|
+
if (builds) {
|
|
368
|
+
const holders = builds.holders.map((holder) => holder.unresolved ? `slot ${holder.slot} unresolved` : holder.client ? `offloaded for ${holder.client}` : holder.workspace ? basename$1(holder.workspace) : `slot ${holder.slot}`);
|
|
369
|
+
lines.push(`builds ${builds.inUse}/${builds.max} (concurrency.maxBuilds)${holders.length ? `: ${holders.join(", ")}` : ""}`);
|
|
370
|
+
}
|
|
371
|
+
if (devices) {
|
|
372
|
+
if (devices.inUse === null) lines.push(`devices ?/${devices.max} (concurrency.maxDevices): ${devices.unknown ?? "not counted"}`);
|
|
373
|
+
else {
|
|
374
|
+
const holders = devices.holders.map((holder) => `${holder.label} ${holder.platform}${holder.slot && holder.slot !== "default" ? ` [${holder.slot}]` : ""}${holder.booting ? " (booting)" : ""}`);
|
|
375
|
+
lines.push(`devices ${devices.inUse}/${devices.max} (concurrency.maxDevices)${holders.length ? `: ${holders.join(", ")}` : ""}`);
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
return lines;
|
|
379
|
+
}
|
|
351
380
|
function parseDfFree(output) {
|
|
352
381
|
const lines = String(output || "").trim().split("\n");
|
|
353
382
|
if (lines.length < 2) return null;
|
|
@@ -724,4 +753,4 @@ async function removeEasSessionClaimAsync(sessionId, root = easMachineStateRoot(
|
|
|
724
753
|
return withDirLockAsync$1(easSessionLedgerLock(root), () => removeEasSessionClaim(sessionId, root, when), { signal });
|
|
725
754
|
}
|
|
726
755
|
//#endregion
|
|
727
|
-
export {
|
|
756
|
+
export { poolLine as A, diskLine as C, loadLine as D, gitSummaryText as E, tightVolumes as F, unprovisionedWorktrees as I, withWebFacts as L, remoteDeviceState as M, slotUsageLines as N, metroReverseTargets as O, statusActivity as P, deviceLeaseStates as S, formatSpace as T, addReverseMissingIssue as _, removeEasSessionClaim as a, capacityLoad as b, inspectStimVersions as c, parseWatchRoots as d, parseWatchmanClients as f, activityLabel as g, RECENT_LAUNCH_MS as h, recordEasSessionClaim as i, remoteDeviceLine as j, parseDfFree as k, parseSubscriberNames as l, runWatchman as m, easMachineStateRoot$1 as n, removeEasSessionClaimAsync as o, parseWatchmanPid as p, readEasSessionLedger$1 as r, compareStimVersions as s, assertEasMachineRootWritable as t, parseTriggerCount as u, applyMachineMemory as v, environmentState as w, deviceLeaseLines as x, capacity as y };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { t as getExecutor } from "./exec-
|
|
2
|
-
import { r as readWorkspaceState$1 } from "./workspace-state-
|
|
3
|
-
import { H as deviceSlotPlatforms, V as deviceSlotKey, p as getProject } from "./config-
|
|
4
|
-
import { v as launchErrorPreview } from "./command-output-
|
|
5
|
-
import { I as readWorkspaceLaunches } from "./project-
|
|
6
|
-
import { o as androidHome, u as androidToolCwd } from "./android-
|
|
7
|
-
import { d as resolveProjectMetro } from "./metro-
|
|
8
|
-
import { i as parseLogcatLine, n as androidLogGroups, r as isAndroidCrashText } from "./android-
|
|
9
|
-
import { S as parseLease, v as deviceLeasePath, y as fileLeaseIo } from "./activity-
|
|
10
|
-
import { r as deviceConsoleLevel } from "./ios-device-
|
|
1
|
+
import { t as getExecutor } from "./exec-aULwtNly.mjs";
|
|
2
|
+
import { r as readWorkspaceState$1 } from "./workspace-state-kIZrdlSg.mjs";
|
|
3
|
+
import { H as deviceSlotPlatforms, V as deviceSlotKey, p as getProject } from "./config-Cn94Jc0g.mjs";
|
|
4
|
+
import { v as launchErrorPreview } from "./command-output-C8R1KIvi.mjs";
|
|
5
|
+
import { I as readWorkspaceLaunches } from "./project-Sui52ywT.mjs";
|
|
6
|
+
import { o as androidHome, u as androidToolCwd } from "./android-CsPs-7Mg.mjs";
|
|
7
|
+
import { d as resolveProjectMetro } from "./metro-BnhXV2Mj.mjs";
|
|
8
|
+
import { i as parseLogcatLine, n as androidLogGroups, r as isAndroidCrashText } from "./android-D577ApKG.mjs";
|
|
9
|
+
import { S as parseLease, v as deviceLeasePath, y as fileLeaseIo } from "./activity-DRMg4_mD.mjs";
|
|
10
|
+
import { r as deviceConsoleLevel } from "./ios-device-CiBA-er9.mjs";
|
|
11
11
|
import { createHash, randomUUID } from "node:crypto";
|
|
12
12
|
import { existsSync, readFileSync, renameSync } from "node:fs";
|
|
13
13
|
import { homedir } from "node:os";
|
|
@@ -88,6 +88,28 @@ function parseIosCrash(text, target) {
|
|
|
88
88
|
return null;
|
|
89
89
|
}
|
|
90
90
|
}
|
|
91
|
+
/**
|
|
92
|
+
* The symbol dyld could not bind when one image of the app bundle needs a symbol that another image of the same
|
|
93
|
+
* bundle does not export. Only the bundle's own bytes decide this, so a stored app that does it never launches.
|
|
94
|
+
*/
|
|
95
|
+
function bundleBindFailure(record) {
|
|
96
|
+
if (record.event !== "native_crash" || typeof record.rawReport !== "string") return null;
|
|
97
|
+
try {
|
|
98
|
+
const termination = JSON.parse(record.rawReport.slice(record.rawReport.indexOf("\n") + 1)).termination;
|
|
99
|
+
if (termination?.namespace !== "DYLD") return null;
|
|
100
|
+
const bundles = /* @__PURE__ */ new Map();
|
|
101
|
+
let symbol;
|
|
102
|
+
for (const line of termination.reasons ?? []) {
|
|
103
|
+
symbol ??= /^Symbol not found: (\S+)/.exec(line)?.[1];
|
|
104
|
+
const image = /^(Referenced from|Expected in):\s+<[^>]+> (.*?\.app)\//.exec(line);
|
|
105
|
+
if (image?.[1] && image[2]) bundles.set(image[1], image[2]);
|
|
106
|
+
}
|
|
107
|
+
const bundle = bundles.get("Referenced from");
|
|
108
|
+
return symbol && bundle && bundle === bundles.get("Expected in") ? symbol : null;
|
|
109
|
+
} catch {
|
|
110
|
+
return null;
|
|
111
|
+
}
|
|
112
|
+
}
|
|
91
113
|
/** Extracts crash-buffer groups only when their own process header names the target app. */
|
|
92
114
|
function parseAndroidCrashes(text, target, clockOffsetMs) {
|
|
93
115
|
const entries = text.split("\n").map((line) => parseLogcatLine(line, { clockOffsetMs })).filter((record) => record !== null && Number(record.ts) >= target.since && Number(record.ts) <= (target.until ?? Infinity));
|
|
@@ -310,6 +332,22 @@ async function simulatorFatalConsole(target, signal) {
|
|
|
310
332
|
signal?.throwIfAborted();
|
|
311
333
|
return records;
|
|
312
334
|
}
|
|
335
|
+
async function androidCrashClockOffset(deviceId, signal) {
|
|
336
|
+
const before = Date.now();
|
|
337
|
+
const clock = (await crashCommand("adb", [
|
|
338
|
+
"-s",
|
|
339
|
+
deviceId,
|
|
340
|
+
"shell",
|
|
341
|
+
"date",
|
|
342
|
+
"+%s%3N"
|
|
343
|
+
], {
|
|
344
|
+
timeoutMs: 1e3,
|
|
345
|
+
cwd: androidToolCwd()
|
|
346
|
+
}, signal))?.trim();
|
|
347
|
+
const after = Date.now();
|
|
348
|
+
if (!/^\d{13}$/.test(clock ?? "") || after < before || after - before > 1e3) return null;
|
|
349
|
+
return Math.round((before + after) / 2) - Number(clock);
|
|
350
|
+
}
|
|
313
351
|
/** Reads platform crash evidence without starting, stopping or modifying a device. */
|
|
314
352
|
async function captureNativeCrashes(target, logsDir, signal, env = process.env) {
|
|
315
353
|
signal?.throwIfAborted();
|
|
@@ -343,20 +381,8 @@ async function captureNativeCrashes(target, logsDir, signal, env = process.env)
|
|
|
343
381
|
}
|
|
344
382
|
if (nativeReports.length) records = nativeReports;
|
|
345
383
|
} else if (target.platform === "android") {
|
|
346
|
-
const
|
|
347
|
-
|
|
348
|
-
"-s",
|
|
349
|
-
target.deviceId,
|
|
350
|
-
"shell",
|
|
351
|
-
"date",
|
|
352
|
-
"+%s%3N"
|
|
353
|
-
], {
|
|
354
|
-
timeoutMs: 1e3,
|
|
355
|
-
cwd: androidToolCwd()
|
|
356
|
-
}, signal))?.trim();
|
|
357
|
-
const after = Date.now();
|
|
358
|
-
if (!/^\d{13}$/.test(clock ?? "") || after < before || after - before > 1e3) return [];
|
|
359
|
-
const offset = Math.round((before + after) / 2) - Number(clock);
|
|
384
|
+
const offset = target.clockOffsetMs === void 0 ? await androidCrashClockOffset(target.deviceId, signal) : target.clockOffsetMs;
|
|
385
|
+
if (offset === null) return [];
|
|
360
386
|
const text = await crashCommand("adb", [
|
|
361
387
|
"-s",
|
|
362
388
|
target.deviceId,
|
|
@@ -722,4 +748,4 @@ async function errorDiagnostics(input, { root, logsDir, port, allowRequest = fal
|
|
|
722
748
|
return merged;
|
|
723
749
|
}
|
|
724
750
|
//#endregion
|
|
725
|
-
export {
|
|
751
|
+
export { captureNativeCrashes as a, simulatorConsolePaths as c, bundleBindFailure as i, IOS_CRASH_REPORT_RETRY as n, captureWorkspaceCrashes as o, androidCrashClockOffset as r, printNativeCrashReport as s, errorDiagnostics as t };
|
|
@@ -4,7 +4,7 @@ import { existsSync, rmSync } from "node:fs";
|
|
|
4
4
|
import { availableParallelism, loadavg, tmpdir } from "node:os";
|
|
5
5
|
import { join } from "node:path";
|
|
6
6
|
import { ambientContext, ambientEnv } from "@stim-cli/core";
|
|
7
|
-
import { createDebugLog, runId } from "@stim-cli/core/state";
|
|
7
|
+
import { createDebugLog, redactArgv, redactCommandLine, runId, trace } from "@stim-cli/core/state";
|
|
8
8
|
import { basename as basename$1, delimiter as delimiter$1, join as join$1, resolve as resolve$1 } from "path";
|
|
9
9
|
import { execSync } from "child_process";
|
|
10
10
|
import spawn from "cross-spawn";
|
|
@@ -876,12 +876,37 @@ function outcomeOf(error) {
|
|
|
876
876
|
};
|
|
877
877
|
}
|
|
878
878
|
let executionId = 0;
|
|
879
|
-
function
|
|
879
|
+
function fileSpan(file, args, opts) {
|
|
880
|
+
const program = basename$1(file);
|
|
881
|
+
const argv = redactArgv(args ?? [], opts.redact, file);
|
|
882
|
+
const first = argv[0];
|
|
883
|
+
return {
|
|
884
|
+
name: first && /^[a-z][a-z0-9-]{1,23}$/.test(first) ? `${program} ${first}` : program,
|
|
885
|
+
args: {
|
|
886
|
+
argv: [file, ...argv],
|
|
887
|
+
...opts.cwd ? { cwd: opts.cwd } : {}
|
|
888
|
+
}
|
|
889
|
+
};
|
|
890
|
+
}
|
|
891
|
+
function commandSpan(cmd, opts) {
|
|
892
|
+
return {
|
|
893
|
+
name: programOf(cmd.replace(/^\s*(?:[A-Za-z_][A-Za-z0-9_]*=\S*\s+)+/, "")).replace(/["']/g, ""),
|
|
894
|
+
args: {
|
|
895
|
+
command: redactCommandLine(cmd, opts.redact),
|
|
896
|
+
...opts.cwd ? { cwd: opts.cwd } : {}
|
|
897
|
+
}
|
|
898
|
+
};
|
|
899
|
+
}
|
|
900
|
+
function timedSync(fn, program, span) {
|
|
880
901
|
return (...args) => {
|
|
881
|
-
|
|
902
|
+
const logging = debugLog.enabled();
|
|
903
|
+
const tracing = trace.enabled();
|
|
904
|
+
if (!logging && !tracing) return fn(...args);
|
|
882
905
|
const id = ++executionId;
|
|
883
906
|
const name = program(...args);
|
|
884
907
|
const started = performance.now();
|
|
908
|
+
const traced = tracing ? span(...args) : null;
|
|
909
|
+
const end = traced ? trace.beginExec(traced.name, traced.args) : null;
|
|
885
910
|
debugLog.log("exec.start", {
|
|
886
911
|
program: name,
|
|
887
912
|
executionId: id
|
|
@@ -894,6 +919,7 @@ function timedSync(fn, program) {
|
|
|
894
919
|
ms: Math.round(performance.now() - started),
|
|
895
920
|
ok: true
|
|
896
921
|
});
|
|
922
|
+
end?.({ ok: true });
|
|
897
923
|
return out;
|
|
898
924
|
} catch (error) {
|
|
899
925
|
debugLog.log("exec", {
|
|
@@ -902,19 +928,24 @@ function timedSync(fn, program) {
|
|
|
902
928
|
ms: Math.round(performance.now() - started),
|
|
903
929
|
...outcomeOf(error)
|
|
904
930
|
});
|
|
931
|
+
end?.(outcomeOf(error));
|
|
905
932
|
throw error;
|
|
906
933
|
}
|
|
907
934
|
};
|
|
908
935
|
}
|
|
909
936
|
let active = {
|
|
910
937
|
...defaultExecutor,
|
|
911
|
-
run: timedSync((cmd, opts) => defaultExecutor.run(cmd, opts), programOf),
|
|
912
|
-
runFile: timedSync((file, args, opts) => defaultExecutor.runFile(file, args, opts), (file) => basename$1(file)),
|
|
938
|
+
run: timedSync((cmd, opts) => defaultExecutor.run(cmd, opts), programOf, (cmd, opts) => commandSpan(cmd, opts)),
|
|
939
|
+
runFile: timedSync((file, args, opts) => defaultExecutor.runFile(file, args, opts), (file) => basename$1(file), (file, args, opts) => fileSpan(file, args, opts)),
|
|
913
940
|
async runFileAsync(file, args, opts) {
|
|
914
|
-
|
|
941
|
+
const logging = debugLog.enabled();
|
|
942
|
+
const tracing = trace.enabled();
|
|
943
|
+
if (!logging && !tracing) return defaultExecutor.runFileAsync(file, args, opts);
|
|
915
944
|
const id = ++executionId;
|
|
916
945
|
const name = basename$1(file);
|
|
917
946
|
const started = performance.now();
|
|
947
|
+
const traced = tracing ? fileSpan(file, args, opts) : null;
|
|
948
|
+
const end = traced ? trace.beginExec(traced.name, traced.args) : null;
|
|
918
949
|
debugLog.log("exec.start", {
|
|
919
950
|
program: name,
|
|
920
951
|
executionId: id
|
|
@@ -927,6 +958,7 @@ let active = {
|
|
|
927
958
|
ms: Math.round(performance.now() - started),
|
|
928
959
|
ok: true
|
|
929
960
|
});
|
|
961
|
+
end?.({ ok: true });
|
|
930
962
|
return out;
|
|
931
963
|
} catch (error) {
|
|
932
964
|
debugLog.log("exec", {
|
|
@@ -935,8 +967,27 @@ let active = {
|
|
|
935
967
|
ms: Math.round(performance.now() - started),
|
|
936
968
|
...outcomeOf(error)
|
|
937
969
|
});
|
|
970
|
+
end?.(outcomeOf(error));
|
|
938
971
|
throw error;
|
|
939
972
|
}
|
|
973
|
+
},
|
|
974
|
+
spawn(cmd, args, opts) {
|
|
975
|
+
const child = defaultExecutor.spawn(cmd, args, opts);
|
|
976
|
+
if (!trace.enabled()) return child;
|
|
977
|
+
const { name, args: spanArgs } = fileSpan(cmd, args, {
|
|
978
|
+
timeoutMs: "unbounded",
|
|
979
|
+
...typeof opts?.cwd === "string" ? { cwd: opts.cwd } : {}
|
|
980
|
+
});
|
|
981
|
+
const end = trace.beginExec(name, {
|
|
982
|
+
...spanArgs,
|
|
983
|
+
spawned: true
|
|
984
|
+
});
|
|
985
|
+
child.once("close", (exit, signal) => end({
|
|
986
|
+
ok: exit === 0,
|
|
987
|
+
...exit !== null ? { exit } : {},
|
|
988
|
+
...signal ? { signal } : {}
|
|
989
|
+
}));
|
|
990
|
+
return child;
|
|
940
991
|
}
|
|
941
992
|
};
|
|
942
993
|
function getExecutor() {
|