question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[BUG] cant create webkit context

See original GitHub issue

Context:

  • Playwright Version: 0.14.0
  • Operating System: Fedora 31
  • Node: v11.15.0

Code Snippet

I just used snippet from README.md

const playwright = require('playwright');

(async () => {
  for (const browserType of ['chromium', 'firefox', 'webkit']) {
    const browser = await playwright[browserType].launch();
    const context = await browser.newContext();
    const page = await context.newPage();
    await page.goto('http://whatsmyuseragent.org/');
    await page.screenshot({ path: `example-${browserType}.png` });
    await browser.close();
  }
})();

Describe the bug

It creates firefox and chrome screenshots, then falls:

$ node test.js
[(node:13203) UnhandledPromiseRejectionWarning: Error: Protocol error (Playwright.createContext): Browser has been closed.
    at Promise (/home/Lightgazer/etc/code/playwright/node_modules/playwright-core/lib/webkit/wkConnection.js:102:63)
    at new Promise [(<anonymous>)]
    at WKSession.send (/home/Lightgazer/etc/code/playwright/node_modules/playwright-core/lib/webkit/wkConnection.js:101:16)
    at WKBrowser.newContext (/home/Lightgazer/etc/code/playwright/node_modules/playwright-core/lib/webkit/wkBrowser.js:65:65)
    at WKBrowser.<anonymous> (/home/Lightgazer/etc/code/playwright/node_modules/playwright-core/lib/helper.js:64:31)
    at /home/Lightgazer/etc/code/playwright/test.js:6:35
(node:13203) 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(). (rejection id: 1)
(node:13203) [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.]

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:4
  • Comments:17 (6 by maintainers)

github_iconTop GitHub Comments

3reactions
aslushnikovcommented, Aug 21, 2020

Operating System: Fedora 31

@Lightgazer fedora is not officially supported atm, so build’s crashing.

I’m using focal (20.04), there’s not libvpx5 package too since it’s been superseded by libvpx5.

@thisguychris Focal (Ubuntu 20.04) is now officially supported since Playwright v1.3.0

Is it possible to statically link all dependencies to each browser executable (or bundle them within their directories) , for better sandboxing?

@Philipp-M all our attempts here failed so far.


Everybody: Playwright v1.3.0 features a “launch doctor” that should print a nice error when some of the browsers miss a dependency and thus cannot launch. Hopefully, this should help battling the dependencies!

3reactions
anoop0567commented, May 14, 2020

Hi, same error on Ubuntu 19.10

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bug #1966418 “[jammy regression] webkit apps do not display ...
Starting it up from the command line shows this output: ``` EGLDisplay Initialization failed: EGL_NOT_INITIALIZED Cannot create EGL context: ...
Read more >
Error creating WebGL context. Three js chrome?
I perform extensive, continuous testing. As I modify live settings in Chrome Inspector, THREE does not reflect all changes without fail. Memory ...
Read more >
231423 – SIGSEGV when creating WebGL context in Safari ...
Summary: SIGSEGV when creating WebGL context in Safari 15.0, crashes tab ... You need to log in before you can comment on or...
Read more >
WKWebView doesn't show from the be… - Apple Developer
The problem is that WKWebView can't do anything until the view is properly loaded and initialized. You might want to move the "load..."...
Read more >
357296 - Remove "webkit-3d" context type - chromium
The following revision refers to this bug: ... Removed the ability to create WebGL contexts with 'webkit-3d' BUG=357296
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found