Skip to content

perf(ios): synthesize taps on resolved in-app back controls - #3880

Merged
thymikee merged 2 commits into
mainfrom
perf/ios-back-synthesized-tap
Oct 22, 2026
Merged

thymikee merged 2 commits into
mainfrom
perf/ios-back-synthesized-tap

Conversation

@thymikee

@thymikee thymikee commented Oct 21, 2026 •

Copy link
Copy Markdown
Member

Summary

Use synthesized coordinate taps for resolved iOS in-app back controls. Retain measured candidate frames through ranking and dispatch to avoid repeated element resolution and XCTest tap quiescence waits. Keep the navigation-bar → ranked back control → verified leading-slot fallback and #2728 typed outcomes. macOS/tvOS behavior is unchanged. Three files; no scope expansion. Related: #2728.

Validation

Base: 642393cadb4510cdccab581c1046ac83e9b52ae8. Head: 0351d1996998593599a9a24806298747f2a545c0.

  • pnpm check:affected --run --head 0351d19969: exit 0, exactCommit=true; receipt .tmp/validation/run-YyADUC/receipt.json.
  • pnpm format, pnpm check:xctest-selection, TypeScript build, iOS runner build: passed.
  • Two focused native tests: head 2 passed; same tests/fixture with base navigation: 2 failed on the intended XCTest-tap assertion. Independent review: no findings.
  • Bluesky 1.136.0, dedicated iPhone 17 Pro/iOS 27.0: identical post-thread → back → feed sequence, three successful runs each. Runner accepted→completed milliseconds: base 2091/2378/2331; head 1397/1461/1527. CLI wall milliseconds: base 2382/2705/2535; head 1588/1720/1860. Median runner time improves 37.3%; all six navigations verified on the feed.

CI still owns macOS/native cross-platform builds and integration/coverage. Review control-selection parity and the existing synthesis-failure fallback. No PR was opened by this worker.

Implemented by a Codex worker; opened and reviewed by the coordinating Claude session.

🤖 Generated with Claude Code

View guided diff Turn on auto-fix

@github-actions

github-actions Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

Size Report

Metric Base Current Diff
Installed (including dependencies) 5.52 MB 5.52 MB -6.7 kB
Package (unpacked) 5.52 MB 5.52 MB -6.7 kB
Package (download) 1.67 MB 1.67 MB -2.7 kB

Startup median (7 runs, lower is better):

Scenario Base Current Diff
CLI --version 44.9 ms 43.9 ms -1.0 ms
CLI --help 89.5 ms 92.2 ms +2.6 ms

Review follow-up. isHittable promises a hittable point, not a hittable
center, so a bar button partly under an overlay could take a synthesized
center tap that misses it. The navigation bar branch keeps XCTest's
element tap; the ranked back control, which already tapped its center,
keeps the synthesized dispatch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@thymikee

Copy link
Copy Markdown
Member Author

Independent review (Codex, read-only) of 0351d19969 raised one P2, fixed in ed1a21f98a.

P2: the navigation-bar branch replaced back.tap() with a frame-centre synthesized tap. isHittable promises a hittable point, not a hittable centre, so a bar button partly under an overlay could pass selection while its centre missed. That branch now keeps XCTest's element tap, exactly as on main. The ranked back control (the branch Bluesky's "Go back" takes, which already tapped its centre) keeps the synthesized dispatch, so the measured gain is unchanged. The navigation-bar test now asserts exactly one element tap.

Validation at ed1a21f98a:

  • pnpm check:affected --run --head: passed.
  • testRankedInAppBackUsesSynthesisWithoutXCTestTap and testNavigationBarBackKeepsTheElementTap: passed on an iOS 27.0 iPhone 17 Pro simulator.

@thymikee

Copy link
Copy Markdown
Member Author

This PR is ready at ed1a21f. All 16 checks pass on that commit, and I know of no conflicts. Not blocking, and you can take or leave it: tapResolvedNavigationBackControl in RunnerTests+Navigation.swift repeats the same synthesis-then-XCTest-fallback tap that tapTopLeadingNavigationFallback uses in the same file, so one small private helper that taps a point and reports whether it dispatched could serve both branches. The Bluesky timing ran on 0351d19, not ed1a21f, so one back run on ed1a21f whose runner log shows the coordinateTap synthesis marker would confirm that the ranked branch carries the gain. Nothing else needs to happen before merge.

@thymikee thymikee added the ready-for-human Valid work that needs human implementation, judgment, or maintainer merge label Oct 21, 2026
@thymikee
thymikee merged commit 3602746 into main Oct 22, 2026
16 checks passed
@thymikee
thymikee deleted the perf/ios-back-synthesized-tap branch October 22, 2026 02:53
@github-actions

Copy link
Copy Markdown
Contributor
PR Preview Action v1.8.1
Preview removed because the pull request was closed.
2026-10-22 02:55 UTC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-human Valid work that needs human implementation, judgment, or maintainer merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant