peachsim 0.1.1716 → 0.1.1728
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 +21 -3
- package/cli/app-bundle-resources.ts +2 -1
- package/cli/app-fonts.ts +4 -4
- package/cli/app-splash.ts +4 -4
- package/cli/app-stubs.ts +17 -0
- package/cli/command-registry.ts +1 -0
- package/cli/commands/control.ts +82 -822
- package/cli/commands/daemon.ts +8 -0
- package/cli/commands/detox.ts +3 -0
- package/cli/commands/doctor.ts +19 -2
- package/cli/commands/inspect/actions.ts +74 -14
- package/cli/commands/inspect/core.ts +5 -1
- package/cli/commands/inspect/settling.ts +5 -2
- package/cli/commands/inspect/wait-ready.ts +6 -0
- package/cli/commands/inspect.ts +48 -45
- package/cli/commands/kotlin.ts +12 -2
- package/cli/commands/package.ts +750 -0
- package/cli/commands/serve.ts +6 -0
- package/cli/commands/shell-url.ts +834 -0
- package/cli/commands/swift.ts +42 -102
- package/cli/commands/test.ts +20 -0
- package/cli/commands/upload.ts +1 -1
- package/cli/device-option.ts +1 -1
- package/cli/main.ts +13 -1
- package/cli/native-input.ts +199 -0
- package/cli/outbound-endpoints.ts +26 -1
- package/cli/packaged-app-launcher.ts +95 -0
- package/cli/scene-video.ts +13 -6
- package/detox/index.ts +187 -23
- package/dist-lib/agent-daemon-client.cjs +1 -1
- package/dist-lib/agent-events.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/bundle-channel.cjs +38000 -31658
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +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/config.mjs +1 -1
- package/dist-lib/detox/index.cjs +184 -60
- package/dist-lib/dev-bundle-resolution.cjs +14 -13
- package/dist-lib/expo-swift-bundle.cjs +18199 -11834
- package/dist-lib/expo-swift-metadata.cjs +4 -1
- package/dist-lib/expo-swift-metadata.mjs +3 -1
- package/dist-lib/home-paths.cjs +21 -2
- package/dist-lib/host/bridge-host.cjs +26509 -23850
- package/dist-lib/host/fetch-proxy-handler.cjs +221 -222
- 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 +876 -389
- 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 +127 -16
- package/dist-lib/menu.cjs +7 -1
- package/dist-lib/menu.mjs +7 -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 +883 -404
- package/dist-lib/native-app-identity-project.cjs +694 -280
- package/dist-lib/native-app-identity-project.mjs +490 -83
- package/dist-lib/native-app-identity.cjs +13 -2
- package/dist-lib/native-app-identity.mjs +13 -2
- 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/public-origins-lib-esm.json +28 -23
- package/dist-lib/public-origins-lib.json +392 -224
- package/dist-lib/react-native-host-modules.cjs +32 -2
- package/dist-lib/react-native-host-modules.mjs +32 -2
- package/dist-lib/reap-browser.cjs +12 -4
- package/dist-lib/scripts/dev-server-scanner.cjs +15 -8
- package/dist-lib/sdk.cjs +17 -7
- package/dist-lib/sdk.mjs +16 -7
- package/dist-lib/skills.cjs +61838 -47851
- package/dist-lib/swift-compile.cjs +583 -360
- package/dist-lib/swift-compile.mjs +496 -275
- package/dist-lib/swift-package.cjs +1 -1
- package/dist-lib/swift-package.mjs +1 -1
- package/dist-lib/swift-submit.cjs +2 -2
- package/dist-lib/swift-submit.mjs +2 -2
- package/dist-lib/swift-toolchain.cjs +105 -17
- package/dist-lib/swift.cjs +1 -1
- package/dist-lib/vite-swift.cjs +4453 -2231
- package/dist-lib/vite.cjs +230 -228
- package/dist-lib/worklet-executable.cjs +1 -1
- package/dist-lib/worklet-executable.mjs +1 -1
- package/dist-types/packages/peach-compat/src/stubs/native-seams/react-native-cookies.d.ts +17 -8
- package/dist-types/packages/peach-engine/src/engine/canvaskit-renderer.d.ts +1 -0
- package/dist-types/packages/peach-engine/src/engine/image-loader.d.ts +7 -5
- package/dist-types/packages/peach-engine/src/engine/memory-counts.d.ts +3 -1
- package/dist-types/packages/peach-engine/src/engine/node.d.ts +1 -11
- package/dist-types/packages/peach-engine/src/engine/types.d.ts +3 -0
- package/dist-types/packages/peach-engine/src/render-worker/compositor-protocol.d.ts +9 -0
- package/dist-types/packages/peach-engine/src/render-worker/host-service-protocol.d.ts +3 -0
- package/dist-types/packages/peach-engine/src/render-worker/native-ui-commandContract.d.ts +1 -1
- package/dist-types/packages/peach-engine/src/render-worker/shell-protocol.d.ts +4 -0
- package/dist-types/packages/peach-engine/src/render-worker/tree-sync-port.d.ts +1 -1
- package/dist-types/packages/peach-engine/src/render-worker/worklet-runtime.d.ts +23 -1
- package/dist-types/packages/peach-engine/src/shell-events.d.ts +1 -0
- package/dist-types/packages/peach-globals/src/audioBridgeContract.d.ts +5 -0
- package/dist-types/packages/peach-globals/src/index.d.ts +1 -1
- package/dist-types/packages/peach-globals/src/keyboardBridgeContract.d.ts +11 -0
- package/dist-types/packages/peach-globals/src/shellBridgeContract.d.ts +1 -0
- package/dist-types/packages/peach-globals/src/testBridgeContract.d.ts +9 -2
- package/package.json +1 -1
- package/runtime-companion.json +1 -1
- package/scripts/dev-server-scanner.ts +12 -25
- package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Headers/ASFoundation.h +52 -0
- package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Headers/ASWebAuthenticationSession.h +128 -0
- package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Headers/ASWebAuthenticationSessionCallback.h +35 -0
- package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Headers/AuthenticationServices.h +3 -0
- package/sdk/ios/System/Library/Frameworks/AuthenticationServices.framework/Modules/module.modulemap +5 -0
- package/sdk/ios/System/Library/Frameworks/CFNetwork.framework/Headers/CFHTTPMessage.h +724 -0
- package/sdk/ios/System/Library/Frameworks/CFNetwork.framework/Headers/CFNetwork.h +4 -0
- package/sdk/ios/System/Library/Frameworks/CFNetwork.framework/Headers/CFNetworkDefs.h +27 -0
- package/sdk/ios/System/Library/Frameworks/CFNetwork.framework/Modules/module.modulemap +5 -0
- package/sdk/ios/System/Library/Frameworks/CoreFoundation.framework/Headers/CFURL.h +1301 -0
- package/sdk/ios/System/Library/Frameworks/CoreGraphics.framework/Headers/CoreGraphics.h +2 -0
- package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLLocationManager.h +21 -50
- package/sdk/ios/System/Library/Frameworks/CoreLocation.framework/Headers/CLRegion.h +6 -6
- package/sdk/ios/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h +75 -9
- package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIApplication.h +12 -0
- package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIInterface.h +23 -0
- package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIKit.h +7 -9
- package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIOrientation.h +14 -0
- package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIStringDrawing.h +12 -0
- package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIView.h +14 -0
- package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIViewAnimating.h +12 -0
- package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIViewController.h +16 -0
- package/sdk/ios/System/Library/Frameworks/UIKit.framework/Headers/UIWindow.h +2 -0
- package/sdk/ios/usr/include/ConditionalMacros.h +619 -0
- package/sdk/ios/usr/include/module.modulemap +1 -0
- package/sdk/ios/usr/include/objc/objc-sync.h +59 -0
- package/sdk/ios/usr/include/os.modulemap +5 -0
- package/sdk/ios/usr/include/sys/cdefs.h +5 -0
- package/sdk/ios/usr/include/sys/ioccom.h +99 -0
- package/sdk/ios/usr/include/sys/syslog.h +236 -0
- package/sdk/ios/usr/include/syslog.h +24 -0
- package/sdk/ios/wasm/include/fcntl.h +4 -2
- package/sdk/ios/wasm/include/stdio.h +24 -0
- package/sdk/ios/wasm/include/stdlib.h +32 -7
- package/sdk/ios/wasm/include/sys/file.h +7 -0
- package/sdk/ios/wasm/include/sys/ioctl.h +6 -0
- package/sdk/ios/wasm/include/sys/syscall.h +9 -0
- package/sdk/ios/wasm/include/sys/time.h +10 -0
- package/sdk/ios/wasm/include/unistd.h +12 -3
- package/sdk/native-hashes.json +1 -0
- package/skills/contrast/SKILL.md +2 -1
- package/skills/peach-test/SKILL.md +7 -3
- package/src/admitted-mac-build.ts +3 -0
- package/src/android-app-identity.ts +18 -0
- package/src/android-root-module.ts +9 -9
- package/src/appPackageContract.ts +81 -0
- package/src/bridge-contract.ts +50 -0
- package/src/bundle-channel.mjs +21 -4
- package/src/dev-bundle-resolution.ts +7 -27
- package/src/dom-source-reference.ts +15 -0
- package/src/expo-discovery-cache.ts +127 -23
- package/src/expo-manifest-body.ts +33 -0
- package/src/expo-native-workspace.ts +38 -13
- package/src/expo-swift-host.ts +264 -62
- package/src/expoSwiftContract.ts +3 -0
- package/src/generated/swift-c-predefines.json +1 -1
- package/src/home-paths.ts +35 -1
- package/src/host/app-package-handler.ts +47 -0
- package/src/host/bridge-host.ts +3 -0
- package/src/host/staged-host-files.ts +18 -0
- package/src/index.ts +3 -0
- package/src/kotlin-host.ts +21 -18
- package/src/kotlin-instance-source.ts +126 -0
- package/src/menu.ts +7 -0
- package/src/native-app-identity-project.ts +7 -2
- package/src/native-app-identity.ts +11 -0
- package/src/native-firebase-config.ts +24 -1
- package/src/nitro-adapter.lock.json +268 -268
- package/src/nitro-bundle.ts +8 -0
- package/src/nitro-compile.ts +35 -9
- package/src/nitro-dependencies.ts +21 -19
- package/src/nitro-source.ts +4 -0
- package/src/nitroContract.ts +7 -0
- package/src/react-native-bridge-modules.ts +68 -42
- package/src/react-native-host-modules.ts +31 -1
- package/src/reactNativeConfigurationContract.ts +14 -0
- package/src/reap-browser.ts +15 -3
- package/src/sdk.ts +5 -0
- package/src/settingsContract.ts +27 -1
- package/src/sim-client.ts +4 -1
- package/src/storageSnapshotContract.ts +3 -0
- package/src/swift-compile.ts +221 -41
- package/src/swift-coverage/provenance.ts +1 -0
- package/src/swift-coverage/xcode-asset-symbols.ts +922 -0
- package/src/swift-coverage/xcode-assets.ts +89 -131
- package/src/swift-coverage/xcode.ts +1 -1
- package/src/swift-cxx-reachable.ts +2 -1
- package/src/swift-distribution.lock.json +14 -13
- package/src/swift-host.ts +95 -22
- package/src/swift-icu.ts +1 -1
- package/src/swift-link-roots.ts +118 -0
- package/src/swift-objc-compile.ts +144 -22
- package/src/swift-objc-import.ts +6 -0
- package/src/swift-objc-standin.ts +2 -14
- package/src/swift-package-manifest.ts +14 -6
- package/src/swift-packages.ts +75 -11
- package/src/swift-pdf-raster.ts +1 -0
- package/src/swift-root-lock.ts +17 -1
- package/src/swift-source-pods.ts +2 -10
- package/src/swift-standin-emit.ts +592 -57
- package/src/swift-standins.ts +430 -49
- package/src/swift-submit.ts +3 -1
- package/src/swift-toolchain.ts +140 -17
- package/src/turbo-codegen-intake.ts +91 -0
- package/src/vite-plugin-one.ts +13 -9
- package/src/vite-plugin.ts +28 -15
- package/src/xcode-project.ts +223 -22
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1728 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1728 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1728 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/cloud.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1728 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/cloud.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1728 | (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
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1728 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __defProp = Object.defineProperty;
|
package/dist-lib/config.mjs
CHANGED
package/dist-lib/detox/index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1728 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -1883,8 +1883,11 @@ async function waitForSootsimIdle({
|
|
|
1883
1883
|
}
|
|
1884
1884
|
const counts = await countsRead
|
|
1885
1885
|
if (counts === BUSY) workerBusy = true
|
|
1886
|
-
|
|
1887
|
-
|
|
1886
|
+
// <Image> loads are left to the image loader, which counts only those
|
|
1887
|
+
// that can reach the window. a runtime older than the CLI reports none.
|
|
1888
|
+
const imageLoads = counts?.imageLoads ?? { total: 0, inFlight: 0 }
|
|
1889
|
+
requestTotal = typeof counts?.total === 'number' ? counts.total - imageLoads.total : 0
|
|
1890
|
+
requestInFlight = typeof counts?.inFlight === 'number' ? counts.inFlight - imageLoads.inFlight : 0
|
|
1888
1891
|
const total = await nodeCountRead
|
|
1889
1892
|
if (total === BUSY) workerBusy = true
|
|
1890
1893
|
nodeCount = typeof total === 'number' ? total : null
|
|
@@ -2355,7 +2358,7 @@ var import_node_module = require("node:module");
|
|
|
2355
2358
|
var import_node_path2 = require("node:path");
|
|
2356
2359
|
|
|
2357
2360
|
// runtime-companion.json
|
|
2358
|
-
var runtime_companion_default = { abi: 1, sha256: "
|
|
2361
|
+
var runtime_companion_default = { abi: 1, sha256: "aca3aa069c8104a207ce2d98944ba1ed096878d12c25e9e9d44c3df0e2a63323", file: "node/cli-aca3aa069c8104a207ce2d98944ba1ed096878d12c25e9e9d44c3df0e2a63323.cjs" };
|
|
2359
2362
|
|
|
2360
2363
|
// src/runtime-assets.ts
|
|
2361
2364
|
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
@@ -5665,7 +5668,7 @@ function createBridge(wsPort, opts = {}) {
|
|
|
5665
5668
|
const identity = getCliIdentity();
|
|
5666
5669
|
const ownerPid = getStableOwnerPid();
|
|
5667
5670
|
let terminalError;
|
|
5668
|
-
const ready = new Promise((
|
|
5671
|
+
const ready = new Promise((resolve3, reject) => {
|
|
5669
5672
|
const handshakeTimer = setTimeout(() => {
|
|
5670
5673
|
reject(
|
|
5671
5674
|
new Error(
|
|
@@ -5694,7 +5697,7 @@ function createBridge(wsPort, opts = {}) {
|
|
|
5694
5697
|
);
|
|
5695
5698
|
} catch {
|
|
5696
5699
|
}
|
|
5697
|
-
|
|
5700
|
+
resolve3();
|
|
5698
5701
|
});
|
|
5699
5702
|
ws.on("close", (code, reason) => {
|
|
5700
5703
|
clearTimeout(handshakeTimer);
|
|
@@ -5789,7 +5792,7 @@ function createBridge(wsPort, opts = {}) {
|
|
|
5789
5792
|
await ready;
|
|
5790
5793
|
if (terminalError) throw terminalError;
|
|
5791
5794
|
const id = nextId++;
|
|
5792
|
-
return new Promise((
|
|
5795
|
+
return new Promise((resolve3, reject) => {
|
|
5793
5796
|
const payload = { ...cmdOverride ?? cmd, id };
|
|
5794
5797
|
if (payload.simId === void 0 && defaultSimId) {
|
|
5795
5798
|
payload.simId = defaultSimId;
|
|
@@ -5805,7 +5808,7 @@ function createBridge(wsPort, opts = {}) {
|
|
|
5805
5808
|
pending.set(id, {
|
|
5806
5809
|
resolve: (v) => {
|
|
5807
5810
|
clearTimeoutFn();
|
|
5808
|
-
|
|
5811
|
+
resolve3(v);
|
|
5809
5812
|
},
|
|
5810
5813
|
reject: (e) => {
|
|
5811
5814
|
clearTimeoutFn();
|
|
@@ -6014,8 +6017,8 @@ async function pollUntil(read, ready, options) {
|
|
|
6014
6017
|
let intervalTimer;
|
|
6015
6018
|
try {
|
|
6016
6019
|
await Promise.race([
|
|
6017
|
-
new Promise((
|
|
6018
|
-
intervalTimer = setTimeout(
|
|
6020
|
+
new Promise((resolve3) => {
|
|
6021
|
+
intervalTimer = setTimeout(resolve3, Math.min(intervalMs, remaining));
|
|
6019
6022
|
}),
|
|
6020
6023
|
boundary
|
|
6021
6024
|
]);
|
|
@@ -6145,7 +6148,7 @@ async function acquireChromiumAdmission(deps) {
|
|
|
6145
6148
|
);
|
|
6146
6149
|
waited = true;
|
|
6147
6150
|
}
|
|
6148
|
-
await new Promise((
|
|
6151
|
+
await new Promise((resolve3, reject) => {
|
|
6149
6152
|
const abort = () => {
|
|
6150
6153
|
clearTimeout(timer);
|
|
6151
6154
|
signal?.removeEventListener("abort", abort);
|
|
@@ -6157,7 +6160,7 @@ async function acquireChromiumAdmission(deps) {
|
|
|
6157
6160
|
};
|
|
6158
6161
|
const timer = setTimeout(() => {
|
|
6159
6162
|
signal?.removeEventListener("abort", abort);
|
|
6160
|
-
|
|
6163
|
+
resolve3();
|
|
6161
6164
|
}, 500);
|
|
6162
6165
|
signal?.addEventListener("abort", abort, { once: true });
|
|
6163
6166
|
if (signal?.aborted) abort();
|
|
@@ -6746,8 +6749,11 @@ async function launchWithPauseAwareDeadline(launch, opts) {
|
|
|
6746
6749
|
function platformChromeLaunch(launch, opts, rendererTarget, policy = {}) {
|
|
6747
6750
|
return async () => {
|
|
6748
6751
|
const runtime = policy.runtime ?? currentRuntime();
|
|
6749
|
-
if (softwareChromeAllowed(runtime)) {
|
|
6750
|
-
return launchWithPauseAwareDeadline(
|
|
6752
|
+
if (policy.software ?? softwareChromeAllowed(runtime)) {
|
|
6753
|
+
return launchWithPauseAwareDeadline(
|
|
6754
|
+
launch,
|
|
6755
|
+
softwareChromeLaunchOptions(opts, runtime)
|
|
6756
|
+
);
|
|
6751
6757
|
}
|
|
6752
6758
|
const gpuOptions = chromeLaunchOptions(opts, runtime);
|
|
6753
6759
|
let browser;
|
|
@@ -6842,7 +6848,12 @@ function softwareChromeLaunchOptions(opts, runtime = currentRuntime()) {
|
|
|
6842
6848
|
}
|
|
6843
6849
|
function chromeLaunchOptions(opts = {}, runtime = currentRuntime()) {
|
|
6844
6850
|
if (signalShutdownClaimed) {
|
|
6845
|
-
opts = {
|
|
6851
|
+
opts = {
|
|
6852
|
+
...opts,
|
|
6853
|
+
handleSIGINT: false,
|
|
6854
|
+
handleSIGTERM: false,
|
|
6855
|
+
handleSIGHUP: false
|
|
6856
|
+
};
|
|
6846
6857
|
}
|
|
6847
6858
|
return softwareChromeAllowed(runtime) ? softwareChromeLaunchOptions(opts, runtime) : gpuChromeLaunchOptions(opts, runtime);
|
|
6848
6859
|
}
|
|
@@ -7112,7 +7123,7 @@ async function dragScrollNode(page, node, pixels, direction, startPositionX, sta
|
|
|
7112
7123
|
if (!canvas) throw new Error("peach interactive canvas not found");
|
|
7113
7124
|
const axisDelta = endPage2.x !== startPage2.x ? endPage2.x - startPage2.x : endPage2.y - startPage2.y;
|
|
7114
7125
|
const sign = Math.sign(axisDelta);
|
|
7115
|
-
const nextFrame = () => new Promise((
|
|
7126
|
+
const nextFrame = () => new Promise((resolve3) => requestAnimationFrame(() => resolve3()));
|
|
7116
7127
|
const fire = (type, point) => {
|
|
7117
7128
|
const progress = (point - startAxis2) / (sign * travel2);
|
|
7118
7129
|
canvas.dispatchEvent(
|
|
@@ -7165,10 +7176,10 @@ async function dragScrollNode(page, node, pixels, direction, startPositionX, sta
|
|
|
7165
7176
|
await nextFrame();
|
|
7166
7177
|
fire("pointermove", point2);
|
|
7167
7178
|
}
|
|
7168
|
-
await new Promise((
|
|
7179
|
+
await new Promise((resolve3) => setTimeout(resolve3, 300));
|
|
7169
7180
|
await nextFrame();
|
|
7170
7181
|
fire("pointerup", offsets[offsets.length - 1]);
|
|
7171
|
-
await new Promise((
|
|
7182
|
+
await new Promise((resolve3) => setTimeout(resolve3, 750));
|
|
7172
7183
|
remaining = strokeRemaining;
|
|
7173
7184
|
}
|
|
7174
7185
|
},
|
|
@@ -7998,10 +8009,10 @@ var SootSimWaitForAction = class {
|
|
|
7998
8009
|
throw lastError || new Error(`waitFor timed out after ${ms}ms`);
|
|
7999
8010
|
}
|
|
8000
8011
|
// if no withTimeout is called, just run the assertion once
|
|
8001
|
-
async then(
|
|
8012
|
+
async then(resolve3, reject) {
|
|
8002
8013
|
try {
|
|
8003
8014
|
await this.withTimeout(5e3);
|
|
8004
|
-
|
|
8015
|
+
resolve3(void 0);
|
|
8005
8016
|
} catch (e) {
|
|
8006
8017
|
reject(e);
|
|
8007
8018
|
}
|
|
@@ -8386,7 +8397,7 @@ async function waitForSootsimShellReady(page, timeout = 3e4) {
|
|
|
8386
8397
|
await page.evaluate(
|
|
8387
8398
|
async ({ timeoutMs, expectsInitialAppPaint: expectsInitialAppPaint2 }) => {
|
|
8388
8399
|
let deadline = Date.now() + timeoutMs;
|
|
8389
|
-
const sleep = (ms) => new Promise((
|
|
8400
|
+
const sleep = (ms) => new Promise((resolve3) => setTimeout(resolve3, ms));
|
|
8390
8401
|
const remaining = () => Math.max(1, deadline - Date.now());
|
|
8391
8402
|
const withTimeout = async (label, promise) => {
|
|
8392
8403
|
let timer = null;
|
|
@@ -8472,7 +8483,7 @@ async function waitForSootsimWorkletsIdle(page, timeout = 3e3) {
|
|
|
8472
8483
|
if (typeof getPeerStats !== "function") {
|
|
8473
8484
|
return { settled: true, skipped: true };
|
|
8474
8485
|
}
|
|
8475
|
-
const sleep = (ms) => new Promise((
|
|
8486
|
+
const sleep = (ms) => new Promise((resolve3) => setTimeout(resolve3, ms));
|
|
8476
8487
|
const start = Date.now();
|
|
8477
8488
|
const deadline = start + timeout2;
|
|
8478
8489
|
const requiredStableMs = 120;
|
|
@@ -8493,11 +8504,11 @@ async function waitForSootsimWorkletsIdle(page, timeout = 3e3) {
|
|
|
8493
8504
|
peerProgress = peerRead && "peachPeerProgress" in peerRead ? peerRead.peachPeerProgress ?? null : null;
|
|
8494
8505
|
const stats = await Promise.race([
|
|
8495
8506
|
peerRead,
|
|
8496
|
-
new Promise((
|
|
8507
|
+
new Promise((resolve3) => {
|
|
8497
8508
|
timer = setTimeout(
|
|
8498
8509
|
() => {
|
|
8499
8510
|
deadlineTimerLateMs = Date.now() - deadline;
|
|
8500
|
-
|
|
8511
|
+
resolve3(void 0);
|
|
8501
8512
|
},
|
|
8502
8513
|
Math.max(0, deadline - Date.now())
|
|
8503
8514
|
);
|
|
@@ -8605,8 +8616,8 @@ async function quiesceContextMedia(context) {
|
|
|
8605
8616
|
})
|
|
8606
8617
|
)
|
|
8607
8618
|
),
|
|
8608
|
-
new Promise((
|
|
8609
|
-
timer = setTimeout(
|
|
8619
|
+
new Promise((resolve3) => {
|
|
8620
|
+
timer = setTimeout(resolve3, CONTEXT_MEDIA_QUIESCE_TIMEOUT_MS);
|
|
8610
8621
|
})
|
|
8611
8622
|
]).catch(() => {
|
|
8612
8623
|
});
|
|
@@ -8718,7 +8729,9 @@ async function queryMatcherInPage({
|
|
|
8718
8729
|
let hadNumericLayout = false;
|
|
8719
8730
|
let disappearedMidWait = false;
|
|
8720
8731
|
while (Date.now() - startedAt < maxWaitMs) {
|
|
8721
|
-
const observation = await window.__sootsimTest.observeTapTarget(indexedMatcher
|
|
8732
|
+
const observation = await window.__sootsimTest.observeTapTarget(indexedMatcher, {
|
|
8733
|
+
includeUnreachable: true
|
|
8734
|
+
});
|
|
8722
8735
|
const node = observation;
|
|
8723
8736
|
if (!node) {
|
|
8724
8737
|
if (hadNumericLayout) disappearedMidWait = true;
|
|
@@ -8753,16 +8766,16 @@ async function queryMatcherInPage({
|
|
|
8753
8766
|
}
|
|
8754
8767
|
}
|
|
8755
8768
|
const frameStarted = performance.now();
|
|
8756
|
-
await new Promise((
|
|
8757
|
-
const timeoutId = setTimeout(
|
|
8769
|
+
await new Promise((resolve3) => {
|
|
8770
|
+
const timeoutId = setTimeout(resolve3, 50);
|
|
8758
8771
|
requestAnimationFrame(() => {
|
|
8759
8772
|
clearTimeout(timeoutId);
|
|
8760
|
-
|
|
8773
|
+
resolve3();
|
|
8761
8774
|
});
|
|
8762
8775
|
});
|
|
8763
8776
|
const remaining = 25 - (performance.now() - frameStarted);
|
|
8764
8777
|
if (remaining > 0)
|
|
8765
|
-
await new Promise((
|
|
8778
|
+
await new Promise((resolve3) => setTimeout(resolve3, remaining));
|
|
8766
8779
|
}
|
|
8767
8780
|
const elapsed = Date.now() - startedAt;
|
|
8768
8781
|
const target = JSON.stringify(indexedMatcher);
|
|
@@ -8814,7 +8827,9 @@ async function dispatchTapAtSootsimPoint(page, point, token) {
|
|
|
8814
8827
|
let x;
|
|
8815
8828
|
let y;
|
|
8816
8829
|
if ("nodeId" in point2) {
|
|
8817
|
-
const resolved = await window.__sootsimTest.resolveTapTarget(point2.nodeId
|
|
8830
|
+
const resolved = await window.__sootsimTest.resolveTapTarget(point2.nodeId, {
|
|
8831
|
+
includeUnreachable: true
|
|
8832
|
+
});
|
|
8818
8833
|
if (!resolved) throw new Error(`element disappeared before tap: ${point2.nodeId}`);
|
|
8819
8834
|
const node = resolved.match;
|
|
8820
8835
|
if (point2.offset) {
|
|
@@ -9271,8 +9286,8 @@ function createSootSimElement(matcher) {
|
|
|
9271
9286
|
);
|
|
9272
9287
|
}
|
|
9273
9288
|
await page.evaluate(
|
|
9274
|
-
() => new Promise((
|
|
9275
|
-
requestAnimationFrame(() =>
|
|
9289
|
+
() => new Promise((resolve3) => {
|
|
9290
|
+
requestAnimationFrame(() => resolve3());
|
|
9276
9291
|
})
|
|
9277
9292
|
);
|
|
9278
9293
|
if (_synchronizationEnabled) {
|
|
@@ -9377,7 +9392,7 @@ function createSootSimElement(matcher) {
|
|
|
9377
9392
|
}
|
|
9378
9393
|
const target = candidates[0];
|
|
9379
9394
|
const tapTarget = await page.evaluate(
|
|
9380
|
-
async (nodeId) => window.__sootsimTest?.resolveTapTarget(nodeId),
|
|
9395
|
+
async (nodeId) => window.__sootsimTest?.resolveTapTarget(nodeId, { includeUnreachable: true }),
|
|
9381
9396
|
target.nodeId
|
|
9382
9397
|
);
|
|
9383
9398
|
if (!tapTarget) {
|
|
@@ -9568,6 +9583,31 @@ async function postRemotePushToSimulator(params, launch) {
|
|
|
9568
9583
|
await postPreparedRemotePush(detoxNotificationToApnsPayload(params), launch);
|
|
9569
9584
|
}
|
|
9570
9585
|
var ONSET_STEP_MS = 1e3 / 240;
|
|
9586
|
+
var PHASE_SEARCH_MS = 1e3 / 30;
|
|
9587
|
+
function storedNativeProgressFrames(namePrefix, label) {
|
|
9588
|
+
const nativeTarget = `${DETOX_PLATFORM}${(process.env.APPEARANCE_REPORTED || process.env.APPEARANCE) === "dark" ? "-dark" : ""}`;
|
|
9589
|
+
const targetDir = path6.resolve(
|
|
9590
|
+
process.cwd(),
|
|
9591
|
+
process.env.CONFORMANCE_PROOF_DIR || "artifacts/conformance-proof/latest",
|
|
9592
|
+
nativeTarget
|
|
9593
|
+
);
|
|
9594
|
+
if (!fs4.existsSync(targetDir)) return null;
|
|
9595
|
+
for (const caseName of fs4.readdirSync(targetDir)) {
|
|
9596
|
+
if (!namePrefix.startsWith(`${caseName}-`)) continue;
|
|
9597
|
+
const checkpointDir = path6.join(
|
|
9598
|
+
targetDir,
|
|
9599
|
+
caseName,
|
|
9600
|
+
namePrefix.slice(caseName.length + 1)
|
|
9601
|
+
);
|
|
9602
|
+
if (!fs4.existsSync(path6.join(checkpointDir, `${label}.png`))) return null;
|
|
9603
|
+
return {
|
|
9604
|
+
baselinePng: fs4.readFileSync(path6.join(checkpointDir, "pre-trigger.png")).toString("base64"),
|
|
9605
|
+
png: fs4.readFileSync(path6.join(checkpointDir, `${label}.png`)).toString("base64")
|
|
9606
|
+
};
|
|
9607
|
+
}
|
|
9608
|
+
return null;
|
|
9609
|
+
}
|
|
9610
|
+
var isProgressStage = (stage) => stage.offsetMs > 0 && stage.nativeActualMs === void 0 && !stage.anchor;
|
|
9571
9611
|
var device = {
|
|
9572
9612
|
_currentUrl: "",
|
|
9573
9613
|
_platform: DETOX_PLATFORM,
|
|
@@ -9772,7 +9812,7 @@ var device = {
|
|
|
9772
9812
|
_lastReadyAtMs: 0,
|
|
9773
9813
|
async reloadReactNative() {
|
|
9774
9814
|
const page = getPage();
|
|
9775
|
-
await page.
|
|
9815
|
+
await page.evaluate(() => window.SootSim.bridges.hotRemount.reloadExternalApp());
|
|
9776
9816
|
await waitForSootsimTree(page, 3e4);
|
|
9777
9817
|
await waitForSootsimSurfaceMetrics(page, 3e4);
|
|
9778
9818
|
await waitForSootsimShellReady(page, 3e4);
|
|
@@ -9987,7 +10027,7 @@ var device = {
|
|
|
9987
10027
|
const horizonFrame = cadence2.mode === "playing" && anchorMs !== null ? anchorFrameIndex + controller.framesForOffset(1900) : null;
|
|
9988
10028
|
while (rows.length - 1 < endFrame) {
|
|
9989
10029
|
if (horizonFrame !== null && rows.length - 1 >= horizonFrame) {
|
|
9990
|
-
await new Promise((
|
|
10030
|
+
await new Promise((resolve3) => setTimeout(resolve3, 1e3 / 60));
|
|
9991
10031
|
break;
|
|
9992
10032
|
}
|
|
9993
10033
|
await observeTick();
|
|
@@ -10348,7 +10388,7 @@ var device = {
|
|
|
10348
10388
|
} else {
|
|
10349
10389
|
while (!(input.workletFrameTimestampsSeconds ? state.triggerCompleted : state.triggerStarted)) {
|
|
10350
10390
|
if (state.cancelled) throw new Error("peach motion capture was cancelled");
|
|
10351
|
-
await new Promise((
|
|
10391
|
+
await new Promise((resolve3) => setTimeout(resolve3, 0));
|
|
10352
10392
|
}
|
|
10353
10393
|
}
|
|
10354
10394
|
let visibleStart = null;
|
|
@@ -10541,30 +10581,98 @@ var device = {
|
|
|
10541
10581
|
);
|
|
10542
10582
|
};
|
|
10543
10583
|
const snapshots = [];
|
|
10584
|
+
const stepToTime = async (targetMs) => {
|
|
10585
|
+
let receipt = currentReceipt;
|
|
10586
|
+
if (targetMs < receipt.virtualTimestampMs - 0.01) {
|
|
10587
|
+
throw new Error(
|
|
10588
|
+
`sample time ${targetMs}ms precedes the frames already stepped`
|
|
10589
|
+
);
|
|
10590
|
+
}
|
|
10591
|
+
while (receipt.virtualTimestampMs + 1e3 / 60 <= targetMs + 0.01) {
|
|
10592
|
+
receipt = await controller.stepFrame();
|
|
10593
|
+
}
|
|
10594
|
+
if (targetMs - receipt.virtualTimestampMs > 0.01) {
|
|
10595
|
+
receipt = await controller.stepFrame(targetMs - receipt.virtualTimestampMs);
|
|
10596
|
+
}
|
|
10597
|
+
currentReceipt = receipt;
|
|
10598
|
+
return receipt;
|
|
10599
|
+
};
|
|
10600
|
+
const sampleAt = async (stage, anchorReceipt, anchorId, targetMs) => {
|
|
10601
|
+
const receipt = await stepToTime(targetMs);
|
|
10602
|
+
snapshots.push({
|
|
10603
|
+
actualMs: receipt.virtualTimestampMs - anchorReceipt.virtualTimestampMs,
|
|
10604
|
+
anchorId,
|
|
10605
|
+
bitmap: await captureBitmap(),
|
|
10606
|
+
frameIndex: receipt.frameIndex,
|
|
10607
|
+
label: stage.label,
|
|
10608
|
+
offsetMs: stage.offsetMs,
|
|
10609
|
+
virtualTimestampMs: receipt.virtualTimestampMs
|
|
10610
|
+
});
|
|
10611
|
+
};
|
|
10612
|
+
const nativeProgressPercent = async (progress) => {
|
|
10613
|
+
const decode = async (png) => createImageBitmap(
|
|
10614
|
+
await (await fetch(`data:image/png;base64,${png}`)).blob()
|
|
10615
|
+
);
|
|
10616
|
+
const nativeBaseline = await decode(progress.baselinePng);
|
|
10617
|
+
const nativeStage = await decode(progress.png);
|
|
10618
|
+
const bounds = boundsFor(nativeStage);
|
|
10619
|
+
return measureChange({
|
|
10620
|
+
baseline: regionPixels(nativeBaseline),
|
|
10621
|
+
candidate: regionPixels(nativeStage),
|
|
10622
|
+
definition: input.motionChangeDefinition,
|
|
10623
|
+
height: bounds.height,
|
|
10624
|
+
label: "native stage progress",
|
|
10625
|
+
width: bounds.width
|
|
10626
|
+
}).changePercent;
|
|
10627
|
+
};
|
|
10628
|
+
let phaseMs = 0;
|
|
10544
10629
|
for (const stage of input.stages) {
|
|
10545
10630
|
if (state.cancelled) throw new Error("peach motion capture was cancelled");
|
|
10546
10631
|
const { anchorId, receipt: anchorReceipt } = await resolveAnchor(stage);
|
|
10547
10632
|
if (typeof stage.nativeActualMs === "number") {
|
|
10548
|
-
|
|
10633
|
+
await sampleAt(
|
|
10634
|
+
stage,
|
|
10635
|
+
anchorReceipt,
|
|
10636
|
+
anchorId,
|
|
10637
|
+
anchorReceipt.virtualTimestampMs + stage.nativeActualMs
|
|
10638
|
+
);
|
|
10639
|
+
continue;
|
|
10640
|
+
}
|
|
10641
|
+
const touchOffsetMs = await stageOffsetMs(stage.offsetMs, anchorId);
|
|
10642
|
+
if (stage.nativeProgress) {
|
|
10643
|
+
const targetPercent = await nativeProgressPercent(stage.nativeProgress);
|
|
10644
|
+
const nominalMs = anchorReceipt.virtualTimestampMs + touchOffsetMs;
|
|
10549
10645
|
let receipt2 = currentReceipt;
|
|
10550
|
-
|
|
10551
|
-
throw new Error(
|
|
10552
|
-
`peach stage ${stage.label} native time ${stage.nativeActualMs}ms precedes the frames already stepped`
|
|
10553
|
-
);
|
|
10554
|
-
}
|
|
10555
|
-
while (receipt2.virtualTimestampMs + 1e3 / 60 <= targetMs + 0.01) {
|
|
10646
|
+
while (receipt2.virtualTimestampMs + 1e3 / 60 <= nominalMs - input.phaseSearchMs) {
|
|
10556
10647
|
receipt2 = await controller.stepFrame();
|
|
10557
10648
|
}
|
|
10558
|
-
|
|
10559
|
-
|
|
10560
|
-
|
|
10561
|
-
|
|
10649
|
+
let progressBitmap = null;
|
|
10650
|
+
while (!progressBitmap) {
|
|
10651
|
+
if (receipt2.virtualTimestampMs > nominalMs + input.phaseSearchMs) {
|
|
10652
|
+
throw new Error(
|
|
10653
|
+
`peach stage ${stage.label} never reached the native progress ${targetPercent}% within ${input.phaseSearchMs}ms of ${touchOffsetMs}ms`
|
|
10654
|
+
);
|
|
10655
|
+
}
|
|
10656
|
+
receipt2 = await controller.stepFrame(1);
|
|
10657
|
+
const candidateBitmap = await captureBitmap();
|
|
10658
|
+
const bounds = boundsFor(candidateBitmap);
|
|
10659
|
+
const progress = measureChange({
|
|
10660
|
+
baseline,
|
|
10661
|
+
candidate: regionPixels(candidateBitmap),
|
|
10662
|
+
definition: input.motionChangeDefinition,
|
|
10663
|
+
height: bounds.height,
|
|
10664
|
+
label: "peach stage progress",
|
|
10665
|
+
width: bounds.width
|
|
10666
|
+
}).changePercent;
|
|
10667
|
+
if (progress >= targetPercent) progressBitmap = candidateBitmap;
|
|
10668
|
+
else candidateBitmap.close();
|
|
10562
10669
|
}
|
|
10563
10670
|
currentReceipt = receipt2;
|
|
10671
|
+
phaseMs = receipt2.virtualTimestampMs - nominalMs;
|
|
10564
10672
|
snapshots.push({
|
|
10565
10673
|
actualMs: receipt2.virtualTimestampMs - anchorReceipt.virtualTimestampMs,
|
|
10566
10674
|
anchorId,
|
|
10567
|
-
bitmap:
|
|
10675
|
+
bitmap: progressBitmap,
|
|
10568
10676
|
frameIndex: receipt2.frameIndex,
|
|
10569
10677
|
label: stage.label,
|
|
10570
10678
|
offsetMs: stage.offsetMs,
|
|
@@ -10572,7 +10680,15 @@ var device = {
|
|
|
10572
10680
|
});
|
|
10573
10681
|
continue;
|
|
10574
10682
|
}
|
|
10575
|
-
|
|
10683
|
+
if (phaseMs !== 0) {
|
|
10684
|
+
await sampleAt(
|
|
10685
|
+
stage,
|
|
10686
|
+
anchorReceipt,
|
|
10687
|
+
anchorId,
|
|
10688
|
+
anchorReceipt.virtualTimestampMs + touchOffsetMs + (anchorId === "transition" ? phaseMs : 0)
|
|
10689
|
+
);
|
|
10690
|
+
continue;
|
|
10691
|
+
}
|
|
10576
10692
|
const stageFrameIndex = anchorReceipt.frameIndex + controller.framesForOffset(touchOffsetMs);
|
|
10577
10693
|
const kept = keptFrames.get(stageFrameIndex);
|
|
10578
10694
|
if (kept && stageFrameIndex <= currentReceipt.frameIndex) {
|
|
@@ -10602,8 +10718,8 @@ var device = {
|
|
|
10602
10718
|
if (input.workletFrameTimestampsSeconds) controller.endWorkletFrameReceipt();
|
|
10603
10719
|
let releasedOffsetMs = 0;
|
|
10604
10720
|
while (input.hold && !releaseReceipt()) {
|
|
10605
|
-
|
|
10606
|
-
releasedOffsetMs =
|
|
10721
|
+
currentReceipt = await controller.stepFrame();
|
|
10722
|
+
releasedOffsetMs = currentReceipt.virtualTimestampMs - driveStart.virtualTimestampMs;
|
|
10607
10723
|
}
|
|
10608
10724
|
await heldInput;
|
|
10609
10725
|
if (input.settleMs > 0) {
|
|
@@ -10614,12 +10730,14 @@ var device = {
|
|
|
10614
10730
|
),
|
|
10615
10731
|
releasedOffsetMs
|
|
10616
10732
|
);
|
|
10617
|
-
await
|
|
10733
|
+
await stepToTime(
|
|
10734
|
+
driveStart.virtualTimestampMs + maximumPrimaryMs + input.settleMs
|
|
10735
|
+
);
|
|
10618
10736
|
}
|
|
10619
10737
|
while (!state.triggerCompleted) {
|
|
10620
10738
|
if (state.cancelled) throw new Error("peach motion capture was cancelled");
|
|
10621
10739
|
await controller.stepFrame();
|
|
10622
|
-
await new Promise((
|
|
10740
|
+
await new Promise((resolve3) => setTimeout(resolve3, 0));
|
|
10623
10741
|
}
|
|
10624
10742
|
const stats = input.workletFrameTimestampsSeconds ? await pairedPeerStats() : null;
|
|
10625
10743
|
return {
|
|
@@ -10655,6 +10773,7 @@ var device = {
|
|
|
10655
10773
|
workletFrameTimestampsSeconds: options.workletFrameTimestampsSeconds,
|
|
10656
10774
|
detectionTimeoutMs: options.detectionTimeoutMs ?? 3e3,
|
|
10657
10775
|
onsetStepMs: ONSET_STEP_MS,
|
|
10776
|
+
phaseSearchMs: PHASE_SEARCH_MS,
|
|
10658
10777
|
frame: options.frame ?? null,
|
|
10659
10778
|
anchorAtTouch: options.anchorAtTouch ?? null,
|
|
10660
10779
|
witnessedDrag: options.witnessedDrag === true,
|
|
@@ -10663,7 +10782,12 @@ var device = {
|
|
|
10663
10782
|
platform: device.getPlatform(),
|
|
10664
10783
|
rootFrame: options.rootFrame ?? null,
|
|
10665
10784
|
settleMs,
|
|
10666
|
-
stages
|
|
10785
|
+
stages: stages.map(
|
|
10786
|
+
(stage, index) => index === stages.findIndex(isProgressStage) ? {
|
|
10787
|
+
...stage,
|
|
10788
|
+
nativeProgress: storedNativeProgressFrames(namePrefix, stage.label) ?? void 0
|
|
10789
|
+
} : stage
|
|
10790
|
+
),
|
|
10667
10791
|
token
|
|
10668
10792
|
}
|
|
10669
10793
|
);
|
|
@@ -10840,13 +10964,13 @@ var device = {
|
|
|
10840
10964
|
state.ready = true;
|
|
10841
10965
|
while (state.anchorPerformanceMs === null || state.anchorWallMs === null) {
|
|
10842
10966
|
if (state.cancelled) throw new Error("peach timed capture was cancelled");
|
|
10843
|
-
await new Promise((
|
|
10967
|
+
await new Promise((resolve3) => setTimeout(resolve3, 0));
|
|
10844
10968
|
}
|
|
10845
10969
|
const captureAnchorMs = state.anchorWallMs;
|
|
10846
10970
|
const captureAnchorPerformanceMs = state.anchorPerformanceMs;
|
|
10847
10971
|
const snaps = await Promise.all(
|
|
10848
10972
|
input.stages.map(
|
|
10849
|
-
(stage) => new Promise((
|
|
10973
|
+
(stage) => new Promise((resolve3) => {
|
|
10850
10974
|
const fire = async () => {
|
|
10851
10975
|
const actualMs = performance.now() - captureAnchorPerformanceMs;
|
|
10852
10976
|
const captureRequestedAtMs = Date.now();
|
|
@@ -10873,7 +10997,7 @@ var device = {
|
|
|
10873
10997
|
dataUrl = await screenshot({ format: "png" });
|
|
10874
10998
|
captureCompletedMs = performance.now() - captureAnchorPerformanceMs;
|
|
10875
10999
|
}
|
|
10876
|
-
|
|
11000
|
+
resolve3({
|
|
10877
11001
|
label: stage.label,
|
|
10878
11002
|
offsetMs: stage.offsetMs,
|
|
10879
11003
|
actualMs,
|
|
@@ -10882,7 +11006,7 @@ var device = {
|
|
|
10882
11006
|
dataUrl
|
|
10883
11007
|
});
|
|
10884
11008
|
} catch {
|
|
10885
|
-
|
|
11009
|
+
resolve3({
|
|
10886
11010
|
label: stage.label,
|
|
10887
11011
|
offsetMs: stage.offsetMs,
|
|
10888
11012
|
actualMs,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! peach v0.1.
|
|
1
|
+
/*! peach v0.1.1728 | (c) 2026 Tamagui LLC | Proprietary; see LICENSE */
|
|
2
2
|
let __sootsim_import_meta_url = '', __sootsim_import_meta_dirname = '', __sootsim_import_meta_filename = ''; try { __sootsim_import_meta_url = require('url').pathToFileURL(__filename).href; __sootsim_import_meta_dirname = __dirname; __sootsim_import_meta_filename = __filename; } catch {}
|
|
3
3
|
"use strict";
|
|
4
4
|
var __create = Object.create;
|
|
@@ -186,6 +186,15 @@ function parseExpoManifestBody(body) {
|
|
|
186
186
|
}
|
|
187
187
|
throw new Error("Expo manifest response has no manifest part");
|
|
188
188
|
}
|
|
189
|
+
function readExpoManifestFields(manifest) {
|
|
190
|
+
if (typeof manifest?.bundleUrl === "string")
|
|
191
|
+
return { launchUrl: manifest.bundleUrl, client: manifest };
|
|
192
|
+
const launchUrl = manifest?.launchAsset?.url;
|
|
193
|
+
return {
|
|
194
|
+
launchUrl: typeof launchUrl === "string" ? launchUrl : void 0,
|
|
195
|
+
client: manifest?.extra?.expoClient || manifest?.extra || {}
|
|
196
|
+
};
|
|
197
|
+
}
|
|
189
198
|
|
|
190
199
|
// src/native-dev-bundle-url.ts
|
|
191
200
|
init_define_SWIFT_COVERAGE_SOURCE_DIGESTS();
|
|
@@ -382,16 +391,11 @@ async function probeExpoManifest(normalizedBaseUrl, port, pageOrigin, options) {
|
|
|
382
391
|
return { state: "no-manifest" };
|
|
383
392
|
}
|
|
384
393
|
if (!manifest || typeof manifest !== "object") return { state: "no-manifest" };
|
|
385
|
-
const
|
|
386
|
-
const expoClient = extra && typeof extra === "object" && "expoClient" in extra ? extra.expoClient : extra;
|
|
387
|
-
const client = expoClient && typeof expoClient === "object" ? expoClient : {};
|
|
388
|
-
const launchAsset = "launchAsset" in manifest ? manifest.launchAsset : void 0;
|
|
389
|
-
const rawLaunchUrl = launchAsset && typeof launchAsset === "object" && "url" in launchAsset && typeof launchAsset.url === "string" ? launchAsset.url : void 0;
|
|
394
|
+
const { launchUrl: rawLaunchUrl, client } = readExpoManifestFields(manifest);
|
|
390
395
|
const launchUrl = rawLaunchUrl ? alignLoopbackBundleUrlWithProbe(rawLaunchUrl, normalizedBaseUrl) : void 0;
|
|
391
|
-
const name =
|
|
396
|
+
const name = typeof client.name === "string" ? client.name : void 0;
|
|
392
397
|
if (!launchUrl && !name) return { state: "no-manifest" };
|
|
393
|
-
const
|
|
394
|
-
const manifestProjectRoot = "projectRoot" in internal && typeof internal.projectRoot === "string" && internal.projectRoot.length > 0 ? internal.projectRoot : null;
|
|
398
|
+
const manifestProjectRoot = typeof client._internal?.projectRoot === "string" && client._internal.projectRoot.length > 0 ? client._internal.projectRoot : null;
|
|
395
399
|
return {
|
|
396
400
|
state: "resolved",
|
|
397
401
|
bundle: {
|
|
@@ -400,10 +404,7 @@ async function probeExpoManifest(normalizedBaseUrl, port, pageOrigin, options) {
|
|
|
400
404
|
launchUrl || `${normalizedBaseUrl}${METRO_BUNDLE_PATH}`
|
|
401
405
|
),
|
|
402
406
|
port,
|
|
403
|
-
framework: inferManifestFramework(
|
|
404
|
-
launchUrl,
|
|
405
|
-
"sdkVersion" in client ? client.sdkVersion : void 0
|
|
406
|
-
),
|
|
407
|
+
framework: inferManifestFramework(launchUrl, client.sdkVersion),
|
|
407
408
|
projectName: name
|
|
408
409
|
}
|
|
409
410
|
};
|