peachsim 0.1.663 → 0.1.664
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/cli/commands/control.ts +9 -17
- package/cli/commands/inspect/core.ts +45 -32
- package/cli/commands/inspect/settling.ts +31 -21
- package/dist-lib/agent-daemon-client.cjs +1 -1
- package/dist-lib/agent-events.cjs +1 -1
- package/dist-lib/agent-identity.cjs +1 -1
- package/dist-lib/agent-sessions.cjs +1 -1
- package/dist-lib/attached-projects.cjs +1 -1
- package/dist-lib/auth/shared-session.cjs +1 -1
- package/dist-lib/backend-origin.cjs +1 -1
- package/dist-lib/beta.cjs +1 -1
- package/dist-lib/beta.mjs +1 -1
- package/dist-lib/bridge-constants.cjs +1 -1
- package/dist-lib/bridge-contract-input.cjs +2 -6
- package/dist-lib/bridge-contract-input.mjs +2 -6
- package/dist-lib/bridge-contract.cjs +6 -1
- package/dist-lib/bridge-contract.mjs +5 -1
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +1 -1
- package/dist-lib/cli-constants.cjs +1 -1
- package/dist-lib/cloud-contract.cjs +1 -1
- package/dist-lib/cloud-contract.mjs +1 -1
- package/dist-lib/cloud-test-args.cjs +1 -1
- package/dist-lib/cloud-test-args.mjs +1 -1
- package/dist-lib/cloud.cjs +1 -1
- package/dist-lib/cloud.mjs +1 -1
- package/dist-lib/config.cjs +1 -1
- package/dist-lib/detox/index.cjs +1 -1
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/home-paths.cjs +1 -1
- package/dist-lib/host/bridge-host.cjs +1 -1
- package/dist-lib/host/fetch-proxy-handler.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
- package/dist-lib/host/replacement-module-handler.cjs +1 -1
- package/dist-lib/host/websocket-proxy.cjs +1 -1
- package/dist-lib/index.cjs +17 -24
- package/dist-lib/jump-to-source-babel.cjs +1 -1
- package/dist-lib/jump-to-source-native.cjs +1 -1
- package/dist-lib/kotlin-host.cjs +1 -1
- package/dist-lib/menu.cjs +1 -1
- package/dist-lib/menu.mjs +1 -1
- package/dist-lib/metro-fingerprint-registry.cjs +1 -1
- package/dist-lib/metro-fingerprint-registry.mjs +1 -1
- package/dist-lib/metro-production-bundle.cjs +1 -1
- package/dist-lib/metro-production-bundle.mjs +1 -1
- package/dist-lib/metro.cjs +1 -1
- package/dist-lib/native-app-identity.cjs +1 -1
- package/dist-lib/native-app-identity.mjs +1 -1
- package/dist-lib/plist.cjs +1 -1
- package/dist-lib/plist.mjs +1 -1
- package/dist-lib/profiles.cjs +1 -1
- package/dist-lib/public-brand.cjs +1 -1
- package/dist-lib/react-native-host-modules.cjs +1 -1
- package/dist-lib/react-native-host-modules.mjs +1 -1
- package/dist-lib/render-mode.cjs +1 -1
- package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
- package/dist-lib/sdk.cjs +52 -39
- package/dist-lib/sdk.mjs +50 -39
- package/dist-lib/skills.cjs +38 -34
- package/dist-lib/swift-compile.cjs +1 -1
- package/dist-lib/swift-compile.mjs +1 -1
- package/dist-lib/swift-package.cjs +1 -1
- package/dist-lib/swift-package.mjs +1 -1
- package/dist-lib/swift-submit.cjs +1 -1
- package/dist-lib/swift-submit.mjs +1 -1
- package/dist-lib/swift.cjs +1 -1
- package/dist-lib/vite-swift.cjs +1 -1
- package/dist-lib/vite.cjs +1 -1
- package/kotlin/fixtures/kotlin-app-variants/Widgets.kt +56 -0
- package/package.json +1 -1
- package/src/bridge-contract-input.ts +1 -5
- package/src/bridge-contract.ts +16 -4
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/kotlin-host.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/menu.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/menu.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/metro.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/plist.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/plist.mjs
CHANGED
package/dist-lib/profiles.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/render-mode.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/sdk.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
|
@@ -62,6 +62,7 @@ __export(sdk_exports, {
|
|
|
62
62
|
inspectLogs: () => inspectLogs,
|
|
63
63
|
inspectMemory: () => inspectMemory,
|
|
64
64
|
inspectNodeCount: () => inspectNodeCount,
|
|
65
|
+
inspectReadySnapshot: () => inspectReadySnapshot,
|
|
65
66
|
inspectRequests: () => inspectRequests,
|
|
66
67
|
inspectScreens: () => inspectScreens,
|
|
67
68
|
inspectScrollStateAt: () => inspectScrollStateAt,
|
|
@@ -84,6 +85,7 @@ __export(sdk_exports, {
|
|
|
84
85
|
rankInteractive: () => rankInteractive,
|
|
85
86
|
readyProbeHasContent: () => readyProbeHasContent,
|
|
86
87
|
readyProbeHasTargetContent: () => readyProbeHasTargetContent,
|
|
88
|
+
readyProbeIsReady: () => readyProbeIsReady,
|
|
87
89
|
resolveFindMode: () => resolveFindMode,
|
|
88
90
|
resolveMaxMsFlag: () => resolveMaxMsFlag,
|
|
89
91
|
scoreInteractive: () => scoreInteractive,
|
|
@@ -114,6 +116,9 @@ function readyProbeHasContent(probe) {
|
|
|
114
116
|
function readyProbeHasTargetContent(probe) {
|
|
115
117
|
return probe.liveFrameActive || probe.targets > 0;
|
|
116
118
|
}
|
|
119
|
+
function readyProbeIsReady(probe) {
|
|
120
|
+
return (probe.flag === true ? readyProbeHasContent(probe) : readyProbeHasTargetContent(probe)) && probe.externalReady !== false && !probe.externalError && !probe.loadingText;
|
|
121
|
+
}
|
|
117
122
|
|
|
118
123
|
// cli/commands/inspect/core.ts
|
|
119
124
|
function resolveMaxMsFlag(args, fallbackMs) {
|
|
@@ -854,39 +859,38 @@ function waitReadyReason(status) {
|
|
|
854
859
|
return !status.externalError && status.suppressedEntryError ? `${base} (suppressed entry error: ${status.suppressedEntryError})` : base;
|
|
855
860
|
}
|
|
856
861
|
async function inspectWaitReady(bridge, timeoutMs = 2e4, options = {}) {
|
|
862
|
+
const result = await sendReadyWait(bridge, timeoutMs, timeoutMs + 1e3, options.simId);
|
|
863
|
+
const status = waitReadyStatus(result, result.matched && !result.probe?.externalError);
|
|
864
|
+
if (!status.ready && options.onProgress) options.onProgress(status);
|
|
865
|
+
return status;
|
|
866
|
+
}
|
|
867
|
+
async function inspectReadySnapshot(bridge, sendTimeoutMs, simId) {
|
|
868
|
+
const result = await sendReadyWait(bridge, 1, sendTimeoutMs, simId);
|
|
869
|
+
return waitReadyStatus(result, result.probe ? readyProbeIsReady(result.probe) : false);
|
|
870
|
+
}
|
|
871
|
+
async function sendReadyWait(bridge, timeoutMs, sendTimeoutMs, simId) {
|
|
857
872
|
const start = Date.now();
|
|
858
|
-
let result;
|
|
859
873
|
try {
|
|
860
|
-
|
|
874
|
+
return await bridge.send(
|
|
861
875
|
{
|
|
862
876
|
type: "waitFor",
|
|
863
|
-
...
|
|
864
|
-
waitForOptions: {
|
|
865
|
-
condition: {
|
|
866
|
-
type: "ready",
|
|
867
|
-
...options.stableMs === void 0 ? {} : { stableMs: options.stableMs }
|
|
868
|
-
},
|
|
869
|
-
timeoutMs
|
|
870
|
-
}
|
|
877
|
+
...simId ? { simId } : {},
|
|
878
|
+
waitForOptions: { condition: { type: "ready" }, timeoutMs }
|
|
871
879
|
},
|
|
872
|
-
{ timeoutMs:
|
|
880
|
+
{ timeoutMs: sendTimeoutMs }
|
|
873
881
|
);
|
|
874
882
|
} catch (error) {
|
|
875
883
|
const bridgeError = error instanceof Error ? error.message : String(error);
|
|
876
884
|
if (bridgeError.startsWith("multiple sims are connected:") || bridgeError.startsWith("saved sim ")) {
|
|
877
885
|
throw error;
|
|
878
886
|
}
|
|
879
|
-
|
|
880
|
-
matched: false,
|
|
881
|
-
elapsedMs: Date.now() - start,
|
|
882
|
-
polls: 0,
|
|
883
|
-
error: bridgeError
|
|
884
|
-
};
|
|
887
|
+
return { matched: false, elapsedMs: Date.now() - start, polls: 0, error: bridgeError };
|
|
885
888
|
}
|
|
889
|
+
}
|
|
890
|
+
function waitReadyStatus(result, ready) {
|
|
886
891
|
const probe = result.probe;
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
ready: result.matched && !externalError,
|
|
892
|
+
return {
|
|
893
|
+
ready,
|
|
890
894
|
elapsedMs: result.elapsedMs,
|
|
891
895
|
nodes: probe?.nodes ?? 0,
|
|
892
896
|
targets: probe?.targets ?? 0,
|
|
@@ -897,13 +901,11 @@ async function inspectWaitReady(bridge, timeoutMs = 2e4, options = {}) {
|
|
|
897
901
|
loadingText: probe?.loadingText ?? "",
|
|
898
902
|
externalReady: probe?.externalReady ?? null,
|
|
899
903
|
externalStatus: probe?.externalStatus ?? "",
|
|
900
|
-
externalError,
|
|
904
|
+
externalError: probe?.externalError ?? "",
|
|
901
905
|
suppressedEntryError: probe?.suppressedEntryError ?? "",
|
|
902
906
|
errors: probe?.errors ?? 0,
|
|
903
907
|
bridgeError: result.error ?? ""
|
|
904
908
|
};
|
|
905
|
-
if (!status.ready && options.onProgress) options.onProgress(status);
|
|
906
|
-
return status;
|
|
907
909
|
}
|
|
908
910
|
async function inspectWaitSelector(bridge, testId, timeoutMs = 5e3, opts = {}) {
|
|
909
911
|
const gone = opts.gone === true;
|
|
@@ -1692,22 +1694,31 @@ async function waitForSootsimIdle({
|
|
|
1692
1694
|
}
|
|
1693
1695
|
async function waitReadyAndSettle(bridge, timeoutMs, options = {}) {
|
|
1694
1696
|
const start = Date.now();
|
|
1695
|
-
const
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
maxMs: Math.max(100, Math.min(1e4, timeoutMs - (Date.now() - start))),
|
|
1701
|
-
pollMs: 32,
|
|
1702
|
-
stablePolls: 2
|
|
1697
|
+
const remaining = () => Math.max(0, start + timeoutMs - Date.now());
|
|
1698
|
+
const result = (status, idle2) => ({
|
|
1699
|
+
status,
|
|
1700
|
+
idle: idle2,
|
|
1701
|
+
elapsedMs: Date.now() - start
|
|
1703
1702
|
});
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
bridge,
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1703
|
+
let idle = null;
|
|
1704
|
+
for (; ; ) {
|
|
1705
|
+
const ready = await inspectWaitReady(bridge, remaining(), options);
|
|
1706
|
+
if (!ready.ready) return result(ready, idle);
|
|
1707
|
+
idle = await waitForSootsimIdle({
|
|
1708
|
+
bridge,
|
|
1709
|
+
simId: options.simId,
|
|
1710
|
+
maxMs: Math.min(1e4, remaining()),
|
|
1711
|
+
pollMs: 32,
|
|
1712
|
+
stablePolls: 2
|
|
1713
|
+
});
|
|
1714
|
+
if (!idle.settled) return result(ready, idle);
|
|
1715
|
+
const settled = await inspectReadySnapshot(
|
|
1716
|
+
bridge,
|
|
1717
|
+
Math.max(1e3, remaining()),
|
|
1718
|
+
options.simId
|
|
1719
|
+
);
|
|
1720
|
+
if (settled.ready || remaining() === 0) return result(settled, idle);
|
|
1721
|
+
}
|
|
1711
1722
|
}
|
|
1712
1723
|
|
|
1713
1724
|
// cli/commands/inspect/actions.ts
|
|
@@ -2608,6 +2619,7 @@ var SimClient = class {
|
|
|
2608
2619
|
inspectLogs,
|
|
2609
2620
|
inspectMemory,
|
|
2610
2621
|
inspectNodeCount,
|
|
2622
|
+
inspectReadySnapshot,
|
|
2611
2623
|
inspectRequests,
|
|
2612
2624
|
inspectScreens,
|
|
2613
2625
|
inspectScrollStateAt,
|
|
@@ -2630,6 +2642,7 @@ var SimClient = class {
|
|
|
2630
2642
|
rankInteractive,
|
|
2631
2643
|
readyProbeHasContent,
|
|
2632
2644
|
readyProbeHasTargetContent,
|
|
2645
|
+
readyProbeIsReady,
|
|
2633
2646
|
resolveFindMode,
|
|
2634
2647
|
resolveMaxMsFlag,
|
|
2635
2648
|
scoreInteractive,
|
package/dist-lib/sdk.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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);
|
|
@@ -13,6 +13,9 @@ function readyProbeHasContent(probe) {
|
|
|
13
13
|
function readyProbeHasTargetContent(probe) {
|
|
14
14
|
return probe.liveFrameActive || probe.targets > 0;
|
|
15
15
|
}
|
|
16
|
+
function readyProbeIsReady(probe) {
|
|
17
|
+
return (probe.flag === true ? readyProbeHasContent(probe) : readyProbeHasTargetContent(probe)) && probe.externalReady !== false && !probe.externalError && !probe.loadingText;
|
|
18
|
+
}
|
|
16
19
|
|
|
17
20
|
// cli/commands/inspect/core.ts
|
|
18
21
|
function resolveMaxMsFlag(args, fallbackMs) {
|
|
@@ -753,39 +756,38 @@ function waitReadyReason(status) {
|
|
|
753
756
|
return !status.externalError && status.suppressedEntryError ? `${base} (suppressed entry error: ${status.suppressedEntryError})` : base;
|
|
754
757
|
}
|
|
755
758
|
async function inspectWaitReady(bridge, timeoutMs = 2e4, options = {}) {
|
|
759
|
+
const result = await sendReadyWait(bridge, timeoutMs, timeoutMs + 1e3, options.simId);
|
|
760
|
+
const status = waitReadyStatus(result, result.matched && !result.probe?.externalError);
|
|
761
|
+
if (!status.ready && options.onProgress) options.onProgress(status);
|
|
762
|
+
return status;
|
|
763
|
+
}
|
|
764
|
+
async function inspectReadySnapshot(bridge, sendTimeoutMs, simId) {
|
|
765
|
+
const result = await sendReadyWait(bridge, 1, sendTimeoutMs, simId);
|
|
766
|
+
return waitReadyStatus(result, result.probe ? readyProbeIsReady(result.probe) : false);
|
|
767
|
+
}
|
|
768
|
+
async function sendReadyWait(bridge, timeoutMs, sendTimeoutMs, simId) {
|
|
756
769
|
const start = Date.now();
|
|
757
|
-
let result;
|
|
758
770
|
try {
|
|
759
|
-
|
|
771
|
+
return await bridge.send(
|
|
760
772
|
{
|
|
761
773
|
type: "waitFor",
|
|
762
|
-
...
|
|
763
|
-
waitForOptions: {
|
|
764
|
-
condition: {
|
|
765
|
-
type: "ready",
|
|
766
|
-
...options.stableMs === void 0 ? {} : { stableMs: options.stableMs }
|
|
767
|
-
},
|
|
768
|
-
timeoutMs
|
|
769
|
-
}
|
|
774
|
+
...simId ? { simId } : {},
|
|
775
|
+
waitForOptions: { condition: { type: "ready" }, timeoutMs }
|
|
770
776
|
},
|
|
771
|
-
{ timeoutMs:
|
|
777
|
+
{ timeoutMs: sendTimeoutMs }
|
|
772
778
|
);
|
|
773
779
|
} catch (error) {
|
|
774
780
|
const bridgeError = error instanceof Error ? error.message : String(error);
|
|
775
781
|
if (bridgeError.startsWith("multiple sims are connected:") || bridgeError.startsWith("saved sim ")) {
|
|
776
782
|
throw error;
|
|
777
783
|
}
|
|
778
|
-
|
|
779
|
-
matched: false,
|
|
780
|
-
elapsedMs: Date.now() - start,
|
|
781
|
-
polls: 0,
|
|
782
|
-
error: bridgeError
|
|
783
|
-
};
|
|
784
|
+
return { matched: false, elapsedMs: Date.now() - start, polls: 0, error: bridgeError };
|
|
784
785
|
}
|
|
786
|
+
}
|
|
787
|
+
function waitReadyStatus(result, ready) {
|
|
785
788
|
const probe = result.probe;
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
ready: result.matched && !externalError,
|
|
789
|
+
return {
|
|
790
|
+
ready,
|
|
789
791
|
elapsedMs: result.elapsedMs,
|
|
790
792
|
nodes: probe?.nodes ?? 0,
|
|
791
793
|
targets: probe?.targets ?? 0,
|
|
@@ -796,13 +798,11 @@ async function inspectWaitReady(bridge, timeoutMs = 2e4, options = {}) {
|
|
|
796
798
|
loadingText: probe?.loadingText ?? "",
|
|
797
799
|
externalReady: probe?.externalReady ?? null,
|
|
798
800
|
externalStatus: probe?.externalStatus ?? "",
|
|
799
|
-
externalError,
|
|
801
|
+
externalError: probe?.externalError ?? "",
|
|
800
802
|
suppressedEntryError: probe?.suppressedEntryError ?? "",
|
|
801
803
|
errors: probe?.errors ?? 0,
|
|
802
804
|
bridgeError: result.error ?? ""
|
|
803
805
|
};
|
|
804
|
-
if (!status.ready && options.onProgress) options.onProgress(status);
|
|
805
|
-
return status;
|
|
806
806
|
}
|
|
807
807
|
async function inspectWaitSelector(bridge, testId, timeoutMs = 5e3, opts = {}) {
|
|
808
808
|
const gone = opts.gone === true;
|
|
@@ -1591,22 +1591,31 @@ async function waitForSootsimIdle({
|
|
|
1591
1591
|
}
|
|
1592
1592
|
async function waitReadyAndSettle(bridge, timeoutMs, options = {}) {
|
|
1593
1593
|
const start = Date.now();
|
|
1594
|
-
const
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
maxMs: Math.max(100, Math.min(1e4, timeoutMs - (Date.now() - start))),
|
|
1600
|
-
pollMs: 32,
|
|
1601
|
-
stablePolls: 2
|
|
1594
|
+
const remaining = () => Math.max(0, start + timeoutMs - Date.now());
|
|
1595
|
+
const result = (status, idle2) => ({
|
|
1596
|
+
status,
|
|
1597
|
+
idle: idle2,
|
|
1598
|
+
elapsedMs: Date.now() - start
|
|
1602
1599
|
});
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
bridge,
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1600
|
+
let idle = null;
|
|
1601
|
+
for (; ; ) {
|
|
1602
|
+
const ready = await inspectWaitReady(bridge, remaining(), options);
|
|
1603
|
+
if (!ready.ready) return result(ready, idle);
|
|
1604
|
+
idle = await waitForSootsimIdle({
|
|
1605
|
+
bridge,
|
|
1606
|
+
simId: options.simId,
|
|
1607
|
+
maxMs: Math.min(1e4, remaining()),
|
|
1608
|
+
pollMs: 32,
|
|
1609
|
+
stablePolls: 2
|
|
1610
|
+
});
|
|
1611
|
+
if (!idle.settled) return result(ready, idle);
|
|
1612
|
+
const settled = await inspectReadySnapshot(
|
|
1613
|
+
bridge,
|
|
1614
|
+
Math.max(1e3, remaining()),
|
|
1615
|
+
options.simId
|
|
1616
|
+
);
|
|
1617
|
+
if (settled.ready || remaining() === 0) return result(settled, idle);
|
|
1618
|
+
}
|
|
1610
1619
|
}
|
|
1611
1620
|
|
|
1612
1621
|
// cli/commands/inspect/actions.ts
|
|
@@ -2506,6 +2515,7 @@ export {
|
|
|
2506
2515
|
inspectLogs,
|
|
2507
2516
|
inspectMemory,
|
|
2508
2517
|
inspectNodeCount,
|
|
2518
|
+
inspectReadySnapshot,
|
|
2509
2519
|
inspectRequests,
|
|
2510
2520
|
inspectScreens,
|
|
2511
2521
|
inspectScrollStateAt,
|
|
@@ -2528,6 +2538,7 @@ export {
|
|
|
2528
2538
|
rankInteractive,
|
|
2529
2539
|
readyProbeHasContent,
|
|
2530
2540
|
readyProbeHasTargetContent,
|
|
2541
|
+
readyProbeIsReady,
|
|
2531
2542
|
resolveFindMode,
|
|
2532
2543
|
resolveMaxMsFlag,
|
|
2533
2544
|
scoreInteractive,
|
package/dist-lib/skills.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
|
@@ -33273,10 +33273,20 @@ var init_app_splash = __esm({
|
|
|
33273
33273
|
});
|
|
33274
33274
|
|
|
33275
33275
|
// src/bridge-contract.ts
|
|
33276
|
-
|
|
33276
|
+
function readyProbeHasContent(probe3) {
|
|
33277
|
+
return probe3.liveFrameActive || probe3.targets > 0 || probe3.nodes >= SEMANTIC_READY_CONTENT_NODE_FLOOR;
|
|
33278
|
+
}
|
|
33279
|
+
function readyProbeHasTargetContent(probe3) {
|
|
33280
|
+
return probe3.liveFrameActive || probe3.targets > 0;
|
|
33281
|
+
}
|
|
33282
|
+
function readyProbeIsReady(probe3) {
|
|
33283
|
+
return (probe3.flag === true ? readyProbeHasContent(probe3) : readyProbeHasTargetContent(probe3)) && probe3.externalReady !== false && !probe3.externalError && !probe3.loadingText;
|
|
33284
|
+
}
|
|
33285
|
+
var SEMANTIC_READY_CONTENT_NODE_FLOOR, PUBLIC_NO_NETWORK_MARKER, HEADLESS_TENANT_FETCH_HUNG_MARKER;
|
|
33277
33286
|
var init_bridge_contract = __esm({
|
|
33278
33287
|
"src/bridge-contract.ts"() {
|
|
33279
33288
|
"use strict";
|
|
33289
|
+
SEMANTIC_READY_CONTENT_NODE_FLOOR = 100;
|
|
33280
33290
|
PUBLIC_NO_NETWORK_MARKER = "public Peach Cloud simulators have no network";
|
|
33281
33291
|
HEADLESS_TENANT_FETCH_HUNG_MARKER = "headless tenant fetch hung";
|
|
33282
33292
|
}
|
|
@@ -33762,39 +33772,38 @@ function waitReadyReason(status) {
|
|
|
33762
33772
|
return !status.externalError && status.suppressedEntryError ? `${base} (suppressed entry error: ${status.suppressedEntryError})` : base;
|
|
33763
33773
|
}
|
|
33764
33774
|
async function inspectWaitReady(bridge, timeoutMs = 2e4, options = {}) {
|
|
33775
|
+
const result = await sendReadyWait(bridge, timeoutMs, timeoutMs + 1e3, options.simId);
|
|
33776
|
+
const status = waitReadyStatus(result, result.matched && !result.probe?.externalError);
|
|
33777
|
+
if (!status.ready && options.onProgress) options.onProgress(status);
|
|
33778
|
+
return status;
|
|
33779
|
+
}
|
|
33780
|
+
async function inspectReadySnapshot(bridge, sendTimeoutMs, simId) {
|
|
33781
|
+
const result = await sendReadyWait(bridge, 1, sendTimeoutMs, simId);
|
|
33782
|
+
return waitReadyStatus(result, result.probe ? readyProbeIsReady(result.probe) : false);
|
|
33783
|
+
}
|
|
33784
|
+
async function sendReadyWait(bridge, timeoutMs, sendTimeoutMs, simId) {
|
|
33765
33785
|
const start = Date.now();
|
|
33766
|
-
let result;
|
|
33767
33786
|
try {
|
|
33768
|
-
|
|
33787
|
+
return await bridge.send(
|
|
33769
33788
|
{
|
|
33770
33789
|
type: "waitFor",
|
|
33771
|
-
...
|
|
33772
|
-
waitForOptions: {
|
|
33773
|
-
condition: {
|
|
33774
|
-
type: "ready",
|
|
33775
|
-
...options.stableMs === void 0 ? {} : { stableMs: options.stableMs }
|
|
33776
|
-
},
|
|
33777
|
-
timeoutMs
|
|
33778
|
-
}
|
|
33790
|
+
...simId ? { simId } : {},
|
|
33791
|
+
waitForOptions: { condition: { type: "ready" }, timeoutMs }
|
|
33779
33792
|
},
|
|
33780
|
-
{ timeoutMs:
|
|
33793
|
+
{ timeoutMs: sendTimeoutMs }
|
|
33781
33794
|
);
|
|
33782
33795
|
} catch (error) {
|
|
33783
33796
|
const bridgeError = error instanceof Error ? error.message : String(error);
|
|
33784
33797
|
if (bridgeError.startsWith("multiple sims are connected:") || bridgeError.startsWith("saved sim ")) {
|
|
33785
33798
|
throw error;
|
|
33786
33799
|
}
|
|
33787
|
-
|
|
33788
|
-
matched: false,
|
|
33789
|
-
elapsedMs: Date.now() - start,
|
|
33790
|
-
polls: 0,
|
|
33791
|
-
error: bridgeError
|
|
33792
|
-
};
|
|
33800
|
+
return { matched: false, elapsedMs: Date.now() - start, polls: 0, error: bridgeError };
|
|
33793
33801
|
}
|
|
33802
|
+
}
|
|
33803
|
+
function waitReadyStatus(result, ready) {
|
|
33794
33804
|
const probe3 = result.probe;
|
|
33795
|
-
|
|
33796
|
-
|
|
33797
|
-
ready: result.matched && !externalError,
|
|
33805
|
+
return {
|
|
33806
|
+
ready,
|
|
33798
33807
|
elapsedMs: result.elapsedMs,
|
|
33799
33808
|
nodes: probe3?.nodes ?? 0,
|
|
33800
33809
|
targets: probe3?.targets ?? 0,
|
|
@@ -33805,13 +33814,11 @@ async function inspectWaitReady(bridge, timeoutMs = 2e4, options = {}) {
|
|
|
33805
33814
|
loadingText: probe3?.loadingText ?? "",
|
|
33806
33815
|
externalReady: probe3?.externalReady ?? null,
|
|
33807
33816
|
externalStatus: probe3?.externalStatus ?? "",
|
|
33808
|
-
externalError,
|
|
33817
|
+
externalError: probe3?.externalError ?? "",
|
|
33809
33818
|
suppressedEntryError: probe3?.suppressedEntryError ?? "",
|
|
33810
33819
|
errors: probe3?.errors ?? 0,
|
|
33811
33820
|
bridgeError: result.error ?? ""
|
|
33812
33821
|
};
|
|
33813
|
-
if (!status.ready && options.onProgress) options.onProgress(status);
|
|
33814
|
-
return status;
|
|
33815
33822
|
}
|
|
33816
33823
|
function consoleEntriesEval(level, limit) {
|
|
33817
33824
|
const getter = level === "error" ? "getErrors" : "getWarnings";
|
|
@@ -37440,17 +37447,14 @@ async function maybeDescribeAfterOpen(wsPort, simId, args) {
|
|
|
37440
37447
|
if (noDescribe) return;
|
|
37441
37448
|
let readyProbe = null;
|
|
37442
37449
|
try {
|
|
37443
|
-
readyProbe = await
|
|
37450
|
+
readyProbe = await inspectReadySnapshot(bridge, 3e3);
|
|
37444
37451
|
} catch {
|
|
37445
37452
|
}
|
|
37446
|
-
if (readyProbe) {
|
|
37447
|
-
|
|
37448
|
-
|
|
37449
|
-
|
|
37450
|
-
|
|
37451
|
-
);
|
|
37452
|
-
console.log(" before interacting, run: peach wait ready --max-ms 120000");
|
|
37453
|
-
}
|
|
37453
|
+
if (readyProbe && !readyProbe.ready) {
|
|
37454
|
+
console.log(
|
|
37455
|
+
` app still loading: ${waitReadyReason(readyProbe)} (nodes: ${readyProbe.nodes}, targets: ${readyProbe.targets})`
|
|
37456
|
+
);
|
|
37457
|
+
console.log(" before interacting, run: peach wait ready --max-ms 120000");
|
|
37454
37458
|
}
|
|
37455
37459
|
const result = await inspectDescribe(bridge, {
|
|
37456
37460
|
describe: true,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/swift.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/vite-swift.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|
package/dist-lib/vite.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.664 | (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;
|