Как исправить ошибку прокси Playwright?

Промучался много времени, ошибку исправить так и не смог. Данные прокси менял много раз.

Код:
const browser = await firefox.launch({
			product: 'firefox',
			ignoreHTTPSErrors: true, 
			proxy: {
				server: `http://${proxy[i].ip}:${proxy[i].port}/`,
				user: username,
				password: password
			}
		});


Консоль:
(node:61465) UnhandledPromiseRejectionWarning: page.goto: net::ERR_TUNNEL_CONNECTION_FAILED at http://2ip.ru
=========================== logs ===========================
navigating to "http://2ip.ru", waiting until "load"
============================================================
Note: use DEBUG=pw:api environment variable to capture Playwright logs.
Error
    at Object.captureStackTrace (/home/daniil/Рабочий стол/JavaScript/app/node_modules/playwright/lib/utils/stackTrace.js:51:19)
    at Connection.sendMessageToServer (/home/daniil/Рабочий стол/JavaScript/app/node_modules/playwright/lib/client/connection.js:73:48)
    at Proxy.<anonymous> (/home/daniil/Рабочий стол/JavaScript/app/node_modules/playwright/lib/client/channelOwner.js:64:61)
    at /home/daniil/Рабочий стол/JavaScript/app/node_modules/playwright/lib/client/frame.js:100:65
    at Frame._wrapApiCall (/home/daniil/Рабочий стол/JavaScript/app/node_modules/playwright/lib/client/channelOwner.js:77:34)
    at Frame.goto (/home/daniil/Рабочий стол/JavaScript/app/node_modules/playwright/lib/client/frame.js:98:21)
    at /home/daniil/Рабочий стол/JavaScript/накрутка прослушиваний/node_modules/playwright/lib/client/page.js:267:60
    at Page._attributeToPage (/home/daniil/Рабочий стол/JavaScript/накрутка прослушиваний/node_modules/playwright/lib/client/page.js:202:20)
    at Page.goto (/home/daniil/Рабочий стол/JavaScript/app/node_modules/playwright/lib/client/page.js:267:21)
    at /home/daniil/Рабочий стол/JavaScript/app/app.js:27:14
(Use `node --trace-warnings ...` to show where the warning was created)
(node:61465) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:61465) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
  • Вопрос задан
  • 339 просмотров
Пригласить эксперта
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Войти через центр авторизации
Похожие вопросы