Skip to content

fix(runtime): isolate tool failures and recover interrupted actions automatically - #6527

Merged
M4n5ter merged 2 commits into
rust-previewfrom
fix/cua-attachment-settlement
Nov 1, 2026
Merged

M4n5ter merged 2 commits into
rust-previewfrom
fix/cua-attachment-settlement

Conversation

@M4n5ter

@M4n5ter M4n5ter commented Nov 1, 2026 •

Copy link
Copy Markdown
Member

Summary

A failed browser claim could leave cleanup uncertain, retire the Computer provider and its Agent dependents, and disconnect the conversation and catalog observers. The desktop then kept reconnecting while displaying internal recovery actions.

This change keeps failed work with its actual owner without retiring unrelated services or leaving completed workers in the active-session controls. Returned business results remain usable through tool persistence, Code Mode and the native Client, independently of cleanup status. Bot and ordinary conversations both receive sealed unknown tool outcomes when processing later messages and worker notifications.

Conversations, creation, settings, sign-in, approvals, uploads, interface settings and terminals automatically observe their original operations. Terminal outcomes release local waiting; unknown outcomes preserve unsent drafts and never fabricate attachments. Background recovery does not repeat business mutations. A stable preparation lease and SQLite CAS prevent recovery from cancelling another window or process while it is preparing a request. The manual receipt, recovery and abandonment panels are removed.

Browser integration pins maka-agent/cua#3, which reclaims an explicitly selected tab from an old extension session while retaining one lifecycle cleanup chain.

Verification

  • CUA core: 1,547 passed, 1 ignored, including cancellation, concurrent finishing and lost finalization acknowledgement recovery.
  • Workbench: 65 behavior tests passed; generated UI TypeScript checks, changed-file Biome checks, workspace Rust formatting and ASF source-header audit passed.
  • Native renderer: narrow/wide and light/dark settings layouts inspected, including a simulated pending operation. The image below demonstrates layout; automatic recovery is exercised by behavior tests.
  • Independent GPT-6 Astra high advisor reviewed the final recovery and ownership paths and found no remaining blocker.
  • macOS affected batch: 622 cases passed. Two stale expectations were corrected (a fixed explanatory sentence and requiring Client close to fail after Host accepted cleanup custody); both passed focused reruns. Additional focused regressions for ordinary-session notifications, model panic/SQL failure isolation and returned results with retained cleanup also passed.
  • Linux: 61 Client/kernel cases and 114 Engine cases verified across the suite runs and focused reruns; one Engine case skipped. The updated restart test verifies the next model request receives the unknown outcome without replaying the original mutation.
  • Strict Clippy passed for the affected runtime, Client, Agent, Engine and Facts crates. Native-desktop Clippy reports 11 existing diagnostics in unchanged macOS keyboard/controller/focus code.

Automatic action status in light/dark, wide/narrow layouts

Remaining validation

  • Finish the affected Rust regression runs and record the final results.
  • Complete the real desktop browser acceptance matrix, including Windows. Current mocked extension tests do not certify this matrix.

No live desktop restart or user-database rewrite was performed.

AI use

  • No generative tool made a substantive contribution
  • Generative tooling made a substantive contribution

Tool(s) and scope: Codex implemented the changes and tests; a separate GPT-6 Astra high advisor reviewed correctness and ownership. Human owner: @M4n5ter.

Checklist

  • Tests cover the change and fail without it
  • Lint, format, typecheck and affected regressions checked locally; the native-desktop baseline Clippy diagnostics are recorded above

Does this PR entail a change in behavior?

  • Yes — described under Summary above
  • No

…utomatically

Preserve returned tool results independently of cleanup, keep failed work with its actual owner, and let unrelated Agent and UI operations continue. Recover original actions across conversations, settings, uploads, approvals and terminals without manual receipt handling.

Generated-by: Codex
…ipts

Keep the model aware that an operation may have completed and let it inspect current state and continue. Retain typed original evidence without testing a fixed explanatory sentence.

Generated-by: Codex
@M4n5ter
M4n5ter marked this pull request as ready for review November 1, 2026 06:49
@M4n5ter
M4n5ter merged commit 6719a0c into rust-preview Nov 1, 2026
11 of 14 checks passed
@M4n5ter
M4n5ter deleted the fix/cua-attachment-settlement branch November 1, 2026 06:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant