Production data analysis (BU2, 24h) shows:
- 36.5% of consecutive failures are AsyncIO CancelledError in get_browser_state_summary
- Complex pages can take 30-60s for DOM extraction alone
- 30s timeout was too aggressive for heavy pages
60s provides 2x buffer while still catching genuinely stuck requests.
Can be overridden via TIMEOUT_BrowserStateRequestEvent env var.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
CDP's dispatchKeyEvent doesn't trigger beforeinput events that Draft.js
relies on for text input. This causes the first character to be dropped.
Solution: Detect Draft.js editors via specific DOM attributes (DraftEditor
class, data-contents, data-block, data-offset-key) and prepend a sacrifice
space character that Draft.js will drop, preserving the actual text.
playwright 1.57.0 installs chromium to $playwright_path/chromium-*/chrome-linux64/, causing the existing paths to fail to find the browser. globing chrome-linux* will allow watchdog to find playwright installed 32-bit and 64-bit chromium.
- Add ClickCoordinateEvent to handle coordinate-based clicking via CDP
- Replace broken page.mouse.click() with CDP Input.dispatchMouseEvent
- Add safety checks for file inputs, select elements, and print dialogs
- Add get_dom_element_at_coordinates() to BrowserSession for element detection
- Add force parameter to ClickElementAction to optionally skip safety checks
- Update _click_by_coordinate to dispatch ClickCoordinateEvent instead of using mouse
This fixes coordinate clicking functionality by using CDP directly instead of
the broken Actor mouse object, matching the implementation from mert/everything_coordinates.