feat(#202): Phase 4 — eradicate legacy runner apps (uninstall, not just pkill)#270
Merged
Conversation
…arbitrate) Re-examines the #202 architecture debate with post-shipping evidence: - Phase 4: uninstall (not just pkill) the on-device legacy runner apps - Phase 5: supervisor split so the bridge survives Metro restarts (#264) - Phase 6: canonical maestro surface + arbiter-aware foreign flows (#186) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- BLOCKER: mandatory baseDeps update in pre-existing suite (TypeError is swallowed by fail-open, contingency could never trigger) - zero-apps parse guard: clean:false on 0 parsed bundles, never memoized - selectInstalledLegacyApps takes the parsed Set (one parse per scan) - spec: corrected stale cdp_repair_action caller claim Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… memo, no terminate) - BLOCKER: live gate detects via parseSimctlListapps (raw .includes also matches nested GroupContainers keys — gate validated the wrong layer) - memo dropped: device lock's degraded fail-open path can't rule out a reinstall by another session; scan every open (~tens of ms) - terminateApp dropped: simctl uninstall terminates running apps itself - gate also proves the parser reads real 'listapps <udid>' output Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…listapps Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… bundles, fail-open Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ry open) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…t device-open Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ate) Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…form An open with platform omitted defaults to iOS but raw args.platform === 'ios' read false, silently skipping legacy-app eradication (the Phase 4 feature) and the fast-runner spawn. Found by final pre-PR review. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
#202 Phase 4 (first phase of the re-think spec
docs/superpowers/specs/2026-06-10-device-control-phase4-6-rethink-design.md§1): at iOS device-open,ensureSingleRunnernow detects the legacy upstream runner apps installed on the target simulator (com.callstack.agentdevice.runner+.uitests.xctrunner) andsimctl uninstalls them.Closes out the #202 comment (2026-06-08): killing the host processes (Phase 1) was insufficient — iOS relaunches an installed XCUITest runner into the foreground mid-
maestro_run, backgrounding the app under test and wedging CDP. Only uninstalling fixes it; eradication must target artifacts, not processes.Design decisions (multi-LLM plan review, 2 rounds)
simctl listapps, ~150–350 ms measured). A memo can't be made safe: the Phase 1.5 device lock fails open in its degraded path, so another session can reinstall on the same UDID.simctl uninstallterminates a running app itself; Phase 1's scopedKill already ran.listappsparsing to 0 bundles is a parse/format failure (a booted sim always has system apps), surfaced as a warning, never read as "clean".removedApps+meta.timings_ms.appEradicationin the result); a device-open is never blocked. Opt-out:RN_DEVICE_KILL_LEGACY=0.Final-review catch
The pre-existing eradication/fast-runner gates used raw
args.platform === 'ios', silently skipping whenplatformis omitted (defaults to iOS). Fixed to the normalizedplatform+ wiring test (94b0932).Live gate (booted iPhone 17 Pro, iOS 26.5)
Planted a stub app under the legacy bundle id (RnFastRunner.app clone, PlistBuddy-rewritten CFBundleIdentifier), then ran the device-open path:
Steady-state
appEradication(nothing to remove): ~150–350 ms.Tests
baseDepsupdate in the pre-existing suite, normalized-platform wiring test)Phases 5 (#264 supervisor split) and 6 (#186 foreign-flow arbitration) follow on this spec.
🤖 Generated with Claude Code