sway icon indicating copy to clipboard operation
sway copied to clipboard

Input spam and 100% CPU usage

Open kuon opened this issue 1 year ago • 3 comments

Since I upgraded to Sway 1.9, wlroot 0.17.3, libinput 1.25.0, kernel 6.9.1 my system is unresponsive when I am in a text input.

For example, in firefox, in the URL input, the border blinks and I have 100% CPU usage, in my terminal emulator too.

If I launch wev and focus my kitty terminal, I have an output like below that spams very fast.

I am not sure the issue actually comes from sway, but I am wondering if you have any idea how to debug this.

Cheers

[14:     wl_keyboard] repeat_info: rate: 25 keys/sec; delay: 600 ms
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64732
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64732
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64754
[14:     wl_keyboard] repeat_info: rate: 25 keys/sec; delay: 600 ms
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64732
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64732
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64754
[14:     wl_keyboard] repeat_info: rate: 25 keys/sec; delay: 600 ms
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64732
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64732
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64754
[14:     wl_keyboard] repeat_info: rate: 25 keys/sec; delay: 600 ms
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64732
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64732
[14:     wl_keyboard] keymap: format: 1 (xkb v1), size: 64754

kuon avatar May 21 '24 23:05 kuon

Your bug report is missing debug logs. Please add a link to the full debug log file.

sway -d >sway.log 2>&1

emersion avatar May 22 '24 07:05 emersion

I'm sorry, It was late and I guess I was very tired.

sway.log

After looking at the log today with a fresh brain, I realize it could be caused by fcitx (between line 2500 and 4000 we see virtual keyboard added/removed), and after killing fcitx the issue was solved.

I might be hitting this https://github.com/fcitx/fcitx5/issues/1044

I leave this open if there is anything that can be done on sway side, but if you confirm this is not a sway issue, I let you close it.

Cheers

kuon avatar May 22 '24 09:05 kuon

@kuon Thanks a lot. I have been struggling on this whole day.

akhiljalagam avatar Jun 19 '24 13:06 akhiljalagam

The commit that supposedly fixes this has been merged. This can be re-opened if still an issue.

Nefsen402 avatar Jul 29 '24 19:07 Nefsen402