Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "world-monitor",
"private": true,
"version": "2.5.18",
"version": "2.5.19",
"license": "AGPL-3.0-only",
"type": "module",
"scripts": {
Expand All @@ -28,6 +28,7 @@
"test:e2e:runtime": "VITE_VARIANT=full playwright test e2e/runtime-fetch.spec.ts",
"test:e2e": "npm run test:e2e:runtime && npm run test:e2e:full && npm run test:e2e:tech && npm run test:e2e:finance",
"test:data": "node --test tests/*.test.mjs",
"test:feeds": "node scripts/validate-rss-feeds.mjs",
"test:sidecar": "node --test src-tauri/sidecar/local-api-server.test.mjs api/_cors.test.mjs api/youtube/embed.test.mjs api/cyber-threats.test.mjs api/usni-fleet.test.mjs scripts/ais-relay-rss.test.cjs api/loaders-xml-wms-regression.test.mjs",
"test:e2e:visual:full": "VITE_VARIANT=full playwright test -g \"matches golden screenshots per layer and zoom\"",
"test:e2e:visual:tech": "VITE_VARIANT=tech playwright test -g \"matches golden screenshots per layer and zoom\"",
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "world-monitor"
version = "2.5.18"
version = "2.5.19"
description = "World Monitor desktop application"
authors = ["World Monitor"]
edition = "2021"
Expand Down
22 changes: 22 additions & 0 deletions src-tauri/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1163,6 +1163,28 @@ fn main() {
eprintln!("[tauri] VM detected; disabled WebKitGTK accelerated compositing for iframe/video compatibility");
}

// NVIDIA proprietary drivers often fail to create a surfaceless EGL
// display (EGL_BAD_ALLOC) in WebKitGTK's web process, especially on
// Wayland where explicit sync can also cause flickering/crashes.
// Detect NVIDIA by checking for /proc/driver/nvidia (created by
// nvidia.ko) and apply Wayland-specific workarounds.
let has_nvidia = std::path::Path::new("/proc/driver/nvidia").exists();
if has_nvidia {
if env::var_os("__NV_DISABLE_EXPLICIT_SYNC").is_none() {
unsafe { env::set_var("__NV_DISABLE_EXPLICIT_SYNC", "1") };
}
// Force X11 backend on NVIDIA + Wayland to avoid surfaceless EGL
// failures. Users who prefer native Wayland can override with
// GDK_BACKEND=wayland.
if env::var_os("WAYLAND_DISPLAY").is_some() && env::var_os("GDK_BACKEND").is_none() {
unsafe { env::set_var("GDK_BACKEND", "x11") };
eprintln!(
"[tauri] NVIDIA GPU + Wayland detected; forcing GDK_BACKEND=x11 to avoid EGL_BAD_ALLOC. \
Set GDK_BACKEND=wayland to override."
);
}
}

// On Wayland-only compositors (e.g. niri, river, sway without XWayland),
// GTK3 may fail to initialise if it defaults to X11 backend first and no
// DISPLAY is set. Explicitly prefer the Wayland backend when a Wayland
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"$schema": "https://schema.tauri.app/config/2",
"productName": "World Monitor",
"mainBinaryName": "world-monitor",
"version": "2.5.18",
"version": "2.5.19",
"identifier": "app.worldmonitor.desktop",
"build": {
"beforeDevCommand": "npm run build:sidecar-sebuf && npm run dev",
Expand Down