Open ExpandingMan opened 5 months ago
webgpu loves to panic instead of allowing graceful failure. The root cause here is likely graphics driver specific. You mentioned nvidia; that is famously a PITA on linux.
It may be helpful to have you run debug non-stripped build so that the panic stack trace is a bit more informative.
It's possible that things are better in a more recent version of wgpu, but the last time we tried to upgrade it had a fatal memory leak.
Yeah, basically once nvidia driver 555 and linux 6.10 land on mainline manjaro I'm going to sit down one weekend and bang my head against the wall until I finally get nvidia wayland to work reliably. (Supposedly at that point it should "just work", but I have zero confidence in that, nvidia has been a gigantic pain in the ass with wayland.)
Once I get to the other side of that, assuming I survive with my sanity intact, if wezterm is still not working I will come back with a detailed report.
What Operating System(s) are you seeing this problem on?
Linux Wayland
Which Wayland compositor or X11 Window manager(s) are you using?
Hyprland
WezTerm version
wezterm 20240519-164007-6fe1d4d2
Did you try the latest nightly build to see if the issue is better (or worse!) than your current version?
Yes, and I updated the version box above to show the version of the nightly that I tried
Describe the bug
Panic on startup, dump below. This only happens with WebGPU, otherwise it hangs and I can't get it to do anything at all.
To Reproduce
wezterm
Configuration
local WezTerm = require("wezterm") local act = WezTerm.action
return { -- the WebGpu front-end uses vulkan; currently still has somewhat wonky text rendering front_end = "WebGpu", webgpu_power_preference = "HighPerformance", enable_tab_bar = false, color_scheme = "DraculaCorrect", --font = WezTerm.font{family="JuliaMono", assume_emoji_presentation=false}, font = WezTerm.font("JuliaMono"), default_cursor_style = "BlinkingBar", cursor_blink_rate = 400, cursor_thickness = "1.5pt", font_rules = { {italic=true, font=WezTerm.font("JuliaMono-MediumItalic")}, {intensity="Bold", font=WezTerm.font("JuliaMono-Bold")}, {intensity="Bold", italic=true, font=WezTerm.font("JuliaMono-BoldItalic")}, }, font_size = 12.0, window_padding = { left = 0, right = 0, top = 0, bottom = 0, },
}
Expected Behavior
Open window and run normally,
Logs
10:28:55.553 WARN window::os::wayland::connection > Unable to resolve appearance using xdg-desktop-portal: get_appearance.read_setting: Reading xdg-portal org.freedesktop.appearance color-scheme: org.freedesktop.DBus.Error.UnknownMethod: No such interface “org.freedesktop.portal.Settings” on object at path /org/freedesktop/portal/desktop 10:28:55.764 ERROR env_bootstrap > panic at /w/wezterm/wezterm/vendor/wgpu-0.18.0/src/backend/direct.rs:778:18 - !? 0:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22: libc_start_main
23:
thread 'main' panicked at /__w/wezterm/wezterm/vendor/wgpu-0.18.0/src/backend/direct.rs:778:18: Error in Surface::configure: Validation Error
Caused by: Parent device is lost
stack backtrace: note: Some details are omitted, run with
RUST_BACKTRACE=full
for a verbose backtrace. thread panicked while processing panic. aborting. fish: Job 1, './wezterm' terminated by signal SIGABRT (Abort)Anything else?
I had gotten the
xdg-desktop-portal
warning to go away by installingxdg-desktop-portal-hyprland
, but it comes back when I use the nightly appimage.Here is the dump it gives using
wezterm 20240203-110809-5046fc22
the binary of which I have installed via the package manager.Note that this is part of an ambitious attempt to hopefully finally, finally get nvidia wayland working with a WM. Most stuff seems to be working more-or-less out of the box on hyprland now, but I've had a few issues. This is one of them.