Repository navigation
Self-repair's new clicks on native and pixel-only backends, by element identity and the record check - #1709
Merged
Conversation
…by element identity and the record check A bridge click with no record identity under it is admitted outside a browser only when a record check covers every save: on an accessibility backend its element (role, name, ancestry, window) must also be unique in the pinned window; on pixels the record check alone admits it. The new step carries the dialog around it as a screen pre-check, and only a person approves such a fix. The browser rule is unchanged. Adds repair/element_identity.py, MacOSBackend.element_identity_at, the repair hold's element_identity op, the design note docs/REPAIR_ON_EVERY_BACKEND.md and a macOS real-app qualification script with its first results.
…ueness with the backend's own locator
Member
Author
Independent adversarial reviewVerdict: APPROVE. No blockers. Reviewer. An independent subagent. It was given the diff and the product's safety rules, not the author's conclusions. It worked read-only and drove no screen. Commits reviewed. Tests the reviewer ran. What was probed, and held
Findings (all non-blockers; left for a follow-up PR under the post-approval freeze)
|
This was referenced Nov 2, 2026
This was referenced Nov 3, 2026
abrichr
added a commit
that referenced
this pull request
Nov 3, 2026
abrichr
added a commit
that referenced
this pull request
Nov 3, 2026
…1706) * Backend parity: capability by surface, with evidence for every cell Rewrites docs/BACKEND_PARITY.md as a capability x surface matrix (web, Windows, macOS, Linux, RDP, Citrix), each cell QUALIFIED, TESTED, CODE ONLY or MISSING with its evidence path, and links the twelve backend-parity issues. Corrects claims the evidence doesn't support: Citrix in-session has no run inside a Citrix session, the Linux GTK3 job doesn't run in the monorepo, the macOS trials drove the backend directly, repair and rollback run on web apps only, and the RDP numbers name their apps and scripted harness. * Backend parity: apply the adversarial review Split rollback (refused off the web) from undo (code only off the web); add the surface-neutral guarded save; one rule for scripted recordings; Windows compile and record were run on a real VM, with the full 4 of 10 run tally; shadow mode gets the same verdict on every surface; web approvals drop to tested (scripted person, local Cloud stand-in); live repair vs offline teach; more refusals; the Aardwolf RDP batch was a Windows 11 VM; flow's linux-atspi-x11 job, not capture's AT-SPI read, is the one that never runs. * Backend parity: non-web self-repair exists (#1709, #1715, #1717) Self-repair and repair by default run outside a browser with repair.session, qualified end to end on macOS AX and not yet on Windows UI Automation or RDP. Teaching the fix (--hold-on-halt) and rollback stay web-only. * Backend parity: describe qualified surfaces with evidence
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.
Self-repair could add a new click (dismiss an update notice, close a new dialog) only in a browser, because each new click needed a DOM record identity. This change makes the rule backend-neutral. Design:
packages/flow/docs/REPAIR_ON_EVERY_BACKEND.md.What changes
A new bridge click is admitted as follows (
openadapt_flow/repair/element_identity.py):"A record check covers the workflow" (
record_check_cover): the run has a system-of-record verifier, the profile isstandardorregulated, there is at least one save, and every save declares confirmed effects on each path and has an armed identity check of its own. Anything else refuses the click, and the run stays stopped for a person.A backend that has accessibility reads but no
element_identity_at(Windows and Linux today) is refused with that reason, not treated as pixels only.A click admitted on the record check:
_dialog_band): the box from the AX ancestry or the drawn box on pixels, the text hashed with the bundle's salt. It's a screen pre-check, and it keeps theclinical-writearmed-click rule intact. No dialog, or no readable text, refuses the click._Patch.needs_person).step_x admitted by element_and_record_check (button 'Later')) and in what the approver sees ("checked by the record check").Also:
MacOSBackend.element_identity_atandQuartzMacAXClient.ancestry; the repair hold answerselement_identity; agent teach takes the dialog box from the identity's ancestry when there is one.Tests
tests/test_repair_element_identity.py(46): parsing and fail-closed validation, backend kind (including the realMacOSBackend,FreeRDPBackendandRemoteDisplayBackendclasses), uniqueness, cover, admission per kind, the dialog band,needs_person, the hold op and agent teach.Real-app qualification (macOS)
benchmark/repair_every_backend/qualify_macos.pyrecords a note workflow on a native Cocoa app (tests/native_apps/Chart.swift, SQLite) and repairs its new "Update available" notice. By CAPABILITIES' definitions this is a synthetic app (OpenAdapt's own), driven through live macOS AX, screen capture, input and database. Scripted repair agent and approver.Through
MacOSBackend, live: the run stops at the notice before any save; the "Later" click's AX identity is read (button "Later"insideAXSheet "Update available", in windowChart), found unique and admitted onelement_and_record_check; the patched bundle passesclinical-write; underdemothe click is refused and nobody is asked; with no verifier the run gate refuses. No run wrote a wrong row.Not passing end to end yet, for reasons outside the repair code (details in the benchmark README):
MacOSBackendrefuses its first structural click:remote delivery receipt does not bind the resolved target(action_evidence._delivery_receipt_errorexpects the structural fingerprint;click_guardedbinds frame and point). The unrepaired bundle fails the same way, so nostandard-profile run on native macOS completes today.MacOSBackendrefuses input to a realNSAlertsheet (a separate CG window); the test app draws its notice in the window.RECONCILIATION_REQUIRED, so it isn't repairable; plus a focus race after launch and shifted typing on a macOS host.Not covered: Windows UIA and RDP (waiting on
WindowsBackend.element_identity_atand the lab), and the CLI (run --self-repairstill refuses non-web).Review
Changes repair and identity: needs a recorded independent adversarial review before merge. Over 1,000 code lines, so the coordinator merges it by hand.