From e358dd39535b7c3c6f58084a0eebcaabc5a636cb Mon Sep 17 00:00:00 2001 From: DavertMik Date: Thu, 4 Jun 2026 12:40:54 +0300 Subject: [PATCH] Require Tester to try visualClick on visible elements when locators fail When a click or locator repeatedly fails (not found, timeout, intercepted) on a target that is visible on the page, the Tester must now attempt visualClick at least once before re-researching, switching targets, or concluding the element is unreachable. The prior rule was a soft "use as fallback" and got skipped, letting the Tester exhaust broken locators and wrongly decide a visible control did not exist. Co-Authored-By: Claude Opus 4.8 --- CHANGELOG.md | 5 +++++ src/ai/tester.ts | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index eeb13b6..1d3a1a8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## 2026-06-04 + +### Changes +- [Tester] When a click or locator keeps failing on a button or link that is plainly visible on the page, the Tester now always tries clicking it by its visual appearance at least once before re-researching, switching targets, or deciding the element is unreachable. Previously it could exhaust broken locators and wrongly conclude a visible control did not exist. + ## 2026-06-03 ### Changes diff --git a/src/ai/tester.ts b/src/ai/tester.ts index 65961e4..bb634b7 100644 --- a/src/ai/tester.ts +++ b/src/ai/tester.ts @@ -750,7 +750,7 @@ export class Tester extends TaskAgent implements Agent { - When filling complex form with lot of actions performed, use see() to look which fields were filled and which are not - When verify() fails, use see() to visually confirm the result — visual confirmation is equally valid evidence - For visual state verification (active tabs, selected items, counts, colors), prefer see() over DOM-based verify() - - When click() fails and element is visually present, use visualClick() as fallback + - When click() fails on an element you can see — or believe is there but may look different — you MUST try visualClick() before giving up; don't repeat visualClick in a row - If you land on a "Not Found", 404, or error page that is NOT part of the scenario, call reset() immediately to return to the initial page and try again - If you see a server error page (500, 503, etc.), record it with record({ notes: ["Server error on /path"], status: "fail" }) and call reset() to continue testing