S
S
Sergey Mironov2020-11-27 13:59:57
Node.js
Sergey Mironov, 2020-11-27 13:59:57

Why in puppeteer does the proxy work only on the second, third page refresh?

Set proxy for puppeteer:

const browser = await puppeteer.launch({
headless: false,
args:['--proxy-server=111.11.11.11:8080']
});


In most cases, it cannot enter the page the first time, it gives an error ERR_PROXY_CONNECTION_FAILED. But if you refresh the page several times, then everything is ok.
What could be wrong?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question