[Bug]: Not resuming at the time last paused #1171

Open
opened 2026-04-24 23:51:54 +02:00 by adam · 8 comments
Owner

Originally created by @bxpressiv on GitHub (Mar 15, 2025).

I have verified that the bug is not already awaiting release

Yes

What was the Problem?

When driving my car, it often doesn't save local progress so when I restart the car later the app loads a previous save state, so if I listened for 20mins, it would go back 20mins. Sorry I don't have technical knowledge and can't really explain this well, but can answer any questions if this is unclear. I think this is related to some previously reported bugs but am not 100% certain.

Steps to Reproduce the Issue

This can be reproduced through normal use in my car, but I can tell you how I avoid this:

When I stop driving, I don't turn off the engine (which auto stops my media) and open the ABS app, allow the server to connect to the app while the book is still playing and then I hit pause. This seems to then sync local and server and avoids going back when my car auto connects and plays the next time I drive. This is obviously a workaround requiring manual intervention rather than an ideal workflow.

What was Expected?

The ABS app should play the latest save state and not go back.

Phone Model

Galaxy Z Fold 6

Phone OS

Android 14

Audiobookshelf App Version

Android App - 0.9.79

Installation Source

Google Play Store

Additional Notes

I'm not smart so don't understand the how or why, I hope I have conveyed the problem. I think if hypothetically the ABS app was connected to the server the whole time they would stay synced. If that's a battery issue, then maybe an option to prefer local, or something like that may resolve the issue.

I am on ABS v2.19.5

Originally created by @bxpressiv on GitHub (Mar 15, 2025). ### I have verified that the [bug is not already awaiting release](https://github.com/advplyr/audiobookshelf-app/issues?q=is%3Aissue%20label%3A%22awaiting%20release%22) Yes ### What was the Problem? When driving my car, it often doesn't save local progress so when I restart the car later the app loads a previous save state, so if I listened for 20mins, it would go back 20mins. Sorry I don't have technical knowledge and can't really explain this well, but can answer any questions if this is unclear. I think this is related to some previously reported bugs but am not 100% certain. ### Steps to Reproduce the Issue This can be reproduced through normal use in my car, but I can tell you how I avoid this: When I stop driving, I don't turn off the engine (which auto stops my media) and open the ABS app, allow the server to connect to the app while the book is still playing and then I hit pause. This seems to then sync local and server and avoids going back when my car auto connects and plays the next time I drive. This is obviously a workaround requiring manual intervention rather than an ideal workflow. ### What was Expected? The ABS app should play the latest save state and not go back. ### Phone Model Galaxy Z Fold 6 ### Phone OS Android 14 ### Audiobookshelf App Version Android App - 0.9.79 ### Installation Source Google Play Store ### Additional Notes I'm not smart so don't understand the how or why, I hope I have conveyed the problem. I think if hypothetically the ABS app was connected to the server the whole time they would stay synced. If that's a battery issue, then maybe an option to prefer local, or something like that may resolve the issue. I am on ABS v2.19.5
adam added the bugandroidprogress sync labels 2026-04-24 23:51:54 +02:00
Author
Owner

@nrjohnstone commented on GitHub (Mar 20, 2025):

I have the same thing happening when I listen to audiobooks in the car as well.. Any progress made while not connected to the server seems to be lost once the server connection is re-established

@nrjohnstone commented on GitHub (Mar 20, 2025): I have the same thing happening when I listen to audiobooks in the car as well.. Any progress made while not connected to the server seems to be lost once the server connection is re-established
Author
Owner

@nrjohnstone commented on GitHub (Mar 20, 2025):

I haven't looked into the code to try and find a fix for this, but I would assume that while an audio book is playing without the server connection, the local progress is stored/updated every X seconds regardless of "hitting pause" or not.

Then once the server is reconnected, the sync API should compare the position AND the last updated datetime stamp for the server vs the app on your phone.

I would assume that whoever has the latest datetime stamp wins, and that position is sync'd, so in this case the phone position is pushed to the server and stored there.

@nrjohnstone commented on GitHub (Mar 20, 2025): I haven't looked into the code to try and find a fix for this, but I would assume that while an audio book is playing without the server connection, the local progress is stored/updated every X seconds regardless of "hitting pause" or not. Then once the server is reconnected, the sync API should compare the position AND the last updated datetime stamp for the server vs the app on your phone. I would assume that whoever has the latest datetime stamp wins, and that position is sync'd, so in this case the phone position is pushed to the server and stored there.
Author
Owner

@Meningitix commented on GitHub (Mar 23, 2025):

Having this problem as well, but I found, that it seems to also save the progress locally when pressing pause in AA. I am not connected to my server when driving.

@Meningitix commented on GitHub (Mar 23, 2025): Having this problem as well, but I found, that it seems to also save the progress locally when pressing pause in AA. I am not connected to my server when driving.
Author
Owner

@nrjohnstone commented on GitHub (Mar 24, 2025):

I tried cloning this repo and building the app, but not being that familiar with android development there is a lot undocumented things that you need to know to have a successful build.

