feat(desktop): close exact windows with one native request #134
- IA
Add `desktop_close` for an exact window target from native inventory. The native service selects one supported background AX route before input and rechecks process generation, window ID and bounds. Accepted or ambiguous input never falls through to another close attempt. An unsaved-work dialog leaves close unknown with unsafe retry and fresh inventory; confirmed disappearance survives a failed follow-up read. No foreground fallback, forced close or automatic dialog response.
Part of #8 and #73. This does not complete the broader window/dialog slice.
Validation on exact head `a2c1870f68651bb898d0d52f0c9beccba0d9c77d`:
- Types, CI, Swift parse, independent source review, signed development build and strict signatures pass; GitHub CI passes. - Real AppKit stale-generation/bounds and pre-cancel checks refused with zero close callbacks. One deferred close opened an actual unsaved-work sheet: exactly one request, zero closes, unknown/unsafe native outcome and refreshed inventory. - A real pi/OpenAI run fetched `desktop_windows` immediately before one close, received a signed confirmed result and empty window inventory, and the fixture recorded exactly one close. Exact tool results, usage and execution counts survived worker exit and same-store reopen without replay. - The first model attempt correctly refused stale startup geometry before input. Its original result is preserved; only the unproven normal-close phase was rerun after matching real frame/inventory observations. Both runs' fixtures, workers, development host and app were stopped; temporary channels/projects were removed.
Close-specific in-flight cancellation, crash/hosted routing, self-close, and a second machine remain unverified. Evidence: `/tmp/ace-close-smoke.bD8VDF`, `/tmp/ace-close-model-smoke.K0UnZY`, and `/tmp/ace-close-model-live.1K1dxT/cleanup-final.json`.
### Built in Ace
Used Codex's direct file/terminal tools for implementation, review and builds under Nate's explicit direct-tool authorization while developing Ace's desktop tools. Live validation used Ace's real source host, signed native bridge and pi channel. Related dogfooding gaps: #5, #9 and #22.
iamnbutlerreferenced this in Finish native window, menu, and dialog workflows #73last month on GitHub
iamnbutlerready-for-reviewlast month on GitHub
iamnbutlermerged a08b9cf436e3last month on GitHub
iamnbutlerreferenced this in [Meta] Complete native computer use in Ace #8last month on GitHub
iamnbutlerreferenced this in Read bounded clipboard image previews #135last month on GitHub