Repository navigation
feat(ios): name the dismiss controls when back changes nothing - #4628
Conversation
Size Report
Startup median (7 runs, lower is better):
|
iOS back stays the navigation pop: the BackButton press, else the verified edge swipe. When the swipe changes nothing, such as on a full-screen modal, the refusal now lists the hittable Back, Close, Cancel or xmark buttons in the window's top band as details.dismissControls, each with a selector the caller can press without a new snapshot. The hint names a lone control. Back never presses them: Close or Cancel can discard a draft or end a flow. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Read the dismiss controls with an exact predicate and their snapshot frames, ask hittability last, and have the runner name the attribute each control is pressed by. A control whose label or identifier another button shares is left out, since its selector would match both. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… back help The every-field ErrorPayload fixture sets dismissControls so the encoder contract covers it. The back description is rewritten shorter than before, so the always-loaded MCP tools stay within their byte budget. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Apex Sentinel · ✅ ApproveSince the last review: 0 new · 0 still open · 0 no longer raised No open findings. Reviewed with this repository's own Sentinel configuration ( 💬 Talking to SentinelIn a finding's thread, reply with:
On this conversation, comment Earlier reviewsReview of
|
| Where | Finding |
|---|---|
apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+Navigation.swift:748 |
Dismiss controls are read from every window but judged in one window's frame space |
packages/apple-runner/src/runner-contract.ts:592 |
Ambiguity is checked among buttons only, but the emitted id= selector matches any role |
1 finding below minor hidden (user_settings.min_severity).
Reviewed with this repository's own Sentinel configuration (fce2fa6247c5).
Review of 8a3d7f07 · 17.11.2026 11:22 UTC
Apex Sentinel · ✅ Approve
2 finding(s): 2 minor.
🟡 Minor (2)
| Where | Finding |
|---|---|
apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+Navigation.swift:711 |
Ambiguity is checked among buttons only, but the emitted selector matches any element type |
apple/runner/AgentDeviceRunner/AgentDeviceRunnerUITests/RunnerTests+Navigation.swift:749 |
dismissControls is read from every window, so a sheet's button can be pressed for the wrong window |
Reviewed with this repository's own Sentinel configuration (fce2fa6247c5).
There was a problem hiding this comment.
Apex Sentinel: 2 new findings on 8a3d7f0. The verdict and the full list are in the summary comment.
8a3d7f0 to
2df99ee
Compare
There was a problem hiding this comment.
Apex Sentinel: 2 findings moved to a new line on 2df99ee. The verdict and the full list are in the summary comment.
… selectors Both dismiss control selectors now carry role=button, so press resolves them against buttons only, the set the runner checks for uniqueness; a selectors test pins that scope for the label and id forms. The runner lists controls only from the window back swiped on and checks each label or identifier against the buttons of every window, compared the way the selector engine normalizes text. The test file is renamed for the module it covers. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The change at c13ce51 reads well, but the live device run is stale. It covers 8a3d7f0, and c13ce51 changed the runner read afterwards: listing roots now come from Of the open inline threads, #4628 (comment) (frame space) is outdated and fixed at c13ce51, because listing now uses Not blocking, and you can take or leave these. A listed selector should name exactly one node in the tree The lint failure is oxlint max-lines on |
The uniqueness read now compares each button's snapshot label, which falls back to its value or a child's text as press sees it, and reads unlabeled buttons for that reason. A shared normalization table ties the runner's selectorText to the selector engine's normalizeText. With no resolved window the first read also serves as the listing read. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Live run at ca13deb on an iPhone 17 Pro Max simulator (iOS 27.0). It uses this branch's CLI with a private state dir. Wallet was installed and signed up through the UI.
These XCUITests pass on the same simulator at ca13deb, run with
ca13deb applies all three optional notes:
The Lint failure is main's |
|
Both checks still red at ca13deb come from main and are already being fixed. Neither touches this diff.
This branch will rebase onto main once #4630 and #4631 land. 🤖 Generated with Claude Code |
|
The PR is ready at ca13deb. The findings from the earlier review are fixed, and I found nothing new that needs a change. The live run and the XCUITest pass list are in your comment at this head. Not blocking: these can be taken or left, namely a test that pins the Two inline threads no longer apply, so you can resolve them: the listing now reads only the back window's roots (thread), and both selector forms carry Lint fails on max-lines in |
Summary
iOS
backstill only pops the navigation stack (BackButton, else the verified edge swipe) and never presses Close or Cancel. Onback_swipe_no_change(e.g. a full-screen modal) the refusal addsdetails.dismissControls: [{ selector, label, identifier? }]: hittable buttons in the top band of the window back swiped, named back, close, cancel orxmark*, never Done/Save. The hint names a lone one. Help,commands.mdandRUNNER_PROTOCOL.mdsay iOS back does not close modals or sheets, unlike Android's system back. 12 files.backexpires the ref frame before it swipes (ADR 0014). Entries carryrole=button label="…"orrole=button id="…", which resolve only against buttons. A control whose snapshot label or identifier another button in any window shares is omitted; a shared fixture ties the runner's text comparison tonormalizeText.Validation
iPhone 17 Pro Max simulator, iOS 27.0, head ca13deb:
back --in-appand--system→back_swipe_no_change,dismissControls: [{selector:'role=button label="Close"', label:'Close'}], hintPress 'role=button label="Close"' to dismiss this screen; …. Base 26a8a1b had no list.press 'role=button label="Close"'→kind: unique; snapshot shows Home ("Welcome back", "Hi, Review").back_swipe_no_change,dismissControlsabsent.testInAppBackNeverPressesABarButtonOnlyTitledBack, both new dismiss-control tests, the normalization test,testInAppBackPressesTheNavigationBarBackButton,testErrorPayloadEncodesEveryField….package-boundariesmax-lines (test(gates): keep package-boundaries.test.ts under max-lines #4630).🤖 Generated with Claude Code