Auto-recording idle rollover ignores actions with dropped frames

Author: XalzerophCreated Sep 23, 2026Updated Sep 23, 2026

Automatic recording rollover currently measures idle time from the newest JPG frame.

When screenshot capture fails, _capture() still writes the action to events.jsonl with frame_error, but no JPG is created. In that state the recording never becomes stale if it has no frames, or can become stale too early if the most recent actions failed after an older successful frame.

The idle boundary should track the latest recorded action. events.jsonl is updated for both successful and failed captures, with JPG mtime only as a fallback for older/incomplete recordings.

Source: browser-use/browser-harness