@swmansion/argent 0.35.1-next.92 → 0.35.1-next.94

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.91";
39150
+ return "0.35.1-next.93";
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.91";
17180
+ return "0.35.1-next.93";
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.91" : installedVersion;
38591
+ const highlightsVersion = true ? "0.35.1-next.93" : installedVersion;
38592
38592
  const captureTimeoutMs = options.captureTimeoutMs ?? CAPTURE_TIMEOUT_MS;
38593
38593
  const trees = createTreeMemory();
38594
38594
  const screenshots = createScreenshotMemory();
@@ -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.91";
73428
+ return "0.35.1-next.93";
73429
73429
  }
73430
73430
  return "0.0.0";
73431
73431
  }
@@ -75241,6 +75241,7 @@ var import_semver2 = __toESM(require_semver2());
75241
75241
  init_command_on_path();
75242
75242
  var execFileAsync6 = (0, import_node_util6.promisify)(import_node_child_process8.execFile);
75243
75243
  var MIN_ARGENT_CLOUD_VERSION = "1.1.0";
75244
+ var ARGENT_CLOUD_INSTALL_DOCS_URL = "https://docs.swmansion.com/argent/docs/cloud/fundamentals/installation";
75244
75245
  var LEGACY_NAME = "sim-remote";
75245
75246
  var VERSION_TIMEOUT_MS = 5e3;
75246
75247
  var VERSION_TTL_MS = 6e4;
@@ -75477,7 +75478,7 @@ var INSTALL_HINTS = {
75477
75478
  "xcrun": "Xcode command-line tools not found \u2014 iOS/tvOS simulators need a macOS host with them installed. On macOS, run `xcode-select --install` (or install Xcode from the App Store) and retry.",
75478
75479
  "adb": "Android SDK Platform Tools not found. Install `platform-tools` via Android Studio \u2192 SDK Manager or `sdkmanager 'platform-tools'` (`brew install --cask android-platform-tools` on macOS). If installed, ensure `adb` is on PATH or point `$ANDROID_HOME` (or the `android.sdkRoot` config key) at the SDK root (the resolver checks `<root>/platform-tools/adb`). Only required for Android devices and emulators.",
75479
75480
  "emulator": "Android Emulator not found. Install via Android Studio \u2192 SDK Manager \u2192 Emulator, or `sdkmanager 'emulator'`. If installed, ensure `emulator` is on PATH or point `$ANDROID_HOME` (or the `android.sdkRoot` config key) at the SDK root (the resolver checks `<root>/emulator/emulator`). Only required to launch new Android emulators via `boot-device`.",
75480
- "sim-remote": "Argent Cloud CLI not found: `ARGENT_CLOUD_BIN` is unset or not executable, and no `argent-cloud` or `sim-remote` is on PATH or in `~/.local/bin`. Install it as described at https://docs.swmansion.com/argent/docs/cloud/fundamentals/installation, then run its `login` command (`sim-remote login`) before invoking any ios-remote tool. Only required for remote iOS simulators.",
75481
+ "sim-remote": `Argent Cloud CLI not found: \`ARGENT_CLOUD_BIN\` is unset or not executable, and no \`argent-cloud\` or \`sim-remote\` is on PATH or in \`~/.local/bin\`. Install it as described at ${ARGENT_CLOUD_INSTALL_DOCS_URL}, then run its \`login\` command (\`sim-remote login\`) before invoking any ios-remote tool. Only required for remote iOS simulators.`,
75481
75482
  "vega": "Vega SDK CLI not found. Install the Amazon Vega SDK and run `source ~/vega/env` so `vega` (or its `kepler` alias) is on PATH; the resolver also checks `~/vega/bin/vega`. Only required for Vega (Fire TV) devices.",
75482
75483
  "harmony-emulator": "HarmonyOS emulator manager not found. Install DevEco Studio; a macOS install at `/Applications/DevEco-Studio.app` is found automatically, and anywhere else set `$DEVECO_STUDIO_HOME` to the directory holding `tools/emulator/Emulator` (the resolver also checks that path under `Contents/`, so a macOS app bundle works too). Only required to list or launch HarmonyOS emulators.",
75483
75484
  "hdc": "`hdc`, the HarmonyOS device connector, was not found. Install DevEco Studio (it ships `hdc` under `sdk/default/openharmony/toolchains`, and a macOS install at `/Applications/DevEco-Studio.app` is found automatically), or put `hdc` from the OpenHarmony command-line tools on PATH, or set `$DEVECO_STUDIO_HOME` to the directory holding `sdk/default/openharmony/toolchains/hdc` (the resolver also checks that path under `Contents/`, so a macOS app bundle works too). Only required to drive HarmonyOS devices."
@@ -99565,25 +99566,39 @@ function decodeHexFingerprint(fingerprint) {
99565
99566
  }
99566
99567
  return out;
99567
99568
  }
