@swmansion/argent 0.35.1-next.1 → 0.35.1-next.11
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/bin/argent-android-devtools-0.4.0.apk +0 -0
- package/bin/darwin/argent-macos-helper +0 -0
- package/bin/darwin/ax-service +0 -0
- package/bin/darwin/tvos-ax-service +0 -0
- package/bin/darwin/tvos-hid-daemon +0 -0
- package/bin/network-inspector/network-inspector.jar +0 -0
- package/bin/tcp/ax-service +0 -0
- package/dist/cli-cmds.mjs +97 -24
- package/dist/client.js +14 -1
- package/dist/installer.mjs +362 -162
- package/dist/mcp-server.mjs +51 -9
- package/dist/tool-args.generated.d.ts +30 -0
- package/dist/tool-server.cjs +108534 -107482
- package/dylibs/libArgentAudio.dylib +0 -0
- package/dylibs/libArgentInjectionBootstrap.dylib +0 -0
- package/dylibs/libKeyboardPatch.dylib +0 -0
- package/dylibs/libNativeDevtoolsIos.dylib +0 -0
- package/dylibs/macos/libArgentInjectionBootstrap.dylib +0 -0
- package/dylibs/macos/libNativeDevtoolsMacos.dylib +0 -0
- package/dylibs/tcp/argent-audio-feeder +0 -0
- package/dylibs/tcp/libArgentAudio.dylib +0 -0
- package/dylibs/tcp/libArgentInjectionBootstrap.dylib +0 -0
- package/dylibs/tcp/libKeyboardPatch.dylib +0 -0
- package/dylibs/tcp/libNativeDevtoolsIos.dylib +0 -0
- package/dylibs/tvos/libArgentInjectionBootstrap.dylib +0 -0
- package/dylibs/tvos/libKeyboardPatch.dylib +0 -0
- package/dylibs/tvos/libNativeDevtoolsIos.dylib +0 -0
- package/package.json +2 -2
- package/skills/argent-create-e2e/references/e2e-yaml.md +23 -2
- package/skills/argent-create-e2e/references/live-authoring.md +7 -0
package/dist/mcp-server.mjs
CHANGED
|
@@ -32125,6 +32125,7 @@ function buildToolsServerEnv(paths, port, baseEnv = process.env, options = {}) {
|
|
|
32125
32125
|
env.ARGENT_IDLE_TIMEOUT_MINUTES = String(options.idleTimeoutMinutes);
|
|
32126
32126
|
}
|
|
32127
32127
|
env[AUTH_TOKEN_ENV] = options.token ?? "";
|
|
32128
|
+
env.ARGENT_SERVER_MANAGED = options.managed ?? "autospawn";
|
|
32128
32129
|
if (paths.installKind) env.ARGENT_INSTALL_KIND = paths.installKind;
|
|
32129
32130
|
if (paths.installProjectRoot) env.ARGENT_PROJECT_ROOT = paths.installProjectRoot;
|
|
32130
32131
|
return env;
|
|
@@ -32889,7 +32890,19 @@ function getWhatsNewSeenVersion(options = {}) {
|
|
|
32889
32890
|
return typeof value === "string" ? value : null;
|
|
32890
32891
|
}
|
|
32891
32892
|
function setWhatsNewSeenVersion(version2, options = {}) {
|
|
32892
|
-
|
|
32893
|
+
let recorded = false;
|
|
32894
|
+
updateConfig(
|
|
32895
|
+
(config2) => {
|
|
32896
|
+
const value = getAtPath(config2, WHATS_NEW_SEEN_KEY);
|
|
32897
|
+
const seen = typeof value === "string" ? value : null;
|
|
32898
|
+
if (options.ifSeen !== void 0 && options.ifSeen !== seen) return;
|
|
32899
|
+
setAtPath(config2, WHATS_NEW_SEEN_KEY, version2);
|
|
32900
|
+
recorded = true;
|
|
32901
|
+
},
|
|
32902
|
+
"global",
|
|
32903
|
+
options
|
|
32904
|
+
);
|
|
32905
|
+
return recorded;
|
|
32893
32906
|
}
|
|
32894
32907
|
|
|
32895
32908
|
// ../configuration-core/src/secrets.ts
|
|
@@ -33089,6 +33102,15 @@ var CONFIG_SCHEMA = [
|
|
|
33089
33102
|
// drained/reset, not just the file rewritten.
|
|
33090
33103
|
manageCommand: "argent telemetry"
|
|
33091
33104
|
},
|
|
33105
|
+
{
|
|
33106
|
+
key: "autoUpdate.enabled",
|
|
33107
|
+
description: "Automatically update the global Argent installation. Project-local installs require confirmation.",
|
|
33108
|
+
scopes: ["global"],
|
|
33109
|
+
parse: asBoolean,
|
|
33110
|
+
merge: "prioritize-local",
|
|
33111
|
+
default: true,
|
|
33112
|
+
example: "false"
|
|
33113
|
+
},
|
|
33092
33114
|
{
|
|
33093
33115
|
key: "lens.agent",
|
|
33094
33116
|
description: "Coding-agent id remembered by `argent lens` to skip the picker.",
|
|
@@ -33436,7 +33458,10 @@ function collectFlowRequests(doc) {
|
|
|
33436
33458
|
visit(step.steps, depth + 1);
|
|
33437
33459
|
}
|
|
33438
33460
|
};
|
|
33439
|
-
if (isRecord(doc))
|
|
33461
|
+
if (isRecord(doc)) {
|
|
33462
|
+
visit(doc.steps, 0);
|
|
33463
|
+
visit(doc.shutdown, 0);
|
|
33464
|
+
}
|
|
33440
33465
|
return { runTargets: [...runTargets], snapshots: [...snapshots], toolSteps, nested };
|
|
33441
33466
|
}
|
|
33442
33467
|
function baselineKeyFor(canonicalPath2, flowName) {
|
|
@@ -36741,8 +36766,13 @@ async function flowRunToMcpContent(result, ctx) {
|
|
|
36741
36766
|
});
|
|
36742
36767
|
if (typeof result.warning === "string")
|
|
36743
36768
|
blocks.push({ type: "text", text: `\u26A0 ${result.warning}` });
|
|
36769
|
+
let inShutdown = false;
|
|
36744
36770
|
for (let i = 0; i < result.steps.length; i++) {
|
|
36745
36771
|
const step = result.steps[i];
|
|
36772
|
+
if (step.shutdown === true && !inShutdown) {
|
|
36773
|
+
inShutdown = true;
|
|
36774
|
+
blocks.push({ type: "text", text: "shutdown:" });
|
|
36775
|
+
}
|
|
36746
36776
|
const num = step.index !== void 0 ? step.index + 1 : i + 1;
|
|
36747
36777
|
const glyph = step.status ? `${STATUS_GLYPH[step.status] ?? "\u2022"} ` : "";
|
|
36748
36778
|
const reason = step.reason ?? step.error;
|
|
@@ -36774,6 +36804,12 @@ async function flowRunToMcpContent(result, ctx) {
|
|
|
36774
36804
|
blocks.push({ type: "text", text: `\u2717 baseline not written: ${path18}: ${error2}` });
|
|
36775
36805
|
}
|
|
36776
36806
|
}
|
|
36807
|
+
if (result.shutdownFailed === true) {
|
|
36808
|
+
blocks.push({
|
|
36809
|
+
type: "text",
|
|
36810
|
+
text: "\u26A0 shutdown did not finish: a shutdown step failed, so the run may have left state behind."
|
|
36811
|
+
});
|
|
36812
|
+
}
|
|
36777
36813
|
if (result.ok !== void 0) {
|
|
36778
36814
|
const counted = (result.passed ?? 0) + (result.failed ?? 0) + (result.errored ?? 0) + (result.skipped ?? 0);
|
|
36779
36815
|
const note = result.ok && counted === 0 ? " (no test steps)" : "";
|
|
@@ -37987,11 +38023,15 @@ function formatWhatsNewNote(version2, highlights) {
|
|
|
37987
38023
|
].join("\n");
|
|
37988
38024
|
}
|
|
37989
38025
|
function takeWhatsNewNote(current) {
|
|
37990
|
-
|
|
37991
|
-
|
|
37992
|
-
|
|
37993
|
-
|
|
37994
|
-
|
|
38026
|
+
let seen = getWhatsNewSeenVersion();
|
|
38027
|
+
while (isNewerThanSeen(current, seen)) {
|
|
38028
|
+
if (setWhatsNewSeenVersion(current, { ifSeen: seen })) {
|
|
38029
|
+
const highlights = highlightsSince(seen, current);
|
|
38030
|
+
return highlights.length > 0 ? formatWhatsNewNote(current, highlights) : void 0;
|
|
38031
|
+
}
|
|
38032
|
+
seen = getWhatsNewSeenVersion();
|
|
38033
|
+
}
|
|
38034
|
+
return void 0;
|
|
37995
38035
|
}
|
|
37996
38036
|
|
|
37997
38037
|
// ../argent-mcp/src/mcp-server.ts
|
|
@@ -38017,6 +38057,8 @@ async function startMcpServer(options) {
|
|
|
38017
38057
|
const autoScreenshotOn = autoScreenshotEnabled();
|
|
38018
38058
|
const autoDescribeOn = autoDescribeEnabled();
|
|
38019
38059
|
const whatsNewOn = whatsNewEnabled();
|
|
38060
|
+
const installedVersion = getInstalledVersion();
|
|
38061
|
+
const highlightsVersion = true ? "0.35.1-next.9" : installedVersion;
|
|
38020
38062
|
const captureTimeoutMs = options.captureTimeoutMs ?? CAPTURE_TIMEOUT_MS;
|
|
38021
38063
|
const trees = createTreeMemory();
|
|
38022
38064
|
const screenshots = createScreenshotMemory();
|
|
@@ -38183,14 +38225,14 @@ ${shown.text}` }];
|
|
|
38183
38225
|
if (!whatsNewOn || whatsNewChecked) return [];
|
|
38184
38226
|
whatsNewChecked = true;
|
|
38185
38227
|
try {
|
|
38186
|
-
const note = takeWhatsNewNote(
|
|
38228
|
+
const note = takeWhatsNewNote(highlightsVersion);
|
|
38187
38229
|
return note ? [{ type: "text", text: note }] : [];
|
|
38188
38230
|
} catch {
|
|
38189
38231
|
return [];
|
|
38190
38232
|
}
|
|
38191
38233
|
}
|
|
38192
38234
|
const server = new Server(
|
|
38193
|
-
{ name: "argent", version:
|
|
38235
|
+
{ name: "argent", version: installedVersion },
|
|
38194
38236
|
{
|
|
38195
38237
|
capabilities: { tools: {} },
|
|
38196
38238
|
instructions: SERVER_INSTRUCTIONS
|
|
@@ -95,6 +95,8 @@ export interface ArgentToolArgs {
|
|
|
95
95
|
readOnly?: boolean;
|
|
96
96
|
/** Android only: the emulator's console port, an even number from 5554 to 5584 (`emulator -port`), the range adb finds emulators in; its serial is `emulator-<port>`. Without it the emulator takes the first free port from 5554 up, as Android Studio does. The gRPC server Argent needs for screenshots and gestures goes on the port plus 3000, which must be free too. Given a port, the tool reuses only the emulator on that port and fails if another emulator holds it, or if this AVD runs there writable on a read-only boot and `force` is not set. A read-only emulator started with `-port` belongs to the calls that give that port: a call without `port` never reuses or shuts it down. Where the process list cannot be read (Windows, or a failed `ps`), Argent knows only the pinned emulators it booted itself, so a writable call without `port` can reuse, or with `force` shut down, one that someone else pinned. A writable one is still reused, or with `force` shut down, by a writable call without `port`, since the AVD runs one writable emulator at a time. `force` shuts nothing down when another emulator of the AVD would still block the boot. Ignored on other platforms. */
|
|
97
97
|
port?: number;
|
|
98
|
+
/** Local iOS simulator only: apply accessibility preferences and leave the simulator shut down for a pool manager to boot. Requires Shutdown state. Cannot be combined with force: true. */
|
|
99
|
+
prepareOnly?: boolean;
|
|
98
100
|
/** iOS only: boot the simulator core WITHOUT opening its GUI window (Simulator.app, or Device Hub on Xcode 27+). The device still streams via simulator-server. The `ARGENT_SIMULATOR_NO_WINDOW` env var (1/true/yes) forces this host-wide. */
|
|
99
101
|
headless?: boolean;
|
|
100
102
|
/** Electron: path to the Electron app to launch. Either a packaged .app bundle / executable, or a project directory whose package.json points the Electron binary at the entry script. */
|
|
@@ -245,6 +247,8 @@ export interface ArgentToolArgs {
|
|
|
245
247
|
project_root: string;
|
|
246
248
|
/** Text the echo step prints */
|
|
247
249
|
message: string;
|
|
250
|
+
/** Save the message in the shutdown list. stepCount counts shutdown entries. */
|
|
251
|
+
shutdown?: boolean;
|
|
248
252
|
};
|
|
249
253
|
"e2e-add-script": {
|
|
250
254
|
/** E2E test name passed to e2e-start-recording. */
|
|
@@ -255,6 +259,12 @@ export interface ArgentToolArgs {
|
|
|
255
259
|
path: string;
|
|
256
260
|
/** Time limit in milliseconds. The default is 30000 and the minimum is 100. */
|
|
257
261
|
timeout?: number;
|
|
262
|
+
/** Environment overrides for this script. Argent uses them immediately and saves them on the step. Values can include {{secret:NAME}} or {{output:PATH}}. */
|
|
263
|
+
env?: {
|
|
264
|
+
[key: string]: string;
|
|
265
|
+
};
|
|
266
|
+
/** Save the script in the shutdown list. It still runs immediately. Its output reaches only later shutdown steps. stepCount counts shutdown entries. */
|
|
267
|
+
shutdown?: boolean;
|
|
258
268
|
};
|
|
259
269
|
"e2e-add-step": {
|
|
260
270
|
/** Name of the e2e test being recorded: the one passed to e2e-start-recording. */
|
|
@@ -267,6 +277,8 @@ export interface ArgentToolArgs {
|
|
|
267
277
|
args?: string;
|
|
268
278
|
/** Milliseconds to sleep before executing this step during replay. */
|
|
269
279
|
delayMs?: number;
|
|
280
|
+
/** Save the call in the shutdown list. The call still runs immediately. stepCount counts shutdown entries. */
|
|
281
|
+
shutdown?: boolean;
|
|
270
282
|
};
|
|
271
283
|
"e2e-execute": {
|
|
272
284
|
/** Name of a saved e2e test to run from `<project_root>/.argent/e2e`, or `.argent/flows` when it is not there (e.g. "settings-explore"). */
|
|
@@ -285,6 +297,10 @@ export interface ArgentToolArgs {
|
|
|
285
297
|
updateBaselines?: boolean;
|
|
286
298
|
/** Set to true to confirm the execution prerequisite has been met. Required when a fragment defines an executionPrerequisite: without it, the call runs no step and returns the prerequisite text. Not a dry run: an e2e test with no prerequisite runs in full. To read a prerequisite without running, read executionPrerequisite in the YAML file. */
|
|
287
299
|
prerequisiteAcknowledged?: boolean;
|
|
300
|
+
/** Script environment overrides for this run, including run: fragments. Names match [A-Za-z_][A-Za-z0-9_]*, except __proto__. Values can include {{secret:NAME}}. A missing secret rejects the run before any step. */
|
|
301
|
+
env?: {
|
|
302
|
+
[key: string]: string;
|
|
303
|
+
};
|
|
288
304
|
/** @deprecated Renamed to `e2e_test_path`. */
|
|
289
305
|
flow_path?: string;
|
|
290
306
|
/** @deprecated Renamed to `e2e_test_file`. */
|
|
@@ -310,6 +326,16 @@ export interface ArgentToolArgs {
|
|
|
310
326
|
/** @deprecated Renamed to `e2e_test_file`. */
|
|
311
327
|
flow_file?: string;
|
|
312
328
|
};
|
|
329
|
+
"e2e-set-env": {
|
|
330
|
+
/** Test name passed to e2e-start-recording. */
|
|
331
|
+
name: string;
|
|
332
|
+
/** Absolute project root passed to e2e-start-recording. */
|
|
333
|
+
project_root: string;
|
|
334
|
+
/** Variable names to update. A null value removes that name. Omitted names keep their values. Use {{secret:NAME}} for credentials. */
|
|
335
|
+
env: {
|
|
336
|
+
[key: string]: string | null;
|
|
337
|
+
};
|
|
338
|
+
};
|
|
313
339
|
"e2e-start-recording": {
|
|
314
340
|
/** Name for this e2e test (e.g. "settings-explore"): letters, digits, underscore and hyphen only. */
|
|
315
341
|
name: string;
|
|
@@ -322,6 +348,10 @@ export interface ArgentToolArgs {
|
|
|
322
348
|
platform?: "ios" | "android" | "chromium" | "vega" | "macos" | Array<"ios" | "android" | "chromium" | "vega" | "macos">;
|
|
323
349
|
runtimeKind?: "mobile" | "tv";
|
|
324
350
|
};
|
|
351
|
+
/** Default script environment values saved in the test's top-level env. Use {{secret:NAME}} for credentials. */
|
|
352
|
+
env?: {
|
|
353
|
+
[key: string]: string;
|
|
354
|
+
};
|
|
325
355
|
};
|
|
326
356
|
"file-panel": {
|
|
327
357
|
/** Mac app id from `list-devices` (macos-app-<bundle id>). */
|