Skip to content
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

wvkbd v0.14 and later crash on key press under Wayfire 0.7.4 #52

Open
kefabean opened this issue Nov 5, 2023 · 6 comments
Open

wvkbd v0.14 and later crash on key press under Wayfire 0.7.4 #52

kefabean opened this issue Nov 5, 2023 · 6 comments
Assignees
Labels
bug Something isn't working

Comments

@kefabean
Copy link

kefabean commented Nov 5, 2023

I was running the latest packaged version of wvkbd (v0.12) provided by which seemed to be working fine under latest available Wayfire (0.7.4) (Debian Bookworm on ARM64). However, I wanted to make some custom keyboard layouts so decided to modify and recompile from source.

I checked out the 0.14.3 tag and everything builds and installs successfully but I get the following 'client communication' error in Wayfire debug log when I press a key. I reverted all my changes and recompiled vanilla from the tag. Same issue. Tags v0.14, v0.14.1, v0.14.2 yield the same result but v0.12 and v0.13 are working fine.

Could this be a bug in wvkbd or is this more likely to be an issue running under wayfire?

DD 05-11-23 23:28:15.200 - [src/core/seat/pointer.cpp:120] change cursor focus 0xaaaaecb10dc8 -> 0xaaaaecb13728
DD 05-11-23 23:28:16.800 - [src/core/seat/pointer.cpp:120] change cursor focus 0xaaaaecb13728 -> 0xaaaaecb10dc8
DD 05-11-23 23:28:17.455 - [src/core/seat/pointer.cpp:120] change cursor focus 0xaaaaecb10dc8 -> 0xaaaaecb13728
DD 05-11-23 23:28:20.734 - [src/core/seat/pointer.cpp:120] change cursor focus 0xaaaaecb13728 -> 0xaaaaecb10dc8
DD 05-11-23 23:28:21.232 - [src/core/seat/pointer.cpp:120] change cursor focus 0xaaaaecb10dc8 -> 0xaaaaecb13728
II 05-11-23 23:28:21.864 - [wayland] error in client communication (pid 12786)
II 05-11-23 23:28:21.864 - [src/core/seat/input-manager.cpp:94] remove input: virtual keyboard
DD 05-11-23 23:28:21.864 - [src/core/seat/pointer.cpp:120] change cursor focus 0xaaaaecb13728 -> (null)
DD 05-11-23 23:28:21.864 - [src/core/core.cpp:595] focusing layer 0
@proycon
Copy link
Collaborator

proycon commented Nov 10, 2023

I tried wvkbd v0.14.3 on wayfire 0.8.0 and there it crashes immediately even:

Initializing keyboard
Found 54 layouts
Found 2 layers
Resize 2160x250 1.000000, 55 layouts
listener function for opcode 1 of wl_surface is NULL
[1]    8005 IOT instruction (core dumped)  ./wvkbd-mobintl

gdb trace:

#0  __pthread_kill_implementation
    (threadid=<optimized out>, signo=signo@entry=6, no_tid=no_tid@entry=0) at pthread_kill.c:44
#1  0x00007ffff78858a3 in __pthread_kill_internal (signo=6, threadid=<optimized out>)
    at pthread_kill.c:78
#2  0x00007ffff7835668 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
#3  0x00007ffff781d4b8 in __GI_abort () at abort.c:79
#4  0x00007ffff7f864f2 in wl_abort
    (fmt=fmt@entry=0x7ffff7f8b338 "listener function for opcode %u of %s is NULL\n")
    at ../wayland-1.22.0/src/wayland-util.c:462
#5  0x00007ffff7f86700 in wl_closure_invoke
    (closure=closure@entry=0x5555556c81d0, target=<optimized out>,
    target@entry=0x55555562dfc0, opcode=opcode@entry=1, data=<optimized out>, flags=1)
    at ../wayland-1.22.0/src/connection.c:1022
#6  0x00007ffff7f86e73 in dispatch_event
    (display=display@entry=0x5555556289d0, queue=0x555555628ac0)
    at ../wayland-1.22.0/src/wayland-client.c:1631
#7  0x00007ffff7f8713c in dispatch_queue (queue=0x555555628ac0, display=0x5555556289d0)
    at ../wayland-1.22.0/src/wayland-client.c:1777
#8  wl_display_dispatch_queue_pending (display=0x5555556289d0, queue=0x555555628ac0)
    at ../wayland-1.22.0/src/wayland-client.c:2019
#9  0x0000555555580ef1 in main (argc=1, argv=0x7fffffffd7c8) at main.c:1018

You said that v0.12 works fine, I wonder if the culprit is the fractional scaling support we added in v0.14 and whether that's implemented in wayfire (I also noticed a warning about that when launching 'foot').

This will need some deeper investigation.

@proycon proycon added the bug Something isn't working label Nov 10, 2023
proycon added a commit that referenced this issue Nov 10, 2023
This fixes "listener function for opcode 1 of wl_surface is NULL" error in wayfire 0.8.0

Ref: #52
@proycon
Copy link
Collaborator

proycon commented Nov 10, 2023

I implemented a fix for the issue I encountered above, after which wvkbd runs fine on the latest wayfire 0.8.0 .

However, this might not fix the original issue on wayfire 0.7.4. Could you give it a try?

@proycon proycon self-assigned this Nov 10, 2023
@kefabean
Copy link
Author

kefabean commented Nov 11, 2023

Brilliant, great news - glad to hear you managed to get it working under the latest Wayfire.

However, I just tried a quick recompile on Wayfire v0.7.4 and I'm getting the same issue. I'm trying to use the default distro versions of Wayfire as that's what most people will be using.

When I get a second I might also try running under Wayfire v0.7.5 which is what ships by default with the latest Raspberry Pi OS (and is the ultimate destination for my compiled binary).

(I'm compiling and testing under vanilla Debian Bookworm ARM64 (which uses Wayfire 0.7.4) under UTM on MacOS to speed up compile/test times).

@kefabean kefabean changed the title wvkbd v0.13 and later crash on key press under Wayfire 0.7.4 wvkbd v0.14 and later crash on key press under Wayfire 0.7.4 Jan 22, 2024
@proycon
Copy link
Collaborator

proycon commented Mar 3, 2024

Did you have more luck on v0.7.5? I hope RaspiOS switches to 0.8.0 soon then this issue would be solved.

@proycon
Copy link
Collaborator

proycon commented Mar 3, 2024

I released wvkbd v0.14.4 that should address this for at least wayfire 0.8.0

@kefabean
Copy link
Author

kefabean commented Mar 3, 2024

Unfortunately not yet. I've held back on the version of wvkbd I'm using until Raspberry Pi OS switches to Wayfire v0.8.0. Like you say, fingers crossed this will be soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants