Expand description
Resolve block_id → CDP target id.
CEF’s /json endpoint exposes every active page target but does
NOT expose the underlying cef::Browser::identifier(), so we can’t
match by CEF id directly. Phase 1 strategy:
- Ask the pane manager for the pane’s current URL.
- Probe
GET http://127.0.0.1:<debug>/json. - Find the entry whose
urlmatches the pane’s URL AND whoseidisn’t already owned by some other cached block. - Cache
(block_id → target_id)for subsequent calls.
Known limit: two panes navigated to the same URL can’t be
distinguished this way. Phase-1 consumers (dom-smoke, stress
harness) use distinct URLs to avoid the collision. A later phase
can swap in a snapshot-at-create strategy for bulletproof
one-to-one mapping (see SPEC_BROWSER_DOM_API.md §5.5).