New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
page.setExtraHTTPHeaders cause 'ERR_INVALID_ARGUMENT' error #5077
Comments
I wonder if setting (resetting?) some headers is bad? |
fwiw, we started seeing this error when we upgraded to puppeteer 2.0.0. And like @danielabel said, it turned out to be because of a header we'd always been sending (Cookie2) making chrome barf. The fix was just to stop sending that header. |
We’re getting the same
Using |
Agreed with @agarzola, the |
FYI we've also encountered this error with Puppeteer 2.0 (not before) and when overriding header |
It seems that some headers cannot be set using setExtraHTTPHeaders. "Proxy-" cannot be set probably because that's a browser-wide setting and should be done by
others are Hop-by-hop headers that only make sense per-request https://www.freesoft.org/CIE/RFC/2068/143.htm (setExtraHTTPHeaders works per-tab and influences for example all XHR requests from that tab too). But it would be nice if Puppeteer returned a more helpful error message than just |
same issue |
same issue here, when I call |
Is there any workaround? |
If you want to pass proxy-authorization then use below code instead of
|
Thanks for replying me. Actually, I want to get workaround for |
Fix? |
I removed it, and then everything works |
I meant an error in principle, I think it is wrong that some arguments cannot be passed. |
We're marking this issue as unconfirmed because it has not had recent activity and we weren't able to confirm it yet. It will be closed if no further activity occurs within the next 30 days. |
We are closing this issue. If the issue still persists in the latest version of Puppeteer, please reopen the issue and update the description. We will try our best to accomodate it! |
Steps to reproduce
Tell us about your environment:
What steps will reproduce the problem?
What is the expected result?
go to the url success
What happens instead?
But, if I replace header
proxy-authorization
toproxyauthorization
, it's fine.So,it seems that it's not allowed containing '-' in header, is this corrent? Or is it an issue?
The text was updated successfully, but these errors were encountered: