canonical / mir-kiosk-kodi

Snap packaging for Kodi
4 stars 1 forks source link

Fails to run on native shell #30

Closed AlanGriffiths closed 2 years ago

AlanGriffiths commented 2 years ago

Running on a Wayland shell (e.g. GNOME or egmde):

$ WAYLAND_DISPLAY=wayland-0 mir-kiosk-kodi
VA error: wayland: Wayland roundtrip error: Protocol error (errno 71)
libva info: VA-API version 1.7.0
libva error: vaGetDriverNameByIndex() failed with invalid VADisplay, driver_name = (null)
terminate called after throwing an instance of 'std::system_error'
  what():  wl_display_roundtrip_queue: Protocol error
Crash report available at /home/alan/snap/mir-kiosk-kodi/337/kodi_crashlog-20220506_084637.lo

Running on a nested shell (e.g. Frame or egmde):

$ WAYLAND_DISPLAY=wayland-99 mir-kiosk-kodi
libEGL warning: Wayland client render node authentication is unnecessary
libva info: VA-API version 1.7.0
libva info: Trying to open /snap/mir-kiosk-kodi/337/graphics/dri/iHD_drv_video.so
libva info: Found init function __vaDriverInit_1_7
libva info: va_openDriver() returns 0
libEGL warning: Wayland client render node authentication is unnecessary
...

kodi_crashlog-20220506_084637.log

kodi-wayland-debug.log

AlanGriffiths commented 2 years ago

Not sure when that started. Tried some recent versions but see the same problem.

AlanGriffiths commented 2 years ago

The WAYLAND_DEBUG log looks similar to the working run until:

...
[2263238.986] wl_drm@12.device("/dev/dri/renderD128")
[2263239.039]  -> wl_drm@12.authenticate(0)
[2263239.049] wl_drm@12.format(808669761)
[2263239.075] wl_drm@12.format(808669784)
[2263239.084] wl_drm@12.format(808665665)
[2263239.093] wl_drm@12.format(875713089)
[2263239.123] wl_drm@12.format(875713112)
[2263239.134] wl_drm@12.format(909199186)
[2263239.145] wl_drm@12.format(961959257)
[2263239.156] wl_drm@12.format(825316697)
[2263239.179] wl_drm@12.format(842093913)
[2263239.188] wl_drm@12.format(909202777)
[2263239.197] wl_drm@12.format(875713881)
[2263239.205] wl_drm@12.format(842094158)
[2263239.214] wl_drm@12.format(909203022)
[2263239.223] wl_drm@12.format(1448695129)
[2263239.233] wl_drm@12.capabilities(1)
[2263239.242] wl_callback@11.done(9015)
[2263239.252]  -> wl_display@1.sync(new id wl_callback@11)
[2263239.399] wl_display@1.error(wl_drm@12, 0, "authenticate failed")
VA error: wayland: Wayland roundtrip error: Protocol error (errno 71)

For reference, the working version:

...
[2538061.313] wl_drm@11.device("/dev/dri/renderD128")
[2538061.357]  -> wl_drm@11.authenticate(0)
[2538061.370] wl_drm@11.format(808669761)
[2538061.379] wl_drm@11.format(808669784)
[2538061.389] wl_drm@11.format(808665665)
[2538061.398] wl_drm@11.format(875713089)
[2538061.407] wl_drm@11.format(875713112)
[2538061.416] wl_drm@11.format(909199186)
[2538061.425] wl_drm@11.format(961959257)
[2538061.435] wl_drm@11.format(825316697)
[2538061.444] wl_drm@11.format(842093913)
[2538061.453] wl_drm@11.format(909202777)
[2538061.462] wl_drm@11.format(875713881)
[2538061.471] wl_drm@11.format(842094158)
[2538061.480] wl_drm@11.format(909203022)
[2538061.495] wl_drm@11.format(1448695129)
[2538061.505] wl_drm@11.capabilities(1)
[2538061.514] wl_callback@10.done(1)
[2538061.525]  -> wl_display@1.sync(new id wl_callback@10)
[2538061.652] wl_display@1.delete_id(10)
[2538061.671] wl_drm@11.authenticated()
[2538061.679] wl_callback@10.done(1)
AlanGriffiths commented 2 years ago

To eliminate variables, I rebuilt using the 20.04 archive kodi and not the ppa:team-xbmc/ppa one. Same problem.

In addition, installing unsnapped from the archive also shows a problem:


$ sudo apt install kodi kodi-wayland
$ WINDOWING=wayland WAYLAND_DISPLAY=wayland-0 kodi
VA error: wayland: Wayland roundtrip error: Protocol error (errno 71)
libva info: VA-API version 1.7.0
libva error: vaGetDriverNameByIndex() failed with invalid VADisplay, driver_name = (null)
terminate called after throwing an instance of 'std::system_error'
  what():  wl_display_roundtrip_queue: Protocol error
Aborted (core dumped)
Crash report available at /home/alan/kodi_crashlog-20220506_100723.log
AlanGriffiths commented 2 years ago

The native (.deb) kodi from 22.04 works

Saviq commented 2 years ago

I've gone back to revision 51, same behaviour, so it's something outside of the snap.

Saviq commented 2 years ago

No obvious related change here:

https://github.com/xbmc/xbmc/compare/e12e66e019...b738e65ae5

AlanGriffiths commented 2 years ago

I don't think this is a packaging problem: testing on 20.04 both the archive version and the ppa:team-xbmc/ppa version fail to run using WINDOWING=wayland.

As we're packaging from the 20.04 archive and PPA we'll be inheriting that behaviour.