Skip to content

fix(computer-use): probe EditableText iface on Linux set-value - #12603

Closed
bbingz wants to merge 2 commits into
stablyai:mainfrom
bbingz:fix/10569-linux-set-value-editable-text
Closed

bbingz wants to merge 2 commits into
stablyai:mainfrom
bbingz:fix/10569-linux-set-value-editable-text

Conversation

@bbingz

@bbingz bbingz commented Aug 5, 2026 •

Copy link
Copy Markdown
Contributor

Summary

computer set-value fails on every Linux desktop with 'Accessible' object has no attribute 'is_editable_text' — the feature is completely broken, not degraded.

  • Atspi.Accessible.is_editable_text is not exposed through Python GObject Introspection, so the attribute access raised before attempt() could catch it.
  • Use get_editable_text_iface() and fall back to the Value interface.
  • Unit test stubs ATSPI and covers editable / value / no-iface paths.

Root cause independently confirmed by @nwparker on issue #10569 (2026-07-27):

set_value() uses node.is_editable_text, which is not present on the Python GObject Introspection Atspi.Accessible binding (gir1.2-atspi-2.0).

Use node.get_editable_text_iface() is not None (GIR-exposed) instead of node.is_editable_text.

Fixes #10569

Test plan

  • python3 native/computer-use-linux/set_value_test.py

@coderabbitai

coderabbitai Bot commented Aug 5, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

Updated set_value to handle missing nodes, access the EditableText interface directly, and use the Value interface as a fallback. Added tests with stubbed GI and Atspi modules for editable-text assignment, numeric value conversion, and failure when neither interface is available.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description includes the summary and a focused test plan but omits Screenshots, full Testing checks, AI Review Report, Security Audit, and Notes. Add all missing template sections, record the required validation results, and include AI review, security audit, and platform compatibility details.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed The changes resolve issue #10569 by removing the unavailable is_editable_text access, using get_editable_text_iface(), preserving fallback behavior, and adding regression tests.
Out of Scope Changes check ✅ Passed The runtime change and ATSPI stub tests are directly related to the linked Linux set-value failure and its regression coverage.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title clearly and concisely describes the Linux set-value fix for EditableText interface detection.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: c520b1b8-5825-4ab4-a2c9-cf0a1b09178a

📥 Commits

Reviewing files that changed from the base of the PR and between 7956335 and a195e6b49deb52cafdde8b2842bfe62037fe927b.

📒 Files selected for processing (2)
  • native/computer-use-linux/runtime.py
  • native/computer-use-linux/set_value_test.py

Atspi.Accessible.is_editable_text is not exposed through Python GObject
Introspection, so attribute access raised before attempt() could catch it
and every set-value failed. Use get_editable_text_iface() instead (stablyai#10569).
@bbingz
bbingz force-pushed the fix/10569-linux-set-value-editable-text branch from a195e6b to a71a7d3 Compare August 5, 2026 00:35
Load runtime.py inside mock.patch.dict so incomplete gi fakes do not
leak into later tests via permanent sys.modules assignment.
@coderabbitai

coderabbitai Bot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Note

GitHub couldn't provide a complete incremental comparison for this pull request, so CodeRabbit is performing a full review instead. This review may take a little longer.

@bbingz

bbingz commented Aug 6, 2026

Copy link
Copy Markdown
Contributor Author

Consolidate decision (with @innocarpe on #10586): #10586 is the intended merge path.

This PR stays open only as a temporary carrier for set_value_test.py until that suite is cherry-picked onto #10586 (or a maintainer picks the inverse). See the note on #10586 for the tip + raw URL.

Not rebasing further until the direction is final so we do not churn CI on a PR we plan to close.

@innocarpe

Copy link
Copy Markdown
Contributor

@bbingz Following the consolidate plan: your set_value_test.py is now on #10586 (6a6c4125a2). Safe to close this PR as duplicate when ready — credit stays in the file header + #10586 comment.

@bbingz

bbingz commented Aug 7, 2026

Copy link
Copy Markdown
Contributor Author

Closing as duplicate of #10586.

@innocarpe folded the ATSPI-stubbed suite (native/computer-use-linux/set_value_test.py, credit tip a0d9c0547) onto #10586 at 6a6c4125a and confirmed 3/3 locally. Single merge path from here: #10586.

Thanks for consolidating on the older probe PR — exactly the outcome we wanted.

@bbingz bbingz closed this Aug 7, 2026
@innocarpe

Copy link
Copy Markdown
Contributor

Thanks @bbingz for closing as duplicate and for the ATSPI suite — much cleaner single path on #10586.

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.

[Bug]: Orca's computer use set-value fails with 'Accessible' object has no attribute 'is_editable_text' on Linux Mint 22.3 x86_64 (Ubuntu 24.04)

4 participants