-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[BUG] IP:PORT Proxy doesnt work on playwright-firefox #3233
Comments
@sentoxaio the following works for me (with my personal proxy): const {chromium, webkit, firefox} = require('playwright');
(async () => {
const browser = await firefox.launch({
headless: false,
proxy: {
server: 'http://40.112.209.181:3128',
username: process.env.PROXY_USERNAME,
password: process.env.PROXY_PASSWORD,
},
});
const page = await browser.newPage();
await page.goto('https://example.com');
})(); Maybe something else is going wrong? |
@aslushnikov I am talking about proxies without an authentication (password & username). |
Indeed, proxies with user:pass authentication work well on playwright-firefox but proxies without user:pass authentication don't. |
@sentoxaio, @FoonkG: I tried with a local charles proxy running on The script with playwright const {chromium, webkit, firefox} = require('playwright');
(async () => {
const browser = await firefox.launch({
headless: false,
proxy: {
server: 'http://127.0.0.1:8888'
},
});
const page = await browser.newPage();
await page.goto('https://example.com');
})(); Any more details to help me reproduce this? |
FYI: current |
The problem also might be not adding http:// in front of the proxy ip:port |
Yeah, protocol is pretty important! This way you can specify both regular (HTTP) and Secure (HTTPS) web proxies. |
Ah, now I understand! We have a shortform in the documentation that doesn't actually work for firefox. We'll fix this. |
Short notation implies `http://` scheme. Fixes microsoft#3233
Short notation implies `http://` scheme. Fixes microsoft#3233
Short notation implies `http://` scheme. Fixes #3233
Code Snippet
Orginal Error:
It seems like that ip:port proxies don't work with playwright-firefox.
When you put http:// before it the browser starts, but throws
this error:
The text was updated successfully, but these errors were encountered: