peachsim 0.1.527 → 0.1.570

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.
Files changed (158) hide show
  1. package/README.md +26 -26
  2. package/cli/app-fonts.ts +1 -1
  3. package/cli/app-splash.ts +1 -1
  4. package/cli/bin.ts +1 -1
  5. package/cli/bridge-diagnostics.ts +1 -1
  6. package/cli/bridge-flow-runner.ts +57 -5
  7. package/cli/cloud-client.ts +273 -6
  8. package/cli/cloud-dispatch.ts +22 -2
  9. package/cli/cloud-session.ts +60 -4
  10. package/cli/cloud-test-tunnel.ts +354 -0
  11. package/cli/commands/box/bundle-plane.ts +2 -2
  12. package/cli/commands/box/checkout-plane.ts +1 -1
  13. package/cli/commands/box/rnx-command.ts +2 -2
  14. package/cli/commands/box/search-command.ts +2 -2
  15. package/cli/commands/box.ts +8 -8
  16. package/cli/commands/compat.ts +1 -1
  17. package/cli/commands/control.ts +22 -3
  18. package/cli/commands/detox.ts +1 -1
  19. package/cli/commands/device.ts +1 -1
  20. package/cli/commands/diagnose.ts +1 -1
  21. package/cli/commands/film.ts +1 -1
  22. package/cli/commands/flow.ts +60 -3
  23. package/cli/commands/inspect/actions.ts +1 -1
  24. package/cli/commands/inspect/core.ts +6 -7
  25. package/cli/commands/inspect/find.ts +2 -1
  26. package/cli/commands/inspect/resolve-target.ts +5 -3
  27. package/cli/commands/inspect/shared.ts +1 -1
  28. package/cli/commands/inspect/wait-event.ts +1 -1
  29. package/cli/commands/inspect/wait-selector.ts +15 -4
  30. package/cli/commands/inspect.ts +19 -14
  31. package/cli/commands/maestro.ts +464 -43
  32. package/cli/commands/permissions.ts +1 -1
  33. package/cli/commands/platform.ts +205 -8
  34. package/cli/commands/preview.ts +2 -2
  35. package/cli/commands/record.ts +2 -2
  36. package/cli/commands/report-issue.ts +2 -2
  37. package/cli/commands/screenshot-layers.ts +1 -1
  38. package/cli/commands/screenshot.ts +1 -1
  39. package/cli/commands/setup.ts +2 -2
  40. package/cli/commands/test.ts +440 -115
  41. package/cli/commands/three-mode.ts +1 -1
  42. package/cli/commands/upload.ts +5 -5
  43. package/cli/commands/what-happened.ts +1 -1
  44. package/cli/desktop-companion.ts +3 -3
  45. package/cli/drivers/playwright-sim-host.ts +2 -2
  46. package/cli/flow-file.ts +7 -0
  47. package/cli/flow-live-status.ts +65 -8
  48. package/cli/help-core.ts +3 -3
  49. package/cli/hidden-runtime-alias.ts +1 -1
  50. package/cli/maestro-report.ts +178 -0
  51. package/cli/main.ts +1 -1
  52. package/cli/outbound-endpoints.ts +185 -136
  53. package/cli/parse-args.ts +1 -1
  54. package/cli/registry.ts +1 -1
  55. package/cli/resolve-assets.ts +1 -1
  56. package/cli/run-registry.ts +8 -0
  57. package/cli/send-to-box.ts +4 -4
  58. package/cli/ws-bridge.ts +3 -5
  59. package/detox/expectations.ts +1 -1
  60. package/detox/gestures.ts +2 -2
  61. package/detox/index.ts +71 -29
  62. package/detox/jest-preset.cjs +3 -3
  63. package/detox/jest-setup-after-env.cjs +1 -1
  64. package/dist-lib/agent-daemon-client.cjs +2 -2
  65. package/dist-lib/agent-events.cjs +1 -1
  66. package/dist-lib/agent-identity.cjs +1 -1
  67. package/dist-lib/agent-sessions.cjs +2 -2
  68. package/dist-lib/attached-projects.cjs +2 -2
  69. package/dist-lib/auth/shared-session.cjs +1 -1
  70. package/dist-lib/backend-origin.cjs +1 -1
  71. package/dist-lib/beta.cjs +1 -1
  72. package/dist-lib/beta.mjs +1 -1
  73. package/dist-lib/bridge-constants.cjs +1 -1
  74. package/dist-lib/bridge-contract-input.cjs +1 -1
  75. package/dist-lib/bridge-contract-input.mjs +1 -1
  76. package/dist-lib/bridge-contract.cjs +1 -1
  77. package/dist-lib/bridge-contract.mjs +1 -1
  78. package/dist-lib/capture-contract.cjs +94 -3
  79. package/dist-lib/capture-contract.mjs +93 -3
  80. package/dist-lib/cli-constants.cjs +1 -1
  81. package/dist-lib/cloud-contract.cjs +1 -1
  82. package/dist-lib/cloud-contract.mjs +1 -1
  83. package/dist-lib/cloud.cjs +2 -2
  84. package/dist-lib/cloud.mjs +2 -2
  85. package/dist-lib/config.cjs +1 -1
  86. package/dist-lib/detox/index.cjs +106 -25
  87. package/dist-lib/detox/jest-preset.cjs +3 -3
  88. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  89. package/dist-lib/home-paths.cjs +1 -1
  90. package/dist-lib/host/bridge-host.cjs +137 -61
  91. package/dist-lib/host/fetch-proxy-handler.cjs +28 -2
  92. package/dist-lib/host/fetch-proxy-overrides.cjs +33 -3
  93. package/dist-lib/host/fetch-proxy-overrides.mjs +30 -2
  94. package/dist-lib/host/replacement-module-handler.cjs +1 -1
  95. package/dist-lib/host/websocket-proxy.cjs +1 -1
  96. package/dist-lib/index.cjs +209 -16
  97. package/dist-lib/jump-to-source-babel.cjs +1 -1
  98. package/dist-lib/jump-to-source-native.cjs +1 -1
  99. package/dist-lib/menu.cjs +2 -2
  100. package/dist-lib/menu.mjs +2 -2
  101. package/dist-lib/metro-fingerprint-registry.cjs +1 -1
  102. package/dist-lib/metro-fingerprint-registry.mjs +1 -1
  103. package/dist-lib/metro-production-bundle.cjs +3 -3
  104. package/dist-lib/metro-production-bundle.mjs +3 -3
  105. package/dist-lib/metro.cjs +8 -8
  106. package/dist-lib/profiles.cjs +1 -1
  107. package/dist-lib/public-brand.cjs +2 -2
  108. package/dist-lib/react-native-host-modules.cjs +1 -1
  109. package/dist-lib/react-native-host-modules.mjs +1 -1
  110. package/dist-lib/render-mode.cjs +1 -1
  111. package/dist-lib/scripts/dev-server-scanner.cjs +31 -15
  112. package/dist-lib/sdk.cjs +3 -2
  113. package/dist-lib/sdk.mjs +3 -2
  114. package/dist-lib/skills.cjs +362 -163
  115. package/dist-lib/swift-submit.cjs +1 -1
  116. package/dist-lib/swift-submit.mjs +1 -1
  117. package/dist-lib/swift.cjs +583 -16
  118. package/dist-lib/vite.cjs +29 -14
  119. package/package.json +9 -9
  120. package/scripts/dev-server-scanner.ts +41 -14
  121. package/scripts/optional-demo-registry.ts +3 -3
  122. package/skills/contrast/SKILL.md +9 -9
  123. package/skills/rnx-debug/SKILL.md +14 -4
  124. package/skills/rnx-perf/SKILL.md +5 -5
  125. package/skills/rnx-setup/SKILL.md +11 -11
  126. package/skills/rnx-test/SKILL.md +11 -11
  127. package/skills/rnx-visual/SKILL.md +6 -6
  128. package/src/agent-sessions.ts +3 -3
  129. package/src/attached-projects.ts +1 -1
  130. package/src/bridge-contract-input.ts +1 -1
  131. package/src/bridge-contract.ts +23 -5
  132. package/src/capture-contract.ts +145 -3
  133. package/src/config.ts +2 -2
  134. package/src/connect.ts +2 -2
  135. package/src/home-paths.ts +3 -3
  136. package/src/host/bridge-host.ts +2 -2
  137. package/src/host/fetch-proxy-handler.ts +4 -3
  138. package/src/host/fetch-proxy-overrides.ts +41 -0
  139. package/src/host/plane-host.ts +2 -2
  140. package/src/index.ts +3 -0
  141. package/src/metro-plugin.ts +4 -4
  142. package/src/metro-production-bundle.ts +2 -2
  143. package/src/native-seam-manifest.ts +6 -6
  144. package/src/public-brand.ts +1 -1
  145. package/src/rolldown-plugin-swift.ts +8 -5
  146. package/src/runtime-assets.ts +8 -6
  147. package/src/screenshots/frame-compose.ts +24 -56
  148. package/src/screenshots/org-deck.ts +1 -1
  149. package/src/screenshots/registry.ts +4 -4
  150. package/src/screenshots/schema.ts +1 -1
  151. package/src/sdk.ts +2 -2
  152. package/src/settings-bundle.ts +1 -1
  153. package/src/sim-client.ts +2 -4
  154. package/src/skills/builtin/compat-check.ts +1 -1
  155. package/src/vite-plugin-one.ts +1 -1
  156. package/src/vite-plugin-swift.ts +11 -6
  157. package/src/vite-plugin.ts +30 -17
  158. package/src/worklets-babel.ts +2 -2
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.527 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.570 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -28,7 +28,7 @@ module.exports = __toCommonJS(public_brand_exports);
28
28
  var name = "rnx";
