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
I'm noticing that some websites are returning page.goto: net::ERR_HTTP2_PROTOCOL_ERROR error when running in headless mode, but works fine in headful mode.
I suspect that they employ some anti-bot measures that are detecting this in headless mode.
Do you have any ideas or recommendations to make this work in headless mode when an HTTP2 protocol error is returned?
Thanks!
Edit:
I found that setting userAgent via context helps avoid the HTTP2 protocol error and the navigation succeeds, but once I add anything extra into the context, their Kasada kicks in and responds with 429 (even in headful mode). I've only been able to successfully use this if I don't add anything extra and use this as-is in headful mode only.
For example this worked avoid the HTTP2 error, but once on the website I get 429 response when trying to reach their login endpoint in both headless and headful:
constcontext=awaitbrowser.newContext({userAgent: 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36',});
The text was updated successfully, but these errors were encountered:
Currently, we consider headless patching to be almost impossible without patching chromium or major os hook patching.
Id recommend you to just use headful, or emulating displays for example with Xvfb on Linux.
Hi,
I'm noticing that some websites are returning
page.goto: net::ERR_HTTP2_PROTOCOL_ERROR
error when running in headless mode, but works fine in headful mode.Here are just a couple websites that do this:
https://disneycruise.disney.go.com
https://www.countdown.co.nz
We can use this simple example to reproduce:
I suspect that they employ some anti-bot measures that are detecting this in headless mode.
Do you have any ideas or recommendations to make this work in headless mode when an HTTP2 protocol error is returned?
Thanks!
Edit:
I found that setting userAgent via context helps avoid the HTTP2 protocol error and the navigation succeeds, but once I add anything extra into the context, their Kasada kicks in and responds with 429 (even in headful mode). I've only been able to successfully use this if I don't add anything extra and use this as-is in headful mode only.
For example this worked avoid the HTTP2 error, but once on the website I get 429 response when trying to reach their login endpoint in both headless and headful:
The text was updated successfully, but these errors were encountered: