playwright: [BUG] launchPersistentContext hanging on "about:blank" [REOPENED]

Context:

  • Playwright Version: 1.7.1
  • Operating System: Mac
  • Node.js version: v14.15.1
  • Browser: Chromium

Code Snippet

const {chromium} = require('playwright');

(async () => {
  const options = {
                  headless : false, 
                  userAgent: 'Mozilla/5.0 (iPhone; CPU iPhone OS 14_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/87.0.4280.77 Mobile/15E148 Safari/604.1'
                }

                const browser = await chromium.launchPersistentContext(`udd1`, options)
                var [page] = await browser.pages();
                await page.goto("https://www.google.com/");
})();

Describe the bug

Sometimes the browser hangs on “about:blank”. I’ve tested and it seems that if I even console.log(browser), then it doesn’t even log it when this occurs… The only way to get past this is to refresh the page by using CMD + R on my keyboard. I’m unsure why this is happening as it doesn’t occur every time I run my code. It seems as if the browser isn’t even launching as it doesn’t log.

https://github.com/microsoft/playwright/issues/4981

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 19

Commits related to this issue

Most upvoted comments

@bb1234cp thank you the repro steps! I was able to debug this to a nasty race condition on our side. Sorry for this taking so long!