WebKitWebProcess error

Hello,

When I try to use a program on the container that uses the GtkWebKit2 I get this error:

(WebKitWebProcess:14579): Gdk-ERROR **: 20:05:32.533: The program ‘WebKitWebProcess’ received an X Window System error.
This probably reflects a bug in the program.
The error was ‘BadValue (integer parameter out of range for operation)’.
(Details: serial 217 error_code 2 request_code 151 (GLX) minor_code 34)
(Note to programmers: normally, X errors are reported asynchronously;
that is, you will receive the error a while after causing it.
To debug your program, run it with the GDK_SYNCHRONIZE environment
variable to change this behavior. You can then get a meaningful
backtrace from your debugger if you break on the gdk_x_error() function.)

So, in order to reproduce, create a container, install devhelp, and the docs you want, toolbox run -c container devhelp

The application open without problems, but when you select any topic, the message appears. Devhelp remains working though.

This only happens with NVIDIA proprietary drivers. Can someone help me?

Hello @arxcruz,
Are you running a Gnome session in Wayland? You could try to run Gnome in Xorg instead to see if the problem goes away.

I am using Xorg for sure because I am using NVIDIA proprietary drivers, when I’m using nouveau drivers with wayland, it works fine, however, I get problem with external monitor when my computer hybernate, the external monitor doesn’t come up again, so the workaround is change the frequency and cancel. Since this is very annoying and I wasn’t able to find anything to fix it, I prefer to use the proprietary driver.

Ah yes, the Nvidia proprietary drivers are Xorg only, I’ll see if I can get something reproduced on my PC.

In a simple C code you can also see the problem, if you run this code, it will shows a window saying the browser can’t recognize any video format, but when you right click and select copy debug info, it fails with the same problem as well.

#include <gtk/gtk.h>
#include <webkit2/webkit2.h>

static void activate(GtkApplication *app, gpointer user_data);

int main(int argc, char **argv)
{
    GtkApplication *app;
    int status;

    app = gtk_application_new("org.test.test", G_APPLICATION_FLAGS_NONE);
    g_signal_connect(app, "activate", G_CALLBACK(activate), NULL);
    status = g_application_run(G_APPLICATION(app), argc, argv);
    g_object_unref(app);
    return status;
}

static void activate(GtkApplication *app, gpointer user_data)
{
    GtkWidget *window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
    WebKitWebView *web_view;

    gtk_application_add_window(app, GTK_WINDOW(window));

    gtk_window_set_position(GTK_WINDOW(window), GTK_WIN_POS_CENTER);
    gtk_window_set_default_size(GTK_WINDOW(window), 400, 400);
    gtk_window_set_title(GTK_WINDOW(window), "Demo");

    web_view = WEBKIT_WEB_VIEW(webkit_web_view_new());

    gtk_container_add(GTK_CONTAINER(window), GTK_WIDGET(web_view));

    gtk_widget_set_size_request(window, 100, 100);
    webkit_web_view_load_uri(web_view, "https://www.youtube.com/embed/?v=vCoF21OXu2E");
    gtk_widget_show_all(window);
}

gcc demo.c -o demo `pkg-config --libs --cflags gtk±3.0 webkit2gtk-4.0

BadValue (integer parameter out of range for operation) may happen when the application tries to access a shm from the host (e.g. podman run --ipc host). It seems like https://github.com/debarshiray/toolbox/pull/171 should fix the issue, but it’s only in master for now, >0.0.10.

Did not work, same problem…

Any ideas? I really wanted to have this working on Silverblue, I’m almost switching to normal Fedora. Also, Devhelp doesn’t work from the container because of the same problem…

Managed to easily reproduce it (with you demo app) and passed the info to upstream - https://bugs.webkit.org/show_bug.cgi?id=199666.