stim 1.33.0 → 1.35.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-DTh_LxrE.mjs → acquire-artifact-0E_iw7Rf.mjs} +1 -1
- package/dist/{act-Cur4YKtK.mjs → act-CyxFP8Vj.mjs} +9 -10
- package/dist/{activity-C8kBq9w0.mjs → activity-BQpJpAjA.mjs} +2 -2
- package/dist/{agent-device-usage-output-BTRaK_up.mjs → agent-device-usage-output-BoOC3ZF9.mjs} +3 -3
- package/dist/{android-D5mCdVl2.mjs → android-CjcJE7uA.mjs} +5 -5
- package/dist/{android-BL-QqHjc.mjs → android-YRb1UzSy.mjs} +27 -29
- package/dist/{android-project-BDlPnfmL.d.mts → android-project-DhO6el8N.d.mts} +1 -1
- package/dist/api.d.mts +1 -1
- package/dist/api.mjs +21 -21
- package/dist/{artifact-BufzdGbT.mjs → artifact-2NIRz6SC.mjs} +19 -15
- package/dist/{artifact-BMjubIP2.mjs → artifact-BG4h_WTC.mjs} +11 -11
- package/dist/{auto-placement-D7P98glJ.mjs → auto-placement-CBdWa87P.mjs} +4 -5
- package/dist/{browser-web-C74et-Nv.mjs → browser-web-CNlRugJv.mjs} +5 -5
- package/dist/{build-DFBGWOTc.mjs → build-CNE3Wo5-.mjs} +15 -16
- package/dist/build-artifact-cache-D7B6seMj.mjs +174 -0
- package/dist/build-artifact-cache.d.mts +25 -0
- package/dist/build-artifact-cache.mjs +2 -0
- package/dist/{build-cache-Cqj4FGnX.mjs → build-cache-_fkewiwH.mjs} +6 -1
- package/dist/{build-plan-T3Hi24ax.mjs → build-plan-BSgR9yKo.mjs} +5 -5
- package/dist/{cli-B2YSjc9s.mjs → cli-DK24VzHi.mjs} +17 -17
- package/dist/cli.mjs +1 -1
- package/dist/{client-0_Mnfz0a.mjs → client-Dy0eJJtz.mjs} +49 -11
- package/dist/{command-output-DWI9tGPU.mjs → command-output-CGxrQ3Bd.mjs} +1 -1
- package/dist/{dependencies-CgvBZbXD.mjs → dependencies-IVl2Ga2D.mjs} +27 -30
- package/dist/{dev-client-ChsHwgrn.mjs → dev-client-DDApoVvd.mjs} +2 -2
- package/dist/{device-android-B8TQP5AX.mjs → device-android-C-biM49_.mjs} +3 -3
- package/dist/{ccache-BXtzEL6M.mjs → device-capacity-C0PiTyRb.mjs} +1004 -63
- package/dist/device-host-worker.mjs +6 -7
- package/dist/{device-B0htCt2u.mjs → device-mOFYiHiw.mjs} +8 -8
- package/dist/{device-DOehZpyx.mjs → device-p_cp8IzW.mjs} +6 -6
- package/dist/{device-pool-DP4sCeCC.mjs → device-pool-nsMvt2X2.mjs} +2 -2
- package/dist/{device-provision-CnNOIxCF.mjs → device-provision-BYYJuRKZ.mjs} +7 -7
- package/dist/{doctor-C6Xn96RS.mjs → doctor-BBAb8NLe.mjs} +1 -1
- package/dist/{doctor-9GrW5YSP.mjs → doctor-BptE4PaK.mjs} +10 -11
- package/dist/{doctor-nRLBoajo.mjs → doctor-RosbBfTV.mjs} +11 -12
- package/dist/doctor-fingerprint.mjs +1 -1
- package/dist/{doctor-watchman-CDhpC3Oh.mjs → doctor-watchman-CKOnCINh.mjs} +2 -2
- package/dist/{eas-build-CpJ4h9tG.mjs → eas-build-BxJdzQnF.mjs} +2 -2
- package/dist/{eas-fallback-B3z5nL1g.mjs → eas-fallback-DU2WDF8r.mjs} +2 -2
- package/dist/{eas-session-ledger-Bspy-VJQ.mjs → eas-session-ledger-DCUfh6m7.mjs} +1 -1
- package/dist/{error-diagnostics-DoLGklYX.mjs → error-diagnostics-D6wlK-yX.mjs} +3 -3
- package/dist/{gc-DolXpMSB.mjs → gc-BUkonUfz.mjs} +10 -10
- package/dist/{gc-BWoOp9q7.mjs → gc-CvMEytXz.mjs} +2 -2
- package/dist/{guide-CmZB0GtP.mjs → guide-BWozWG7D.mjs} +25 -15
- package/dist/{hosted-android-ByG-ICuh.mjs → hosted-android-y6K3DKQT.mjs} +2 -2
- package/dist/{hosted-client-D19Lv0tg.mjs → hosted-client-Bb89P6an.mjs} +2 -2
- package/dist/{hosted-logs-D7anR6Dk.mjs → hosted-logs-DYPsnWMF.mjs} +2 -2
- package/dist/{hosted-logs-sync-D182b1eJ.mjs → hosted-logs-sync-DfUJ2GpF.mjs} +4 -4
- package/dist/{hosted-macos-D0DDQxvl.mjs → hosted-macos-DsEzYVY_.mjs} +4 -4
- package/dist/{hosted-native-BzXIy97W.mjs → hosted-native-C9xQYYFb.mjs} +4 -4
- package/dist/{ios-AdhPKXO3.mjs → ios-BCKxjpRp.mjs} +8 -8
- package/dist/{ios-dbXzjTxx.mjs → ios-FhMkDfNC.mjs} +19 -21
- package/dist/{ios-device-DXbHZfFe.mjs → ios-device-DMOnaH5n.mjs} +1 -1
- package/dist/{ios-project-BzfLigfh.mjs → ios-project-PXBDoaii.mjs} +5 -5
- package/dist/ios-signing-CCFNjjWU.mjs +202 -0
- package/dist/{js-swap-EDVOJmqx.mjs → js-swap-07ikLRJJ.mjs} +3 -3
- package/dist/{launch-CKHpthsw.mjs → launch-CTq5gBim.mjs} +13 -13
- package/dist/{lightened-Cv4ToJRX.mjs → lightened-DikgC3-S.mjs} +2 -2
- package/dist/{logs-IagR9dWI.mjs → logs-DwI3Rkpf.mjs} +5 -5
- package/dist/{logs-DCQ3_tGS.mjs → logs-YDMfEohb.mjs} +3 -3
- package/dist/{macos-Ch7vuM-G.mjs → macos-BoNM-l6f.mjs} +14 -14
- package/dist/{macos-pc0aVVbN.mjs → macos-C_e9f5-5.mjs} +1 -1
- package/dist/maintenance-run.mjs +3 -3
- package/dist/{native-android-B3CEDq4R.mjs → native-android-Mv4YTrVN.mjs} +11 -11
- package/dist/{native-gradle-artifact-inputs-BLnO2hHR.mjs → native-gradle-artifact-inputs-C_TU6wPq.mjs} +2 -2
- package/dist/{native-runtime-e1OU8gEN.mjs → native-runtime-oDqT4UES.mjs} +3 -3
- package/dist/{native-xcode-inputs-DL3ETb8s.mjs → native-xcode-inputs-DsozghTX.mjs} +1 -1
- package/dist/{native-xcode-ios-D4e8k2Jy.mjs → native-xcode-ios-UXnH9NRY.mjs} +13 -13
- package/dist/offload-worker.d.mts +6 -1
- package/dist/offload-worker.mjs +40 -15
- package/dist/{phone-reverses-rvyxW1Fl.mjs → phone-reverses-B9WyCBKQ.mjs} +1 -1
- package/dist/{placement-log-nnGnu8mo.mjs → placement-log-D0DZLcJk.mjs} +1 -1
- package/dist/{plan-placement-D3JD-T-K.mjs → plan-placement-DqmLrWoX.mjs} +4 -4
- package/dist/{ports-CZJJfJ8Q.mjs → ports-C1_1Qgdy.mjs} +1 -1
- package/dist/{prebuild-Bhs7TTcz.mjs → prebuild-BptrXmh_.mjs} +6 -6
- package/dist/{project-DWEXiBA9.mjs → project-Dqqj3IkW.mjs} +11 -11
- package/dist/{react-native-android-C6Y270GS.mjs → react-native-android-Bsm_o4A8.mjs} +18 -18
- package/dist/{react-native-build-DaPfzf_e.mjs → react-native-build-BTUcE926.mjs} +4 -4
- package/dist/{react-native-doctor-DGMPxkPS.mjs → react-native-doctor-CfsCTKZt.mjs} +4 -4
- package/dist/{react-native-ios-dX48_92n.mjs → react-native-ios-_cK2pjZn.mjs} +25 -19
- package/dist/{reload-BGwblBJ9.mjs → reload-CXgce4Yo.mjs} +1 -1
- package/dist/{reload-DsOByDfy.mjs → reload-DsTMtMDU.mjs} +6 -6
- package/dist/{remote-D0uJZ76R.mjs → remote-BsmYHUxH.mjs} +6 -6
- package/dist/{result-DuimMZKJ.mjs → result-DK6nTO-M.mjs} +9 -10
- package/dist/{server-command-BC0EgMfY.mjs → server-command-Cu2w-UjB.mjs} +2 -2
- package/dist/{server-expo-15RjL0ir.mjs → server-expo-CjQwxvIi.mjs} +1 -1
- package/dist/server-expo-DbSypdNl.mjs +2 -0
- package/dist/{settings-CuP55ieT.mjs → settings-DcmVICCn.mjs} +2 -2
- package/dist/{settings-payload-BIGGQ3or.mjs → settings-payload-BoiFMiFq.mjs} +1 -1
- package/dist/{settings-write-D85j8mej.mjs → settings-write-B3LzEVwf.mjs} +2 -2
- package/dist/{slot-launch-D4oREwhx.mjs → slot-launch-DsQmPdlg.mjs} +2 -2
- package/dist/{stage-DKC6tDXu.mjs → stage-Dqk0qvaI.mjs} +1 -1
- package/dist/{start-BsEV4S-s.mjs → start-DIFiT2P5.mjs} +5 -5
- package/dist/{start-DfPSLc__.mjs → start-GkRBR1e3.mjs} +1 -1
- package/dist/{stats-ByEUblPr.mjs → stats-Dz08IopP.mjs} +3 -3
- package/dist/{status-C6hLlDqW.mjs → status-DhKv_e8a.mjs} +11 -12
- package/dist/{status-FP1MH9qn.mjs → status-Dost__Vn.mjs} +1 -1
- package/dist/{status-watch-D8s823CZ.mjs → status-watch-UecLnPQD.mjs} +1 -1
- package/dist/status-worker.mjs +1 -1
- package/dist/{stop-CpTy6bod.mjs → stop-CcZISot5.mjs} +2 -2
- package/dist/{stop-5LKfVv-0.mjs → stop-QFOqgICJ.mjs} +2 -2
- package/dist/{stop-BVI2-L7s.mjs → stop-vRe6TQk5.mjs} +9 -9
- package/dist/supervisor-run.mjs +7 -8
- package/dist/{support-CqyWfZZI.mjs → support-CNqJDBrH.mjs} +3 -3
- package/dist/support-DW575Dnx.mjs +2050 -0
- package/dist/{swiftpm-artifact-inputs-uq5oV7xR.mjs → swiftpm-artifact-inputs-DQTJTczX.mjs} +1 -1
- package/dist/{swiftpm-macos-BuhqYB3n.mjs → swiftpm-macos-BKczZ0k9.mjs} +4 -4
- package/dist/{toolchain-D_jotUG7.mjs → toolchain-BDlugtoh.mjs} +1 -1
- package/dist/{toolchain-s5ZmG42Z.mjs → toolchain-DRQyCvlp.mjs} +406 -8
- package/dist/web-D1m1LKEz.mjs +2 -0
- package/dist/{web-DwYCTFdh.mjs → web-TDWjHUT3.mjs} +3 -3
- package/dist/web-run.mjs +1 -1
- package/dist/{workspaces-B3ahAHZc.mjs → workspaces-CY3KSdC0.mjs} +2 -2
- package/dist/{worktree-CrjsPIs2.mjs → worktree-D6myrQ2H.mjs} +1 -1
- package/dist/{worktree-BhsML6GV.mjs → worktree-fKKe8j5M.mjs} +10 -10
- package/package.json +12 -7
- package/dist/device-capacity-BAkETfIl.mjs +0 -867
- package/dist/device-ios-DFaYFdar.mjs +0 -716
- package/dist/device-lease-run-DpiCnRbZ.mjs +0 -282
- package/dist/idle-shutdown-6i8CHoNq.mjs +0 -142
- package/dist/ios-signing-D-tSX1iF.mjs +0 -489
- package/dist/selection-xS50Mt0V.mjs +0 -791
- package/dist/server-expo-gYIypb0-.mjs +0 -2
- package/dist/support-D8OH0z98.mjs +0 -287
- package/dist/web-cCfM8kwV.mjs +0 -2
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
import { createHash, randomUUID } from "node:crypto";
|
|
2
|
+
import { createReadStream } from "node:fs";
|
|
3
|
+
import { isDeepStrictEqual } from "node:util";
|
|
4
|
+
import { basename, join } from "node:path";
|
|
5
|
+
import { reactNativeArtifactIdentity } from "@stim-cli/core";
|
|
6
|
+
import { isJsonObject } from "@stim-cli/core/state";
|
|
7
|
+
import { mkdir, readFile, rename, rm, writeFile } from "node:fs/promises";
|
|
8
|
+
import { createFilesystemFileCache } from "@stim-cli/cache";
|
|
9
|
+
//#region src/offload/build-artifact-cache.ts
|
|
10
|
+
const androidPackage = (value) => typeof value === "string" && /^[A-Za-z_][\w]*(?:\.[A-Za-z_][\w]*)+$/.test(value);
|
|
11
|
+
function gradleQueryKey(query) {
|
|
12
|
+
const { android, inputs } = query;
|
|
13
|
+
return createHash("sha256").update(JSON.stringify([
|
|
14
|
+
query.project,
|
|
15
|
+
query.sourceDigest,
|
|
16
|
+
inputs.ignored,
|
|
17
|
+
inputs.outputs,
|
|
18
|
+
android.variant,
|
|
19
|
+
android.abi === "all" ? null : android.abi,
|
|
20
|
+
android.compilerCache,
|
|
21
|
+
android.gradleBuildCache,
|
|
22
|
+
android.pch,
|
|
23
|
+
android.gradleRoot ?? null,
|
|
24
|
+
android.module ?? null
|
|
25
|
+
])).digest("hex");
|
|
26
|
+
}
|
|
27
|
+
const completedKind = (query) => "build" in query ? "swiftpm" : "sourceDigest" in query ? "gradle" : "react-native";
|
|
28
|
+
const completedKey = (query) => "sourceDigest" in query && !("build" in query) ? gradleQueryKey(query) : createHash("sha256").update(JSON.stringify(query)).digest("hex");
|
|
29
|
+
function validArtifactIdentity(value) {
|
|
30
|
+
return isJsonObject(value) && typeof value.fingerprint === "string" && value.fingerprint.length > 0 && value.fingerprint.length <= 256 && typeof value.cacheKey === "string" && value.cacheKey.length > 0 && value.cacheKey.length <= 1024;
|
|
31
|
+
}
|
|
32
|
+
async function verified(path, artifact, signal) {
|
|
33
|
+
const digest = createHash("sha256");
|
|
34
|
+
let size = 0;
|
|
35
|
+
for await (const chunk of createReadStream(path, { signal })) {
|
|
36
|
+
size += chunk.length;
|
|
37
|
+
digest.update(chunk);
|
|
38
|
+
}
|
|
39
|
+
return size === artifact.size && digest.digest("hex") === artifact.sha256;
|
|
40
|
+
}
|
|
41
|
+
/** Completed immutable archives within one authenticated client's repository area. */
|
|
42
|
+
var BuildArtifactCache = class {
|
|
43
|
+
files;
|
|
44
|
+
directory;
|
|
45
|
+
constructor(directory) {
|
|
46
|
+
this.directory = directory;
|
|
47
|
+
this.files = createFilesystemFileCache(join(directory, "files"));
|
|
48
|
+
}
|
|
49
|
+
record(identity) {
|
|
50
|
+
const key = createHash("sha256").update(JSON.stringify([identity.fingerprint, identity.cacheKey])).digest("hex");
|
|
51
|
+
return join(this.directory, `${key}.json`);
|
|
52
|
+
}
|
|
53
|
+
async lookup(identity, signal) {
|
|
54
|
+
signal.throwIfAborted();
|
|
55
|
+
try {
|
|
56
|
+
const record = JSON.parse(await readFile(this.record(identity), {
|
|
57
|
+
encoding: "utf8",
|
|
58
|
+
signal
|
|
59
|
+
}));
|
|
60
|
+
if (!isJsonObject(record) || record.fingerprint !== identity.fingerprint || record.cacheKey !== identity.cacheKey || typeof record.name !== "string" || basename(record.name) !== record.name || !(record.name.endsWith(".app") || record.name.endsWith(".apk") && androidPackage(record.androidPackage)) || typeof record.size !== "number" || !Number.isSafeInteger(record.size) || record.size <= 0 || typeof record.sha256 !== "string" || !/^[a-f0-9]{64}$/.test(record.sha256)) return null;
|
|
61
|
+
if ((await this.files.stat({
|
|
62
|
+
key: record.sha256,
|
|
63
|
+
signal
|
|
64
|
+
}))?.size !== record.size) return null;
|
|
65
|
+
return {
|
|
66
|
+
...identity,
|
|
67
|
+
name: record.name,
|
|
68
|
+
size: record.size,
|
|
69
|
+
sha256: record.sha256,
|
|
70
|
+
...record.name.endsWith(".apk") && androidPackage(record.androidPackage) ? { androidPackage: record.androidPackage } : {}
|
|
71
|
+
};
|
|
72
|
+
} catch {
|
|
73
|
+
signal.throwIfAborted();
|
|
74
|
+
return null;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
async store(identity, parameters, archive, artifact, signal) {
|
|
78
|
+
if (!validArtifactIdentity(identity) || !await verified(archive, artifact, signal)) return false;
|
|
79
|
+
await this.files.store({
|
|
80
|
+
key: artifact.sha256,
|
|
81
|
+
sourcePath: archive,
|
|
82
|
+
overwrite: true,
|
|
83
|
+
signal
|
|
84
|
+
});
|
|
85
|
+
await mkdir(this.directory, {
|
|
86
|
+
recursive: true,
|
|
87
|
+
mode: 448
|
|
88
|
+
});
|
|
89
|
+
const temporary = join(this.directory, `${randomUUID()}.partial`);
|
|
90
|
+
try {
|
|
91
|
+
await writeFile(temporary, JSON.stringify({
|
|
92
|
+
...identity,
|
|
93
|
+
...artifact,
|
|
94
|
+
parameters
|
|
95
|
+
}), {
|
|
96
|
+
mode: 384,
|
|
97
|
+
signal
|
|
98
|
+
});
|
|
99
|
+
signal.throwIfAborted();
|
|
100
|
+
await rename(temporary, this.record(identity));
|
|
101
|
+
return true;
|
|
102
|
+
} finally {
|
|
103
|
+
await rm(temporary, { force: true });
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
async storeCompleted(query, identity, receipt, archive, artifact, signal) {
|
|
107
|
+
if (!("build" in query) && ("sourceDigest" in query || query.platform === "android")) {
|
|
108
|
+
if (!artifact.name.endsWith(".apk") || !androidPackage(artifact.androidPackage)) return;
|
|
109
|
+
} else if (!artifact.name.endsWith(".app")) return;
|
|
110
|
+
if (!await this.store(identity, { ...query }, archive, artifact, signal)) return;
|
|
111
|
+
const key = completedKey(query);
|
|
112
|
+
const temporary = join(this.directory, `${randomUUID()}.partial`);
|
|
113
|
+
try {
|
|
114
|
+
await writeFile(temporary, JSON.stringify({
|
|
115
|
+
query: key,
|
|
116
|
+
receipt
|
|
117
|
+
}), {
|
|
118
|
+
mode: 384,
|
|
119
|
+
signal
|
|
120
|
+
});
|
|
121
|
+
signal.throwIfAborted();
|
|
122
|
+
await rename(temporary, join(this.directory, `${key}.${completedKind(query)}.json`));
|
|
123
|
+
} finally {
|
|
124
|
+
await rm(temporary, { force: true });
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
async completedRecord(query, signal) {
|
|
128
|
+
signal.throwIfAborted();
|
|
129
|
+
try {
|
|
130
|
+
const key = completedKey(query);
|
|
131
|
+
const record = JSON.parse(await readFile(join(this.directory, `${key}.${completedKind(query)}.json`), {
|
|
132
|
+
encoding: "utf8",
|
|
133
|
+
signal
|
|
134
|
+
}));
|
|
135
|
+
return isJsonObject(record) && record.query === key && isJsonObject(record.receipt) ? record : null;
|
|
136
|
+
} catch {
|
|
137
|
+
signal.throwIfAborted();
|
|
138
|
+
return null;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
async receipt(query, signal) {
|
|
142
|
+
return (await this.completedRecord(query, signal))?.receipt ?? null;
|
|
143
|
+
}
|
|
144
|
+
async lookupReactNative(query, signal) {
|
|
145
|
+
const record = await this.completedRecord(query, signal);
|
|
146
|
+
if (!record || !isJsonObject(record.receipt) || !isJsonObject(record.receipt.toolchain) || !isDeepStrictEqual(record.receipt.query, query)) return null;
|
|
147
|
+
return this.lookup(reactNativeArtifactIdentity({
|
|
148
|
+
query,
|
|
149
|
+
toolchain: record.receipt.toolchain
|
|
150
|
+
}), signal);
|
|
151
|
+
}
|
|
152
|
+
async fetch(identity, destinationDir, signal) {
|
|
153
|
+
const artifact = await this.lookup(identity, signal);
|
|
154
|
+
if (!artifact) return null;
|
|
155
|
+
const path = await this.files.resolve({
|
|
156
|
+
key: artifact.sha256,
|
|
157
|
+
destinationDir,
|
|
158
|
+
signal
|
|
159
|
+
});
|
|
160
|
+
if (!path) return null;
|
|
161
|
+
let complete = false;
|
|
162
|
+
try {
|
|
163
|
+
complete = await verified(path, artifact, signal);
|
|
164
|
+
return complete ? {
|
|
165
|
+
path,
|
|
166
|
+
artifact
|
|
167
|
+
} : null;
|
|
168
|
+
} finally {
|
|
169
|
+
if (!complete) await rm(path, { force: true });
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
};
|
|
173
|
+
//#endregion
|
|
174
|
+
export { validArtifactIdentity as n, BuildArtifactCache as t };
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { BuildArtifactIdentity, BuildArtifactResult, BuildGradleArtifactQuery, BuildReactNativeArtifactQuery, BuildSwiftpmArtifactQuery, CachedBuildArtifact } from "@stim-cli/core/protocol";
|
|
2
|
+
//#region src/offload/build-artifact-cache.d.ts
|
|
3
|
+
type CompletedQuery = BuildGradleArtifactQuery | BuildReactNativeArtifactQuery | BuildSwiftpmArtifactQuery;
|
|
4
|
+
declare function validArtifactIdentity(value: unknown): value is BuildArtifactIdentity;
|
|
5
|
+
/** Completed immutable archives within one authenticated client's repository area. */
|
|
6
|
+
declare class BuildArtifactCache {
|
|
7
|
+
private readonly files;
|
|
8
|
+
private readonly directory;
|
|
9
|
+
constructor(directory: string);
|
|
10
|
+
private record;
|
|
11
|
+
lookup(identity: BuildArtifactIdentity, signal: AbortSignal): Promise<CachedBuildArtifact | null>;
|
|
12
|
+
store(identity: BuildArtifactIdentity, parameters: Record<string, unknown>, archive: string, artifact: BuildArtifactResult, signal: AbortSignal): Promise<boolean>;
|
|
13
|
+
storeCompleted(query: CompletedQuery, identity: BuildArtifactIdentity, receipt: unknown, archive: string, artifact: BuildArtifactResult & {
|
|
14
|
+
androidPackage?: string;
|
|
15
|
+
}, signal: AbortSignal): Promise<void>;
|
|
16
|
+
private completedRecord;
|
|
17
|
+
receipt(query: CompletedQuery, signal: AbortSignal): Promise<unknown | null>;
|
|
18
|
+
lookupReactNative(query: BuildReactNativeArtifactQuery, signal: AbortSignal): Promise<CachedBuildArtifact | null>;
|
|
19
|
+
fetch(identity: BuildArtifactIdentity, destinationDir: string, signal: AbortSignal): Promise<{
|
|
20
|
+
path: string;
|
|
21
|
+
artifact: CachedBuildArtifact;
|
|
22
|
+
} | null>;
|
|
23
|
+
}
|
|
24
|
+
//#endregion
|
|
25
|
+
export { BuildArtifactCache, validArtifactIdentity };
|
|
@@ -416,6 +416,11 @@ function expoEnvFiles(env = {}) {
|
|
|
416
416
|
".env"
|
|
417
417
|
];
|
|
418
418
|
}
|
|
419
|
+
/** The env files only a production bundle of an Expo app reads, beside the ones `expoEnvFiles` lists. */
|
|
420
|
+
function expoProductionEnvFiles(env = {}) {
|
|
421
|
+
if (/^(1|true)$/i.test(env.EXPO_NO_DOTENV ?? "")) return [];
|
|
422
|
+
return [".env.production.local", ".env.production"];
|
|
423
|
+
}
|
|
419
424
|
const inNodeModules = (path) => path.split("/").includes("node_modules");
|
|
420
425
|
/**
|
|
421
426
|
* Absolute paths of the files git ignores that a fingerprint with `sources` hashed or the Expo config loader read:
|
|
@@ -866,4 +871,4 @@ function fingerprintDiffRecord({ changed, previousHash, hash }) {
|
|
|
866
871
|
};
|
|
867
872
|
}
|
|
868
873
|
//#endregion
|
|
869
|
-
export {
|
|
874
|
+
export { trackedFingerprintPaths as A, providerUploadOutcome as C, storedAppId as D, storeBuild as E, compareAssetManifests as F, readAssetManifest as I, untrackedNativeFiles as M, assetDiffReason as N, storedAssetManifest as O, captureAssetManifest as P, providerDownloadPath as S, resolveBuild as T, gitignoredFingerprintInputs as _, compareSourceLists as a, packageIn as b, entryDir as c, expoEnvFiles as d, expoProductionEnvFiles as f, fingerprintProject as g, fingerprintOptions as h, changedOnlyInside as i, untrackedMissLine as j, storedSources as k, evictBuild as l, fingerprintDiffRecord as m, buildCacheKey as n, configInputsChanged as o, filesystemBuildCapability as p, changedDuringBuildLine as r, diffFingerprintSources as s, artifactIn as t, expoConfigContents as u, ignoredFingerprintPaths as v, refingerprintAfterMutation as w, prepareProviderDownloadDir as x, inputsChangedDuringBuild as y };
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { a as trackReportResource } from "./exec-CGuDzt40.mjs";
|
|
2
|
-
import { i as formatDuration, l as phaseLine, m as shortHash, u as plural } from "./command-output-
|
|
2
|
+
import { i as formatDuration, l as phaseLine, m as shortHash, u as plural } from "./command-output-CGxrQ3Bd.mjs";
|
|
3
3
|
import { an as makeTemporaryDirectory, sn as removeTemporaryEntryAsync } from "./settings-B5IBDfTx.mjs";
|
|
4
|
-
import {
|
|
5
|
-
import { at as readStats, q as estimateBuild } from "./workspaces-
|
|
6
|
-
import { c as entryDir, t as artifactIn } from "./build-cache-
|
|
7
|
-
import { l as predictBuildMiss, o as staleNativeDirRefusal } from "./prebuild-
|
|
4
|
+
import { Yn as easAuthNote } from "./device-capacity-C0PiTyRb.mjs";
|
|
5
|
+
import { at as readStats, q as estimateBuild } from "./workspaces-CY3KSdC0.mjs";
|
|
6
|
+
import { c as entryDir, t as artifactIn } from "./build-cache-_fkewiwH.mjs";
|
|
7
|
+
import { l as predictBuildMiss, o as staleNativeDirRefusal } from "./prebuild-BptrXmh_.mjs";
|
|
8
8
|
import chalk from "chalk";
|
|
9
9
|
import { PROVIDER_LOAD_TIMEOUT_ENV, PROVIDER_LOAD_TIMEOUT_MS, buildResolveTimeoutMs, resolveTieredBuild, timeoutFromEnv } from "@stim-cli/cache";
|
|
10
10
|
//#region src/commands/build-plan.ts
|
|
@@ -5,23 +5,23 @@ import { runId, trace } from "@stim-cli/core/state";
|
|
|
5
5
|
import { Command } from "commander";
|
|
6
6
|
//#region bin/cli.ts
|
|
7
7
|
const commands = /* @__PURE__ */ new Map([
|
|
8
|
-
["doctor", () => import("./doctor-
|
|
9
|
-
["worktree", () => import("./worktree-
|
|
10
|
-
["start", () => import("./start-
|
|
11
|
-
["ports", () => import("./ports-
|
|
12
|
-
["stop", () => import("./stop-
|
|
13
|
-
["ios", () => import("./ios-
|
|
14
|
-
["android", () => import("./android-
|
|
15
|
-
["web", () => import("./web-
|
|
16
|
-
["macos", () => import("./macos-
|
|
17
|
-
["reload", () => import("./reload-
|
|
18
|
-
["device", () => import("./device-
|
|
19
|
-
["logs", () => import("./logs-
|
|
20
|
-
["settings", () => import("./settings-
|
|
21
|
-
["status", () => import("./status-
|
|
22
|
-
["stats", () => import("./stats-
|
|
23
|
-
["gc", () => import("./gc-
|
|
24
|
-
["guide", () => import("./guide-
|
|
8
|
+
["doctor", () => import("./doctor-BBAb8NLe.mjs")],
|
|
9
|
+
["worktree", () => import("./worktree-D6myrQ2H.mjs")],
|
|
10
|
+
["start", () => import("./start-GkRBR1e3.mjs")],
|
|
11
|
+
["ports", () => import("./ports-C1_1Qgdy.mjs")],
|
|
12
|
+
["stop", () => import("./stop-QFOqgICJ.mjs")],
|
|
13
|
+
["ios", () => import("./ios-BCKxjpRp.mjs")],
|
|
14
|
+
["android", () => import("./android-CjcJE7uA.mjs")],
|
|
15
|
+
["web", () => import("./web-D1m1LKEz.mjs")],
|
|
16
|
+
["macos", () => import("./macos-C_e9f5-5.mjs")],
|
|
17
|
+
["reload", () => import("./reload-CXgce4Yo.mjs")],
|
|
18
|
+
["device", () => import("./device-mOFYiHiw.mjs")],
|
|
19
|
+
["logs", () => import("./logs-DwI3Rkpf.mjs")],
|
|
20
|
+
["settings", () => import("./settings-DcmVICCn.mjs")],
|
|
21
|
+
["status", () => import("./status-Dost__Vn.mjs")],
|
|
22
|
+
["stats", () => import("./stats-Dz08IopP.mjs")],
|
|
23
|
+
["gc", () => import("./gc-CvMEytXz.mjs")],
|
|
24
|
+
["guide", () => import("./guide-BWozWG7D.mjs")]
|
|
25
25
|
]);
|
|
26
26
|
const pkg = JSON.parse(readFileSync(new URL("../package.json", import.meta.url), "utf-8"));
|
|
27
27
|
const program = new Command();
|
package/dist/cli.mjs
CHANGED
|
@@ -4,6 +4,6 @@ const encode = (version) => version.split(".", 3).reduce((sum, part) => sum * 1e
|
|
|
4
4
|
if (encode(process.versions.node) < encode("22.12.0")) {
|
|
5
5
|
process.stderr.write(`STIM_NODE_UNSUPPORTED: Stim needs Node 22.12.0 or later; this is Node ${process.versions.node} at ${process.execPath}. To run Stim where a project pins an older Node, see https://stim.appandflow.com/docs/requirements#older-node-pins\n`);
|
|
6
6
|
process.exitCode = 1;
|
|
7
|
-
} else import("./cli-
|
|
7
|
+
} else import("./cli-DK24VzHi.mjs");
|
|
8
8
|
//#endregion
|
|
9
9
|
export {};
|
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
import { C as operationState, E as debugLog, d as throwIfCancelled, r as reportSignal, t as getExecutor } from "./exec-CGuDzt40.mjs";
|
|
2
2
|
import { K as resolveEndpoint, V as openAuthenticated, q as sayHello, v as loadConfig$1 } from "./config-BW0fAtoK.mjs";
|
|
3
3
|
import { o as git, s as gitAsync } from "./operation-exec-DKlBcKAL.mjs";
|
|
4
|
-
import {
|
|
4
|
+
import { C as CCACHE_UNAVAILABLE, Or as discoverCaches, S as CCACHE_NOT_RUN, at as maintenanceLogger, ft as planCacheEmptying, ot as emptyCaches } from "./device-capacity-C0PiTyRb.mjs";
|
|
5
5
|
import { t as canonicalPath } from "./paths-BsJMoPP2.mjs";
|
|
6
|
-
import { A as COMPILATION_CACHE_NOT_RUN, D as readRubyVersion, S as workerToolchain, a as buildsOnlyOnWorker, b as toolchainNotes, c as iosToolchainAsync, j as COMPILATION_CACHE_UNAVAILABLE, o as cocoapodsDifference,
|
|
6
|
+
import { A as COMPILATION_CACHE_NOT_RUN, D as readRubyVersion, S as workerToolchain, _t as runCancellationSignal, a as buildsOnlyOnWorker, b as toolchainNotes, c as iosToolchainAsync, j as COMPILATION_CACHE_UNAVAILABLE, o as cocoapodsDifference, y as toolchainMismatches } from "./toolchain-DRQyCvlp.mjs";
|
|
7
7
|
import { t as resolveMaintenanceSettings } from "./settings-D9LtQaUw.mjs";
|
|
8
|
-
import {
|
|
8
|
+
import { $ as pairedMachines, D as OffloadRefusal, M as namedBuildMachine, R as workerFailureReason, u as isReleaseConfiguration } from "./support-DW575Dnx.mjs";
|
|
9
9
|
import { n as fingerprintNativeInputs, r as manifestDigest } from "./native-inputs-TRTTTRxt.mjs";
|
|
10
10
|
import { a as sourceManifest, i as nativeTransferManifest, n as gitVisiblePaths, r as nativeFileDigest, t as checkNativeTransferMembership } from "./native-source-ChAGj7R1.mjs";
|
|
11
|
+
import { t as BuildArtifactCache } from "./build-artifact-cache-D7B6seMj.mjs";
|
|
11
12
|
import { createHash, webcrypto } from "node:crypto";
|
|
12
13
|
import { closeSync, existsSync, lstatSync, mkdirSync, openSync, readFileSync, readdirSync, realpathSync, rmSync, writeSync } from "node:fs";
|
|
13
14
|
import { isDeepStrictEqual } from "node:util";
|
|
@@ -16,7 +17,7 @@ import { ambientContext, dependencyLockfile, reactNativeArtifactIdentity, reactN
|
|
|
16
17
|
import { automaticMachineEnabled, isJsonObject, maintenanceDir, mayRunHere, placementWord, requireAutomaticMachine, runId, saturation } from "@stim-cli/core/state";
|
|
17
18
|
import { setTimeout as setTimeout$1 } from "node:timers/promises";
|
|
18
19
|
import { WebSocket } from "ws";
|
|
19
|
-
import { access, lstat, readFile, readlink, realpath } from "node:fs/promises";
|
|
20
|
+
import { access, lstat, readFile, readlink, realpath, rename, rm } from "node:fs/promises";
|
|
20
21
|
//#region src/cache/compilation-cache-corruption.ts
|
|
21
22
|
const COMPILATION_CACHE_CORRUPT = "STIM_COMPILATION_CACHE_CORRUPT";
|
|
22
23
|
async function emptyCompilationCache(dir) {
|
|
@@ -368,6 +369,38 @@ function reactNativeArtifactReceipt(query, toolchain) {
|
|
|
368
369
|
receipt
|
|
369
370
|
};
|
|
370
371
|
}
|
|
372
|
+
/**
|
|
373
|
+
* The development app stim-server retained for `query`, placed at `out/app.tgz` and unpacked beside it as a build
|
|
374
|
+
* leaves it, when the client allows a reused artifact and `query` carries a fingerprint other than the one the client
|
|
375
|
+
* looked up; null otherwise or on a miss.
|
|
376
|
+
*/
|
|
377
|
+
async function reusedReactNativeArtifact(job, query, out, signal) {
|
|
378
|
+
if (!job.reuseArtifact || !job.artifactCache || query.fingerprint === job.expectedFingerprint) return null;
|
|
379
|
+
const cache = new BuildArtifactCache(job.artifactCache);
|
|
380
|
+
const cached = await cache.lookupReactNative(query, signal);
|
|
381
|
+
if (!cached) return null;
|
|
382
|
+
await rm(out, {
|
|
383
|
+
recursive: true,
|
|
384
|
+
force: true
|
|
385
|
+
});
|
|
386
|
+
const fetched = await cache.fetch(cached, out, signal);
|
|
387
|
+
if (!fetched) return null;
|
|
388
|
+
const archive = join(out, "app.tgz");
|
|
389
|
+
await rename(fetched.path, archive);
|
|
390
|
+
await getExecutor().runFileAsync("tar", [
|
|
391
|
+
"-xf",
|
|
392
|
+
archive,
|
|
393
|
+
"-C",
|
|
394
|
+
out
|
|
395
|
+
], { timeoutMs: 6e5 });
|
|
396
|
+
const { name, size, sha256 } = fetched.artifact;
|
|
397
|
+
return {
|
|
398
|
+
path: archive,
|
|
399
|
+
name,
|
|
400
|
+
size,
|
|
401
|
+
sha256
|
|
402
|
+
};
|
|
403
|
+
}
|
|
371
404
|
//#endregion
|
|
372
405
|
//#region src/offload/client.ts
|
|
373
406
|
const CONNECT_TIMEOUT_MS = 1e4;
|
|
@@ -417,6 +450,7 @@ function placementLoad(choice) {
|
|
|
417
450
|
maxBuilds: maxBuilds ?? 0
|
|
418
451
|
})} there`;
|
|
419
452
|
}
|
|
453
|
+
const UNSUPPORTED_OFFLOAD_REMEDY = "This build cannot leave this machine. Build it here with --remote-build local or auto where this machine can build it; stim guide settings lists what keeps a build here.";
|
|
420
454
|
/**
|
|
421
455
|
* Whether a build may go to a remote machine at all, before any machine is asked. `auto` keeps the build here while
|
|
422
456
|
* this machine has a free `concurrency.maxBuilds` slot and its load per core is under `server.maxLoadPerCore`.
|
|
@@ -426,7 +460,7 @@ function placementLoad(choice) {
|
|
|
426
460
|
function offloadPlacement({ machines, here, unsupported, localEnabled = true, selected = "auto" }) {
|
|
427
461
|
const word = placementWord(selected);
|
|
428
462
|
if (word === null) {
|
|
429
|
-
if (unsupported) throw new OffloadRefusal(selected, `${unsupported}, so a named remote machine cannot take it
|
|
463
|
+
if (unsupported) throw new OffloadRefusal(selected, `${unsupported}, so a named remote machine cannot take it`, UNSUPPORTED_OFFLOAD_REMEDY);
|
|
430
464
|
if (machines === 0) throw new OffloadRefusal(selected, "no remote machine is paired");
|
|
431
465
|
return {
|
|
432
466
|
offload: true,
|
|
@@ -441,8 +475,8 @@ function offloadPlacement({ machines, here, unsupported, localEnabled = true, se
|
|
|
441
475
|
};
|
|
442
476
|
if (!localEnabled || !mayRunHere(word)) {
|
|
443
477
|
const why = word === "remote-only" ? "remote-only never builds here" : "local is disabled in remote.buildPoolDisabled";
|
|
444
|
-
|
|
445
|
-
if (
|
|
478
|
+
if (unsupported) throw new OffloadRefusal(selected, `${unsupported}; ${why}`, UNSUPPORTED_OFFLOAD_REMEDY);
|
|
479
|
+
if (machines === 0) throw new OffloadRefusal(selected, `no enabled remote machine is paired; ${why}`);
|
|
446
480
|
return {
|
|
447
481
|
offload: true,
|
|
448
482
|
code: word === "remote-only" ? "remote-only" : "local-disabled",
|
|
@@ -1077,7 +1111,11 @@ function leavesPodsToWorker(choice, request) {
|
|
|
1077
1111
|
return request.platform === "ios" && !request.native && target.platform === "ios" && buildsOnlyOnWorker(target.local);
|
|
1078
1112
|
}
|
|
1079
1113
|
function startPods(choice, request) {
|
|
1080
|
-
|
|
1114
|
+
if (request.platform !== "ios" || !leavesPodsToWorker(choice, request)) return {};
|
|
1115
|
+
return {
|
|
1116
|
+
podsOnWorker: true,
|
|
1117
|
+
...request.reuseArtifact === true && choice.connection.supports("build-reuse-artifact") && !isReleaseConfiguration(request.configuration) ? { reuseArtifact: true } : {}
|
|
1118
|
+
};
|
|
1081
1119
|
}
|
|
1082
1120
|
/**
|
|
1083
1121
|
* The fingerprint the machine built under after its own pod install, when it differs from the requested one; null
|
|
@@ -1641,7 +1679,6 @@ async function offloadBuild(input) {
|
|
|
1641
1679
|
keepStaging = true;
|
|
1642
1680
|
return {
|
|
1643
1681
|
ok: true,
|
|
1644
|
-
...cacheHit ? { cacheHit: true } : {},
|
|
1645
1682
|
...rebuilt ? { builtFingerprint: rebuilt } : {},
|
|
1646
1683
|
machine,
|
|
1647
1684
|
artifactPath,
|
|
@@ -1650,7 +1687,7 @@ async function offloadBuild(input) {
|
|
|
1650
1687
|
token: declared.handoff,
|
|
1651
1688
|
sha256: digest
|
|
1652
1689
|
} } : {},
|
|
1653
|
-
...offloadCacheActivity(request.platform, result.compilationCache, cacheHit),
|
|
1690
|
+
...offloadCacheActivity(request.platform, result.compilationCache, cacheHit || result.reused === true),
|
|
1654
1691
|
...native?.provider === "gradle" ? { androidPackage: result.androidPackage } : {},
|
|
1655
1692
|
timings: {
|
|
1656
1693
|
offerMs: choice.offerMs,
|
|
@@ -1677,6 +1714,7 @@ async function offloadBuild(input) {
|
|
|
1677
1714
|
}
|
|
1678
1715
|
function offloadCacheActivity(platform, activity, cacheHit) {
|
|
1679
1716
|
if (cacheHit) return {
|
|
1717
|
+
cacheHit: true,
|
|
1680
1718
|
compilationCache: COMPILATION_CACHE_NOT_RUN,
|
|
1681
1719
|
ccache: CCACHE_NOT_RUN
|
|
1682
1720
|
};
|
|
@@ -1823,4 +1861,4 @@ function offloadCheck(projectRoot, targets) {
|
|
|
1823
1861
|
};
|
|
1824
1862
|
}
|
|
1825
1863
|
//#endregion
|
|
1826
|
-
export {
|
|
1864
|
+
export { setRemoteLogSink as C, verifyGradleTransfer as S, clearCorruptCompilationCache as T, gradleStateDirectories as _, nativeTransferRefusal as a, nativeGradleTransfer as b, offloadPlacement as c, simulatorRuntime as d, reactNativeArtifactReceipt as f, gradleOffloadInputs as g, reusedReactNativeArtifact as h, closeOffload as i, placementLoad as l, reactNativeBuildQuery as m, buildPlacementCandidates as n, offloadBuild as o, reactNativeArtifactToolchain as p, chooseBuildMachine as r, offloadCheck as s, BuildConnection as t, remotePhaseText as u, nativeGradleLocalSourceDigest as v, COMPILATION_CACHE_CORRUPT as w, validateGradleManifest as x, nativeGradleOutputs as y };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as stripAnsi } from "./process-output-Fpl8PYi8.mjs";
|
|
2
|
-
import { t as NO_PROJECT_REFUSAL } from "./project-
|
|
2
|
+
import { t as NO_PROJECT_REFUSAL } from "./project-Dqqj3IkW.mjs";
|
|
3
3
|
import { quotedPath as quotedPath$1 } from "@stim-cli/core";
|
|
4
4
|
import chalk from "chalk";
|
|
5
5
|
//#region src/diagnostics/launch-error-preview.ts
|
|
@@ -1,44 +1,41 @@
|
|
|
1
1
|
import { l as cancellableSleep, t as getExecutor, w as withDrainingCancellation } from "./exec-CGuDzt40.mjs";
|
|
2
2
|
import { f as writeWorkspaceStateAsync, k as workspaceLogsDir, r as readWorkspaceState } from "./workspace-state-BdZ-QgmB.mjs";
|
|
3
|
-
import { _ as stepTimer, c as launchErrorReport, i as formatDuration, l as phaseLine, n as appReadinessMessage, v as launchErrorPreview } from "./command-output-
|
|
3
|
+
import { _ as stepTimer, c as launchErrorReport, i as formatDuration, l as phaseLine, n as appReadinessMessage, v as launchErrorPreview } from "./command-output-CGxrQ3Bd.mjs";
|
|
4
4
|
import { D as upsertProject, dt as deviceSlotKey, k as withConfigLockAsync, m as getProject, u as getConcurrencyLimits, ut as deviceSlotFileKey, y as recordIosSchemeApprovals } from "./config-BW0fAtoK.mjs";
|
|
5
5
|
import { J as resolveCacheProviderConfig, Q as resolveSettings, St as gitCommonDirAsync, Vt as repoRootAsync, an as makeTemporaryDirectory, at as settingsLayers, dt as detectProviders, nt as settingOriginScope, on as removeTemporaryEntry } from "./settings-B5IBDfTx.mjs";
|
|
6
|
-
import { L as workspaceDevServerMode, f as projectRegistry, i as findProjectRoot, v as detectIsExpo, z as writeWorkspaceLaunchAsync } from "./project-
|
|
6
|
+
import { L as workspaceDevServerMode, f as projectRegistry, i as findProjectRoot, v as detectIsExpo, z as writeWorkspaceLaunchAsync } from "./project-Dqqj3IkW.mjs";
|
|
7
7
|
import { o as workspaceLinks } from "./stim-desktop-_WTria-r.mjs";
|
|
8
8
|
import { c as pidExists, d as resolveProjectMetro, f as signalProcessTree } from "./metro-B5PVz0Wv.mjs";
|
|
9
9
|
import { i as createNdjsonWriter } from "./ndjson-CrjIsGzw.mjs";
|
|
10
|
-
import {
|
|
11
|
-
import { St as acquireBuildSlot, Tt as releaseBuildSlot, ct as recordRunStats, it as readRunEstimates, ot as recordCapacityRefusal } from "./workspaces-
|
|
12
|
-
import { E as readPodState, H as readBundleId, T as podsAreStale, U as resolveScheme, V as readBundleExecutable, c as iosToolchainAsync, k as runPodInstall } from "./toolchain-
|
|
13
|
-
import { F as waitForBuild, M as acquireBuildLock, P as releaseBuildLock } from "./activity-
|
|
14
|
-
import {
|
|
10
|
+
import { Bn as readRemoteSimulatorArch, En as devClientUrl, In as launchIosApp, Jn as checkEasAuth, Jt as bundleEntryPoint, Ln as restartedAppNote, Mn as installIosApp, Nn as iosAppProcess, Tn as clearOtherUserApps, Vn as gateMetroOrigin, Xt as ensureMetroReachable, Zn as loadProjectProvider, Zt as ensureRemoteBootOwned, an as LAUNCH_UNVERIFIED, dn as readMetroRecords, en as remoteIosDeps, fn as unattributedLaunchLines, gn as verifyReleaseLaunch, hn as verifyLaunch, in as LAUNCH_FATAL, k as budgetGate, ln as isBundleProof, nr as resolveRemote, pn as unverifiedLaunchLines, r as checkDeviceCapacity, rn as LAUNCH_BUNDLING, rr as uploadRemote, sn as RELEASE_VERIFY_WAIT_MS, tn as resolveRemoteContext, tr as resolveEasCliBin, un as readCollectorRecords, xn as IOS_DEV_MENU_OFF_DEFAULTS_PLIST } from "./device-capacity-C0PiTyRb.mjs";
|
|
11
|
+
import { St as acquireBuildSlot, Tt as releaseBuildSlot, ct as recordRunStats, it as readRunEstimates, ot as recordCapacityRefusal } from "./workspaces-CY3KSdC0.mjs";
|
|
12
|
+
import { E as readPodState, H as readBundleId, T as podsAreStale, U as resolveScheme, V as readBundleExecutable, c as iosToolchainAsync, k as runPodInstall } from "./toolchain-DRQyCvlp.mjs";
|
|
13
|
+
import { F as waitForBuild, M as acquireBuildLock, P as releaseBuildLock } from "./activity-BQpJpAjA.mjs";
|
|
14
|
+
import { E as storeBuild, M as untrackedNativeFiles, T as resolveBuild, g as fingerprintProject, l as evictBuild } from "./build-cache-_fkewiwH.mjs";
|
|
15
15
|
import { d as listAllIosSims, h as listIosRuntimesAsync, r as clearIosAppData } from "./ios-BdZdNsAj.mjs";
|
|
16
|
+
import { C as clearIosAdoptionPending, G as lostLine, J as releaseLeaseOnAbort, K as lostRefusal, U as acquireRunLease, Y as runLease, i as deviceLabel, o as deviceShortName, t as appNameFromPath, z as DEBUG_VERIFY_STEP_MS } from "./support-DW575Dnx.mjs";
|
|
16
17
|
import { n as readHostedIos, o as writeHostedIosAsync } from "./ios-state-CWsBysyN.mjs";
|
|
17
|
-
import { n as hostedMetroPortProbe } from "./hosted-native-
|
|
18
|
-
import { i as prepareHostedIos, r as placeHostedIos } from "./phone-reverses-
|
|
18
|
+
import { n as hostedMetroPortProbe } from "./hosted-native-C9xQYYFb.mjs";
|
|
19
|
+
import { i as prepareHostedIos, r as placeHostedIos } from "./phone-reverses-B9WyCBKQ.mjs";
|
|
19
20
|
import { n as verifyCollectorOwnership } from "./ownership-hC7xvvxF.mjs";
|
|
20
|
-
import { n as nativeRunCommand, r as siblingPlatformSlots, t as launchSlotScope } from "./slot-launch-
|
|
21
|
-
import { a as discoverXcodeProject, r as buildIos } from "./react-native-build-
|
|
22
|
-
import { c as startDevServer, g as detectBundleId } from "./start-
|
|
21
|
+
import { n as nativeRunCommand, r as siblingPlatformSlots, t as launchSlotScope } from "./slot-launch-DsQmPdlg.mjs";
|
|
22
|
+
import { a as discoverXcodeProject, r as buildIos } from "./react-native-build-BTUcE926.mjs";
|
|
23
|
+
import { c as startDevServer, g as detectBundleId } from "./start-DIFiT2P5.mjs";
|
|
23
24
|
import { t as spawnEntry } from "./spawn-entry-jw19m8Nl.mjs";
|
|
24
|
-
import { a as
|
|
25
|
-
import {
|
|
26
|
-
import { n as
|
|
27
|
-
import { i as
|
|
28
|
-
import {
|
|
29
|
-
import { a as
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import { t as
|
|
33
|
-
import {
|
|
34
|
-
import { i as
|
|
35
|
-
import {
|
|
36
|
-
import {
|
|
37
|
-
import {
|
|
38
|
-
import { i as warmMetro, n as ensureBooted, r as ensureOwnedDevice } from "./device-DOehZpyx.mjs";
|
|
39
|
-
import { t as selectFromPool } from "./device-pool-DP4sCeCC.mjs";
|
|
40
|
-
import { s as reportIosResult } from "./ios-project-BzfLigfh.mjs";
|
|
41
|
-
import { i as swapJsBundle } from "./js-swap-EDVOJmqx.mjs";
|
|
25
|
+
import { a as sealAppForDevice, r as gateProfileForDevice } from "./ios-signing-CCFNjjWU.mjs";
|
|
26
|
+
import { a as resolveEasDevelopmentBuild } from "./eas-build-BxJdzQnF.mjs";
|
|
27
|
+
import { c as isWirelessIosDevice, i as iosDeviceProcess, l as listIosDevices, n as installIosDeviceApp, p as verifyIosDeviceReleaseLaunch, r as iosDeviceBounds, t as awaitIosDeviceLaunch, u as localNetworkPending } from "./ios-device-DMOnaH5n.mjs";
|
|
28
|
+
import { a as captureNativeCrashes, c as simulatorConsolePaths, i as bundleBindFailure, n as IOS_CRASH_REPORT_RETRY, s as printNativeCrashReport, t as errorDiagnostics } from "./error-diagnostics-D6wlK-yX.mjs";
|
|
29
|
+
import { t as followHostedLaunchLogs } from "./hosted-logs-sync-DfUJ2GpF.mjs";
|
|
30
|
+
import { a as runPrebuild, d as memoizedFingerprint, n as planPrebuildAsync } from "./prebuild-BptrXmh_.mjs";
|
|
31
|
+
import { i as launchOutcomeRecord, n as ensureWorkspaceStorageSafely } from "./native-runtime-oDqT4UES.mjs";
|
|
32
|
+
import { n as devClientTakesDevMenuParams, r as hasDevClient, t as devClientScheme } from "./dev-client-DDApoVvd.mjs";
|
|
33
|
+
import { t as automaticDevicePlacement } from "./auto-placement-CBdWa87P.mjs";
|
|
34
|
+
import { t as checkEasFallback } from "./eas-fallback-DU2WDF8r.mjs";
|
|
35
|
+
import { i as warmMetro, n as ensureBooted, r as ensureOwnedDevice } from "./device-p_cp8IzW.mjs";
|
|
36
|
+
import { t as selectFromPool } from "./device-pool-nsMvt2X2.mjs";
|
|
37
|
+
import { s as reportIosResult } from "./ios-project-PXBDoaii.mjs";
|
|
38
|
+
import { i as swapJsBundle } from "./js-swap-07ikLRJJ.mjs";
|
|
42
39
|
import { mkdirSync, openSync, writeFileSync } from "node:fs";
|
|
43
40
|
import { networkInterfaces } from "node:os";
|
|
44
41
|
import { basename, join } from "node:path";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { C as resolvePackageJson, b as isPackageResolvable } from "./project-
|
|
2
|
-
import {
|
|
1
|
+
import { C as resolvePackageJson, b as isPackageResolvable } from "./project-Dqqj3IkW.mjs";
|
|
2
|
+
import { $ as readBundleSchemes, Q as pickDevClientScheme } from "./toolchain-DRQyCvlp.mjs";
|
|
3
3
|
import { dirname, join } from "node:path";
|
|
4
4
|
import { isJsonObject, readJsonObject } from "@stim-cli/core/state";
|
|
5
5
|
//#region src/commands/dev-client.ts
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { D as ownership_claim_exports, t as getExecutor } from "./exec-CGuDzt40.mjs";
|
|
2
|
-
import { l as phaseLine } from "./command-output-
|
|
2
|
+
import { l as phaseLine } from "./command-output-CGxrQ3Bd.mjs";
|
|
3
3
|
import { M as acquireAvdClaim, O as withConfigLock, T as setDevice, a as clearDevice, ft as deviceSlotPlatforms, ht as projectDeviceSlots, i as clearAndroidBootPending, k as withConfigLockAsync, t as allConsolePortsAndSerials, v as loadConfig, x as releaseAndroidConsolePort } from "./config-BW0fAtoK.mjs";
|
|
4
4
|
import { l as androidDataPartitionSizeGbSetting, o as androidAvdConfigSetting } from "./settings-B5IBDfTx.mjs";
|
|
5
5
|
import { A as getAvdNameForSerialAsync, G as ownedAvdName, H as ownedAvdDeviceProfile, J as ownedAvdSystemImage, P as listAdbDevicesAsync, Q as pickDefaultSystemImage, R as listAvdsAsync, S as createOwnedAvd, V as nextConsolePort, W as ownedAvdMatchesConfiguration, _ as avdPoolConfiguration, b as bootAndroidEmulator, bt as parkedMaxSetting, ht as adoptParked, it as resolveOwnedAvdSerialAsync, n as OWNED_AVD_CONFIG_DEFAULTS, p as assertOwnedAvdStoppedAsync, t as DEFAULT_AVD_DEVICE_PROFILE, ut as waitForBoot, vt as isLegacyDeletionClaim, xt as readParked, z as listInstalledSystemImages } from "./android-Iq0M2t2d.mjs";
|
|
6
6
|
import { c as pidExists } from "./metro-B5PVz0Wv.mjs";
|
|
7
|
-
import {
|
|
7
|
+
import { _ as withDeviceBootAdmission, n as DeviceAdmissionRefusal, s as countLiveOwnedDevicesFrom } from "./device-capacity-C0PiTyRb.mjs";
|
|
8
|
+
import { gt as teardownParkedAvd, pt as teardownOwnedAvd } from "./workspaces-CY3KSdC0.mjs";
|
|
8
9
|
import { B as reportMemoryCulprits, L as memoryCulpritsUnderAsync, R as readHostMemoryPressure, V as memoryCulpritAdvice, f as listAllIosSimsAsync } from "./ios-BdZdNsAj.mjs";
|
|
9
|
-
import { _ as withDeviceBootAdmission, n as DeviceAdmissionRefusal, s as countLiveOwnedDevicesFrom } from "./device-capacity-BAkETfIl.mjs";
|
|
10
10
|
import { claimRemoveCommand, clearClaimChild, markClaimChildPending, processGroupAlive, releaseClaim, setClaimChild } from "@stim-cli/core/ownership-claim";
|
|
11
11
|
import { randomUUID } from "node:crypto";
|
|
12
12
|
import { existsSync } from "node:fs";
|