-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Freeze when scrolling fast between workspaces #892
Comments
I seem to be having similar freezes. Though, mine are not from scrolling between workspaces, but just switching between them using mod+num rapidly. |
Having the same issue here let me know what information I can provide to help fix this. |
The output of |
just wondering if it's possible to have the scrolling between work spaces feature something that can be toggled during compile time. :x |
I've debugged this issue. That's IPC problem. When user scrolls or clicks in swaybar, ipc_send_workspace_command is being called, which calls ipc_single_command, which waits for a reply and blocks swaybar thread until response from socket. But the response to this command not being sent by IPC server until all subscriptions processed. swaybar opens second socket for event processing and subscribes to workspace updates. Looks like when user scrolling too fast, buffer of event socket fills, which causes deadlock (sway cannot write to event socket because buffer is full, therefore cannot send response, and swaybar infinitely waits for this response). I'm not sure what is the best architectural solution. |
Probably best to change swaybar to avoid submitting so many IPC requests in a row. |
And update sway to avoid the deadlock |
Removed additional event socket to reduce synchronisation problems and limited workspace update requests count.
Sway freezes when I open multiple workspaces and then use the mousewheel in the bar to switch between them very quickly.
Setting
wrap_scroll
does not make a difference.I can not reproduce the issue when switching via bash like this (so I assume it's not the speed but something with the mousewheel):
The only options I have when the freeze happens is to hibernate the laptop using the power key (which does not help because it's still frozen when resuming) and to reboot.
Do you need additional information?
Versions (all Arch Linux packages):
sway version: 0.9-1:
wlc: 0.0.5-1
wayland: 1.11.0-1
sway.log.txt
Thanks for a awesome project :)
The text was updated successfully, but these errors were encountered: