peachsim 0.1.761 → 0.1.763
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/README.md +5 -0
- package/cli/bridge-flow-runner.ts +3 -4
- package/cli/commands/inspect/settling.ts +193 -162
- 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 +1 -1
- package/dist-lib/bridge-contract-input.mjs +1 -1
- package/dist-lib/bridge-contract.cjs +1 -1
- package/dist-lib/bridge-contract.mjs +1 -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 +44 -37
- 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 +191 -159
- 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/native-firebase-metadata.cjs +1 -1
- package/dist-lib/native-firebase-metadata.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 +191 -159
- package/dist-lib/sdk.mjs +191 -159
- package/dist-lib/skills.cjs +240 -202
- 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-toolchain.cjs +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/package.json +1 -1
package/dist-lib/skills.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.763 | (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;
|
|
@@ -30473,6 +30473,43 @@ function iosDevice(spec) {
|
|
|
30473
30473
|
modelName: spec.name
|
|
30474
30474
|
};
|
|
30475
30475
|
}
|
|
30476
|
+
function ipadProDevice(model, name2, width, height, diagonalInches) {
|
|
30477
|
+
return iosDevice({
|
|
30478
|
+
model,
|
|
30479
|
+
name: name2,
|
|
30480
|
+
// iPad Pro 11-inch (M5) 12GB, iOS 27.0, simulator DBD4B183, UIKit probe
|
|
30481
|
+
// scenario `metrics`. portrait UIScreen.bounds 834×1210, scale 2,
|
|
30482
|
+
// nativeBounds 1668×2420. the window matched the screen.
|
|
30483
|
+
width,
|
|
30484
|
+
height,
|
|
30485
|
+
scale: 2,
|
|
30486
|
+
// portrait statusBarFrame was 834×32 at the top, and safeAreaInsets.top
|
|
30487
|
+
// was 32. landscape statusBarFrame stayed 32 tall while safeAreaInsets.top
|
|
30488
|
+
// was 10; this field is the portrait bar.
|
|
30489
|
+
statusBarHeight: 32,
|
|
30490
|
+
landscapeStatusBarHeight: 32,
|
|
30491
|
+
// portrait and landscape safeAreaInsets.bottom were both 20. the probe
|
|
30492
|
+
// has no separate home-indicator height.
|
|
30493
|
+
homeIndicatorHeight: 20,
|
|
30494
|
+
// UIScreen _displayCornerRadius, both orientations. the framebuffer
|
|
30495
|
+
// mask's tangent extent was not measured separately.
|
|
30496
|
+
cornerRadius: cornerRadii(30),
|
|
30497
|
+
continuousCornerRadius: cornerRadii(30),
|
|
30498
|
+
// housing is unsourced. the frame is the display until it is measured.
|
|
30499
|
+
frameInsets: uniformFrameInsets(0),
|
|
30500
|
+
dynamicIsland: null,
|
|
30501
|
+
// portrait safeAreaInsets. landscape was top 10, left 0, bottom 20, right 0.
|
|
30502
|
+
safeAreaInsets: { top: 32, bottom: 20, left: 0, right: 0 },
|
|
30503
|
+
iosVersion: "27.0",
|
|
30504
|
+
// portrait docked keyboard, UIKeyboardFrameEndUserInfoKey
|
|
30505
|
+
// {0, 870, 834, 340}. landscape posted a zero-height frame.
|
|
30506
|
+
keyboardPanelHeights: { qwerty: 333, pad: 333, emoji: 427 },
|
|
30507
|
+
// hypot(1668, 2420) / 11, measured native pixels over the device type's
|
|
30508
|
+
// 11-inch name. not a separate density read.
|
|
30509
|
+
physicalPPI: Math.hypot(width * 2, height * 2) / diagonalInches,
|
|
30510
|
+
hardwareButtons: modernButtons([0, 0], [0, 0], [0, 0], [0, 0])
|
|
30511
|
+
});
|
|
30512
|
+
}
|
|
30476
30513
|
function resolveDevicePosture(model, posture) {
|
|
30477
30514
|
const supported = devices[model].supportedPostures;
|
|
30478
30515
|
return posture && supported?.includes(posture) ? posture : supported?.[0] ?? "closed";
|
|
@@ -30523,7 +30560,7 @@ function rotateDevice(device, side) {
|
|
|
30523
30560
|
const barrelProtrusion = device.housing?.hingeBarrel?.protrusion ?? 0;
|
|
30524
30561
|
if (side === "left") insets.top += barrelProtrusion;
|
|
30525
30562
|
else insets.bottom += barrelProtrusion;
|
|
30526
|
-
const safeArea = device
|
|
30563
|
+
const safeArea = isPadIdiom(device) ? { top: 10, bottom: 20, left: 0, right: 0 } : device.model === "iphone-duo" ? { top: 0, bottom: 34, left: 0, right: 84 } : device.platform === "ios" && device.homeIndicatorHeight > 0 ? {
|
|
30527
30564
|
top: 0,
|
|
30528
30565
|
bottom: 20,
|
|
30529
30566
|
left: device.safeAreaInsets.top,
|
|
@@ -30566,6 +30603,9 @@ function rotateDevice(device, side) {
|
|
|
30566
30603
|
function defaultLandscapeSide(model, posture) {
|
|
30567
30604
|
return model === "iphone-duo" && resolveDevicePosture(model, posture) === "closed" ? "right" : "left";
|
|
30568
30605
|
}
|
|
30606
|
+
function isPadIdiom(spec) {
|
|
30607
|
+
return spec.model === "ipad-pro-11" || spec.model === "ipad-pro-13";
|
|
30608
|
+
}
|
|
30569
30609
|
function getDevice(model, posture, orientation, landscapeSide) {
|
|
30570
30610
|
const device = devices[model];
|
|
30571
30611
|
const side = landscapeSide ?? defaultLandscapeSide(model, posture);
|
|
@@ -31142,42 +31182,9 @@ var init_devices = __esm({
|
|
|
31142
31182
|
// frame and hardware buttons are not sourced yet, so this stays off the
|
|
31143
31183
|
// shipping picker the same way the duo does.
|
|
31144
31184
|
developmentOnly: true,
|
|
31145
|
-
...
|
|
31146
|
-
model: "ipad-pro-11",
|
|
31147
|
-
name: "iPad Pro 11-inch (M5)",
|
|
31148
|
-
// iPad Pro 11-inch (M5) 12GB, iOS 27.0, simulator DBD4B183, UIKit probe
|
|
31149
|
-
// scenario `metrics`. portrait UIScreen.bounds 834×1210, scale 2,
|
|
31150
|
-
// nativeBounds 1668×2420. the window matched the screen.
|
|
31151
|
-
width: 834,
|
|
31152
|
-
height: 1210,
|
|
31153
|
-
scale: 2,
|
|
31154
|
-
// portrait statusBarFrame was 834×32 at the top, and safeAreaInsets.top
|
|
31155
|
-
// was 32. landscape statusBarFrame stayed 32 tall while safeAreaInsets.top
|
|
31156
|
-
// was 10; this field is the portrait bar.
|
|
31157
|
-
statusBarHeight: 32,
|
|
31158
|
-
landscapeStatusBarHeight: 32,
|
|
31159
|
-
// portrait and landscape safeAreaInsets.bottom were both 20. the probe
|
|
31160
|
-
// has no separate home-indicator height.
|
|
31161
|
-
homeIndicatorHeight: 20,
|
|
31162
|
-
// UIScreen _displayCornerRadius, both orientations. the framebuffer
|
|
31163
|
-
// mask's tangent extent was not measured separately.
|
|
31164
|
-
cornerRadius: cornerRadii(30),
|
|
31165
|
-
continuousCornerRadius: cornerRadii(30),
|
|
31166
|
-
// housing is unsourced. the frame is the display until it is measured.
|
|
31167
|
-
frameInsets: uniformFrameInsets(0),
|
|
31168
|
-
dynamicIsland: null,
|
|
31169
|
-
// portrait safeAreaInsets. landscape was top 10, left 0, bottom 20, right 0.
|
|
31170
|
-
safeAreaInsets: { top: 32, bottom: 20, left: 0, right: 0 },
|
|
31171
|
-
iosVersion: "27.0",
|
|
31172
|
-
// portrait docked keyboard, UIKeyboardFrameEndUserInfoKey
|
|
31173
|
-
// {0, 870, 834, 340}. landscape posted a zero-height frame.
|
|
31174
|
-
keyboardPanelHeights: { qwerty: 333, pad: 333, emoji: 427 },
|
|
31175
|
-
// hypot(1668, 2420) / 11, measured native pixels over the device type's
|
|
31176
|
-
// 11-inch name. not a separate density read.
|
|
31177
|
-
physicalPPI: 267.19578360606573,
|
|
31178
|
-
hardwareButtons: modernButtons([0, 0], [0, 0], [0, 0], [0, 0])
|
|
31179
|
-
})
|
|
31185
|
+
...ipadProDevice("ipad-pro-11", "iPad Pro 11-inch (M5)", 834, 1210, 11)
|
|
31180
31186
|
},
|
|
31187
|
+
"ipad-pro-13": ipadProDevice("ipad-pro-13", "iPad Pro 13-inch (M5)", 1032, 1376, 13),
|
|
31181
31188
|
"pixel-8": {
|
|
31182
31189
|
model: "pixel-8",
|
|
31183
31190
|
platform: "android",
|
|
@@ -44579,179 +44586,211 @@ async function waitForSootsimIdle({
|
|
|
44579
44586
|
const start = Date.now()
|
|
44580
44587
|
const deadline = start + ${Math.max(0, Math.round(maxMs))}
|
|
44581
44588
|
const pollMs = ${Math.max(1, Math.round(pollMs))}
|
|
44582
|
-
const requiredStillMs = ${Math.max(1, Math.round(stablePolls)) * Math.max(1, Math.round(pollMs))}
|
|
44583
|
-
const minimumStablePolls = ${Math.min(2, Math.max(1, Math.round(stablePolls)))}
|
|
44584
44589
|
const strict = ${strict ? "true" : "false"}
|
|
44585
44590
|
const paintStill = ${paintStill ? "true" : "false"}
|
|
44591
|
+
const requiredStillMs = paintStill ? 0 : ${Math.max(1, Math.round(stablePolls)) * Math.max(1, Math.round(pollMs))}
|
|
44592
|
+
const minimumStablePolls = paintStill ? 1 : ${Math.min(2, Math.max(1, Math.round(stablePolls)))}
|
|
44586
44593
|
const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms))
|
|
44587
|
-
|
|
44588
|
-
|
|
44589
|
-
|
|
44590
|
-
|
|
44591
|
-
//
|
|
44592
|
-
//
|
|
44593
|
-
|
|
44594
|
-
|
|
44595
|
-
|
|
44594
|
+
const composite = paintStill ? window.SootSim?.bridges?.liveComposite : null
|
|
44595
|
+
if (paintStill && !composite) {
|
|
44596
|
+
return { settled: false, elapsed: Date.now() - start, blockedBy: 'screen pixels unavailable' }
|
|
44597
|
+
}
|
|
44598
|
+
// subscribe to presented frames; authoritative screenshots force a
|
|
44599
|
+
// worker render, which changes the very counter we used to inspect.
|
|
44600
|
+
const unsubscribe = composite?.subscribe(() => {})
|
|
44601
|
+
let pixelFrameToken = -1
|
|
44602
|
+
let screenPixels = null
|
|
44596
44603
|
try {
|
|
44597
|
-
const wfst = window.__sootsimTest?.waitForScreenTransitions
|
|
44598
|
-
if (typeof wfst === 'function') {
|
|
44599
|
-
const remaining = deadline - Date.now()
|
|
44600
|
-
if (remaining > 120) {
|
|
44601
|
-
await wfst({
|
|
44602
|
-
timeoutMs: Math.min(remaining - 80, 4000),
|
|
44603
|
-
settleMs: 64,
|
|
44604
|
-
startWindowMs: 80,
|
|
44605
|
-
})
|
|
44606
|
-
}
|
|
44607
|
-
}
|
|
44608
|
-
} catch {}
|
|
44609
44604
|
|
|
44610
|
-
|
|
44611
|
-
|
|
44612
|
-
|
|
44613
|
-
|
|
44614
|
-
|
|
44615
|
-
|
|
44616
|
-
|
|
44617
|
-
|
|
44618
|
-
let shellAnimating = false
|
|
44619
|
-
// strict also waits out shell motion: a system alert, sheet or menu
|
|
44620
|
-
// animates in the shell worker while the app's own stats read still,
|
|
44621
|
-
// so its presentation is complete only once the shell's list empties.
|
|
44622
|
-
if (strict) {
|
|
44623
|
-
try {
|
|
44624
|
-
const motion = await window.__sootsimTest?.listAnimations?.()
|
|
44625
|
-
shellAnimating = Array.isArray(motion) && motion.some((anim) => anim.realm === 'shell')
|
|
44626
|
-
} catch {}
|
|
44627
|
-
}
|
|
44605
|
+
// route-aware settle: a tap that pushes/pops a screen is async \u2014 the
|
|
44606
|
+
// old screen still renders for a moment, then the new one mounts and
|
|
44607
|
+
// its content loads. a pure layout-hash check reports "idle" on the
|
|
44608
|
+
// outgoing screen or on the incoming skeleton, so a driver re-taps
|
|
44609
|
+
// and stacks duplicate navigations. drain any in-flight screen
|
|
44610
|
+
// transition FIRST, bounded by the overall budget. when no
|
|
44611
|
+
// transition is happening this returns in ~80ms (startWindowMs), so
|
|
44612
|
+
// a plain button tap barely pays for it.
|
|
44628
44613
|
try {
|
|
44629
|
-
const
|
|
44630
|
-
if (
|
|
44631
|
-
|
|
44632
|
-
|
|
44633
|
-
|
|
44634
|
-
|
|
44635
|
-
|
|
44636
|
-
|
|
44637
|
-
|
|
44638
|
-
|
|
44639
|
-
// a freshly-pushed screen showing a skeleton is layout-stable
|
|
44640
|
-
// but not actually settled \u2014 its data/images are still in
|
|
44641
|
-
// flight. treat bounded image-loader fetches as not-idle so
|
|
44642
|
-
// settle waits for real content, capped by the budget.
|
|
44643
|
-
const pf = stats.memory && stats.memory.imageLoader
|
|
44644
|
-
? stats.memory.imageLoader.pendingFetches
|
|
44645
|
-
: 0
|
|
44646
|
-
pendingFetches = typeof pf === 'number' ? pf : 0
|
|
44614
|
+
const wfst = window.__sootsimTest?.waitForScreenTransitions
|
|
44615
|
+
if (typeof wfst === 'function') {
|
|
44616
|
+
const remaining = deadline - Date.now()
|
|
44617
|
+
if (remaining > 120) {
|
|
44618
|
+
await wfst({
|
|
44619
|
+
timeoutMs: Math.min(remaining - 80, 4000),
|
|
44620
|
+
settleMs: 64,
|
|
44621
|
+
startWindowMs: 80,
|
|
44622
|
+
})
|
|
44623
|
+
}
|
|
44647
44624
|
}
|
|
44648
44625
|
} catch {}
|
|
44649
|
-
|
|
44650
|
-
|
|
44651
|
-
|
|
44652
|
-
|
|
44653
|
-
|
|
44654
|
-
|
|
44655
|
-
|
|
44656
|
-
|
|
44657
|
-
|
|
44658
|
-
|
|
44659
|
-
|
|
44626
|
+
|
|
44627
|
+
const readSnapshot = async () => {
|
|
44628
|
+
let animating = false
|
|
44629
|
+
let layoutDirty = false
|
|
44630
|
+
let pendingFetches = 0
|
|
44631
|
+
let requestTotal = 0
|
|
44632
|
+
let requestInFlight = 0
|
|
44633
|
+
let renderStatsAvailable = false
|
|
44634
|
+
let shellAnimating = false
|
|
44635
|
+
// strict also waits out shell motion: a system alert, sheet or menu
|
|
44636
|
+
// animates in the shell worker while the app's own stats read still,
|
|
44637
|
+
// so its presentation is complete only once the shell's list empties.
|
|
44638
|
+
if (strict) {
|
|
44639
|
+
try {
|
|
44640
|
+
const motion = await window.__sootsimTest?.listAnimations?.()
|
|
44641
|
+
shellAnimating = Array.isArray(motion) && motion.some((anim) => anim.realm === 'shell')
|
|
44642
|
+
} catch {}
|
|
44643
|
+
}
|
|
44644
|
+
try {
|
|
44645
|
+
const stats = await window.__sootsimRenderHost?.queryStats?.()
|
|
44646
|
+
if (stats) {
|
|
44647
|
+
renderStatsAvailable = true
|
|
44648
|
+
animating =
|
|
44649
|
+
stats.hasActiveAnims === true ||
|
|
44650
|
+
stats.hasActiveNativeAnimations === true ||
|
|
44651
|
+
stats.hasPendingAnimationFrames === true
|
|
44652
|
+
layoutDirty =
|
|
44653
|
+
stats.layoutDirty === true && stats.renderRequested === true
|
|
44654
|
+
// a freshly-pushed screen showing a skeleton is layout-stable
|
|
44655
|
+
// but not actually settled \u2014 its data/images are still in
|
|
44656
|
+
// flight. treat bounded image-loader fetches as not-idle so
|
|
44657
|
+
// settle waits for real content, capped by the budget.
|
|
44658
|
+
const pf = stats.memory && stats.memory.imageLoader
|
|
44659
|
+
? stats.memory.imageLoader.pendingFetches
|
|
44660
|
+
: 0
|
|
44661
|
+
pendingFetches = typeof pf === 'number' ? pf : 0
|
|
44662
|
+
}
|
|
44663
|
+
} catch {}
|
|
44664
|
+
try {
|
|
44665
|
+
const counts = await window.__sootsimTest?.getRequestCounts?.()
|
|
44666
|
+
requestTotal = typeof counts?.total === 'number' ? counts.total : 0
|
|
44667
|
+
requestInFlight = typeof counts?.inFlight === 'number' ? counts.inFlight : 0
|
|
44668
|
+
} catch {}
|
|
44669
|
+
const root = window.__sootsimRoot
|
|
44670
|
+
const nodes = []
|
|
44671
|
+
if (root) {
|
|
44672
|
+
const walk = (n) => {
|
|
44673
|
+
if (n.layout && n.layout.width > 0) {
|
|
44674
|
+
nodes.push(Math.round(n.layout.x) + ',' + Math.round(n.layout.y) + ',' + Math.round(n.layout.width))
|
|
44675
|
+
}
|
|
44676
|
+
for (const c of n.children || []) walk(c)
|
|
44677
|
+
}
|
|
44678
|
+
walk(root)
|
|
44679
|
+
}
|
|
44680
|
+
if (paintStill) {
|
|
44681
|
+
const canvas = composite.getCanvas()
|
|
44682
|
+
const token = composite.getFrameToken()
|
|
44683
|
+
if (!canvas || canvas.width <= 1 || canvas.height <= 1) {
|
|
44684
|
+
screenPixels = null
|
|
44685
|
+
} else if (token !== pixelFrameToken || canvas.width !== screenPixels?.width || canvas.height !== screenPixels?.height) {
|
|
44686
|
+
const context = canvas.getContext('2d')
|
|
44687
|
+
const image = context?.getImageData(0, 0, canvas.width, canvas.height)
|
|
44688
|
+
screenPixels = image ? { width: image.width, height: image.height, data: new Uint32Array(image.data.buffer) } : null
|
|
44689
|
+
pixelFrameToken = token
|
|
44660
44690
|
}
|
|
44661
|
-
for (const c of n.children || []) walk(c)
|
|
44662
44691
|
}
|
|
44663
|
-
|
|
44692
|
+
return { layout: nodes.join(';'), screenPixels, animating, shellAnimating, layoutDirty, pendingFetches, renderStatsAvailable, requestTotal, requestInFlight }
|
|
44664
44693
|
}
|
|
44665
|
-
return { layout: nodes.join(';'), frameCount, animating, shellAnimating, layoutDirty, pendingFetches, renderStatsAvailable, requestTotal, requestInFlight }
|
|
44666
|
-
}
|
|
44667
44694
|
|
|
44668
|
-
|
|
44669
|
-
|
|
44670
|
-
|
|
44671
|
-
|
|
44672
|
-
|
|
44673
|
-
|
|
44674
|
-
|
|
44675
|
-
|
|
44676
|
-
|
|
44677
|
-
|
|
44678
|
-
|
|
44679
|
-
|
|
44680
|
-
|
|
44681
|
-
|
|
44682
|
-
|
|
44683
|
-
|
|
44684
|
-
|
|
44685
|
-
|
|
44686
|
-
|
|
44687
|
-
|
|
44688
|
-
|
|
44689
|
-
|
|
44690
|
-
|
|
44691
|
-
|
|
44692
|
-
|
|
44693
|
-
|
|
44694
|
-
|
|
44695
|
-
|
|
44696
|
-
|
|
44697
|
-
|
|
44698
|
-
|
|
44699
|
-
|
|
44700
|
-
|
|
44701
|
-
|
|
44702
|
-
|
|
44703
|
-
|
|
44704
|
-
|
|
44705
|
-
|
|
44706
|
-
|
|
44707
|
-
|
|
44708
|
-
|
|
44709
|
-
|
|
44710
|
-
|
|
44711
|
-
|
|
44712
|
-
|
|
44713
|
-
|
|
44714
|
-
|
|
44715
|
-
|
|
44716
|
-
|
|
44717
|
-
|
|
44718
|
-
|
|
44719
|
-
|
|
44720
|
-
|
|
44721
|
-
//
|
|
44722
|
-
|
|
44723
|
-
|
|
44724
|
-
|
|
44725
|
-
|
|
44726
|
-
|
|
44727
|
-
|
|
44728
|
-
|
|
44729
|
-
|
|
44730
|
-
|
|
44731
|
-
|
|
44732
|
-
|
|
44733
|
-
|
|
44734
|
-
|
|
44735
|
-
|
|
44736
|
-
|
|
44737
|
-
|
|
44738
|
-
|
|
44739
|
-
|
|
44740
|
-
|
|
44741
|
-
|
|
44742
|
-
|
|
44743
|
-
|
|
44744
|
-
|
|
44745
|
-
|
|
44746
|
-
|
|
44747
|
-
|
|
44748
|
-
|
|
44749
|
-
|
|
44750
|
-
|
|
44751
|
-
|
|
44752
|
-
|
|
44753
|
-
|
|
44754
|
-
|
|
44695
|
+
// how long generic background network is allowed to keep us waiting AFTER
|
|
44696
|
+
// the screen is otherwise visually settled. apps with continuous traffic
|
|
44697
|
+
// (polling, realtime sockets, a tap that fires 20-50 fetches) never reach
|
|
44698
|
+
// requestInFlight===0 / a stable requestTotal, so requiring full network
|
|
44699
|
+
// quiet burns the ENTIRE budget on every command \u2014 the leading idle that
|
|
44700
|
+
// failed PR-preview recordings for network-heavy apps (3pc fight-pulse).
|
|
44701
|
+
// layout-stability + the image-loader already prove visible content
|
|
44702
|
+
// loaded (a data load changes layout; an image load shows in the loader),
|
|
44703
|
+
// so the generic request counters are a courtesy, not a gate: honor them
|
|
44704
|
+
// only within this grace once the screen is visually still.
|
|
44705
|
+
const networkQuietGraceMs = 1200
|
|
44706
|
+
let lastLayout = ''
|
|
44707
|
+
let lastScreenPixels = null
|
|
44708
|
+
let screenChangedPolls = 0
|
|
44709
|
+
let lastRequestTotal = -1
|
|
44710
|
+
let stable = 0
|
|
44711
|
+
let visuallyStillSince = 0
|
|
44712
|
+
// counts across the whole budget: a flag that is true on every poll is a
|
|
44713
|
+
// different bug from one that is true intermittently, and the two need
|
|
44714
|
+
// opposite fixes (engine vs budget).
|
|
44715
|
+
let polls = 0
|
|
44716
|
+
let dirtyPolls = 0
|
|
44717
|
+
let animatingPolls = 0
|
|
44718
|
+
let layoutChangedPolls = 0
|
|
44719
|
+
const screenUnchanged = (pixels) => {
|
|
44720
|
+
if (!pixels || !lastScreenPixels || pixels.width !== lastScreenPixels.width || pixels.height !== lastScreenPixels.height) return false
|
|
44721
|
+
if (pixels === lastScreenPixels) return true
|
|
44722
|
+
for (let i = 0; i < pixels.data.length; i++) {
|
|
44723
|
+
if (pixels.data[i] !== lastScreenPixels.data[i]) return false
|
|
44724
|
+
}
|
|
44725
|
+
return true
|
|
44726
|
+
}
|
|
44727
|
+
while (Date.now() < deadline) {
|
|
44728
|
+
const snapshot = await readSnapshot()
|
|
44729
|
+
polls++
|
|
44730
|
+
if (snapshot.layoutDirty) dirtyPolls++
|
|
44731
|
+
if (snapshot.animating || snapshot.shellAnimating) animatingPolls++
|
|
44732
|
+
if (polls > 1 && snapshot.layout !== lastLayout) layoutChangedPolls++
|
|
44733
|
+
const screenChanged = paintStill && !screenUnchanged(snapshot.screenPixels)
|
|
44734
|
+
if (polls > 1 && screenChanged) screenChangedPolls++
|
|
44735
|
+
const strictOk =
|
|
44736
|
+
!strict ||
|
|
44737
|
+
(snapshot.renderStatsAvailable &&
|
|
44738
|
+
!snapshot.animating &&
|
|
44739
|
+
!snapshot.shellAnimating &&
|
|
44740
|
+
!snapshot.layoutDirty)
|
|
44741
|
+
// visually settled: no animations, no image content loading, layout
|
|
44742
|
+
// unchanged since the last poll.
|
|
44743
|
+
const visuallyStill =
|
|
44744
|
+
strictOk &&
|
|
44745
|
+
!screenChanged &&
|
|
44746
|
+
snapshot.pendingFetches === 0 &&
|
|
44747
|
+
snapshot.layout === lastLayout
|
|
44748
|
+
// generic network quiet: nothing in flight and no new requests issued.
|
|
44749
|
+
const networkQuiet =
|
|
44750
|
+
snapshot.requestInFlight === 0 && snapshot.requestTotal === lastRequestTotal
|
|
44751
|
+
if (visuallyStill) {
|
|
44752
|
+
stable++
|
|
44753
|
+
if (visuallyStillSince === 0) visuallyStillSince = Date.now()
|
|
44754
|
+
// settle once the screen has held still long enough AND either the
|
|
44755
|
+
// network is genuinely quiet OR it has refused to quiet within the
|
|
44756
|
+
// grace (continuous background traffic must not block forever).
|
|
44757
|
+
if (
|
|
44758
|
+
stable >= minimumStablePolls &&
|
|
44759
|
+
Date.now() - visuallyStillSince >= requiredStillMs &&
|
|
44760
|
+
(networkQuiet || Date.now() - visuallyStillSince >= networkQuietGraceMs)
|
|
44761
|
+
) {
|
|
44762
|
+
return { settled: true, elapsed: Date.now() - start, blockedBy: '' }
|
|
44763
|
+
}
|
|
44764
|
+
} else {
|
|
44765
|
+
stable = 0
|
|
44766
|
+
visuallyStillSince = 0
|
|
44767
|
+
}
|
|
44768
|
+
lastLayout = snapshot.layout
|
|
44769
|
+
lastScreenPixels = snapshot.screenPixels
|
|
44770
|
+
lastRequestTotal = snapshot.requestTotal
|
|
44771
|
+
await sleep(pollMs)
|
|
44772
|
+
}
|
|
44773
|
+
const last = await readSnapshot()
|
|
44774
|
+
const blockers = []
|
|
44775
|
+
if (strict && !last.renderStatsAvailable) blockers.push('render stats unavailable')
|
|
44776
|
+
if (last.animating) blockers.push('animations still running')
|
|
44777
|
+
if (last.shellAnimating) blockers.push('shell animations still running')
|
|
44778
|
+
if (last.layoutDirty) blockers.push('layout still dirty')
|
|
44779
|
+
if (last.pendingFetches > 0) blockers.push(last.pendingFetches + ' image fetches pending')
|
|
44780
|
+
if (last.layout !== lastLayout) blockers.push('layout still changing')
|
|
44781
|
+
if (paintStill && !last.screenPixels) blockers.push('screen pixels unavailable')
|
|
44782
|
+
else if (paintStill && !screenUnchanged(last.screenPixels)) blockers.push('screen pixels still changing')
|
|
44783
|
+
if (last.requestInFlight > 0) blockers.push(last.requestInFlight + ' requests in flight')
|
|
44784
|
+
return {
|
|
44785
|
+
settled: false,
|
|
44786
|
+
elapsed: Date.now() - start,
|
|
44787
|
+
blockedBy:
|
|
44788
|
+
(blockers.length ? blockers.join(', ') : 'unknown') +
|
|
44789
|
+
' over ' + polls + ' polls (layout changed ' + layoutChangedPolls +
|
|
44790
|
+
'x, layoutDirty ' + dirtyPolls + 'x, animating ' + animatingPolls + 'x, screen changed ' + screenChangedPolls + 'x)',
|
|
44791
|
+
}
|
|
44792
|
+
} finally {
|
|
44793
|
+
unsubscribe?.()
|
|
44755
44794
|
}
|
|
44756
44795
|
})()`
|
|
44757
44796
|
},
|
|
@@ -47076,9 +47115,9 @@ var init_bridge_flow_runner = __esm({
|
|
|
47076
47115
|
// maestro waits around taps for the screen to stop changing, up to
|
|
47077
47116
|
// its ios driver's 3 s settle budget, comparing screenshots, so an action
|
|
47078
47117
|
// still in flight (a submit spinner, a sheet closing) finishes before the
|
|
47079
|
-
// next command resolves its target.
|
|
47080
|
-
//
|
|
47081
|
-
//
|
|
47118
|
+
// next command resolves its target. compare consecutive screen pixels,
|
|
47119
|
+
// rather than requiring frame publications to stop for half a second:
|
|
47120
|
+
// a focused input keeps repainting its native blinking caret.
|
|
47082
47121
|
// a screen that never stops proceeds when the budget runs out, as there,
|
|
47083
47122
|
// and names what kept it moving: every such step pays the whole budget.
|
|
47084
47123
|
async waitForAppToSettle() {
|
|
@@ -47087,7 +47126,6 @@ var init_bridge_flow_runner = __esm({
|
|
|
47087
47126
|
simId: this.opts.simId,
|
|
47088
47127
|
maxMs: 3e3,
|
|
47089
47128
|
pollMs: 32,
|
|
47090
|
-
stablePolls: 16,
|
|
47091
47129
|
strict: true,
|
|
47092
47130
|
paintStill: true
|
|
47093
47131
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.763 | (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.763 | (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.763 | (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.763 | (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/swift.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.763 | (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.763 | (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.763 | (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;
|