Describe the bug
Since GNOME 3.36 (which enabled sandboxing in epiphany) I would often see this crash in epiphany
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot create EGL context: invalid display (last error: EGL_SUCCESS)
** (epiphany:26790): WARNING **: 22:25:48.939: Web process crashed
and I can still reproduce this in GNOME 3.38.
Quite honestly epiphany in NixOS is broken. And it seems to be related to sandboxing and probably an issue in webkitgtk itself.
To Reproduce
Steps to reproduce the behavior:
Notify maintainers
@NixOS/gnome
Maintainer information:
# a list of nixpkgs attributes affected by the problem
attribute: gnome3.epiphany
# a list of nixos modules affected by the problem
module:
IIRC this was always broken #32580, I do not see how sandboxing could make it any worse :smirk_cat:
Interesting, when I first used epiphany in NixOS it actually worked fine (I stick to intel and amd graphics). I believe it was in 3.36 that I noticed that it became unusable. Though, the issue you mentioned seems to show the same output, but it was just for NVIDIA users (with the time gap between https://github.com/NixOS/nixpkgs/issues/32580#issuecomment-427537835). I think it might be reasonable to assume that crash outputs in that bug report and this one are just red herrings. And epiphany doesn't give any useful output without extra switches?
I will look at WEBKIT_DISABLE_COMPOSITING_MODE=1, though.
Maybe it actually is the acceleration https://gitlab.gnome.org/search?group_id=8&project_id=1906&repository_ref=master&scope=commits&search=acceleration&snippets=false
I tried toggling different values that are supposed to change it in epiphany (with the wrapper exports dumped into the terminal env) https://wiki.archlinux.org/index.php/GNOME/Web#Hardware_accelerated_compositing and it didn't seem to prove a difference.
It seemed that, at the time of gnome 3.36 it was these bugs that were the issues https://gitlab.gnome.org/GNOME/epiphany/-/issues/1132 https://gitlab.gnome.org/GNOME/epiphany/-/issues/1128 (the bugs in webkitgtk that got reported got commit fixes though). I guess I should try to get a trace, though with https://wiki.gnome.org/Community/GettingInTouch/Bugzilla/GettingTraces and separateDebugInfo how exactly do I get all the symbols?
separateDebugInfohow exactly do I get all the symbols?
IIRC, you need to add separateDebugInfo to the library in the closure of Epiphany, and then also install the same library to environment.systemPackages for the debug info to be picked up by gdb.
Able to reproduce pretty reliably just by going to facebook.com (not logged in).
❯ epiphany
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot create EGL context: invalid display (last error: EGL_SUCCESS)
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot create EGL context: invalid display (last error: EGL_SUCCESS)
** (epiphany:17980): WARNING **: 22:07:05.504: Web process crashed
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
❯ env WEBKIT_DISABLE_COMPOSITING_MODE=1 epiphany
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot create EGL context: invalid display (last error: EGL_SUCCESS)
** (epiphany:18387): WARNING **: 22:09:11.576: Web process crashed
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
Cannot get default EGL display: EGL_BAD_PARAMETER
❯ lspci | grep -i graphics
00:02.0 VGA compatible controller: Intel Corporation Skylake GT2 [HD Graphics 520] (rev 07)
❯ nix-info -m
- system: `"x86_64-linux"`
- host os: `Linux 5.8.14, NixOS, 21.03pre246543.24c9b05ac53 (Okapi)`
- multi-user?: `yes`
- sandbox: `yes`
- version: `nix-env (Nix) 2.3.7`
- channels(root): `"nixos-21.03pre246543.24c9b05ac53, home-manager"`
- channels(austin): `"home-manager"`
- nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`
Yay, found a way to confirm this is a NixOS specific issue. I installed epiphany with flatpak and it works without this crash.
Still the same issue after Gnome 3.38 upgrade.