29
29
  var rnxPublicBrand = Object.freeze({
30
30
  name,
31
- packageName: "rnxsim",
31
+ packageName: "peachsim",
32
32
  commandName: "rnx",
33
33
  domain: "rnxsim.com",
34
34
  origin: "https://rnxsim.com"
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.527 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.570 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.527 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.570 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
 
3
3
  // src/react-native-host-modules.ts
4
4
  var REACT_NATIVE_PASSTHROUGH_SPECIFIERS = [
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.527 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.570 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.527 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.570 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __create = Object.create;
@@ -482,7 +482,7 @@ function __resetAppSettingsBundleCacheForTests() {
482
482
  var import_node_fs = require("node:fs");
483
483
  var import_node_path2 = require("node:path");
484
484
  var import_node_url = require("node:url");
485
- var REGISTRY_REPO_PATH = "packages/sootsim/scripts/demo-app-registry.ts";
485
+ var REGISTRY_REPO_PATH = "packages/peachsim/scripts/demo-app-registry.ts";
486
486
  var MAX_ANCESTOR_STEPS = 8;
487
487
  function findInternalDemoRegistry(startDir) {
488
488
  let dir = startDir;
@@ -840,7 +840,7 @@ async function resolveLocalIconPath(hostname, port, rawIcon) {
840
840
  const res = await httpGet(hostname, port, candidate, "HEAD", ENRICH_TIMEOUT_MS);
841
841
  if (res?.statusCode === 200) {
842
842
  localIconPathCache.set(port, candidate);
843
- portCache.delete(port);
843
+ invalidatePortCache(port);
844
844
  return;
845
845
  }
846
846
  }
@@ -973,7 +973,7 @@ async function fetchManifestEnrichment(result, buildIconProxyUrl) {
973
973
  iconPath: parsed.iconPath,
974
974
  bundleId: parsed.bundleId
975
975
  });
976
- portCache.delete(result.port);
976
+ invalidatePortCache(result.port);
977
977
  }
978
978
  var knownNonPatched = /* @__PURE__ */ new Set();
979
979
  var knownNonExpo = /* @__PURE__ */ new Set();
@@ -1013,16 +1013,19 @@ async function probePort(port, buildIconProxyUrl, listeningProcess) {
1013
1013
  const framework = launchUrl.includes(
1014
1014
  "/one/metro-entry.bundle"
1015
1015
  ) ? "one" : "expo";
1016
- return applyManifest(
1017
- {
1018
- port,
1019
- framework,
1020
- bundleUrl: withRuntimeConfig(port, launchUrl, owner.cwd),
1021
- hmrUrl: `${buildLoopbackProbeBaseUrl("ws:", probeHostname, port)}/hot`,
1022
- lastSeen: Date.now(),
1023
- ...owner
1024
- },
1025
- manifestRes,
1016
+ return enrichWithManifest(
1017
+ applyManifest(
1018
+ {
1019
+ port,
1020
+ framework,
1021
+ bundleUrl: withRuntimeConfig(port, launchUrl, owner.cwd),
1022
+ hmrUrl: `${buildLoopbackProbeBaseUrl("ws:", probeHostname, port)}/hot`,
1023
+ lastSeen: Date.now(),
1024
+ ...owner
1025
+ },
1026
+ manifestRes,
1027
+ buildIconProxyUrl
1028
+ ),
1026
1029
  buildIconProxyUrl
1027
1030
  );
1028
1031
  }
@@ -1101,6 +1104,11 @@ function isSootSimSelfServer(server) {
1101
1104
  }
1102
1105
  var __isSootSimSelfServerForTests = isSootSimSelfServer;
1103
1106
  var portCache = /* @__PURE__ */ new Map();
1107
+ var portCacheInvalidatedAt = /* @__PURE__ */ new Map();
1108
+ function invalidatePortCache(port) {
1109
+ portCache.delete(port);
1110
+ portCacheInvalidatedAt.set(port, Date.now());
1111
+ }
1104
1112
  var NEGATIVE_CACHE_TTL_MS = 3e4;
1105
1113
  var WEAK_RESULT_CACHE_TTL_MS = 1500;
1106
1114
  function isWeakCachedResult(result) {
@@ -1128,6 +1136,7 @@ function __resetScannerCache() {
1128
1136
  knownOne.clear();
1129
1137
  enrichmentCache.clear();
1130
1138
  enrichmentInFlight.clear();
1139
+ portCacheInvalidatedAt.clear();
1131
1140
  __resetAppSettingsBundleCacheForTests();
1132
1141
  }
1133
1142
  async function attachAppSettingsBundle(result, projectRoot) {
@@ -1165,6 +1174,9 @@ async function scanDevServers(opts = {}) {
1165
1174
  for (const p of [...localIconPathCache.keys()]) {
1166
1175
  if (!currentPorts.has(p)) localIconPathCache.delete(p);
1167
1176
  }
1177
+ for (const p of [...portCacheInvalidatedAt.keys()]) {
1178
+ if (!currentPorts.has(p)) portCacheInvalidatedAt.delete(p);
1179
+ }
1168
1180
  const results = [];
1169
1181
  const toProbe = [];
1170
1182
  for (const { port, pid } of processes) {
@@ -1183,12 +1195,16 @@ async function scanDevServers(opts = {}) {
1183
1195
  toProbe.push({ port, pid });
1184
1196
  }
1185
1197
  if (toProbe.length > 0) {
1198
+ const scanStartedAt = Date.now();
1186
1199
  const probed = await Promise.all(
1187
1200
  toProbe.map((p) => probePort(p.port, opts.buildIconProxyUrl, p))
1188
1201
  );
1189
1202
  probed.forEach((result, i) => {
1190
1203
  const { port, pid } = toProbe[i];
1191
- if (pid !== 0) portCache.set(port, { pid, result, cachedAt: Date.now() });
1204
+ const invalidatedAt = portCacheInvalidatedAt.get(port) ?? 0;
1205
+ if (pid !== 0 && invalidatedAt < scanStartedAt) {
1206
+ portCache.set(port, { pid, result, cachedAt: Date.now() });
1207
+ }
1192
1208
  if (result) results.push(result);
1193
1209
  });
1194
1210
  }
package/dist-lib/sdk.cjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.527 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.570 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  let __sootsim_import_meta_url = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; } catch {}
3
3
  "use strict";
4
4
  var __defProp = Object.defineProperty;
@@ -783,13 +783,14 @@ async function inspectWaitReady(bridge, timeoutMs = 2e4, options = {}) {
783
783
  }
784
784
  async function inspectWaitSelector(bridge, testId, timeoutMs = 5e3, opts = {}) {
785
785
  const gone = opts.gone === true;
786
+ const cleanId = testId.replace(/^#/, "");
786
787
  const result = await bridge.send(
787
788
  {
788
789
  type: "waitFor",
789
790
  waitForOptions: {
790
791
  condition: {
791
792
  type: gone ? "absent" : opts.structural === true ? "mounted" : "present",
792
- selector: { testID: testId }
793
+ selector: { testID: cleanId }
793
794
  },
794
795
  timeoutMs
795
796
  }
package/dist-lib/sdk.mjs CHANGED
@@ -1,4 +1,4 @@
1
- /*! rnx v0.1.527 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
1
+ /*! rnx v0.1.570 | (c) 2026 Tamagui LLC | Proprietary — see LICENSE */
2
2
  var __defProp = Object.defineProperty;
3
3
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4
4
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
@@ -687,13 +687,14 @@ async function inspectWaitReady(bridge, timeoutMs = 2e4, options = {}) {
687
687
  }
688
688
  async function inspectWaitSelector(bridge, testId, timeoutMs = 5e3, opts = {}) {
689
689
  const gone = opts.gone === true;
690
+ const cleanId = testId.replace(/^#/, "");
690
691
  const result = await bridge.send(
691
692
  {
692
693
  type: "waitFor",
693
694
  waitForOptions: {
694
695
  condition: {
695
696
  type: gone ? "absent" : opts.structural === true ? "mounted" : "present",
696
- selector: { testID: testId }
697
+ selector: { testID: cleanId }
697
698
  },
698
699
  timeoutMs
699
700
  }