← Back to Discord Forum

When opening `chrome-extension://${extensionId}/notification.html` the tab immediately closes

The extension is a Crypto Wallet. I understand the risks completely.

When I open the extension in a tab, for a flash of a second I can see some HTML being loaded in the devtools and then the tab closes.

The test code is:

await page.goto(extensionPagePath)
  await page.screenshot({ path: 'screenshot.png', fullPage: true })

The second line, the screenshot, gives this error:

Error: page.screenshot: Target closed

This thread is trying to answer question "Why does the tab immediately close when opening the Crypto Wallet extension in a tab and how to fix the 'Target closed' error when trying to take a screenshot?"

0 replies

Related Discord Threads

AboutQuestionsDiscord ForumBrowser ExtensionTagsQA Jobs

Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email luc@ray.run.