99569
+ var CONNECT_TIMEOUT_MS = 2e4;
99568
99570
  async function connectMoq(info, options = {}) {
99569
- const url2 = new URL(info.url);
99570
- if (info.token) url2.searchParams.set("token", info.token);
99571
+ const url2 = withToken(info.url, info.token);
99571
99572
  const fingerprint = decodeHexFingerprint(info.fingerprint);
99573
+ const overdue = new AbortController();
99574
+ const timer = setTimeout(
99575
+ () => overdue.abort(new Error(`no connection after ${CONNECT_TIMEOUT_MS} ms`)),
99576
+ CONNECT_TIMEOUT_MS
99577
+ );
99572
99578
  try {
99573
99579
  return await connection_exports.connect(url2, {
99574
99580
  webtransport: {
99575
99581
  ...options.webtransport,
99576
99582
  serverCertificateHashes: [{ algorithm: "sha-256", value: fingerprint }]
99577
99583
  },
99578
- // The WebSocket fallback is pointless against simulator-server (QUIC
99579
- // only), and racing it costs the default head-start delay on every
99580
- // reconnect.
99581
- websocket: { enabled: false }
99584
+ websocket: websocketFallback(info),
99585
+ signal: options.signal ? AbortSignal.any([overdue.signal, options.signal]) : overdue.signal
99582
99586
  });
99583
99587
  } catch (err) {
99584
99588
  throw unwrapMoqConnectError(err, info.url);
99589
+ } finally {
99590
+ clearTimeout(timer);
99585
99591
  }
99586
99592
  }
99593
+ function withToken(endpoint, token) {
99594
+ const url2 = new URL(endpoint);
99595
+ if (token) url2.searchParams.set("token", token);
99596
+ return url2;
99597
+ }
99598
+ function websocketFallback(info) {
99599
+ if (!info.websocket_url) return { enabled: false };
99600
+ return { enabled: true, url: withToken(info.websocket_url, info.token) };
99601
+ }
99587
99602
  function unwrapMoqConnectError(err, url2) {
99588
99603
  if (err instanceof AggregateError) {
99589
99604
  const parts2 = err.errors.map((e) => e instanceof Error ? `${e.name}: ${e.message}` : String(e));
@@ -108939,7 +108954,7 @@ function cloudAndroidHeldNote(serials) {
108939
108954
  }
108940
108955
  function outdatedCloudCliNote(version3) {
108941
108956
  if (!version3 || !isArgentCloudOutdated(version3)) return null;
108942
- return `iOS: ${argentCloudCommand()} ${version3} is older than ${MIN_ARGENT_CLOUD_VERSION}, the version Argent expects. Argent Cloud simulators still work. The user can update it with \`argent cloud install\`.`;
108957
+ return `iOS: ${argentCloudCommand()} ${version3} is older than ${MIN_ARGENT_CLOUD_VERSION}, the version Argent expects. Argent Cloud simulators still work. The user can update it to the latest release: ${ARGENT_CLOUD_INSTALL_DOCS_URL}`;
108943
108958
  }
108944
108959
  var ANDROID_SDK_MISSING_NOTE = "Android: no SDK found (adb, emulator). Installing the platform tools and creating an AVD adds Android targets.";
108945
108960
  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. stop-all-simulator-servers does the same for that server, also under the device's plain UDID / serial, and leaves it out of 'stopped', so an empty 'stopped' does not mean the provider's server is gone. 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.`;
@@ -162818,7 +162833,7 @@ init_device_info();
162818
162833
  init_capability();
162819
162834
  var AUDIO_DIR_ENV2 = "ARGENT_AUDIO_DIR";
162820
162835
  var AUDIO_DYLIB = "libArgentAudio.dylib";
162821
- var CONNECT_TIMEOUT_MS = 3e4;
162836
+ var CONNECT_TIMEOUT_MS2 = 3e4;
162822
162837
  var REPLY_TIMEOUT_MS = 6e4;
162823
162838
  var MAX_FILE_BYTES = 256 * 1024 * 1024;
162824
162839
  function createRemoteAudioSession(udid) {
@@ -162996,7 +163011,7 @@ async function startFeeder(session) {
162996
163011
  const connected = new Promise((resolve24, reject) => {
162997
163012
  timer = setTimeout(
162998
163013
  () => reject(failure2("The remote audio feeder did not connect.", "audio_remote_link")),
162999
- CONNECT_TIMEOUT_MS
163014
+ CONNECT_TIMEOUT_MS2
163000
163015
  );
163001
163016
  server.on("connection", (socket) => {
163002
163017
  let hello = "";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@swmansion/argent",
3
- "version": "0.35.1-next.92",
3
+ "version": "0.35.1-next.94",
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": "9222e207f06e91cb44ec4a4ca6f7ab9193acd630"
101
+ "gitHead": "a32ee4c2a5c5cf7e284d2434178276a31f7e12bb"
102
102
  }