peachsim 0.1.762 → 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 +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 +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 +197 -166
- 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/README.md
CHANGED
|
@@ -509,6 +509,11 @@ peach maestro generate "verify login"
|
|
|
509
509
|
peach maestro --list-compat # see the verb support matrix
|
|
510
510
|
```
|
|
511
511
|
|
|
512
|
+
Tap settling compares consecutive full-screen pixels within Maestro's iOS
|
|
513
|
+
three-second budget, while also draining screen transitions, native motion and
|
|
514
|
+
image loads. Periodic caret paints do not require a continuous stillness window,
|
|
515
|
+
matching [Maestro's screen comparison](https://github.com/mobile-dev-inc/Maestro/blob/main/maestro-ios-xctest-runner/maestro-driver-iosUITests/Routes/Handlers/ScreenDiffHandler.swift).
|
|
516
|
+
|
|
512
517
|
Most Maestro verbs work out of the box (`tapOn`, `assertVisible`, `inputText`,
|
|
513
518
|
`scrollUntilVisible`, `launchApp`, `when:`, `repeat`, `runFlow`, …). Verbs that
|
|
514
519
|
need real device hardware (GPS, radio, photo library) throw a clear error. See
|
|
@@ -2798,9 +2798,9 @@ export class SootSimBridgeFlowRunner {
|
|
|
2798
2798
|
// maestro waits around taps for the screen to stop changing, up to
|
|
2799
2799
|
// its ios driver's 3 s settle budget, comparing screenshots, so an action
|
|
2800
2800
|
// still in flight (a submit spinner, a sheet closing) finishes before the
|
|
2801
|
-
// next command resolves its target.
|
|
2802
|
-
//
|
|
2803
|
-
//
|
|
2801
|
+
// next command resolves its target. compare consecutive screen pixels,
|
|
2802
|
+
// rather than requiring frame publications to stop for half a second:
|
|
2803
|
+
// a focused input keeps repainting its native blinking caret.
|
|
2804
2804
|
// a screen that never stops proceeds when the budget runs out, as there,
|
|
2805
2805
|
// and names what kept it moving: every such step pays the whole budget.
|
|
2806
2806
|
private async waitForAppToSettle() {
|
|
@@ -2809,7 +2809,6 @@ export class SootSimBridgeFlowRunner {
|
|
|
2809
2809
|
simId: this.opts.simId,
|
|
2810
2810
|
maxMs: 3000,
|
|
2811
2811
|
pollMs: 32,
|
|
2812
|
-
stablePolls: 16,
|
|
2813
2812
|
strict: true,
|
|
2814
2813
|
paintStill: true,
|
|
2815
2814
|
})
|
|
@@ -11,14 +11,13 @@ export type WaitForSootsimIdleOptions = {
|
|
|
11
11
|
simId?: string
|
|
12
12
|
maxMs: number
|
|
13
13
|
pollMs?: number
|
|
14
|
-
// stillness must hold for stablePolls * pollMs. it is measured in time, so
|
|
14
|
+
// layout stillness must hold for stablePolls * pollMs. it is measured in time, so
|
|
15
15
|
// a host where each poll costs more than pollMs proves the same stillness
|
|
16
16
|
// in fewer polls instead of paying the count at its slower rate.
|
|
17
17
|
stablePolls?: number
|
|
18
18
|
strict?: boolean
|
|
19
|
-
//
|
|
20
|
-
//
|
|
21
|
-
// layout or registering as a driven animation.
|
|
19
|
+
// compare consecutive full-screen pixels, as maestro's ios driver does.
|
|
20
|
+
// frame publications and caret blinks do not require a continuous window.
|
|
22
21
|
paintStill?: boolean
|
|
23
22
|
}
|
|
24
23
|
|
|
@@ -48,179 +47,211 @@ export async function waitForSootsimIdle({
|
|
|
48
47
|
const start = Date.now()
|
|
49
48
|
const deadline = start + ${Math.max(0, Math.round(maxMs))}
|
|
50
49
|
const pollMs = ${Math.max(1, Math.round(pollMs))}
|
|
51
|
-
const requiredStillMs = ${Math.max(1, Math.round(stablePolls)) * Math.max(1, Math.round(pollMs))}
|
|
52
|
-
const minimumStablePolls = ${Math.min(2, Math.max(1, Math.round(stablePolls)))}
|
|
53
50
|
const strict = ${strict ? 'true' : 'false'}
|
|
54
51
|
const paintStill = ${paintStill ? 'true' : 'false'}
|
|
52
|
+
const requiredStillMs = paintStill ? 0 : ${Math.max(1, Math.round(stablePolls)) * Math.max(1, Math.round(pollMs))}
|
|
53
|
+
const minimumStablePolls = paintStill ? 1 : ${Math.min(2, Math.max(1, Math.round(stablePolls)))}
|
|
55
54
|
const sleep = (ms) => new Promise((resolve) => setTimeout(resolve, ms))
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
//
|
|
61
|
-
//
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
55
|
+
const composite = paintStill ? window.SootSim?.bridges?.liveComposite : null
|
|
56
|
+
if (paintStill && !composite) {
|
|
57
|
+
return { settled: false, elapsed: Date.now() - start, blockedBy: 'screen pixels unavailable' }
|
|
58
|
+
}
|
|
59
|
+
// subscribe to presented frames; authoritative screenshots force a
|
|
60
|
+
// worker render, which changes the very counter we used to inspect.
|
|
61
|
+
const unsubscribe = composite?.subscribe(() => {})
|
|
62
|
+
let pixelFrameToken = -1
|
|
63
|
+
let screenPixels = null
|
|
65
64
|
try {
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
65
|
+
|
|
66
|
+
// route-aware settle: a tap that pushes/pops a screen is async — the
|
|
67
|
+
// old screen still renders for a moment, then the new one mounts and
|
|
68
|
+
// its content loads. a pure layout-hash check reports "idle" on the
|
|
69
|
+
// outgoing screen or on the incoming skeleton, so a driver re-taps
|
|
70
|
+
// and stacks duplicate navigations. drain any in-flight screen
|
|
71
|
+
// transition FIRST, bounded by the overall budget. when no
|
|
72
|
+
// transition is happening this returns in ~80ms (startWindowMs), so
|
|
73
|
+
// a plain button tap barely pays for it.
|
|
74
|
+
try {
|
|
75
|
+
const wfst = window.__sootsimTest?.waitForScreenTransitions
|
|
76
|
+
if (typeof wfst === 'function') {
|
|
77
|
+
const remaining = deadline - Date.now()
|
|
78
|
+
if (remaining > 120) {
|
|
79
|
+
await wfst({
|
|
80
|
+
timeoutMs: Math.min(remaining - 80, 4000),
|
|
81
|
+
settleMs: 64,
|
|
82
|
+
startWindowMs: 80,
|
|
83
|
+
})
|
|
84
|
+
}
|
|
75
85
|
}
|
|
76
|
-
}
|
|
77
|
-
} catch {}
|
|
86
|
+
} catch {}
|
|
78
87
|
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
88
|
+
const readSnapshot = async () => {
|
|
89
|
+
let animating = false
|
|
90
|
+
let layoutDirty = false
|
|
91
|
+
let pendingFetches = 0
|
|
92
|
+
let requestTotal = 0
|
|
93
|
+
let requestInFlight = 0
|
|
94
|
+
let renderStatsAvailable = false
|
|
95
|
+
let shellAnimating = false
|
|
96
|
+
// strict also waits out shell motion: a system alert, sheet or menu
|
|
97
|
+
// animates in the shell worker while the app's own stats read still,
|
|
98
|
+
// so its presentation is complete only once the shell's list empties.
|
|
99
|
+
if (strict) {
|
|
100
|
+
try {
|
|
101
|
+
const motion = await window.__sootsimTest?.listAnimations?.()
|
|
102
|
+
shellAnimating = Array.isArray(motion) && motion.some((anim) => anim.realm === 'shell')
|
|
103
|
+
} catch {}
|
|
104
|
+
}
|
|
92
105
|
try {
|
|
93
|
-
const
|
|
94
|
-
|
|
106
|
+
const stats = await window.__sootsimRenderHost?.queryStats?.()
|
|
107
|
+
if (stats) {
|
|
108
|
+
renderStatsAvailable = true
|
|
109
|
+
animating =
|
|
110
|
+
stats.hasActiveAnims === true ||
|
|
111
|
+
stats.hasActiveNativeAnimations === true ||
|
|
112
|
+
stats.hasPendingAnimationFrames === true
|
|
113
|
+
layoutDirty =
|
|
114
|
+
stats.layoutDirty === true && stats.renderRequested === true
|
|
115
|
+
// a freshly-pushed screen showing a skeleton is layout-stable
|
|
116
|
+
// but not actually settled — its data/images are still in
|
|
117
|
+
// flight. treat bounded image-loader fetches as not-idle so
|
|
118
|
+
// settle waits for real content, capped by the budget.
|
|
119
|
+
const pf = stats.memory && stats.memory.imageLoader
|
|
120
|
+
? stats.memory.imageLoader.pendingFetches
|
|
121
|
+
: 0
|
|
122
|
+
pendingFetches = typeof pf === 'number' ? pf : 0
|
|
123
|
+
}
|
|
95
124
|
} catch {}
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
// settle waits for real content, capped by the budget.
|
|
112
|
-
const pf = stats.memory && stats.memory.imageLoader
|
|
113
|
-
? stats.memory.imageLoader.pendingFetches
|
|
114
|
-
: 0
|
|
115
|
-
pendingFetches = typeof pf === 'number' ? pf : 0
|
|
125
|
+
try {
|
|
126
|
+
const counts = await window.__sootsimTest?.getRequestCounts?.()
|
|
127
|
+
requestTotal = typeof counts?.total === 'number' ? counts.total : 0
|
|
128
|
+
requestInFlight = typeof counts?.inFlight === 'number' ? counts.inFlight : 0
|
|
129
|
+
} catch {}
|
|
130
|
+
const root = window.__sootsimRoot
|
|
131
|
+
const nodes = []
|
|
132
|
+
if (root) {
|
|
133
|
+
const walk = (n) => {
|
|
134
|
+
if (n.layout && n.layout.width > 0) {
|
|
135
|
+
nodes.push(Math.round(n.layout.x) + ',' + Math.round(n.layout.y) + ',' + Math.round(n.layout.width))
|
|
136
|
+
}
|
|
137
|
+
for (const c of n.children || []) walk(c)
|
|
138
|
+
}
|
|
139
|
+
walk(root)
|
|
116
140
|
}
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
if (n.layout && n.layout.width > 0) {
|
|
128
|
-
nodes.push(Math.round(n.layout.x) + ',' + Math.round(n.layout.y) + ',' + Math.round(n.layout.width))
|
|
141
|
+
if (paintStill) {
|
|
142
|
+
const canvas = composite.getCanvas()
|
|
143
|
+
const token = composite.getFrameToken()
|
|
144
|
+
if (!canvas || canvas.width <= 1 || canvas.height <= 1) {
|
|
145
|
+
screenPixels = null
|
|
146
|
+
} else if (token !== pixelFrameToken || canvas.width !== screenPixels?.width || canvas.height !== screenPixels?.height) {
|
|
147
|
+
const context = canvas.getContext('2d')
|
|
148
|
+
const image = context?.getImageData(0, 0, canvas.width, canvas.height)
|
|
149
|
+
screenPixels = image ? { width: image.width, height: image.height, data: new Uint32Array(image.data.buffer) } : null
|
|
150
|
+
pixelFrameToken = token
|
|
129
151
|
}
|
|
130
|
-
for (const c of n.children || []) walk(c)
|
|
131
152
|
}
|
|
132
|
-
|
|
153
|
+
return { layout: nodes.join(';'), screenPixels, animating, shellAnimating, layoutDirty, pendingFetches, renderStatsAvailable, requestTotal, requestInFlight }
|
|
133
154
|
}
|
|
134
|
-
return { layout: nodes.join(';'), frameCount, animating, shellAnimating, layoutDirty, pendingFetches, renderStatsAvailable, requestTotal, requestInFlight }
|
|
135
|
-
}
|
|
136
155
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
if (polls > 1 && snapshot.layout !== lastLayout) layoutChangedPolls++
|
|
167
|
-
const painted = paintStill && snapshot.frameCount !== lastFrameCount
|
|
168
|
-
if (polls > 1 && painted) paintedPolls++
|
|
169
|
-
const strictOk =
|
|
170
|
-
!strict ||
|
|
171
|
-
(snapshot.renderStatsAvailable &&
|
|
172
|
-
!snapshot.animating &&
|
|
173
|
-
!snapshot.shellAnimating &&
|
|
174
|
-
!snapshot.layoutDirty)
|
|
175
|
-
// visually settled: no animations, no image content loading, layout
|
|
176
|
-
// unchanged since the last poll.
|
|
177
|
-
const visuallyStill =
|
|
178
|
-
strictOk &&
|
|
179
|
-
!painted &&
|
|
180
|
-
snapshot.pendingFetches === 0 &&
|
|
181
|
-
snapshot.layout === lastLayout
|
|
182
|
-
// generic network quiet: nothing in flight and no new requests issued.
|
|
183
|
-
const networkQuiet =
|
|
184
|
-
snapshot.requestInFlight === 0 && snapshot.requestTotal === lastRequestTotal
|
|
185
|
-
if (visuallyStill) {
|
|
186
|
-
stable++
|
|
187
|
-
if (visuallyStillSince === 0) visuallyStillSince = Date.now()
|
|
188
|
-
// settle once the screen has held still long enough AND either the
|
|
189
|
-
// network is genuinely quiet OR it has refused to quiet within the
|
|
190
|
-
// grace (continuous background traffic must not block forever).
|
|
191
|
-
if (
|
|
192
|
-
stable >= minimumStablePolls &&
|
|
193
|
-
Date.now() - visuallyStillSince >= requiredStillMs &&
|
|
194
|
-
(networkQuiet || Date.now() - visuallyStillSince >= networkQuietGraceMs)
|
|
195
|
-
) {
|
|
196
|
-
return { settled: true, elapsed: Date.now() - start, blockedBy: '' }
|
|
156
|
+
// how long generic background network is allowed to keep us waiting AFTER
|
|
157
|
+
// the screen is otherwise visually settled. apps with continuous traffic
|
|
158
|
+
// (polling, realtime sockets, a tap that fires 20-50 fetches) never reach
|
|
159
|
+
// requestInFlight===0 / a stable requestTotal, so requiring full network
|
|
160
|
+
// quiet burns the ENTIRE budget on every command — the leading idle that
|
|
161
|
+
// failed PR-preview recordings for network-heavy apps (3pc fight-pulse).
|
|
162
|
+
// layout-stability + the image-loader already prove visible content
|
|
163
|
+
// loaded (a data load changes layout; an image load shows in the loader),
|
|
164
|
+
// so the generic request counters are a courtesy, not a gate: honor them
|
|
165
|
+
// only within this grace once the screen is visually still.
|
|
166
|
+
const networkQuietGraceMs = 1200
|
|
167
|
+
let lastLayout = ''
|
|
168
|
+
let lastScreenPixels = null
|
|
169
|
+
let screenChangedPolls = 0
|
|
170
|
+
let lastRequestTotal = -1
|
|
171
|
+
let stable = 0
|
|
172
|
+
let visuallyStillSince = 0
|
|
173
|
+
// counts across the whole budget: a flag that is true on every poll is a
|
|
174
|
+
// different bug from one that is true intermittently, and the two need
|
|
175
|
+
// opposite fixes (engine vs budget).
|
|
176
|
+
let polls = 0
|
|
177
|
+
let dirtyPolls = 0
|
|
178
|
+
let animatingPolls = 0
|
|
179
|
+
let layoutChangedPolls = 0
|
|
180
|
+
const screenUnchanged = (pixels) => {
|
|
181
|
+
if (!pixels || !lastScreenPixels || pixels.width !== lastScreenPixels.width || pixels.height !== lastScreenPixels.height) return false
|
|
182
|
+
if (pixels === lastScreenPixels) return true
|
|
183
|
+
for (let i = 0; i < pixels.data.length; i++) {
|
|
184
|
+
if (pixels.data[i] !== lastScreenPixels.data[i]) return false
|
|
197
185
|
}
|
|
198
|
-
|
|
199
|
-
stable = 0
|
|
200
|
-
visuallyStillSince = 0
|
|
186
|
+
return true
|
|
201
187
|
}
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
188
|
+
while (Date.now() < deadline) {
|
|
189
|
+
const snapshot = await readSnapshot()
|
|
190
|
+
polls++
|
|
191
|
+
if (snapshot.layoutDirty) dirtyPolls++
|
|
192
|
+
if (snapshot.animating || snapshot.shellAnimating) animatingPolls++
|
|
193
|
+
if (polls > 1 && snapshot.layout !== lastLayout) layoutChangedPolls++
|
|
194
|
+
const screenChanged = paintStill && !screenUnchanged(snapshot.screenPixels)
|
|
195
|
+
if (polls > 1 && screenChanged) screenChangedPolls++
|
|
196
|
+
const strictOk =
|
|
197
|
+
!strict ||
|
|
198
|
+
(snapshot.renderStatsAvailable &&
|
|
199
|
+
!snapshot.animating &&
|
|
200
|
+
!snapshot.shellAnimating &&
|
|
201
|
+
!snapshot.layoutDirty)
|
|
202
|
+
// visually settled: no animations, no image content loading, layout
|
|
203
|
+
// unchanged since the last poll.
|
|
204
|
+
const visuallyStill =
|
|
205
|
+
strictOk &&
|
|
206
|
+
!screenChanged &&
|
|
207
|
+
snapshot.pendingFetches === 0 &&
|
|
208
|
+
snapshot.layout === lastLayout
|
|
209
|
+
// generic network quiet: nothing in flight and no new requests issued.
|
|
210
|
+
const networkQuiet =
|
|
211
|
+
snapshot.requestInFlight === 0 && snapshot.requestTotal === lastRequestTotal
|
|
212
|
+
if (visuallyStill) {
|
|
213
|
+
stable++
|
|
214
|
+
if (visuallyStillSince === 0) visuallyStillSince = Date.now()
|
|
215
|
+
// settle once the screen has held still long enough AND either the
|
|
216
|
+
// network is genuinely quiet OR it has refused to quiet within the
|
|
217
|
+
// grace (continuous background traffic must not block forever).
|
|
218
|
+
if (
|
|
219
|
+
stable >= minimumStablePolls &&
|
|
220
|
+
Date.now() - visuallyStillSince >= requiredStillMs &&
|
|
221
|
+
(networkQuiet || Date.now() - visuallyStillSince >= networkQuietGraceMs)
|
|
222
|
+
) {
|
|
223
|
+
return { settled: true, elapsed: Date.now() - start, blockedBy: '' }
|
|
224
|
+
}
|
|
225
|
+
} else {
|
|
226
|
+
stable = 0
|
|
227
|
+
visuallyStillSince = 0
|
|
228
|
+
}
|
|
229
|
+
lastLayout = snapshot.layout
|
|
230
|
+
lastScreenPixels = snapshot.screenPixels
|
|
231
|
+
lastRequestTotal = snapshot.requestTotal
|
|
232
|
+
await sleep(pollMs)
|
|
233
|
+
}
|
|
234
|
+
const last = await readSnapshot()
|
|
235
|
+
const blockers = []
|
|
236
|
+
if (strict && !last.renderStatsAvailable) blockers.push('render stats unavailable')
|
|
237
|
+
if (last.animating) blockers.push('animations still running')
|
|
238
|
+
if (last.shellAnimating) blockers.push('shell animations still running')
|
|
239
|
+
if (last.layoutDirty) blockers.push('layout still dirty')
|
|
240
|
+
if (last.pendingFetches > 0) blockers.push(last.pendingFetches + ' image fetches pending')
|
|
241
|
+
if (last.layout !== lastLayout) blockers.push('layout still changing')
|
|
242
|
+
if (paintStill && !last.screenPixels) blockers.push('screen pixels unavailable')
|
|
243
|
+
else if (paintStill && !screenUnchanged(last.screenPixels)) blockers.push('screen pixels still changing')
|
|
244
|
+
if (last.requestInFlight > 0) blockers.push(last.requestInFlight + ' requests in flight')
|
|
245
|
+
return {
|
|
246
|
+
settled: false,
|
|
247
|
+
elapsed: Date.now() - start,
|
|
248
|
+
blockedBy:
|
|
249
|
+
(blockers.length ? blockers.join(', ') : 'unknown') +
|
|
250
|
+
' over ' + polls + ' polls (layout changed ' + layoutChangedPolls +
|
|
251
|
+
'x, layoutDirty ' + dirtyPolls + 'x, animating ' + animatingPolls + 'x, screen changed ' + screenChangedPolls + 'x)',
|
|
252
|
+
}
|
|
253
|
+
} finally {
|
|
254
|
+
unsubscribe?.()
|
|
224
255
|
}
|
|
225
256
|
})()`,
|
|
226
257
|
},
|
|
@@ -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;
|
|
@@ -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 __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;
|
package/dist-lib/beta.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/beta.mjs
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;
|
|
@@ -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 __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 __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;
|
package/dist-lib/cloud.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/cloud.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! rnx v0.1.
|
|
1
|
+
/*! rnx v0.1.763 | (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);
|
package/dist-lib/config.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/detox/index.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;
|
|
@@ -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;
|