You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Restore hidden input delivery when an owned background lease is out of sync #355
PR #311 makes an owned background-execution lease safe when the target still reports document.visibilityState === "hidden": the input tool returns input_not_ready before dispatch instead of reporting a click that may not be delivered. This preserves the safety requirement from #242, but the input is not delivered in this edge case.
BackgroundExecution.has(sessionId, tabId) reports desired ownership. Its applied cache can still match the debugger attachment even if the actual Emulation.setFocusEmulationEnabled override was turned off outside that cache. A normal synchronize() call then skips reapplying the override.
Requested improvement
When a controlled input tool samples hidden while the session owns a persistent background lease, attempt to restore the override through BackgroundExecution itself, then wait for a renderer frame before dispatching. Do not enable or disable focus emulation directly from withInputReady, and do not activate the user's browser window. If readiness still cannot be established, keep returning input_not_ready with no input dispatched.
Acceptance criteria
A dispatcher-level test simulates an owned lease whose applied focus override was lost. A hidden-page click recovers through the lease owner, reaches the page, and leaves the override enabled for the next tool.
Activity
fix(input): restore a dropped background lease before hidden input