Xwayland keyboard inputs get constantly repeated after closing an application
Since upgrading to xwayland 22.1.4, I am having an issue where keys seem to get "stuck" in the Xwayland environment. I can consistently reproduce this problem using sway, Dolphin and sxiv, and visualize it using xev.
How to reproduce:
- Open Dolphin and xev
- Through Dolphin, open an image file using sxiv
- Press
q
to exit sxiv - Open an image file using sxiv again
- Notice that sxiv immediately closes
- Switch focus to xev
- Notice that xev is being spammed with KeyPress and KeyRelease events for
q
Other notes
- I have bisected this issue to commit 71e8be4e
- I can reproduce this issue in sway 1.7 and KDE Plasma 5.26.1, but not GNOME 42.5, which makes me think this might be related to #1392 (closed). I have attached a log I created following these instructions in that issue, although I wasn't able to run any Xwayland applications using this wrapper.