In the event that the page is controlled by the DevTools protocol (webdriver), userAgentData exists but lacks information. For example, when running Playwright after a clean installation using npx playwright test, you may encounter the following error:
Uncaught TypeError: Cannot read properties of undefined (reading 'brand')
at collector (rum:1:16120)
at rum:1:20575
at sentryWrapped (helpers.ts:77:19)
As for the behavior of the navigator.userAgentData API, it returns:
In the event that the page is controlled by the DevTools protocol (webdriver), userAgentData exists but lacks information. For example, when running Playwright after a clean installation using
npx playwright test
, you may encounter the following error:As for the behavior of the
navigator.userAgentData
API, it returns: