fix(ios): avoid replaying alert mutations - #2323
Merged
Merged
Conversation
Member
|
Looks good at |
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
Prevent XCTest-backed
alert acceptandalert dismissfrom being replayed after a lost response. Default/explicitgetstays retryable. Six transport regressions fail before the fix and pass afterward.Scope
12 files: action-aware runner traits across client, session and recovery; transport/provider/startup regressions; shared TypeScript/Swift golden table; help and command docs. No native alert-identity change or QA driver version update.
Validation
Commit
53d9f01f4ccde3665d73b76fd5441ddb64a00d97:pnpm check:affected --runpassed (2,915 related tests). All CI green. macOS: 191 native tests passed, including the golden table. iOS: 77 native tests plus live alert get/dismiss/accept outcomes and session cleanup passed. Local host bootstrap hung; separate Settings replay needed attempt 2 after a capture timeout.Verification
Observability audit: existing command IDs correlate dispatch and status recovery. Tests preserve typed lifecycle/recovery details and prove one mutation dispatch. No additional payload logging, secrets, or configuration.
Automated Test Plan
pnpm exec vitest run --project apple-runner packages/platform-apple/src/runner/__tests__/runner-recovery-wiring.test.ts packages/platform-apple/src/runner/__tests__/runner-command-traits.test.ts; expect no accept/dismiss replay for accepted, started, or completed lost-response states; queries still retry.testAlertReadOnlyClassificationMatchesGoldenTableto pass.examples/test-app/README.md; followdocs/agents/device-verification.mdfor fresh source/isolated simulator setup. Keep the same--platform ios --udid <owned-udid> --session alert-retryon every command. Opencom.callstack.agentdevicelab, navigate Settings → Open automation lab,click id="automation-open-alert", thenalert getandalert dismiss; expectAlert result: cancelled. Reopen andalert accept; expectAlert result: accepted. Retain command/status evidence;closethe original session. Executed in iOS CI.