Skip to content

fix: harden iOS runner command execution#72

Merged
thymikee merged 3 commits intomainfrom
codex/ios-runner-hardening
Feb 18, 2026
Merged

fix: harden iOS runner command execution#72
thymikee merged 3 commits intomainfrom
codex/ios-runner-hardening

Conversation

@thymikee
Copy link
Copy Markdown
Contributor

@thymikee thymikee commented Feb 18, 2026

Summary

Hardened the iOS XCUITest runner command path so transient app instability no longer crashes or restarts the runner during interactions.

  • enabled failure-tolerant XCTest flow (continueAfterFailure = true)
  • added Objective-C exception bridge so XCTest NSException is surfaced as recoverable command errors
  • added liveness and foreground guard before interactions with targeted re-activation
  • added one-shot retry for interaction commands (tap, longPress, drag) on transient failures
  • added post-snapshot and post-activation interaction stabilization delays
  • added shutdown fast-path and bounded main-thread execution timeout

Validation

  • pnpm build:xcuitest
  • pnpm ad open --platform ios RNCLI83
  • pnpm ad snapshot -i --platform ios
  • pnpm ad click @e5 --platform ios
  • 12x stress loop: snapshot -> click (no command failures)
  • inspected ~/.agent-device/daemon.log for run window (no Restarting after unexpected exit / ** TEST EXECUTE FAILED ** markers)

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Feb 18, 2026

PR Preview Action v1.8.1

QR code for preview link

🚀 View preview at
https://callstackincubator.github.io/agent-device/pr-preview/pr-72/

Built to branch gh-pages at 2026-02-18 14:44 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

@thymikee
Copy link
Copy Markdown
Contributor Author

Addressed review follow-ups in commit a2bd557:\n- confirmed both execute paths use executeOnMainSafely (main-thread + dispatched path)\n- centralized NSError domains/codes in RunnerTests for stable semantics\n- added explicit timeout behavior comment (main queue work may still run after timeout)\n- added NSException name fallback in Obj-C catcher to avoid null prefixes\n\nValidation rerun: pnpm build:xcuitest (TEST BUILD SUCCEEDED).

@thymikee thymikee force-pushed the codex/ios-runner-hardening branch from 0d07d9c to 8fde634 Compare February 18, 2026 15:06
@thymikee thymikee merged commit fc10613 into main Feb 18, 2026
5 of 6 checks passed
@thymikee thymikee deleted the codex/ios-runner-hardening branch February 18, 2026 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant