@swmansion/argent 0.30.2-next.4 → 0.30.2-next.5

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
@@ -35577,7 +35577,7 @@ var _CI_VENDOR_COUNT_FOR_TEST = vendors_default.length;
35577
35577
  var SESSION_ID2 = randomUUID5();
35578
35578
  function readCliVersion() {
35579
35579
  if (true) {
35580
- return "0.30.2-next.4";
35580
+ return "0.30.2-next.5";
35581
35581
  }
35582
35582
  return "0.0.0";
35583
35583
  }
@@ -16899,7 +16899,7 @@ var _CI_VENDOR_COUNT_FOR_TEST = vendors_default.length;
16899
16899
  var SESSION_ID = randomUUID4();
16900
16900
  function readCliVersion() {
16901
16901
  if (true) {
16902
- return "0.30.2-next.4";
16902
+ return "0.30.2-next.5";
16903
16903
  }
16904
16904
  return "0.0.0";
16905
16905
  }
@@ -28762,7 +28762,7 @@ async function startMcpServer(options) {
28762
28762
  { name: "argent", version: getInstalledVersion() },
28763
28763
  {
28764
28764
  capabilities: { tools: {} },
28765
- instructions: "Argent \u2014 iOS Simulator, Android Emulator, and Chromium app control for interacting, testing, profiling and debugging mobile and Chromium applications. Interaction tools return the screen after the action: a screenshot plus the accessibility element tree with normalized tap frames. Take coordinates from that tree; call describe (or debugger-component-tree) only when no fresh tree is available \u2014 never guess coordinates from pixels. On session end: call stop-all-simulator-servers with devices: [...] naming the devices this session used, and perform any necessary cleanup. One tool-server is shared by every agent using this argent install, so an unscoped call tears down their devices too \u2014 reserve it for a deliberate machine-wide cleanup. Full guidance is in the argent rule loaded from .claude/rules/argent.md."
28765
+ instructions: "Argent \u2014 iOS Simulator, Android Emulator, and Chromium app control for interacting, testing, profiling and debugging mobile and Chromium applications. Interaction tools return the screen after the action: a screenshot plus the accessibility element tree with normalized tap frames. Take coordinates from that tree; call describe (or debugger-component-tree) only when no fresh tree is available \u2014 never guess coordinates from pixels. Do not stop simulator servers when a task finishes: the next task reuses them. Call stop-all-simulator-servers when the user asks to clean up or ends the session, or when a skill tells you to recycle a device's services, always with devices: [...] naming the devices this session used. Never stop a Metro the user started unless they ask. One tool-server is shared by every agent using this argent install, so an unscoped call tears down their devices too \u2014 reserve it for a deliberate machine-wide cleanup. Full guidance is in the argent rule loaded from .claude/rules/argent.md."
28766
28766
  }
28767
28767
  );