I suspect that the progress is only updated on "pause" events and implementing something like updating the progress position every 10 seconds locally while NOT connected to a server (and maybe every 30 seconds when you are connected?) might help to fix the problem... If it is already doing this then it must be something to do with the sync between server and client

@nrjohnstone commented on GitHub (Mar 24, 2025): I tried cloning this repo and building the app, but not being that familiar with android development there is a lot undocumented things that you need to know to have a successful build. I suspect that the progress is only updated on "pause" events and implementing something like updating the progress position every 10 seconds locally while NOT connected to a server (and maybe every 30 seconds when you are connected?) might help to fix the problem... If it is already doing this then it must be something to do with the sync between server and client
Author
Owner

@nichwall commented on GitHub (Mar 24, 2025):

I tried cloning this repo and building the app, but not being that familiar with android development there is a lot undocumented things that you need to know to have a successful build.

I suspect that the progress is only updated on "pause" events and implementing something like updating the progress position every 10 seconds locally while NOT connected to a server (and maybe every 30 seconds when you are connected?) might help to fix the problem... If it is already doing this then it must be something to do with the sync between server and client

The app is already doing this (sync on pause, and then every 30 seconds while listening). It is an issue with syncing, there are several issues open related to this.

Edit to clarify: it is an issue with syncing when resuming the book. There are also issues with Android Auto not syncing at all if you don't first open the app on the phone. I am not familiar with Android Auto so can't really speak to how to even start looking there.

@nichwall commented on GitHub (Mar 24, 2025): > I tried cloning this repo and building the app, but not being that familiar with android development there is a lot undocumented things that you need to know to have a successful build. > > I suspect that the progress is only updated on "pause" events and implementing something like updating the progress position every 10 seconds locally while NOT connected to a server (and maybe every 30 seconds when you are connected?) might help to fix the problem... If it is already doing this then it must be something to do with the sync between server and client The app is already doing this (sync on pause, and then every 30 seconds while listening). It is an issue with syncing, there are several issues open related to this. Edit to clarify: it is an issue with syncing when resuming the book. There are also issues with Android Auto not syncing at all if you don't first open the app on the phone. I am not familiar with Android Auto so can't really speak to how to even start looking there.
Author
Owner

@larnak commented on GitHub (Jun 1, 2025):

Hi, I have the same problem. My audiobookshelf server is only available on my local network. I downloaded a book on my phone (Pixel 8). When I drive using Android Auto, I play the book from the car system. Some times (but not always), it "forget" my last session's progress. Is it happening because when I'm back home, my phone connect to my local network and then my phone and server sync but the server push its progress to the phone. It feels strange. I hope my comment add something useful to the conversation. I hope I could rely on the sync progress because when I start driving and I realise I'm missing 1h+ of progress in my book and can't find where I was in the book because I'm driving, it's annoying.

I'm very grateful for this project. Thanks for your great work.

@larnak commented on GitHub (Jun 1, 2025): Hi, I have the same problem. My audiobookshelf server is only available on my local network. I downloaded a book on my phone (Pixel 8). When I drive using Android Auto, I play the book from the car system. Some times (but not always), it "forget" my last session's progress. Is it happening because when I'm back home, my phone connect to my local network and then my phone and server sync but the server push its progress to the phone. It feels strange. I hope my comment add something useful to the conversation. I hope I could rely on the sync progress because when I start driving and I realise I'm missing 1h+ of progress in my book and can't find where I was in the book because I'm driving, it's annoying. I'm very grateful for this project. Thanks for your great work.
Author
Owner

@bxpressiv commented on GitHub (Jun 14, 2025):

I have given up using ABS as a player for now and just use it as a server to download and manage the books, which it does exceptionally well. I then download them onto my phone and use a separate player so then I'm not worrying about play states and server connections to try and keep track of where I am in a book.

I wish there was an option to have local only for play states, or something. I'm guessing a lot of people use one device for all their listening, so reaching back to the server is only useful for grabbing another book, and for people who like their statistics.

In its current state the ABS app as a player causes headaches, compared to just seamlessly jumping in and out of a car and it starting and stopping where you want it to, without thinking about it.

@bxpressiv commented on GitHub (Jun 14, 2025): I have given up using ABS as a player for now and just use it as a server to download and manage the books, which it does exceptionally well. I then download them onto my phone and use a separate player so then I'm not worrying about play states and server connections to try and keep track of where I am in a book. I wish there was an option to have local only for play states, or something. I'm guessing a lot of people use one device for all their listening, so reaching back to the server is only useful for grabbing another book, and for people who like their statistics. In its current state the ABS app as a player causes headaches, compared to just seamlessly jumping in and out of a car and it starting and stopping where you want it to, without thinking about it.
Author
Owner

@Alistair1231 commented on GitHub (Jul 1, 2025):

This sounds related to https://github.com/advplyr/audiobookshelf-app/issues/1416

@Alistair1231 commented on GitHub (Jul 1, 2025): This sounds related to https://github.com/advplyr/audiobookshelf-app/issues/1416
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/audiobookshelf-app#1171