[Bug]: Autosleep timer engaging outside of set time. #997

Closed
opened 2026-04-24 23:45:20 +02:00 by adam · 4 comments
Owner

Originally created by @iconoclasthero on GitHub (Jul 25, 2024).

What was the Problem?

The sleep timer was set (1200-0600, later changed to 0000-0600). Playback was started ca. 11:00, outside of either time range. The sleep timer was still active.

Steps to Reproduce the Issue

  1. Set sleep timer
  2. Start playback
  3. Observer sleep timer on.

What was Expected?

Inactive sleep timer

Phone Model

OnePlus 10 Pro

Phone OS

Android 14, stock rom, rooted

Audiobookshelf App Version

Android App - 0.9.74

Installation Source

Other (List in "Additional Notes")

Additional Notes

I probably sideloaded it last time? Not 100% sure. I know that I have sideloaded it before.

Originally created by @iconoclasthero on GitHub (Jul 25, 2024). ### What was the Problem? The sleep timer was set (1200-0600, later changed to 0000-0600). Playback was started ca. 11:00, outside of either time range. The sleep timer was still active. ### Steps to Reproduce the Issue 1. Set sleep timer 2. Start playback 3. Observer sleep timer on. ### What was Expected? Inactive sleep timer ### Phone Model OnePlus 10 Pro ### Phone OS Android 14, stock rom, rooted ### Audiobookshelf App Version Android App - 0.9.74 ### Installation Source Other (List in "Additional Notes") ### Additional Notes I probably sideloaded it last time? Not 100% sure. I know that I _have_ sideloaded it before.
adam added the bug label 2026-04-24 23:45:20 +02:00
adam closed this issue 2026-04-24 23:45:20 +02:00
Author
Owner

@iconoclasthero commented on GitHub (Jul 25, 2024):

It is nice that I was listening to something more or less respectable:

Screenshot_2024-07-25-11-30-39-6 (1)

Screenshot_2024-07-25-11-30-55-9 (1)

@iconoclasthero commented on GitHub (Jul 25, 2024): It is nice that I was listening to something more or less respectable: ![Screenshot_2024-07-25-11-30-39-6 (1)](https://github.com/user-attachments/assets/5c5143d0-8ba4-4824-aa7c-782798b47c4f) ![Screenshot_2024-07-25-11-30-55-9 (1)](https://github.com/user-attachments/assets/67b2e7b8-2ed4-4b6c-a414-cfeea9783525)
Author
Owner

@nichwall commented on GitHub (Jul 25, 2024):

I was able to reproduce this by setting an auto sleep timer to end 3 minutes in the future and beginning playback (observed auto sleep timer enabled correctly). I closed the media player but kept the app open until I was outside of active hours for the auto sleep timer. Once outside of auto sleep timer hours, opening the player (incorrectly) enabled the auto sleep timer with full time remaining.

Completely closing the app and reopening the app correctly did not cause the auto sleep timer to be enabled. Looks like once the auto sleep timer is enabled it is not checked whether it should be disabled without completing closing the app.

@nichwall commented on GitHub (Jul 25, 2024): I was able to reproduce this by setting an auto sleep timer to end 3 minutes in the future and beginning playback (observed auto sleep timer enabled correctly). I closed the media player but kept the app open until I was outside of active hours for the auto sleep timer. Once outside of auto sleep timer hours, opening the player (incorrectly) enabled the auto sleep timer with full time remaining. Completely closing the app and reopening the app correctly did not cause the auto sleep timer to be enabled. Looks like once the auto sleep timer is enabled it is not checked whether it should be disabled without completing closing the app.
Author
Owner

@iconoclasthero commented on GitHub (Jul 26, 2024):

Yeah, what he said about completely closing the app seemed to work. I used app info > force stop to close it.
Changing books, logging into the server didn't have any effect.

@iconoclasthero commented on GitHub (Jul 26, 2024): Yeah, what he said about completely closing the app seemed to work. I used app info > force stop to close it. Changing books, logging into the server didn't have any effect.
Author
Owner

@github-actions[bot] commented on GitHub (Jan 27, 2025):

Fixed in v0.9.79-beta.

@github-actions[bot] commented on GitHub (Jan 27, 2025): Fixed in [v0.9.79-beta](https://github.com/advplyr/audiobookshelf-app/releases/tag/v0.9.79-beta).
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/audiobookshelf-app#997