Hyprland icon indicating copy to clipboard operation
Hyprland copied to clipboard

Hyprland crashes when using kvm switch

Open mgbowe1 opened this issue 3 years ago • 7 comments

When I switch from my desktop to my laptop on my kvm switch hyprland (running on my desktop) crashes. This is repeatable behavior. I'm not sure if the crash happens after I switch from the desktop, or when I switch back. The kvm I'm using does not send EDID data.

I know this use case works on GNOME on wayland, so a fix is most likely possible. Environment is Arch linux using the hyprland-nvidia-git AUR package and the recommended nvidia modifications from the wiki https://wiki.hyprland.org/Nvidia/

Reproduction steps:

  1. be connected to a kvm switch running hyprland
  2. switch the kvm to a different input
  3. switch the kvm back to hyprland system

Expected Result:

hyprland is still running and the system hasn't been kicked back to the login manager

Actual Result:

system has been kicked back to the display manager and hyprland is not running

Note:

I'm submitting this issue without logs temporarily as I need to reproduce the issue and collect them. I'll add them as a comment when I'm finished collecting them.

Please consult the issue guidelines at https://github.com/vaxerski/Hyprland/blob/main/docs/ISSUE_GUIDELINES.md BEFORE submitting.

mgbowe1 avatar Oct 21 '22 17:10 mgbowe1

tmphyprlog-for-bug-report.log Attached logs

mgbowe1 avatar Oct 21 '22 17:10 mgbowe1

I know this use case works on GNOME on wayland

ha-ha. That doesn't mean anything. Test with sway / wayfire.

vaxerski avatar Oct 21 '22 17:10 vaxerski

Thanks for the response, I'll try sway to see if the issue is present there.

I was able to replicate the issue without actually switching the kvm. It seems to be a crash when a monitor is plugged in while hyprland is running.

Here's updated reproduction steps:

  1. use multiple monitors
  2. unplug one monitor's display cable (note that the workspaces will actually move to the other monitor)
  3. plug the display cable back in, hyprland will crash and you'll either be in a tty or your login manager.

mgbowe1 avatar Oct 21 '22 18:10 mgbowe1

I am having this issue too with latest git when switching my kvm. Sway is fine. Also replicated it by just turning both monitors off, no kvm or unplug needed, just turn them off and wait a little bit.

ferrreo avatar Dec 08 '22 13:12 ferrreo

give a coredump then

vaxerski avatar Dec 08 '22 18:12 vaxerski

Ah I don't use systemd so that might be a pain, will try get one though

ferrreo avatar Dec 08 '22 19:12 ferrreo

on all systems coredumps should be stored somewhere. If you find the dump file, you can use gdb to load it against the compiled binary. Then just bt -full

vaxerski avatar Dec 08 '22 19:12 vaxerski

Got the same issue, pretty sure this is the correct coredump using hyprland-git r2704.801a1719-1

dump.tar.gz

iraizo avatar Apr 08 '23 22:04 iraizo

if you're using a modern hl ver then pass me the crash report from ~/.hyprland or $XDG_CACHE_DIR/hyprland if you have the cache dir set.

vaxerski avatar Apr 08 '23 22:04 vaxerski

hyprlandCrashReport93109.txt

here you go

iraizo avatar Apr 09 '23 00:04 iraizo

haha almost the same shit as #804

vaxerski avatar Apr 09 '23 00:04 vaxerski

haha almost the same shit as #804

Looks like it, if i can somehow help debugging/fixing this let me knoww

iraizo avatar Apr 09 '23 00:04 iraizo

hyprlandd.log hyprlandCrashReport5652.txt

I did a debug build against 5e577ac (latest commit at time of writing) and have attached my log and crash report.

This is unfortunately making hyprland nearly unusable for me, as KVM switch usage is a critical part of my workflow, so I'm highly motivated to help out getting this fixed. Please let me know if there's any more information I can provide or anything else my hasn't-touched-C++-in-a-decade ass can do to help out

nmccarty avatar Jul 12 '23 20:07 nmccarty

After 629e61c I am pleased to announce that hyprland now survives kvm switch usage for me

:tada: :tada: :tada:

nmccarty avatar Jul 22 '23 22:07 nmccarty