28768
28768
  server.setRequestHandler(ListToolsRequestSchema, async () => {
@@ -100944,7 +100944,7 @@ var _CI_VENDOR_COUNT_FOR_TEST = vendors_default.length;
100944
100944
  var SESSION_ID = (0, import_node_crypto3.randomUUID)();
100945
100945
  function readCliVersion() {
100946
100946
  if (true) {
100947
- return "0.30.2-next.4";
100947
+ return "0.30.2-next.5";
100948
100948
  }
100949
100949
  return "0.0.0";
100950
100950
  }
@@ -164901,7 +164901,7 @@ function createStopSimulatorServerTool(registry2) {
164901
164901
  completedMsg: ({ params }) => `Stopped simulator server for ${params.udid}`,
164902
164902
  failedMsg: ({ params, failureSignal: failureSignal2 }) => `Failed to stop simulator server for ${params.udid}: ${failureSignal2.error_code}`
164903
164903
  },
164904
- description: `Stop the transport session for a specific device (iOS simulator / Android: simulator-server process; physical iOS: the on-device runner; Chromium: CDP WebSocket) and free its resources; on a TV target it also reaps that device's TV-control daemons. Use when you are done interacting with one device but want to keep others running, or to restart a wedged transport. On iOS / Android / TV it deliberately leaves this device's native-devtools, accessibility, profiler and debugger services running - to drain those as well, use stop-all-simulator-servers with \`devices\`. On CHROMIUM that does not hold: the JS-runtime debugger declares the CDP session as a dependency, so stopping the transport cascades to it and its captured console history goes with it - reconnect with debugger-connect afterwards. Returns { stopped, udid }. Fails silently if no session is open for the given id.`,
164904
+ description: `Stop the transport session for a specific device (iOS simulator / Android: simulator-server process; physical iOS: the on-device runner; Chromium: CDP WebSocket) and free its resources; on a TV target it also reaps that device's TV-control daemons. Use to restart a wedged transport, or when the user is done with one device but wants to keep others running - not just because a task on it finished, since the next task on that device would start cold again. On iOS / Android / TV it deliberately leaves this device's native-devtools, accessibility, profiler and debugger services running - to drain those as well, use stop-all-simulator-servers with \`devices\`. On CHROMIUM that does not hold: the JS-runtime debugger declares the CDP session as a dependency, so stopping the transport cascades to it and its captured console history goes with it - reconnect with debugger-connect afterwards. Returns { stopped, udid }. Fails silently if no session is open for the given id.`,
164905
164905
  zodSchema: zodSchema63,
164906
164906
  services: () => ({}),
164907
164907
  async execute(_services, params) {
@@ -164968,7 +164968,7 @@ function createStopAllSimulatorServersTool(registry2) {
164968
164968
  },
164969
164969
  failedMsg: ({ failureSignal: failureSignal2 }) => `Failed to stop simulator servers: ${failureSignal2.error_code}`
164970
164970
  },
164971
- description: `Stop the services a device owns - simulator-server processes (iOS + Android), native devtools, the iOS accessibility service, TV-control daemons, Chromium CDP sessions, screen recordings, native profiler sessions, and JS-runtime debugger sessions along with the network inspectors and React profiler sessions that ride on them - freeing their spawned processes, sockets and ports. Call this when your session ends or the user says they are done.
164971
+ description: `Stop the services a device owns - simulator-server processes (iOS + Android), native devtools, the iOS accessibility service, TV-control daemons, Chromium CDP sessions, screen recordings, native profiler sessions, and JS-runtime debugger sessions along with the network inspectors and React profiler sessions that ride on them - freeing their spawned processes, sockets and ports. Call this when the user asks to clean up or ends the session, or when a skill tells you to recycle a device's services mid-flow - not just because a task finished, since the next task reuses these services and would start cold again.
164972
164972
  PASS \`devices\` with the device ids this session used: one tool-server serves every agent, subagent and CLI call using this argent install, and an unscoped call tears down THEIR devices too (a mid-recording devtools teardown degrades another agent's e2e test to brittle coordinate taps; that agent is warned, but its recorded steps are already the worse kind). Omit \`devices\` only when a machine-wide cleanup is what you actually want. Passing an EMPTY array scopes to nothing and stops nothing - it is not a way to ask for the machine-wide sweep.
164973
164973
  A JS-runtime debugger session is keyed by the id you called \`debugger-connect\` with. On a Metro serving two or more devices that id is not a udid or serial - connect refuses those and tells you to re-target with the \`logicalDeviceId\` it returns - so a scope built from \`list-devices\` ids cannot reach that session. Pass any such \`logicalDeviceId\` in \`devices\` ALONGSIDE the device id; { left_running } names the ones you missed.
164974
164974
  Returns { stopped } - the URNs of the services that were actually live and got shut down; an ERROR node is disposed too but never appears there, so an empty \`stopped\` only means nothing was still running. { unmatched } lists supplied ids that own no service here, so a mistyped id - or a device NAME passed where an id was expected - does not read as a clean machine. It is NOT proof the id is wrong: a Vega device is driven through CLI/adb shell-outs, so one you only booted and drove with the remote registers no service and always lands here, as does a real device of any platform this session never started anything on. Present ONLY when \`devices\` was supplied AND at least one id matched nothing - absent on an unscoped call and when every id matched. Stopping the same device twice does not report it unmatched: ownership counts regardless of service state. { left_running } lists the URNs of live debugger sessions (and the network inspectors / React profiler sessions riding on them) whose id no device scope can name - re-call with the id after each URN's \`<namespace>:<port>:\` prefix to reap them. { aborted: true } means the caller cancelled the request part-way, so the rest of the machine was left untouched and neither of the other two fields was computed. Past the schema - which rejects an unknown key outright, so the \`udids\` slip is an error rather than a silent machine-wide sweep - the call always succeeds; reaping nothing is a result, not a failure.`,
@@ -165062,7 +165062,7 @@ var stopMetroTool = {
165062
165062
  completedMsg: ({ params }) => `Stopped Metro on port ${params.port}`,
165063
165063
  failedMsg: ({ params, failureSignal: failureSignal2 }) => `Failed to stop Metro on port ${params.port}: ${failureSignal2.error_code}`
165064
165064
  },
165065
- description: `Stop the Metro bundler process listening on a given port (default 8081). Use when ending a React Native session or when Metro must be restarted. Returns { stopped, port, pids }; stopped=false if no process is found on the port. Fails if the port lookup command times out or the process cannot be killed. This is DESTRUCTIVE: always ask the user for confirmation before calling this tool.`,
165065
+ description: `Stop the Metro bundler process listening on a given port (default 8081). Use when the user asks to stop Metro or when Metro must be restarted - do not offer it when a task wraps up, since the next task would wait on a cold Metro start. Returns { stopped, port, pids }; stopped=false if no process is found on the port. Fails if the port lookup command times out or the process cannot be killed. This is DESTRUCTIVE: always ask the user for confirmation before calling this tool.`,
165066
165066
  zodSchema: zodSchema65,
165067
165067
  services: () => ({}),
165068
165068
  async execute(_services, params) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@swmansion/argent",
3
- "version": "0.30.2-next.4",
3
+ "version": "0.30.2-next.5",
4
4
  "mcpName": "io.github.software-mansion/argent",
5
5
  "description": "MCP server for iOS Simulator and Android Emulator control",
6
6
  "license": "Apache-2.0",
package/rules/argent.md CHANGED
@@ -78,11 +78,13 @@ Decision order:
78
78
  - Always open apps with `launch-app` or `open-url`; never tap home screen icons.
79
79
  - If a task can require a saved e2e test, choose `argent-create-e2e` or `argent-qa-e2e` before the first launch or in-app action. Start the recorder before walking the path; recording is not retroactive.
80
80
  - Always use `run-sequence` when performing multiple sequential device actions where you don't need to observe the screen between steps. More in `argent-device-interact` skill.
81
- - When the session ends or the user says they are done: call `stop-all-simulator-servers` with `devices: [...]`
82
- naming the devices this session actually used. One tool-server is shared by every other agent using this
83
- argent install, so an unscoped call tears down their devices too; reserve that form for a deliberate
84
- machine-wide cleanup.
85
- If the user started Metro separately, ask whether to call `stop-metro` (specify the port if not 8081).
81
+ - Do not stop simulator servers when a task finishes: the next task reuses them, and stopping them makes its
82
+ first device action start cold again. Call `stop-all-simulator-servers` when the user asks to clean up or
83
+ ends the session, or when a skill tells you to recycle a device's services (e.g. before a QA proof pass).
84
+ Always pass `devices: [...]` naming the devices this session used. One tool-server is shared by every other
85
+ agent using this argent install, so an unscoped call tears down their devices too; reserve that form for a
86
+ deliberate machine-wide cleanup.
87
+ Never stop a Metro the user started unless they ask (`stop-metro`, specify the port if not 8081).
86
88
  - If tools provided by mcp-server are not sufficient and action can be done using `xcrun`, `adb`, or other commands, use the command. Examples: changing device options, performing a device action such as lock, shake, etc. Not on a physical iPhone.
87
89
  - When waiting for an action, do not call `screenshot` repeatedly without a proper wait mechanism. Use the `await-ui-element` tool to block until the UI settles (e.g. wait for an element to become `visible`/`hidden`, or to contain expected `text`) instead of polling.
88
90
  </general_rules>