So it seems that the device toolbar usually present in any regular DevTools instance is missing when inspecting a remote instance.
And in such cases the device type is set to "Mobile", with the mouse pointer set to a circle, as to indicate that.
Here's how to reproduce this:
start a new headless instance, e.g., with:
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --remote-debugging-port=9222 --headless https://example.com
using another Chrome instance navigate to
chrome://inspect
and inspect the remote tab.as you can see there is no device toolbar.
I also tried to send some Chrome DevTools Protocol commands like:
But to no avail, something happens but the behavior looks broken... I suspect that this is something concerning the DevTools frontend, and not the inspected Chrome instance.
Do you have any idea about how can I work around this? My ultimate goal is to manually interact with a remote headless instance using a desktop device type.
Not sure since when, but in version 121.0.6167.139 a new switch appeared.