-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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] Cannot open file:// URLs with Firefox #822
Comments
Thanks, I can repro! In the snippet below, const playwright = require('playwright');
const path = require('path');
(async () => {
for (const type of ['chromium', 'webkit', 'firefox']) {
const browser = await playwright[type].launch();
const context = await browser.newContext();
const page = await context.newPage();
console.log(`${type}: goto`);
await page.goto(`file:${path.join(__dirname, 'foobar.html')}`);
console.log(`${type} -> ${await page.evaluate(() => document.body.textContent)}`);
await browser.close();
}
})(); |
@aslushnikov ^^ |
pavelfeldman
changed the title
[BUG]Cannot open a local html file with firefox
[BUG] Cannot open file:// URLs with Firefox
Feb 5, 2020
Just encountered the same issue: https://github.com/aesyondu/javascript-questions/tree/tmp/playwright-sample snippet: const path = require("path")
const { firefox } = require("playwright-firefox");
const { chromium } = require("playwright-chromium");
const { webkit } = require("playwright-webkit");
(async () => {
const browser = await firefox.launch({ headless: false })
// const browser = await chromium.launch({ headless: false })
// const browser = await webkit.launch({ headless: false })
const context = await browser.newContext()
context.setDefaultTimeout(9999999)
const page = await context.newPage()
await page.goto(`file:${path.join(__dirname, "index.html")}`) // 2. firefox not resolving page.goto file:
console.log("FIREFOX not outputting this") |
aslushnikov
added a commit
to aslushnikov/playwright
that referenced
this issue
Feb 26, 2020
aslushnikov
added a commit
to aslushnikov/playwright
that referenced
this issue
Feb 26, 2020
aslushnikov
added a commit
to aslushnikov/playwright
that referenced
this issue
Feb 26, 2020
aslushnikov
added a commit
that referenced
this issue
Feb 26, 2020
sand4rt
pushed a commit
to sand4rt/playwright
that referenced
this issue
Dec 21, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Context:
Code Snippet
Help us help you! Put down a short code snippet that illustrates your bug and
that we can run and debug locally. For example:
Describe the bug
const page = await context.newPage(url);
will provoke a code freezeHere is a repo where you could reproduce the problem:
https://github.com/hdorgeval/playwright-controller (the purpose of this repo is to have the same features as exposed by the repo: https://github.com/hdorgeval/puppeteer-core-controller)
and the test in that repo is here:
https://github.com/hdorgeval/playwright-controller/blob/master/src/controller/tests/ctor/controller-ctor.test.ts at line 78
The text was updated successfully, but these errors were encountered: