xbmc
xbmc copied to clipboard
"Put display to sleep when idle" option causes the Kodi GUI to freeze/hang
Bug report
Describe the bug
Here is a clear and concise description of what the problem is:
When Kodi triggers its power saving feature (not the screen saver, but the "Put display to sleep when idle" option) after some minutes of inactivity, it causes the GUI to freeze completely, requiring me to SSH into the system and restart the application.
Unplugging and re-plugging the HDMI cable does not fix the issue, only a restart of the application does.
I am using a slightly modified build of the official flatpak, with the only change being using GLES instead of GL.
Expected Behavior
Here is a clear and concise description of what was expected to happen:
The GUI should not freeze when Kodi puts the display to sleep.
Actual Behavior
The GUI freezes and does not respond to input.
Possible Fix
To Reproduce
Steps to reproduce the behavior:
- Disable the screensaver, and enable the "Put display to sleep" option
- Wait until the display is put to sleep. My TV (LG G1) doesn't turn off immediately, but just shows some static rotating images for a while. The TV does not need to be powered off to reproduce this issue, and the same thing happens even if it is already powered off when the sleep mode is triggered by Kodi.
- Provide some input so as to wake Kodi and unsleep the TV (and turn on the TV if it is powered off). Find that the GUI is frozen.
Debuglog
The debuglog can be found here:
I turn my TV on towards the end of the debug log, and find the GUI to be frozen.
Screenshots
Here are some links or screenshots to help explain the problem:
N/A
Additional context or screenshots (if appropriate)
Here is some additional context or explanation that might help:
N/A
Your Environment
Used Operating system:
-
[ ] Android
-
[ ] iOS
-
[ ] tvOS
-
[x] Linux
-
[ ] macOS
-
[ ] Windows
-
[ ] Windows UWP
-
Operating system version/name: Fedora 40
-
Kodi version: 21 (Flatpak)
note: Once the issue is made we require you to update it with new information or Kodi versions should that be required. Team Kodi will consider your problem report however, we will not make any promises the problem will be solved.
Does this happen if you unplug and replug HDMI cable? I think this is triggered by a HDMI hotplug event.
Does this happen if you unplug and replug HDMI cable? I think this is triggered by a HDMI hotplug event.
Just tested it several times. Unplugging and replugging does not fix it, it's still frozen.
Here's another debug log, but with extra logging for the "windowing" component, as requested in #23921.
It seems to occur while my TV is powered off
Is there an easy way to reproduce the issue? Does unplugging and replugging HDMI make it freeze? Does power cycling the TV make it freeze?
I found some time to test this. Power cycling the TV and/or unplugging the HDMI cable does not reproduce this issue.
I can confirm the "Put display to sleep when idle" option is the culprit, and is 100% reproducible.
Reverting #23921 like in https://github.com/LibreELEC/LibreELEC.tv/issues/8488 fixes the issue for me too.
Stumbled upon this thread while researching the same issue.
Happens every time with my Kodi. Screensaver is set to dim after 3 minutes and turn the screen off after 30. Every time I wake it up the screen stays dimmed and doesn't seem to react, though the navigation sounds can still be heard when using the arrow buttons.
Environment: Kodi 21.0-Omega on x86_64 installed from official flatpak repo, no modifications to the package. Updated yesterday (Friday 24th of May) and checked again today to confirm the issue still happens. No desktop manager of any sort, running raw on whatever the package pulled as a dependency (which is Freedesktop 23.08.17). The service is started by simply running "flatpak run tv.kodi.Kodi" and it seems to handle the graphics by itself. Ubuntu 22.04 with all updates applied.
I can provide logs if you tell me what I need to do.
I'm experiencing this behavior in Kodi 21.0-RC1 with matching error messages from https://github.com/LibreELEC/LibreELEC.tv/issues/8488
Environment: Ubuntu 22.04.3 kernel 6.5.0-14-generic (x86_64) Intel Xe Graphics (TGL GT2) WIndowing sysem: gbm
My repro steps:
- Start video playback (something h264, for example)
- Pause playback, wait for the display to sleep
- Resume playback after display goes to sleep.
Result: Display wakes, and playback audio can be heard, but the picture is permanently frozen and dim. The remote can stop playback and UI button sounds can be heard.
However, if I stop playback while the display is asleep, the screen will wake and the UI will be functional. Playing videos works at this point.
Anyone wanna try https://github.com/xbmc/xbmc/pull/25588?
Anyone wanna try https://github.com/xbmc/xbmc/pull/25588?
Tried it, and it works great so far! Thanks for looking into to this, this has been bothering me for a couple of months now.
Have to use it for a little longer to be sure that it fixes all my "starting playback after leaving kodi idle for a while" issues, though, but it's looking good.
Have to use it for a little longer
Kodi resumes playing just fine now, even after not interacting with it for a night!
Where is this "Put display to sleep when idle" option? I can not find it in the Kodi 21.1 settings. Is it on or off by default?
I am asking because of the problem I am asking about in the Kodi Forum.
Where is this "Put display to sleep when idle" option?
https://kodi.wiki/view/Settings/System/Power_saving
This issue is fixed for me in master, probably because of https://github.com/xbmc/xbmc/pull/25588.