@midscene/ios 1.7.6-beta-20260425023224.0 → 1.7.6

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/es/cli.mjs CHANGED
@@ -1367,12 +1367,10 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1367
1367
  }
1368
1368
  if (this.agent) return this.agent;
1369
1369
  debug('Creating iOS agent with WebDriverAgent options:', opts || {});
1370
- const reportFileName = this.pendingReportFileName ?? this.readCliReportFileName();
1370
+ const reportOptions = this.readCliReportAgentOptions();
1371
1371
  this.agent = await agentFromWebDriverAgent({
1372
1372
  autoDismissKeyboard: false,
1373
- ...reportFileName ? {
1374
- reportFileName
1375
- } : {},
1373
+ ...reportOptions ?? {},
1376
1374
  ...opts ?? {}
1377
1375
  });
1378
1376
  this.lastOptsSignature = nextSignature;
@@ -1387,8 +1385,9 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1387
1385
  cli: this.getAgentInitArgCliMetadata(),
1388
1386
  handler: async (args)=>{
1389
1387
  const initArgs = this.extractAgentInitParam(args);
1390
- const reportSession = this.createNewCliReportSession();
1391
- this.pendingReportFileName = reportSession?.reportFileName;
1388
+ const identity = initArgs?.deviceId ?? (initArgs?.wdaHost || initArgs?.wdaPort ? `wda-${initArgs.wdaHost ?? 'localhost'}-${initArgs.wdaPort ?? 'default'}` : 'auto');
1389
+ const reportSession = this.createNewCliReportSession(identity);
1390
+ this.commitCliReportSession(reportSession);
1392
1391
  if (this.agent) {
1393
1392
  try {
1394
1393
  await this.agent.destroy?.();
@@ -1397,13 +1396,7 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1397
1396
  }
1398
1397
  this.agent = void 0;
1399
1398
  }
1400
- let agent;
1401
- try {
1402
- agent = await this.ensureAgent(initArgs);
1403
- } finally{
1404
- this.pendingReportFileName = void 0;
1405
- }
1406
- this.commitCliReportSession(reportSession);
1399
+ const agent = await this.ensureAgent(initArgs);
1407
1400
  const screenshot = await agent.page.screenshotBase64();
1408
1401
  return {
1409
1402
  content: [
@@ -1426,7 +1419,7 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1426
1419
  ];
1427
1420
  }
1428
1421
  constructor(...args){
1429
- super(...args), mcp_tools_define_property(this, "pendingReportFileName", void 0), mcp_tools_define_property(this, "initArgSpec", {
1422
+ super(...args), mcp_tools_define_property(this, "initArgSpec", {
1430
1423
  namespace: 'ios',
1431
1424
  shape: iosInitArgShape,
1432
1425
  cli: {
@@ -1439,7 +1432,7 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1439
1432
  const tools = new IOSMidsceneTools();
1440
1433
  runToolsCLI(tools, 'midscene-ios', {
1441
1434
  stripPrefix: 'ios_',
1442
- version: "1.7.6-beta-20260425023224.0",
1435
+ version: "1.7.6",
1443
1436
  extraCommands: createReportCliCommands()
1444
1437
  }).catch((e)=>{
1445
1438
  process.exit(reportCLIError(e));
package/dist/es/index.mjs CHANGED
@@ -1373,12 +1373,10 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1373
1373
  }
1374
1374
  if (this.agent) return this.agent;
1375
1375
  debug('Creating iOS agent with WebDriverAgent options:', opts || {});
1376
- const reportFileName = this.pendingReportFileName ?? this.readCliReportFileName();
1376
+ const reportOptions = this.readCliReportAgentOptions();
1377
1377
  this.agent = await agentFromWebDriverAgent({
1378
1378
  autoDismissKeyboard: false,
1379
- ...reportFileName ? {
1380
- reportFileName
1381
- } : {},
1379
+ ...reportOptions ?? {},
1382
1380
  ...opts ?? {}
1383
1381
  });
1384
1382
  this.lastOptsSignature = nextSignature;
@@ -1393,8 +1391,9 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1393
1391
  cli: this.getAgentInitArgCliMetadata(),
1394
1392
  handler: async (args)=>{
1395
1393
  const initArgs = this.extractAgentInitParam(args);
1396
- const reportSession = this.createNewCliReportSession();
1397
- this.pendingReportFileName = reportSession?.reportFileName;
1394
+ const identity = initArgs?.deviceId ?? (initArgs?.wdaHost || initArgs?.wdaPort ? `wda-${initArgs.wdaHost ?? 'localhost'}-${initArgs.wdaPort ?? 'default'}` : 'auto');
1395
+ const reportSession = this.createNewCliReportSession(identity);
1396
+ this.commitCliReportSession(reportSession);
1398
1397
  if (this.agent) {
1399
1398
  try {
1400
1399
  await this.agent.destroy?.();
@@ -1403,13 +1402,7 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1403
1402
  }
1404
1403
  this.agent = void 0;
1405
1404
  }
1406
- let agent;
1407
- try {
1408
- agent = await this.ensureAgent(initArgs);
1409
- } finally{
1410
- this.pendingReportFileName = void 0;
1411
- }
1412
- this.commitCliReportSession(reportSession);
1405
+ const agent = await this.ensureAgent(initArgs);
1413
1406
  const screenshot = await agent.page.screenshotBase64();
1414
1407
  return {
1415
1408
  content: [
@@ -1432,7 +1425,7 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1432
1425
  ];
1433
1426
  }
1434
1427
  constructor(...args){
1435
- super(...args), mcp_tools_define_property(this, "pendingReportFileName", void 0), mcp_tools_define_property(this, "initArgSpec", {
1428
+ super(...args), mcp_tools_define_property(this, "initArgSpec", {
1436
1429
  namespace: 'ios',
1437
1430
  shape: iosInitArgShape,
1438
1431
  cli: {
@@ -1367,12 +1367,10 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1367
1367
  }
1368
1368
  if (this.agent) return this.agent;
1369
1369
  debug('Creating iOS agent with WebDriverAgent options:', opts || {});
1370
- const reportFileName = this.pendingReportFileName ?? this.readCliReportFileName();
1370
+ const reportOptions = this.readCliReportAgentOptions();
1371
1371
  this.agent = await agentFromWebDriverAgent({
1372
1372
  autoDismissKeyboard: false,
1373
- ...reportFileName ? {
1374
- reportFileName
1375
- } : {},
1373
+ ...reportOptions ?? {},
1376
1374
  ...opts ?? {}
1377
1375
  });
1378
1376
  this.lastOptsSignature = nextSignature;
@@ -1387,8 +1385,9 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1387
1385
  cli: this.getAgentInitArgCliMetadata(),
1388
1386
  handler: async (args)=>{
1389
1387
  const initArgs = this.extractAgentInitParam(args);
1390
- const reportSession = this.createNewCliReportSession();
1391
- this.pendingReportFileName = reportSession?.reportFileName;
1388
+ const identity = initArgs?.deviceId ?? (initArgs?.wdaHost || initArgs?.wdaPort ? `wda-${initArgs.wdaHost ?? 'localhost'}-${initArgs.wdaPort ?? 'default'}` : 'auto');
1389
+ const reportSession = this.createNewCliReportSession(identity);
1390
+ this.commitCliReportSession(reportSession);
1392
1391
  if (this.agent) {
1393
1392
  try {
1394
1393
  await this.agent.destroy?.();
@@ -1397,13 +1396,7 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1397
1396
  }
1398
1397
  this.agent = void 0;
1399
1398
  }
1400
- let agent;
1401
- try {
1402
- agent = await this.ensureAgent(initArgs);
1403
- } finally{
1404
- this.pendingReportFileName = void 0;
1405
- }
1406
- this.commitCliReportSession(reportSession);
1399
+ const agent = await this.ensureAgent(initArgs);
1407
1400
  const screenshot = await agent.page.screenshotBase64();
1408
1401
  return {
1409
1402
  content: [
@@ -1426,7 +1419,7 @@ class IOSMidsceneTools extends BaseMidsceneTools {
1426
1419
  ];
1427
1420
  }
1428
1421
  constructor(...args){
1429
- super(...args), mcp_tools_define_property(this, "pendingReportFileName", void 0), mcp_tools_define_property(this, "initArgSpec", {
1422
+ super(...args), mcp_tools_define_property(this, "initArgSpec", {
1430
1423
  namespace: 'ios',
1431
1424
  shape: iosInitArgShape,
1432
1425
  cli: {
@@ -1443,7 +1436,7 @@ class IOSMCPServer extends BaseMCPServer {
1443
1436
  constructor(toolsManager){
1444
1437
  super({
1445
1438
  name: '@midscene/ios-mcp',
1446
- version: "1.7.6-beta-20260425023224.0",
1439
+ version: "1.7.6",
1447
1440
  description: 'Control the iOS device using natural language commands'
1448
1441
  }, toolsManager);
1449
1442
  }
package/dist/lib/cli.js CHANGED
@@ -1391,12 +1391,10 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1391
1391
  }
1392
1392
  if (this.agent) return this.agent;
1393
1393
  debug('Creating iOS agent with WebDriverAgent options:', opts || {});
1394
- const reportFileName = this.pendingReportFileName ?? this.readCliReportFileName();
1394
+ const reportOptions = this.readCliReportAgentOptions();
1395
1395
  this.agent = await agentFromWebDriverAgent({
1396
1396
  autoDismissKeyboard: false,
1397
- ...reportFileName ? {
1398
- reportFileName
1399
- } : {},
1397
+ ...reportOptions ?? {},
1400
1398
  ...opts ?? {}
1401
1399
  });
1402
1400
  this.lastOptsSignature = nextSignature;
@@ -1411,8 +1409,9 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1411
1409
  cli: this.getAgentInitArgCliMetadata(),
1412
1410
  handler: async (args)=>{
1413
1411
  const initArgs = this.extractAgentInitParam(args);
1414
- const reportSession = this.createNewCliReportSession();
1415
- this.pendingReportFileName = reportSession?.reportFileName;
1412
+ const identity = initArgs?.deviceId ?? (initArgs?.wdaHost || initArgs?.wdaPort ? `wda-${initArgs.wdaHost ?? 'localhost'}-${initArgs.wdaPort ?? 'default'}` : 'auto');
1413
+ const reportSession = this.createNewCliReportSession(identity);
1414
+ this.commitCliReportSession(reportSession);
1416
1415
  if (this.agent) {
1417
1416
  try {
1418
1417
  await this.agent.destroy?.();
@@ -1421,13 +1420,7 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1421
1420
  }
1422
1421
  this.agent = void 0;
1423
1422
  }
1424
- let agent;
1425
- try {
1426
- agent = await this.ensureAgent(initArgs);
1427
- } finally{
1428
- this.pendingReportFileName = void 0;
1429
- }
1430
- this.commitCliReportSession(reportSession);
1423
+ const agent = await this.ensureAgent(initArgs);
1431
1424
  const screenshot = await agent.page.screenshotBase64();
1432
1425
  return {
1433
1426
  content: [
@@ -1450,7 +1443,7 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1450
1443
  ];
1451
1444
  }
1452
1445
  constructor(...args){
1453
- super(...args), mcp_tools_define_property(this, "pendingReportFileName", void 0), mcp_tools_define_property(this, "initArgSpec", {
1446
+ super(...args), mcp_tools_define_property(this, "initArgSpec", {
1454
1447
  namespace: 'ios',
1455
1448
  shape: iosInitArgShape,
1456
1449
  cli: {
@@ -1463,7 +1456,7 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1463
1456
  const tools = new IOSMidsceneTools();
1464
1457
  (0, cli_namespaceObject.runToolsCLI)(tools, 'midscene-ios', {
1465
1458
  stripPrefix: 'ios_',
1466
- version: "1.7.6-beta-20260425023224.0",
1459
+ version: "1.7.6",
1467
1460
  extraCommands: (0, core_namespaceObject.createReportCliCommands)()
1468
1461
  }).catch((e)=>{
1469
1462
  process.exit((0, cli_namespaceObject.reportCLIError)(e));
package/dist/lib/index.js CHANGED
@@ -1411,12 +1411,10 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1411
1411
  }
1412
1412
  if (this.agent) return this.agent;
1413
1413
  debug('Creating iOS agent with WebDriverAgent options:', opts || {});
1414
- const reportFileName = this.pendingReportFileName ?? this.readCliReportFileName();
1414
+ const reportOptions = this.readCliReportAgentOptions();
1415
1415
  this.agent = await agentFromWebDriverAgent({
1416
1416
  autoDismissKeyboard: false,
1417
- ...reportFileName ? {
1418
- reportFileName
1419
- } : {},
1417
+ ...reportOptions ?? {},
1420
1418
  ...opts ?? {}
1421
1419
  });
1422
1420
  this.lastOptsSignature = nextSignature;
@@ -1431,8 +1429,9 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1431
1429
  cli: this.getAgentInitArgCliMetadata(),
1432
1430
  handler: async (args)=>{
1433
1431
  const initArgs = this.extractAgentInitParam(args);
1434
- const reportSession = this.createNewCliReportSession();
1435
- this.pendingReportFileName = reportSession?.reportFileName;
1432
+ const identity = initArgs?.deviceId ?? (initArgs?.wdaHost || initArgs?.wdaPort ? `wda-${initArgs.wdaHost ?? 'localhost'}-${initArgs.wdaPort ?? 'default'}` : 'auto');
1433
+ const reportSession = this.createNewCliReportSession(identity);
1434
+ this.commitCliReportSession(reportSession);
1436
1435
  if (this.agent) {
1437
1436
  try {
1438
1437
  await this.agent.destroy?.();
@@ -1441,13 +1440,7 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1441
1440
  }
1442
1441
  this.agent = void 0;
1443
1442
  }
1444
- let agent;
1445
- try {
1446
- agent = await this.ensureAgent(initArgs);
1447
- } finally{
1448
- this.pendingReportFileName = void 0;
1449
- }
1450
- this.commitCliReportSession(reportSession);
1443
+ const agent = await this.ensureAgent(initArgs);
1451
1444
  const screenshot = await agent.page.screenshotBase64();
1452
1445
  return {
1453
1446
  content: [
@@ -1470,7 +1463,7 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1470
1463
  ];
1471
1464
  }
1472
1465
  constructor(...args){
1473
- super(...args), mcp_tools_define_property(this, "pendingReportFileName", void 0), mcp_tools_define_property(this, "initArgSpec", {
1466
+ super(...args), mcp_tools_define_property(this, "initArgSpec", {
1474
1467
  namespace: 'ios',
1475
1468
  shape: iosInitArgShape,
1476
1469
  cli: {
@@ -1407,12 +1407,10 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1407
1407
  }
1408
1408
  if (this.agent) return this.agent;
1409
1409
  debug('Creating iOS agent with WebDriverAgent options:', opts || {});
1410
- const reportFileName = this.pendingReportFileName ?? this.readCliReportFileName();
1410
+ const reportOptions = this.readCliReportAgentOptions();
1411
1411
  this.agent = await agentFromWebDriverAgent({
1412
1412
  autoDismissKeyboard: false,
1413
- ...reportFileName ? {
1414
- reportFileName
1415
- } : {},
1413
+ ...reportOptions ?? {},
1416
1414
  ...opts ?? {}
1417
1415
  });
1418
1416
  this.lastOptsSignature = nextSignature;
@@ -1427,8 +1425,9 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1427
1425
  cli: this.getAgentInitArgCliMetadata(),
1428
1426
  handler: async (args)=>{
1429
1427
  const initArgs = this.extractAgentInitParam(args);
1430
- const reportSession = this.createNewCliReportSession();
1431
- this.pendingReportFileName = reportSession?.reportFileName;
1428
+ const identity = initArgs?.deviceId ?? (initArgs?.wdaHost || initArgs?.wdaPort ? `wda-${initArgs.wdaHost ?? 'localhost'}-${initArgs.wdaPort ?? 'default'}` : 'auto');
1429
+ const reportSession = this.createNewCliReportSession(identity);
1430
+ this.commitCliReportSession(reportSession);
1432
1431
  if (this.agent) {
1433
1432
  try {
1434
1433
  await this.agent.destroy?.();
@@ -1437,13 +1436,7 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1437
1436
  }
1438
1437
  this.agent = void 0;
1439
1438
  }
1440
- let agent;
1441
- try {
1442
- agent = await this.ensureAgent(initArgs);
1443
- } finally{
1444
- this.pendingReportFileName = void 0;
1445
- }
1446
- this.commitCliReportSession(reportSession);
1439
+ const agent = await this.ensureAgent(initArgs);
1447
1440
  const screenshot = await agent.page.screenshotBase64();
1448
1441
  return {
1449
1442
  content: [
@@ -1466,7 +1459,7 @@ class IOSMidsceneTools extends base_tools_namespaceObject.BaseMidsceneTools {
1466
1459
  ];
1467
1460
  }
1468
1461
  constructor(...args){
1469
- super(...args), mcp_tools_define_property(this, "pendingReportFileName", void 0), mcp_tools_define_property(this, "initArgSpec", {
1462
+ super(...args), mcp_tools_define_property(this, "initArgSpec", {
1470
1463
  namespace: 'ios',
1471
1464
  shape: iosInitArgShape,
1472
1465
  cli: {
@@ -1483,7 +1476,7 @@ class IOSMCPServer extends mcp_namespaceObject.BaseMCPServer {
1483
1476
  constructor(toolsManager){
1484
1477
  super({
1485
1478
  name: '@midscene/ios-mcp',
1486
- version: "1.7.6-beta-20260425023224.0",
1479
+ version: "1.7.6",
1487
1480
  description: 'Control the iOS device using natural language commands'
1488
1481
  }, toolsManager);
1489
1482
  }
@@ -182,7 +182,6 @@ declare type IOSInitArgs = Pick<IOSDeviceOpt, 'deviceId' | 'wdaHost' | 'wdaPort'
182
182
  */
183
183
  export declare class IOSMidsceneTools extends BaseMidsceneTools<IOSAgent, IOSInitArgs> {
184
184
  protected getCliReportSessionName(): string;
185
- private pendingReportFileName?;
186
185
  protected readonly initArgSpec: InitArgSpec<IOSInitArgs>;
187
186
  private lastOptsSignature?;
188
187
  protected createTemporaryDevice(): IOSDevice;
@@ -185,7 +185,6 @@ export declare class IOSMCPServer extends BaseMCPServer {
185
185
  */
186
186
  declare class IOSMidsceneTools extends BaseMidsceneTools<IOSAgent, IOSInitArgs> {
187
187
  protected getCliReportSessionName(): string;
188
- private pendingReportFileName?;
189
188
  protected readonly initArgSpec: InitArgSpec<IOSInitArgs>;
190
189
  private lastOptsSignature?;
191
190
  protected createTemporaryDevice(): IOSDevice;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@midscene/ios",
3
- "version": "1.7.6-beta-20260425023224.0",
3
+ "version": "1.7.6",
4
4
  "description": "iOS automation library for Midscene",
5
5
  "keywords": [
6
6
  "iOS UI automation",
@@ -43,10 +43,10 @@
43
43
  "dependencies": {
44
44
  "@inquirer/prompts": "^7.8.6",
45
45
  "open": "10.1.0",
46
- "@midscene/webdriver": "1.7.6-beta-20260425023224.0",
47
- "@midscene/core": "1.7.6-beta-20260425023224.0",
48
- "@midscene/playground": "1.7.6-beta-20260425023224.0",
49
- "@midscene/shared": "1.7.6-beta-20260425023224.0"
46
+ "@midscene/core": "1.7.6",
47
+ "@midscene/webdriver": "1.7.6",
48
+ "@midscene/shared": "1.7.6",
49
+ "@midscene/playground": "1.7.6"
50
50
  },
51
51
  "devDependencies": {
52
52
  "@rslib/core": "^0.18.3",
package/static/index.html CHANGED
@@ -1 +1 @@
1
- <!doctype html><html><head><link rel="icon" href="/favicon.ico"><title>Midscene Playground</title><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><script defer src="/static/js/lib-react.7b1abe58.js"></script><script defer src="/static/js/883.516361ae.js"></script><script defer src="/static/js/index.bfac9a93.js"></script><link href="/static/css/index.dc500f18.css" rel="stylesheet"></head><body><div id="root"></div></body></html>
1
+ <!doctype html><html><head><link rel="icon" href="/favicon.ico"><title>Midscene Playground</title><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><script defer src="/static/js/lib-react.7b1abe58.js"></script><script defer src="/static/js/883.516361ae.js"></script><script defer src="/static/js/index.8f7b788e.js"></script><link href="/static/css/index.dc500f18.css" rel="stylesheet"></head><body><div id="root"></div></body></html>