Repository navigation
fix(ios): request runner synthesis only on platforms that synthesize - #2835
Conversation
…visionOS isIosFamily includes visionOS, so every producer of synthesized:true kept sending it for visionOS taps even though the runner's synthesis path is gated behind #if os(iOS) and falls through to an unsupported-message XCTest fallback on visionOS. Add runnerSynthesizesTap, a named predicate for the leaves the runner actually synthesizes on (iOS and iPadOS), and route every synthesized:true producer through it, including the runner-sequence press-series builder.
Size Report
Startup median (7 runs, lower is better):
|
|
Reviewed at 52dbc1b. Coordinate tap, selector tap and the press-series builder now request synthesis only where the runner can synthesize, and iOS behavior stays the same. The code looks right. Not blocking: Two Smoke Tests jobs were green and two were still running at review time. None of this diff touches the known depth-frontier failure that #2832 fixes. |
|
Summary
isIosFamilyreturns true for visionOS, so every producer ofsynthesized: true(coordinatetap, selector tap, runner-sequence press-series builder) requested the runner's two-finger HID
synthesis path on visionOS even though the native runner gates that path behind
#if os(iOS)and falls into a generic
#elsebranch for visionOS, refusing with a misleading"not supported on macOS" message and forcing an XCTest coordinate-tap fallback.
Adds one named predicate,
runnerSynthesizesTap(packages/kernel/src/device.ts):isIosFamily(device) && !isTvOsDevice(device) && device.appleOs !== 'visionos'. All threesynthesized: trueproducers now call this predicate instead of two independently driftinginline checks; the local
shouldUseSynthesizedIosGesturehelper is deleted in favor of it.Closes #2789.
6 files changed (net +13 production lines; +95 test lines).
PR #2829, opened separately, fixes a distinct visionOS simulator misclassification bug
(
appleOsresolving toiosfor a visionOS simulator whose name lacks a literal "vision"substring), found incidentally while setting up live validation here. Unrelated to this logic.
Validation
Tested at
52dbc1bee2f725a9d54abd099828b1363dc1b8c5.pnpm check:affected --run: all runnablechecks passed (format, lint, typecheck, layering, build, 887 test files / 7789 tests,
daemon-wire-compat 0 drift), exit 0.
Live, on a visionOS 26.2 simulator: pre-fix
pressreturnedgestureFallback: "xctest-coordinate-tap"with the macOS-labeled message; post-fixpressreturns nogestureFallback*fields, and the runner log shows a clean tap with no synthesis markers.Adversarial high-level code review: zero findings. No unresolved risks for this change.