@swmansion/argent 0.35.1-next.89 → 0.35.1-next.90

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/cli-cmds.mjs CHANGED
@@ -39147,7 +39147,7 @@ function isCi(env = process.env) {
39147
39147
  var SESSION_ID2 = randomUUID5();
39148
39148
  function readCliVersion() {
39149
39149
  if (true) {
39150
- return "0.35.1-next.89";
39150
+ return "0.35.1-next.90";
39151
39151
  }
39152
39152
  return "0.0.0";
39153
39153
  }
@@ -17177,7 +17177,7 @@ function isCi(env = process.env) {
17177
17177
  var SESSION_ID = randomUUID4();
17178
17178
  function readCliVersion() {
17179
17179
  if (true) {
17180
- return "0.35.1-next.89";
17180
+ return "0.35.1-next.90";
17181
17181
  }
17182
17182
  return "0.0.0";
17183
17183
  }
@@ -38588,7 +38588,7 @@ async function startMcpServer(options) {
38588
38588
  const autoDescribeOn = autoDescribeEnabled();
38589
38589
  const whatsNewOn = whatsNewEnabled();
38590
38590
  const installedVersion = getInstalledVersion();
38591
- const highlightsVersion = true ? "0.35.1-next.89" : installedVersion;
38591
+ const highlightsVersion = true ? "0.35.1-next.90" : installedVersion;
38592
38592
  const captureTimeoutMs = options.captureTimeoutMs ?? CAPTURE_TIMEOUT_MS;
38593
38593
  const trees = createTreeMemory();
38594
38594
  const screenshots = createScreenshotMemory();
@@ -50896,7 +50896,7 @@ var require_min_release_age = __commonJS({
50896
50896
  exports2.detectMinReleaseAgeMs = detectMinReleaseAgeMs2;
50897
50897
  var node_child_process_1 = require("node:child_process");
50898
50898
  var config_parse_1 = require_config_parse();
50899
- var PROBE_TIMEOUT_MS4 = 3e3;
50899
+ var PROBE_TIMEOUT_MS3 = 3e3;
50900
50900
  var OVERRIDE_ENV2 = "ARGENT_MIN_RELEASE_AGE_DAYS";
50901
50901
  var PM_PROBES = {
50902
50902
  // Probe `before`: that is the effective cutoff npm's resolver applies.
@@ -50916,7 +50916,7 @@ var require_min_release_age = __commonJS({
50916
50916
  }
50917
50917
  function probe4(p, cwd) {
50918
50918
  return new Promise((resolve24) => {
50919
- (0, node_child_process_1.exec)(p.command, { cwd, timeout: PROBE_TIMEOUT_MS4, windowsHide: true }, (err, stdout) => {
50919
+ (0, node_child_process_1.exec)(p.command, { cwd, timeout: PROBE_TIMEOUT_MS3, windowsHide: true }, (err, stdout) => {
50920
50920
  if (err) {
50921
50921
  resolve24(0);
50922
50922
  return;
@@ -52163,7 +52163,7 @@ function readProviderDevices2(record2) {
52163
52163
  async function probeAlive(device) {
52164
52164
  if (!device.simulatorServer) return true;
52165
52165
  const controller = new AbortController();
52166
- const timer = setTimeout(() => controller.abort(), PROBE_TIMEOUT_MS);
52166
+ const timer = setTimeout(() => controller.abort(), EXTERNAL_PROBE_TIMEOUT_MS);
52167
52167
  try {
52168
52168
  await fetch(device.simulatorServer.apiUrl, { signal: controller.signal });
52169
52169
  return true;
@@ -52298,7 +52298,7 @@ function externalSupportHint(id) {
52298
52298
  const where = record2.supportUrl ? ` Report issues at ${record2.supportUrl}.` : "";
52299
52299
  return `This device is provided by ${record2.name}.${where}`;
52300
52300
  }
52301
- var ALLOWED_ENDPOINT_SET, PROBE_TIMEOUT_MS, SIMULATOR_UDID, lastSeenCapabilities, inFlightRevocations;
52301
+ var ALLOWED_ENDPOINT_SET, EXTERNAL_PROBE_TIMEOUT_MS, SIMULATOR_UDID, lastSeenCapabilities, inFlightRevocations;
52302
52302
  var init_external_devices = __esm({
52303
52303
  "../tool-server/src/utils/external-devices.ts"() {
52304
52304
  "use strict";
@@ -52307,7 +52307,7 @@ var init_external_devices = __esm({
52307
52307
  init_device_info();
52308
52308
  init_src3();
52309
52309
  ALLOWED_ENDPOINT_SET = new Set(ALLOWED_SIM_SERVER_ENDPOINTS);
52310
- PROBE_TIMEOUT_MS = 800;
52310
+ EXTERNAL_PROBE_TIMEOUT_MS = 800;
52311
52311
  SIMULATOR_UDID = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
52312
52312
  lastSeenCapabilities = /* @__PURE__ */ new Map();
52313
52313
  inFlightRevocations = /* @__PURE__ */ new Map();
@@ -62430,7 +62430,7 @@ var require_websocket = __commonJS({
62430
62430
  var http8 = require("http");
62431
62431
  var net14 = require("net");
62432
62432
  var tls = require("tls");
62433
- var { randomBytes: randomBytes6, createHash: createHash12 } = require("crypto");
62433
+ var { randomBytes: randomBytes6, createHash: createHash13 } = require("crypto");
62434
62434
  var { Duplex: Duplex2, Readable: Readable2 } = require("stream");
62435
62435
  var { URL: URL2 } = require("url");
62436
62436
  var PerMessageDeflate2 = require_permessage_deflate();
@@ -63111,7 +63111,7 @@ var require_websocket = __commonJS({
63111
63111
  abortHandshake(websocket, socket, "Invalid Upgrade header");
63112
63112
  return;
63113
63113
  }
63114
- const digest = createHash12("sha1").update(key2 + GUID).digest("base64");
63114
+ const digest = createHash13("sha1").update(key2 + GUID).digest("base64");
63115
63115
  if (res.headers["sec-websocket-accept"] !== digest) {
63116
63116
  abortHandshake(websocket, socket, "Invalid Sec-WebSocket-Accept header");
63117
63117
  return;
@@ -63480,7 +63480,7 @@ var require_websocket_server = __commonJS({
63480
63480
  var EventEmitter2 = require("events");
63481
63481
  var http8 = require("http");
63482
63482
  var { Duplex: Duplex2 } = require("stream");
63483
- var { createHash: createHash12 } = require("crypto");
63483
+ var { createHash: createHash13 } = require("crypto");
63484
63484
  var extension2 = require_extension();
63485
63485
  var PerMessageDeflate2 = require_permessage_deflate();
63486
63486
  var subprotocol2 = require_subprotocol();
@@ -63787,7 +63787,7 @@ var require_websocket_server = __commonJS({
63787
63787
  );
63788
63788
  }
63789
63789
  if (this._state > RUNNING) return abortHandshake(socket, 503);
63790
- const digest = createHash12("sha1").update(key2 + GUID).digest("base64");
63790
+ const digest = createHash13("sha1").update(key2 + GUID).digest("base64");
63791
63791
  const headers = [
63792
63792
  "HTTP/1.1 101 Switching Protocols",
63793
63793
  "Upgrade: websocket",
@@ -73425,7 +73425,7 @@ function isCi(env = process.env) {
73425
73425
  var SESSION_ID = (0, import_node_crypto4.randomUUID)();
73426
73426
  function readCliVersion() {
73427
73427
  if (true) {
73428
- return "0.35.1-next.89";
73428
+ return "0.35.1-next.90";
73429
73429
  }
73430
73430
  return "0.0.0";
73431
73431
  }
@@ -74291,7 +74291,7 @@ var import_promises16 = require("node:fs/promises");
74291
74291
  var import_node_os13 = require("node:os");
74292
74292
  var import_node_path18 = require("node:path");
74293
74293
  init_src();
74294
- var import_node_crypto17 = require("node:crypto");
74294
+ var import_node_crypto18 = require("node:crypto");
74295
74295
 
74296
74296
  // ../archive/src/index.ts
74297
74297
  var import_node_child_process2 = require("node:child_process");
@@ -81769,7 +81769,21 @@ function simulatorRuntimeKind(runtimeId) {
81769
81769
  if (runtimeId.includes("tvOS")) return "tv";
81770
81770
  return runtimeId.includes("iOS") ? "mobile" : void 0;
81771
81771
  }
81772
+ var inFlightSetListings = /* @__PURE__ */ new Map();
81772
81773
  async function listDeviceSetSimulators(deviceSet) {
81774
+ const key2 = deviceSet ?? "";
81775
+ let listing = inFlightSetListings.get(key2);
81776
+ if (!listing) {
81777
+ const started = readDeviceSetSimulators(deviceSet).finally(() => {
81778
+ if (inFlightSetListings.get(key2) === started) inFlightSetListings.delete(key2);
81779
+ });
81780
+ listing = started;
81781
+ inFlightSetListings.set(key2, listing);
81782
+ }
81783
+ const { simulators, timedOut: timedOut3 } = await listing;
81784
+ return { simulators: simulators.map((simulator) => ({ ...simulator })), timedOut: timedOut3 };
81785
+ }
81786
+ async function readDeviceSetSimulators(deviceSet) {
81773
81787
  if (deviceSet && !fs23.existsSync(deviceSet)) return { simulators: [], timedOut: false };
81774
81788
  try {
81775
81789
  const { stdout } = await execFileAsync11(
@@ -81845,9 +81859,12 @@ async function lookUpRuntimeKind(udid) {
81845
81859
  return kind;
81846
81860
  }
81847
81861
  async function findIosSimulator(udid) {
81848
- const listing = isExternalId(udid) ? (await listDeviceSetSimulators(await deviceSetForUdid(udid))).simulators : await listIosSimulators();
81862
+ return (await lookUpIosSimulator(udid)).found;
81863
+ }
81864
+ async function lookUpIosSimulator(udid) {
81865
+ const { simulators, timedOut: timedOut3 } = isExternalId(udid) ? await listDeviceSetSimulators(await deviceSetForUdid(udid)) : await scanIosSimulators();
81849
81866
  const native = externalNativeId(udid);
81850
- return listing.find((s) => s.udid === native);
81867
+ return { found: simulators.find((s) => s.udid === native), timedOut: timedOut3 };
81851
81868
  }
81852
81869
  async function isTvOsSimulator(udid) {
81853
81870
  return await getSimulatorRuntimeKind(udid) === "tv";
@@ -81928,13 +81945,17 @@ async function isRemoteFoldableDeviceType(identifier) {
81928
81945
  return KNOWN_FOLDABLE_DEVICE_TYPES.has(identifier) || await isFoldableDeviceType(identifier);
81929
81946
  }
81930
81947
  async function isFoldableSimulator(udid) {
81948
+ return await checkFoldableSimulator(udid) === true;
81949
+ }
81950
+ async function checkFoldableSimulator(udid) {
81931
81951
  const device = resolveDevice(udid);
81932
81952
  if (device.platform !== "ios" || device.kind !== "simulator") return false;
81933
81953
  const cached3 = foldableCache.get(udid);
81934
81954
  if (cached3 !== void 0) return cached3;
81935
- const found = await findIosSimulator(udid);
81936
- const foldable = found?.foldable === true;
81937
- if (found) foldableCache.set(udid, foldable);
81955
+ const { found, timedOut: timedOut3 } = await lookUpIosSimulator(udid);
81956
+ if (!found) return timedOut3 ? "timed-out" : false;
81957
+ const foldable = found.foldable === true;
81958
+ foldableCache.set(udid, foldable);
81938
81959
  return foldable;
81939
81960
  }
81940
81961
 
@@ -108922,6 +108943,9 @@ function outdatedCloudCliNote(version3) {
108922
108943
  }
108923
108944
  var ANDROID_SDK_MISSING_NOTE = "Android: no SDK found (adb, emulator). Installing the platform tools and creating an AVD adds Android targets.";
108924
108945
  var EXTERNAL_DEVICES_HINT = `Some entries are tagged 'external: true': another application is already driving that device, and its 'provider' field names it ('provider.workspace' names the project it opened, when it published one). Drive them with the usual tools, by the 'ext:'-prefixed id. Two rules differ: prefer the external device whose 'provider.workspace.path' matches the project you are working in, and do NOT call boot-device on them, since the provider owns their lifecycle. stop-simulator-server IS safe on them and never stops the provider's server \u2014 it drops argent's cached handles, which is the recovery when calls keep failing against an endpoint the provider has since moved. Each entry's 'capabilities' lists the mechanisms that provider granted; a tool relying on one it withheld fails with a clear message naming the provider.`;
108946
+ function foldableCheckTimedOutHint(names) {
108947
+ return `The foldable check did not finish in time for ${names.join(", ")}, so 'foldable: true' may be missing there. Call list-devices again to retry the check.`;
108948
+ }
108925
108949
  function iosListTimedOutHint() {
108926
108950
  return `iOS simulators may be missing from this list: ${simctlListTimeoutAdvice("list-devices")}`;
108927
108951
  }
@@ -109102,10 +109126,11 @@ async function withClaim(device, session) {
109102
109126
  const claim2 = id === void 0 ? void 0 : await deviceClaims.ownerOf(claimKey(id), session);
109103
109127
  return claim2 ? { ...device, claim: claim2 } : device;
109104
109128
  }
109105
- function toListedExternal(device) {
109129
+ function toListedExternal(device, foldable) {
109106
109130
  return {
109107
109131
  capabilities: Array.from(device.capabilities).sort(),
109108
109132
  external: true,
109133
+ ...foldable ? { foldable: true } : {},
109109
109134
  id: device.id,
109110
109135
  kind: device.kind,
109111
109136
  name: device.name,
@@ -109120,6 +109145,39 @@ function toListedExternal(device) {
109120
109145
  ...device.platform === "ios" ? { udid: device.id } : { serial: device.id }
109121
109146
  };
109122
109147
  }
109148
+ var EXTERNAL_FOLDABLE_BUDGET_MS = 5e3;
109149
+ async function withFoldableFlags(external) {
109150
+ const simulators = external.filter(
109151
+ (device) => device.platform === "ios" && device.kind === "simulator"
109152
+ );
109153
+ if (simulators.length === 0) {
109154
+ return external.map((device) => ({ device, foldable: false, foldableTimedOut: false }));
109155
+ }
109156
+ let timer;
109157
+ const budget = new Promise((resolve24) => {
109158
+ timer = setTimeout(() => resolve24("timed-out"), EXTERNAL_FOLDABLE_BUDGET_MS);
109159
+ });
109160
+ try {
109161
+ return await Promise.all(
109162
+ external.map(async (device) => {
109163
+ if (!simulators.includes(device)) {
109164
+ return { device, foldable: false, foldableTimedOut: false };
109165
+ }
109166
+ const verdict = await Promise.race([
109167
+ checkFoldableSimulator(device.id).catch(() => false),
109168
+ budget
109169
+ ]);
109170
+ return {
109171
+ device,
109172
+ foldable: verdict === true,
109173
+ foldableTimedOut: verdict === "timed-out"
109174
+ };
109175
+ })
109176
+ );
109177
+ } finally {
109178
+ clearTimeout(timer);
109179
+ }
109180
+ }
109123
109181
  function externalShadowIds(external) {
109124
109182
  return new Set(external.map((device) => device.nativeId));
109125
109183
  }
@@ -109197,10 +109255,11 @@ Use when starting a session to discover target ids. Returns { devices, notes? }.
109197
109255
  ) : [],
109198
109256
  /**
109199
109257
  * One directory stat when no provider is registered (the common case)
109200
- * and a short HTTP probe per provider otherwise.
109258
+ * and a short HTTP probe per provider otherwise, then the foldable
109259
+ * check of each lent simulator.
109201
109260
  */
109202
109261
  withDeadline(
109203
- listExternalDevices().catch(() => []),
109262
+ listExternalDevices().catch(() => []).then(withFoldableFlags),
109204
109263
  [],
109205
109264
  "external"
109206
109265
  ),
@@ -109215,7 +109274,7 @@ Use when starting a session to discover target ids. Returns { devices, notes? }.
109215
109274
  "cloud-android"
109216
109275
  )
109217
109276
  ]);
109218
- const externalShadows = externalShadowIds(external);
109277
+ const externalShadows = externalShadowIds(external.map(({ device }) => device));
109219
109278
  const iosTagged = ios.simulators.filter((simulator) => !externalShadows.has(simulator.udid)).map((simulator) => ({ platform: "ios", kind: "simulator", ...simulator }));
109220
109279
  iosTagged.sort(sortIos);
109221
109280
  const iosPhysicalTagged = iosPhysical.filter((d) => !externalShadows.has(d.udid)).map((d) => ({
@@ -109311,7 +109370,7 @@ Use when starting a session to discover target ids. Returns { devices, notes? }.
109311
109370
  ...macos,
109312
109371
  ...vega,
109313
109372
  ...harmonyTagged,
109314
- ...external.map(toListedExternal)
109373
+ ...external.map(({ device, foldable }) => toListedExternal(device, foldable))
109315
109374
  ];
109316
109375
  devices2.sort((a, b) => readinessRank(a) - readinessRank(b));
109317
109376
  const listed = await Promise.all(devices2.map((device) => withClaim(device, ctx?.session)));
@@ -109323,6 +109382,7 @@ Use when starting a session to discover target ids. Returns { devices, notes? }.
109323
109382
  { localIos, darwin: process.platform === "darwin" },
109324
109383
  iosRemote.cloud
109325
109384
  );
109385
+ const foldableTimedOut = external.filter((entry) => entry.foldableTimedOut).map(({ device }) => device.name);
109326
109386
  const cloudCliNote = outdatedCloudCliNote(iosRemote.version);
109327
109387
  const adbPrefix = adbCommandPrefix(process.env);
109328
109388
  const notes = [
@@ -109334,6 +109394,7 @@ Use when starting a session to discover target ids. Returns { devices, notes? }.
109334
109394
  ...xcodeInstallPending.length > 0 ? [xcodeFirstLaunchHint(xcodeInstallPending)] : [],
109335
109395
  ...ios.timedOut ? [iosListTimedOutHint()] : [],
109336
109396
  ...external.length > 0 ? [EXTERNAL_DEVICES_HINT] : [],
109397
+ ...foldableTimedOut.length > 0 ? [foldableCheckTimedOutHint(foldableTimedOut)] : [],
109337
109398
  ...adbPrefix ? [adbServerHint(adbPrefix)] : []
109338
109399
  ];
109339
109400
  return { devices: listed, ...notes.length > 0 ? { notes } : {} };
@@ -109823,6 +109884,16 @@ var fs37 = __toESM(require("node:fs"));
109823
109884
  init_src2();
109824
109885
  init_external_devices();
109825
109886
 
109887
+ // ../tool-server/src/utils/socket-tag.ts
109888
+ var import_node_crypto14 = require("node:crypto");
109889
+ function socketTag(deviceId) {
109890
+ if (/^[A-Za-z0-9-]+$/.test(deviceId)) return deviceId.slice(0, 8);
109891
+ return (0, import_node_crypto14.createHash)("sha256").update(deviceId).digest("hex").slice(0, 12);
109892
+ }
109893
+ function axServiceSocketPath(deviceId) {
109894
+ return `/tmp/ax-${socketTag(deviceId)}.sock`;
109895
+ }
109896
+
109826
109897
  // ../tool-server/src/tools/describe/contract.ts
109827
109898
  init_zod();
109828
109899
  var describeFrameSchema = external_exports.object({
@@ -109892,9 +109963,6 @@ function axServiceRef(device, { transport = "unix" } = {}) {
109892
109963
  }
109893
109964
  var LIVE_PANEL_TIMEOUT_MS = 2e3;
109894
109965
  var FILL_TIMEOUT_MS = 6e3;
109895
- function getSocketPath(udid) {
109896
- return `/tmp/ax-${udid.slice(0, 8)}.sock`;
109897
- }
109898
109966
  function startListener(endpoint, onConnection) {
109899
109967
  return new Promise((resolve24, reject) => {
109900
109968
  if (endpoint.transport === "unix") {
@@ -110129,7 +110197,7 @@ var axServiceBlueprint = {
110129
110197
  const udid = device.id;
110130
110198
  const host = pickIosHost(device);
110131
110199
  const transport = host.requiresTcp ? "tcp" : opts.transport ?? "unix";
110132
- const endpoint = transport === "tcp" ? { transport: "tcp" } : { transport: "unix", socketPath: getSocketPath(udid) };
110200
+ const endpoint = transport === "tcp" ? { transport: "tcp" } : { transport: "unix", socketPath: axServiceSocketPath(udid) };
110133
110201
  const events = new TypedEventEmitter();
110134
110202
  const pendingRpc = /* @__PURE__ */ new Map();
110135
110203
  let nextRpcId = 1;
@@ -115288,7 +115356,7 @@ function browserMajor(browser) {
115288
115356
  const m = /\/(\d+)\./.exec(browser ?? "");
115289
115357
  return m ? Number(m[1]) : void 0;
115290
115358
  }
115291
- var PROBE_TIMEOUT_MS2 = 1e3;
115359
+ var PROBE_TIMEOUT_MS = 1e3;
115292
115360
  var WALK_TIMEOUT_MS = 2e3;
115293
115361
  function withTimeout2(promise2, ms3, what) {
115294
115362
  let timer;
@@ -115361,7 +115429,7 @@ var androidChromeCdpBlueprint = {
115361
115429
  }
115362
115430
  const version3 = await ensureCdpReachable(
115363
115431
  entry.port,
115364
- AbortSignal.timeout(PROBE_TIMEOUT_MS2)
115432
+ AbortSignal.timeout(PROBE_TIMEOUT_MS)
115365
115433
  ).catch(() => void 0);
115366
115434
  entry.pkg = version3?.["Android-Package"];
115367
115435
  entry.major = browserMajor(version3?.Browser);
@@ -115382,13 +115450,13 @@ var androidChromeCdpBlueprint = {
115382
115450
  cdp = new CDPClient(target.webSocketDebuggerUrl, { sendOrigin: false });
115383
115451
  const opening = cdp.connect();
115384
115452
  try {
115385
- await withTimeout2(opening, PROBE_TIMEOUT_MS2, "CDP connect");
115453
+ await withTimeout2(opening, PROBE_TIMEOUT_MS, "CDP connect");
115386
115454
  } catch {
115387
115455
  void opening.then(() => cdp.disconnect()).catch(() => void 0);
115388
115456
  return void 0;
115389
115457
  }
115390
115458
  }
115391
- const visible = await evaluateValue(cdp, "document.visibilityState", PROBE_TIMEOUT_MS2).catch(
115459
+ const visible = await evaluateValue(cdp, "document.visibilityState", PROBE_TIMEOUT_MS).catch(
115392
115460
  () => void 0
115393
115461
  );
115394
115462
  if (visible === "visible") return cdp;
@@ -115412,7 +115480,7 @@ var androidChromeCdpBlueprint = {
115412
115480
  if (major2 !== void 0 && major2 < MIN_CHROME_MAJOR) {
115413
115481
  throw new Error(`Chrome ${major2} publishes its tabs to accessibility`);
115414
115482
  }
115415
- const targets = await listPageTargets(port, AbortSignal.timeout(PROBE_TIMEOUT_MS2));
115483
+ const targets = await listPageTargets(port, AbortSignal.timeout(PROBE_TIMEOUT_MS));
115416
115484
  if (targets.length === 0) throw new Error("no page targets");
115417
115485
  const picked = await firstVisible(targets);
115418
115486
  if (!picked) throw new Error("no visible tab");
@@ -115425,7 +115493,7 @@ var androidChromeCdpBlueprint = {
115425
115493
  const visible = await evaluateValue(
115426
115494
  tab.cdp,
115427
115495
  "document.visibilityState",
115428
- PROBE_TIMEOUT_MS2
115496
+ PROBE_TIMEOUT_MS
115429
115497
  ).catch(() => dropTab());
115430
115498
  return visible === "visible" ? tab?.cdp : void 0;
115431
115499
  };
@@ -115433,7 +115501,7 @@ var androidChromeCdpBlueprint = {
115433
115501
  const cdp = await cachedVisible(pkg) ?? await pickVisibleTab(pkg, await browserPort(pkg));
115434
115502
  try {
115435
115503
  const viewport = JSON.parse(
115436
- String(await evaluateValue(cdp, VIEWPORT_EXPRESSION, PROBE_TIMEOUT_MS2))
115504
+ String(await evaluateValue(cdp, VIEWPORT_EXPRESSION, PROBE_TIMEOUT_MS))
115437
115505
  );
115438
115506
  const data = await withTimeout2(evaluateDescribeDom(cdp), WALK_TIMEOUT_MS, "DOM walk");
115439
115507
  return { ...data, viewport };
@@ -118150,7 +118218,7 @@ function reserveLaunchMeasurement(udid) {
118150
118218
  // ../tool-server/src/utils/ios-device/runner-artifact.ts
118151
118219
  var import_node_child_process29 = require("node:child_process");
118152
118220
  var import_node_util21 = require("node:util");
118153
- var import_node_crypto14 = require("node:crypto");
118221
+ var import_node_crypto15 = require("node:crypto");
118154
118222
  var fs42 = __toESM(require("node:fs"));
118155
118223
  var fsp = __toESM(require("node:fs/promises"));
118156
118224
  var path36 = __toESM(require("node:path"));
@@ -118309,7 +118377,7 @@ var FINGERPRINT_NOISE = /* @__PURE__ */ new Set([
118309
118377
  ]);
118310
118378
  async function fingerprintRunnerSources(projectPath) {
118311
118379
  const root = path36.dirname(projectPath);
118312
- const hash2 = (0, import_node_crypto14.createHash)("sha256");
118380
+ const hash2 = (0, import_node_crypto15.createHash)("sha256");
118313
118381
  const walk = async (dir) => {
118314
118382
  const entries = (await fsp.readdir(dir, { withFileTypes: true })).sort(
118315
118383
  (a, b) => a.name.localeCompare(b.name)
@@ -118418,7 +118486,7 @@ function runnerBuildLocationArgs(derivedDataPath) {
118418
118486
  ];
118419
118487
  }
118420
118488
  function computeRunnerCacheKey(sourcesHash, xcodeVersion2, staticArgs) {
118421
- return (0, import_node_crypto14.createHash)("sha256").update([sourcesHash, xcodeVersion2, ...staticArgs].join("\n")).digest("hex").slice(0, 16);
118489
+ return (0, import_node_crypto15.createHash)("sha256").update([sourcesHash, xcodeVersion2, ...staticArgs].join("\n")).digest("hex").slice(0, 16);
118422
118490
  }
118423
118491
  function isProfileMissingDeviceFailure(logText) {
118424
118492
  return logText.includes("0xe8008012") || /doesn't include the currently selected device/i.test(logText) || /provisioning profile cannot be installed on this device/i.test(logText) || /team has no devices/i.test(logText);
@@ -119152,7 +119220,7 @@ async function readRunnerCrashSummary(resultBundlePath) {
119152
119220
  }
119153
119221
 
119154
119222
  // ../tool-server/src/utils/ios-device/runner-client.ts
119155
- var import_node_crypto15 = require("node:crypto");
119223
+ var import_node_crypto16 = require("node:crypto");
119156
119224
  init_src2();
119157
119225
  var RUNNER_COMMAND_TIMEOUT_MS = 45e3;
119158
119226
  var RUNNER_STATUS_RECOVERY_TIMEOUT_MS = 3e3;
@@ -119365,7 +119433,7 @@ function withCommandId(command2) {
119365
119433
  if (command2.command === "status" || typeof command2.commandId === "string") {
119366
119434
  return command2;
119367
119435
  }
119368
- return { ...command2, commandId: `argent-${(0, import_node_crypto15.randomUUID)()}` };
119436
+ return { ...command2, commandId: `argent-${(0, import_node_crypto16.randomUUID)()}` };
119369
119437
  }
119370
119438
  function unwrapEnvelope(response, udid) {
119371
119439
  const envelope = asEnvelope(response);
@@ -125053,7 +125121,7 @@ init_src2();
125053
125121
 
125054
125122
  // ../tool-server/src/blueprints/macos-app.ts
125055
125123
  var import_node_child_process33 = require("node:child_process");
125056
- var import_node_crypto16 = require("node:crypto");
125124
+ var import_node_crypto17 = require("node:crypto");
125057
125125
  var import_node_events5 = require("node:events");
125058
125126
  var fs46 = __toESM(require("node:fs"));
125059
125127
  var net9 = __toESM(require("node:net"));
@@ -125340,7 +125408,7 @@ function closedByArgentError(bundleId, method) {
125340
125408
  "unknown"
125341
125409
  );
125342
125410
  }
125343
- var nextCdpWireId = (0, import_node_crypto16.randomInt)(2 ** 47);
125411
+ var nextCdpWireId = (0, import_node_crypto17.randomInt)(2 ** 47);
125344
125412
  var LibraryChannel = class {
125345
125413
  /**
125346
125414
  * @param expectedPid the app's pid when known; a launch learns it from the helper after the spawn.
@@ -128982,7 +129050,7 @@ function createHttpApp(registry2, options) {
128982
129050
  });
128983
129051
  return;
128984
129052
  }
128985
- const id = (0, import_node_crypto17.randomUUID)();
129053
+ const id = (0, import_node_crypto18.randomUUID)();
128986
129054
  const tarPath = (0, import_node_path18.join)((0, import_node_os13.tmpdir)(), `argent-upload-${id}.tar.gz`);
128987
129055
  const ws = (0, import_node_fs14.createWriteStream)(tarPath);
128988
129056
  let received2 = 0;
@@ -128999,7 +129067,7 @@ function createHttpApp(registry2, options) {
128999
129067
  });
129000
129068
  if (!res.headersSent) res.status(status).json({ error: message });
129001
129069
  };
129002
- const digest = (0, import_node_crypto17.createHash)("sha256");
129070
+ const digest = (0, import_node_crypto18.createHash)("sha256");
129003
129071
  req.on("data", (chunk) => {
129004
129072
  if (released) return;
129005
129073
  received2 += chunk.length;
@@ -129336,7 +129404,7 @@ function createHttpApp(registry2, options) {
129336
129404
  });
129337
129405
  const keepAlive = def.longRunning && options?.idleTimeoutMs && options.idleTimeoutMs > 0 ? setInterval(() => idleTimer.touch(), Math.max(1e3, IDLE_CHECK_INTERVAL_MS / 2)) : null;
129338
129406
  if (keepAlive) keepAlive.unref?.();
129339
- const toolInvocationId = (0, import_node_crypto17.randomUUID)();
129407
+ const toolInvocationId = (0, import_node_crypto18.randomUUID)();
129340
129408
  let releaseInvocationMeta;
129341
129409
  let recordChildInvocation;
129342
129410
  const recordInvocation = options?.recordInvocation;
@@ -129692,7 +129760,7 @@ init_src2();
129692
129760
  init_src();
129693
129761
 
129694
129762
  // ../tool-server/src/blueprints/android-network-inspector.ts
129695
- var import_node_crypto18 = require("node:crypto");
129763
+ var import_node_crypto19 = require("node:crypto");
129696
129764
  var fs48 = __toESM(require("node:fs"));
129697
129765
  var net10 = __toESM(require("node:net"));
129698
129766
  var path41 = __toESM(require("node:path"));
@@ -129899,7 +129967,7 @@ var NOT_RECONNECTED_NOTE = "the agent's connection dropped, and it did not recon
129899
129967
  var STOPPED_NOTE = "capture stopped by network-capture-stop; network-capture-start turns it on again";
129900
129968
  var AWAY_AT_STOP = "the agent's connection was down at the stop, so it did not get Network.disable; it gets it when it connects again, and argent records none of the app's new requests meanwhile";
129901
129969
  var LOGGED_DETAIL_EVENTS = /* @__PURE__ */ new Set(["interceptor_installed", "interceptor_failed"]);
129902
- var RUN_TAG2 = (0, import_node_crypto18.randomBytes)(2).toString("hex");
129970
+ var RUN_TAG2 = (0, import_node_crypto19.randomBytes)(2).toString("hex");
129903
129971
  var ANDROID_NATIVE_REQUEST_ID = /^android-[0-9a-f]{4}-\d+$/;
129904
129972
  var liveInspectors = /* @__PURE__ */ new Map();
129905
129973
  var nextRecordNumber2 = 1;
@@ -130009,7 +130077,7 @@ function createInspector(serial, packageName, initialMetroPort) {
130009
130077
  process.stderr.write(`[${tag3}] ${line}
130010
130078
  `);
130011
130079
  };
130012
- const secret = (0, import_node_crypto18.randomBytes)(32).toString("hex");
130080
+ const secret = (0, import_node_crypto19.randomBytes)(32).toString("hex");
130013
130081
  let metroPort2 = initialMetroPort;
130014
130082
  let disposed = false;
130015
130083
  let live = false;
@@ -130238,7 +130306,7 @@ function createInspector(serial, packageName, initialMetroPort) {
130238
130306
  }
130239
130307
  async function bindDevicePort() {
130240
130308
  for (let attempt = 0; attempt < DEVICE_PORT_ATTEMPTS; attempt++) {
130241
- const port = DEVICE_PORT_MIN + (0, import_node_crypto18.randomInt)(DEVICE_PORT_SPAN);
130309
+ const port = DEVICE_PORT_MIN + (0, import_node_crypto19.randomInt)(DEVICE_PORT_SPAN);
130242
130310
  try {
130243
130311
  await adbReverse(serial, port, hostPort, { timeoutMs: 1e4, noRebind: true });
130244
130312
  } catch (err) {
@@ -130496,7 +130564,7 @@ function createInspector(serial, packageName, initialMetroPort) {
130496
130564
  return;
130497
130565
  }
130498
130566
  agentNonce = payload.nonce;
130499
- serverNonce = (0, import_node_crypto18.randomBytes)(16).toString("hex");
130567
+ serverNonce = (0, import_node_crypto19.randomBytes)(16).toString("hex");
130500
130568
  writeNdjsonFrame(socket, {
130501
130569
  type: "Control",
130502
130570
  payload: {
@@ -131383,14 +131451,14 @@ function readHandshake(payload) {
131383
131451
  }
131384
131452
  function proofMatches(proof, expected) {
131385
131453
  if (!isHex2(proof, 64)) return false;
131386
- return (0, import_node_crypto18.timingSafeEqual)(Buffer.from(proof, "hex"), Buffer.from(expected, "hex"));
131454
+ return (0, import_node_crypto19.timingSafeEqual)(Buffer.from(proof, "hex"), Buffer.from(expected, "hex"));
131387
131455
  }
131388
131456
  function handshakeProof(secret, parts2) {
131389
- return (0, import_node_crypto18.createHmac)("sha256", Buffer.from(secret, "ascii")).update(parts2.join("\n"), "utf8").digest("hex");
131457
+ return (0, import_node_crypto19.createHmac)("sha256", Buffer.from(secret, "ascii")).update(parts2.join("\n"), "utf8").digest("hex");
131390
131458
  }
131391
131459
  function sessionKeys(agentNonce, serverNonce, secret) {
131392
- const prk = (0, import_node_crypto18.createHmac)("sha256", Buffer.from(agentNonce + serverNonce, "ascii")).update(Buffer.from(secret, "ascii")).digest();
131393
- const expand = (info) => (0, import_node_crypto18.createHmac)("sha256", prk).update(Buffer.concat([Buffer.from(info, "ascii"), Buffer.of(1)])).digest();
131460
+ const prk = (0, import_node_crypto19.createHmac)("sha256", Buffer.from(agentNonce + serverNonce, "ascii")).update(Buffer.from(secret, "ascii")).digest();
131461
+ const expand = (info) => (0, import_node_crypto19.createHmac)("sha256", prk).update(Buffer.concat([Buffer.from(info, "ascii"), Buffer.of(1)])).digest();
131394
131462
  return {
131395
131463
  agent: expand("argent-nwi agent to server"),
131396
131464
  server: expand("argent-nwi server to agent")
@@ -131402,7 +131470,7 @@ function frameIv(counter) {
131402
131470
  return iv;
131403
131471
  }
131404
131472
  function sealFrame(key2, counter, frame2) {
131405
- const cipher = (0, import_node_crypto18.createCipheriv)("aes-256-gcm", key2, frameIv(counter), {
131473
+ const cipher = (0, import_node_crypto19.createCipheriv)("aes-256-gcm", key2, frameIv(counter), {
131406
131474
  authTagLength: GCM_TAG_BYTES
131407
131475
  });
131408
131476
  return Buffer.concat([
@@ -131420,7 +131488,7 @@ function openFrame(key2, counter, sealed) {
131420
131488
  }
131421
131489
  let plaintext;
131422
131490
  try {
131423
- const decipher = (0, import_node_crypto18.createDecipheriv)("aes-256-gcm", key2, frameIv(counter), {
131491
+ const decipher = (0, import_node_crypto19.createDecipheriv)("aes-256-gcm", key2, frameIv(counter), {
131424
131492
  authTagLength: GCM_TAG_BYTES
131425
131493
  });
131426
131494
  decipher.setAuthTag(bytes.subarray(bytes.length - GCM_TAG_BYTES));
@@ -133304,7 +133372,7 @@ init_device_info();
133304
133372
  init_external_devices();
133305
133373
 
133306
133374
  // ../tool-server/src/utils/debugger/target-selection.ts
133307
- var import_node_crypto19 = require("node:crypto");
133375
+ var import_node_crypto20 = require("node:crypto");
133308
133376
  init_src2();
133309
133377
  init_device_info();
133310
133378
  init_macos_app_kind();
@@ -133326,7 +133394,7 @@ function macosAppBundleIdOf(target) {
133326
133394
  const vendorIds = trackedMacosAppKind(bundleId) === "catalyst" ? catalystVendorId ? [catalystVendorId] : [] : [""];
133327
133395
  for (const vendorId of vendorIds) {
133328
133396
  for (const mode of ["fusebox", "legacy"]) {
133329
- const id = (0, import_node_crypto19.createHash)("sha256").update(`apple-${vendorId}-${bundleId}-${mode}`).digest("hex").slice(0, 40);
133397
+ const id = (0, import_node_crypto20.createHash)("sha256").update(`apple-${vendorId}-${bundleId}-${mode}`).digest("hex").slice(0, 40);
133330
133398
  if (id === logicalId) return bundleId;
133331
133399
  }
133332
133400
  }
@@ -133470,7 +133538,7 @@ init_device_info();
133470
133538
  init_external_devices();
133471
133539
 
133472
133540
  // ../tool-server/src/utils/debugger/runtime-device.ts
133473
- var import_node_crypto20 = require("node:crypto");
133541
+ var import_node_crypto21 = require("node:crypto");
133474
133542
  var import_node_child_process34 = require("node:child_process");
133475
133543
  var import_node_util25 = require("node:util");
133476
133544
  init_adb();
@@ -133483,7 +133551,7 @@ async function findRuntimeDevices(cdp, {
133483
133551
  awaitSerials = [],
133484
133552
  waitSerials = []
133485
133553
  } = {}) {
133486
- const marker = `argent-device-probe:${(0, import_node_crypto20.randomUUID)()}`;
133554
+ const marker = `argent-device-probe:${(0, import_node_crypto21.randomUUID)()}`;
133487
133555
  const logged = await cdp.evaluate(
133488
133556
  `(function () {
133489
133557
  if (typeof nativeLoggingHook !== "function") return false;
@@ -134255,7 +134323,7 @@ var jsRuntimeDebuggerBlueprint = {
134255
134323
  init_src2();
134256
134324
 
134257
134325
  // ../tool-server/src/utils/debugger/scripts/network-interceptor.ts
134258
- var import_node_crypto21 = require("node:crypto");
134326
+ var import_node_crypto22 = require("node:crypto");
134259
134327
  var import_node_os14 = require("node:os");
134260
134328
  init_src3();
134261
134329
  var BINARY_BODY_TYPES = /^(image\/(?!svg)|audio\/|video\/|font\/|application\/(octet-stream|pdf|zip|gzip|wasm|x-protobuf)$)/;
@@ -135335,7 +135403,7 @@ var NETWORK_CAPTURE_MARK_SCRIPT = `(function() {
135335
135403
  var g = globalThis;
135336
135404
  return typeof g.__argent_network_mark === 'function' ? g.__argent_network_mark() : JSON.stringify({ install: null });
135337
135405
  })()`;
135338
- var HOLDER = JSON.stringify((0, import_node_crypto21.randomUUID)());
135406
+ var HOLDER = JSON.stringify((0, import_node_crypto22.randomUUID)());
135339
135407
  function holderRecord(capturing2) {
135340
135408
  return JSON.stringify({ capturing: capturing2, pid: process.pid, host: (0, import_node_os14.hostname)() });
135341
135409
  }
@@ -146455,7 +146523,7 @@ async function queryChromiumTree(registry2, device) {
146455
146523
  }
146456
146524
 
146457
146525
  // ../tool-server/src/utils/sub-invoke.ts
146458
- var import_node_crypto22 = require("node:crypto");
146526
+ var import_node_crypto23 = require("node:crypto");
146459
146527
  init_src2();
146460
146528
  async function invokeSubTool(registry2, ctx, toolId, args, extra) {
146461
146529
  const signal = ctx?.signal;
@@ -146473,7 +146541,7 @@ async function invokeSubTool(registry2, ctx, toolId, args, extra) {
146473
146541
  if (!recordChildInvocation) {
146474
146542
  return signal || Object.keys(forwarded).length > 0 ? registry2.invokeTool(toolId, args, { ...signal ? { signal } : {}, ...forwarded }) : registry2.invokeTool(toolId, args);
146475
146543
  }
146476
- const toolInvocationId = (0, import_node_crypto22.randomUUID)();
146544
+ const toolInvocationId = (0, import_node_crypto23.randomUUID)();
146477
146545
  const release3 = recordChildInvocation(toolInvocationId, args);
146478
146546
  try {
146479
146547
  return await registry2.invokeTool(toolId, args, {
@@ -161165,7 +161233,7 @@ var import_node_child_process51 = require("node:child_process");
161165
161233
  var import_node_util41 = require("node:util");
161166
161234
  var fsp5 = __toESM(require("node:fs/promises"));
161167
161235
  var path56 = __toESM(require("node:path"));
161168
- var import_node_crypto23 = require("node:crypto");
161236
+ var import_node_crypto24 = require("node:crypto");
161169
161237
  init_src2();
161170
161238
 
161171
161239
  // ../tool-server/src/utils/ios-launch-time/workflow.ts
@@ -161749,7 +161817,7 @@ async function measurePreparedLaunch(context2, ctx) {
161749
161817
  const runnerSigning = context2.simulator ? null : await resolveRunnerSigningConfig(context2.deviceId);
161750
161818
  const runnerBundleId = runnerSigning?.appBundleId ?? "com.argent.runner.tsimulator";
161751
161819
  const testBundleId = runnerSigning?.testBundleId ?? `${runnerBundleId}.uitests`;
161752
- const runnerBuildKey = (0, import_node_crypto23.createHash)("sha256").update(
161820
+ const runnerBuildKey = (0, import_node_crypto24.createHash)("sha256").update(
161753
161821
  [
161754
161822
  // Builds for two simulators, or two iPhones, are the same build.
161755
161823
  context2.simulator ? "iOS Simulator" : "iOS",
@@ -161888,7 +161956,7 @@ async function measurePreparedLaunch(context2, ctx) {
161888
161956
 
161889
161957
  // ../tool-server/src/tools/profiler/native-profiler/launch-analysis/profile.ts
161890
161958
  var import_node_child_process52 = require("node:child_process");
161891
- var import_node_crypto24 = require("node:crypto");
161959
+ var import_node_crypto25 = require("node:crypto");
161892
161960
  var import_node_util42 = require("node:util");
161893
161961
  var fsp6 = __toESM(require("node:fs/promises"));
161894
161962
  var path57 = __toESM(require("node:path"));
@@ -162136,7 +162204,7 @@ var TABLE_XPATH = (schema) => `/trace-toc/run[@number="1"]/data/table[@schema="$
162136
162204
  async function writeProfilerSession(xml) {
162137
162205
  const debugDir = await getDebugDir();
162138
162206
  const timestamp = (/* @__PURE__ */ new Date()).toISOString().replace(/[-:]/g, "").replace("T", "-").slice(0, 15);
162139
- const sessionId = `${timestamp}-launch-${(0, import_node_crypto24.randomUUID)()}`;
162207
+ const sessionId = `${timestamp}-launch-${(0, import_node_crypto25.randomUUID)()}`;
162140
162208
  const cpuXmlPath = path57.join(debugDir, `native-profiler-${sessionId}_raw_cpu.xml`);
162141
162209
  await fsp6.writeFile(cpuXmlPath, xml, { flag: "wx" });
162142
162210
  return { sessionId, cpuXmlPath };
@@ -162475,7 +162543,7 @@ init_zod();
162475
162543
  var import_node_child_process53 = require("node:child_process");
162476
162544
  var fs70 = __toESM(require("node:fs"));
162477
162545
  var path58 = __toESM(require("node:path"));
162478
- var import_node_crypto25 = require("node:crypto");
162546
+ var import_node_crypto26 = require("node:crypto");
162479
162547
  var import_node_util43 = require("node:util");
162480
162548
  init_src2();
162481
162549
  init_capability();
@@ -162691,7 +162759,7 @@ async function setAudioInput(session, source) {
162691
162759
  } else {
162692
162760
  removeFiles(dir, `in-${process.pid}-`);
162693
162761
  feeder = new InputFeeder(
162694
- path58.join(dir, `in-${process.pid}-${(0, import_node_crypto25.randomUUID)().slice(0, 8)}.ring`),
162762
+ path58.join(dir, `in-${process.pid}-${(0, import_node_crypto26.randomUUID)().slice(0, 8)}.ring`),
162695
162763
  feederSource
162696
162764
  );
162697
162765
  feeder.start();
@@ -162744,7 +162812,7 @@ function releaseAudio(session) {
162744
162812
  var fs71 = __toESM(require("node:fs"));
162745
162813
  var net13 = __toESM(require("node:net"));
162746
162814
  var path59 = __toESM(require("node:path"));
162747
- var import_node_crypto26 = require("node:crypto");
162815
+ var import_node_crypto27 = require("node:crypto");
162748
162816
  init_src2();
162749
162817
  init_device_info();
162750
162818
  init_capability();
@@ -162917,7 +162985,7 @@ async function startFeeder(session) {
162917
162985
  const stale = session.link;
162918
162986
  session.link = null;
162919
162987
  await stale?.close();
162920
- const token = (0, import_node_crypto26.randomBytes)(12).toString("hex");
162988
+ const token = (0, import_node_crypto27.randomBytes)(12).toString("hex");
162921
162989
  const server = net13.createServer();
162922
162990
  await new Promise((resolve24, reject) => {
162923
162991
  server.once("error", reject);
@@ -164229,7 +164297,7 @@ var import_util16 = require("util");
164229
164297
  init_src2();
164230
164298
  init_device_info();
164231
164299
  var POST_PASS_TIMEOUT_MS = 10 * 6e4;
164232
- var PROBE_TIMEOUT_MS3 = 15e3;
164300
+ var PROBE_TIMEOUT_MS2 = 15e3;
164233
164301
  var execFileAsync44 = (0, import_util16.promisify)(import_child_process10.execFile);
164234
164302
  var TRIM_FILTERS = `fps=${OUTPUT_FPS},mpdecimate=hi=1:lo=1:frac=1,setpts=N/${OUTPUT_FPS}/TB,tpad=stop_mode=clone:stop_duration=1`;
164235
164303
  async function startRemoteCapture(api, params) {
@@ -164485,7 +164553,7 @@ async function probe3(file2, entries) {
164485
164553
  "default=noprint_wrappers=1:nokey=1",
164486
164554
  file2
164487
164555
  ],
164488
- { timeout: PROBE_TIMEOUT_MS3, encoding: "utf8" }
164556
+ { timeout: PROBE_TIMEOUT_MS2, encoding: "utf8" }
164489
164557
  );
164490
164558
  return String(stdout).trim().split(/\s+/);
164491
164559
  } catch {
@@ -174026,7 +174094,7 @@ init_device_info();
174026
174094
  init_capability();
174027
174095
 
174028
174096
  // ../tool-server/src/tools/flows/flow-visual.ts
174029
- var import_node_crypto27 = require("node:crypto");
174097
+ var import_node_crypto28 = require("node:crypto");
174030
174098
  var fs90 = __toESM(require("node:fs/promises"));
174031
174099
  var os19 = __toESM(require("node:os"));
174032
174100
  var path72 = __toESM(require("node:path"));
@@ -176172,7 +176240,7 @@ async function runSnapshot(env, opts) {
176172
176240
  });
176173
176241
  let captureWarned = shot.warning !== void 0 ? { warning: shot.warning } : {};
176174
176242
  const { w, h } = await pngDimensions(shot.image.hostPath);
176175
- const cropSuffix = opts.cropOn === void 0 ? "" : `-crop-${(0, import_node_crypto27.createHash)("sha256").update(cropIdentity(opts.cropOn)).digest("hex").slice(0, 8)}`;
176243
+ const cropSuffix = opts.cropOn === void 0 ? "" : `-crop-${(0, import_node_crypto28.createHash)("sha256").update(cropIdentity(opts.cropOn)).digest("hex").slice(0, 8)}`;
176176
176244
  const keyFor = (width, height) => `${opts.name}__${authoringPlatform(env.device.platform)}-${width}x${height}${cropSuffix}`;
176177
176245
  const baselineFor = (file2) => opts.clientFlowPath === void 0 ? path72.join(baselineDir(opts.flowsDir, opts.flowName), file2) : clientBaselinePath(opts.clientFlowPath, opts.flowName, file2);
176178
176246
  const snapshotKey = keyFor(w, h);
@@ -178678,7 +178746,7 @@ var dismissUpdateTool = {
178678
178746
  };
178679
178747
 
178680
178748
  // ../tool-server/src/tools/screenshot-diff/index.ts
178681
- var import_node_crypto28 = __toESM(require("node:crypto"));
178749
+ var import_node_crypto29 = __toESM(require("node:crypto"));
178682
178750
  var import_promises26 = __toESM(require("fs/promises"));
178683
178751
  var import_node_os19 = __toESM(require("node:os"));
178684
178752
  var import_path9 = __toESM(require("path"));
@@ -178822,7 +178890,7 @@ async function resolveOutputDir(params, options) {
178822
178890
  const dir = import_path9.default.join(
178823
178891
  import_node_os19.default.tmpdir(),
178824
178892
  "argent-screenshot-diff",
178825
- import_node_crypto28.default.randomBytes(6).toString("hex")
178893
+ import_node_crypto29.default.randomBytes(6).toString("hex")
178826
178894
  );
178827
178895
  await import_promises26.default.mkdir(dir, { recursive: true });
178828
178896
  return dir;
@@ -178927,7 +178995,7 @@ async function captureIosDeviceLiveInput(params) {
178927
178995
  return writeLivePng(params.outputDir, params.name, png);
178928
178996
  }
178929
178997
  async function writeLivePng(outputDir, name, png) {
178930
- const suffix = import_node_crypto28.default.randomBytes(4).toString("hex");
178998
+ const suffix = import_node_crypto29.default.randomBytes(4).toString("hex");
178931
178999
  const destination = import_path9.default.join(outputDir, `${name}-${suffix}.live.png`);
178932
179000
  await import_promises26.default.mkdir(outputDir, { recursive: true });
178933
179001
  await import_promises26.default.writeFile(destination, png);
@@ -178945,7 +179013,7 @@ async function captureHarmonyLiveInput(params) {
178945
179013
  }
178946
179014
  await ensureDep("hdc");
178947
179015
  const captured2 = await captureHarmonyScreenshotPng({ connectKey: params.connectKey, scale: 1 });
178948
- const suffix = import_node_crypto28.default.randomBytes(4).toString("hex");
179016
+ const suffix = import_node_crypto29.default.randomBytes(4).toString("hex");
178949
179017
  const destination = import_path9.default.join(params.outputDir, `${params.name}-${suffix}.live.png`);
178950
179018
  try {
178951
179019
  await import_promises26.default.mkdir(params.outputDir, { recursive: true });
@@ -178968,7 +179036,7 @@ async function captureLiveInput(params) {
178968
179036
  captureScreenshot2,
178969
179037
  params.peekFor?.(params.device)
178970
179038
  );
178971
- const suffix = import_node_crypto28.default.randomBytes(4).toString("hex");
179039
+ const suffix = import_node_crypto29.default.randomBytes(4).toString("hex");
178972
179040
  const destination = import_path9.default.join(params.outputDir, `${params.name}-${suffix}.live.png`);
178973
179041
  await import_promises26.default.mkdir(params.outputDir, { recursive: true });
178974
179042
  await import_promises26.default.copyFile(capture.path, destination);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@swmansion/argent",
3
- "version": "0.35.1-next.89",
3
+ "version": "0.35.1-next.90",
4
4
  "mcpName": "io.github.software-mansion/argent",
5
5
  "description": "MCP server for iOS Simulator, Android Emulator, Chromium app and Mac app control",
6
6
  "license": "Apache-2.0",
@@ -98,5 +98,5 @@
98
98
  "vitest": "^5.0.5",
99
99
  "yaml": "^2.9.1"
100
100
  },
101
- "gitHead": "7f1ac94c91afbbebf9b0e53b7c18f684406e523b"
101
+ "gitHead": "caa5e59eb10ccf32347bc4ffa209da8068bc9851"
102
102
  }