NilsBrause / waylandpp

Wayland C++ bindings
https://nilsbrause.github.io/waylandpp_docs/
Other
82 stars 26 forks source link

Examples fail at runtime: interface 'wl_surface' has no event 2 #82

Open skligys opened 7 months ago

skligys commented 7 months ago

After upgrading to Sway 1.9 a few days ago, examples started failing at runtime. They used to run fine before the upgrade.

# ./shm
interface 'wl_surface' has no event 2
terminate called after throwing an instance of 'std::system_error'
  what():  wl_display_dispatch: No such file or directory
Aborted (core dumped)
# ./egl
interface 'wl_surface' has no event 2
terminate called after throwing an instance of 'std::system_error'
  what():  wl_display_dispatch: Resource temporarily unavailable
Aborted (core dumped)
wilypomegranate commented 7 months ago

This seems to be directly related to this issue

https://github.com/NilsBrause/waylandpp/issues/77

By putting in a new wayland.xml and xdg-shell.xml and recompiling, everything works.(At least on my arch box)

skligys commented 7 months ago

Thanks, building from your branch fixed it: https://github.com/wilypomegranate/waylandpp

It looks that the owner is not approving any PRs?

wilypomegranate commented 7 months ago

After a little investigation and reading wayland docs, I don't think binding to the registry should use what the server sends back since this is the maximum version that the server supports. I'd think instead that clients should use what version they know about and decide on whether to continue.