podverse-rn
podverse-rn copied to clipboard
Improve offline experience by saving progress and played while offline
Is your feature request related to a problem? Please describe. Many features do not work when offline but they could work! These features include saved progress and marking an episode as played. Sometimes the queue doesn't load when offline. It is difficult to figure out which episodes are downloaded and available to play while offline.
Describe the solution you'd like When offline I would like to be able to have my progress saved. I would like the podcasts I have play to be marked as played while offline. I would like the queue to load up and my offline episodes to be played while offline.
When I am finally back online the server can be updated with the offline changes which were made.
Describe alternatives you've considered A message to the user explaining how many features will not work if offline is a minimum IMHO.
Related to: #1675
Thank you for this great proposal! Our offline experience needs a lot of improvement, especially in the ways you've described.
To be honest I haven't had a clear idea yet of how to 1) handle all the syncing with the server that needs to happen as devices go online and offline, and 2) handle syncing collisions from multiple devices going back online.
-
seems like it could be relatively easy, if we just keep track of queue, history, and now playing item updates in local storage during offline mode, then when the device is online, it sends those updates batched to the server, and clears them from local storage if successful.
-
seems to complicate things though...my guess is we'll need to compare "last updated at" timestamps and only save those events from offline mode to the database if the offline events have a more recent timestamp than the database.
Anyway, offline mode definitely has to improve so I'll make this a top priority.
I am having a problem (or perhaps few related problems) that I think this improvement would address.
Basically, Podverse keeps losing my place, particularly when I'm switching networks (e.g. from WiFi to mobile). Even more frustratingly the behavior is inconsistent!
- Sometimes it loses my place within the episode, skipping me back to an earlier place it thinks I'm at
- Other times it completely loses the episode I'm on and starts playing the next item in the queue
- Most often it just puts me back at the beginning of the current episode.
I've gathered, from a previous issue I submitted, that Podverse has a difficult time telling when my phone is online, which seems to be a bug related to my specific hardware and/or LineageOS. As such, this behavior is triggered constantly to the point where I nearly rage-quit using Podverse yesterday, so I'm hoping to see something like "better saving of progress" implemented soon!
Other potentially useful info:
- I am only using the single Android device (not loading the web client or logging in from another device in between or anything)
- I am a Premium subscriber
@brandonlichtenwalner I'm sorry for the trouble! 😣 that is very frustrating. Are you on the latest version 4.12.3? I added a fallback function that saves the last playback position somewhat recently every minute, and that is supposed to prevent the app from completely losing the current position.
I wonder however if the issues you are facing could be related to LineageOS having stricter network security rules? And if those intermittently cause errors in our player, and result in the app skipping / mishandling them? That's just a wild guess because I have seen intermittent SSL errors in the player before that I can't explain, and I expect LineageOS is at the higher end of strict with network requests.
Do you have the same syncing with time issues for downloaded episodes as streamed episodes? Or is the issue specific to streaming?
Thanks for following up. Yes I'm on 4.12.3 Build 5181. I have Google Play Services installed and it's installed through the Play Store and stays updated automatically as if I were using a stock Android device. I don't know of any particular network security rules in LineageOS, but I'll start looking into it.
Is there anything related to notification access that could be causing or exacerbating the issue? I noticed that Android was blocking notifications for Podverse, so I turned them back on just now to see if that will help.
If anything, the issue is specific to downloaded episodes, because I rarely stream them (unless my place gets lost and the episode accidentally gets marked played and then deleted). I'll try to take note of what happens (or if it's worse) when I switch to streaming an episode.
On Sat, Mar 4, 2023, 00:16 Mitch Downey @.***> wrote:
@brandonlichtenwalner https://github.com/brandonlichtenwalner I'm sorry for the trouble! 😣 that is very frustrating. Are you on the latest version 4.12.3? I added a fallback function that saves the last playback position somewhat recently every minute, and that is supposed to prevent the app from completely losing the current position.
I wonder however if the issues you are facing could be related to LineageOS having stricter network security rules? And if those intermittently cause errors in our player, and result in the app skipping / mishandling them? That's just a wild guess because I have seen intermittent SSL errors in the player before that I can't explain, and I expect LineageOS is at the higher end of strict with network requests.
Do you have the same syncing with time issues for downloaded episodes as streamed episodes? Or is the issue specific to streaming?
— Reply to this email directly, view it on GitHub https://github.com/podverse/podverse-rn/issues/1692#issuecomment-1454457996, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABLQC7AIIHRSIKLWOUYGIO3W2LF35ANCNFSM6AAAAAAVDARQ7Q . You are receiving this because you were mentioned.Message ID: @.***>
I have also noticed Podverse sometimes losing the progress played. I switch between two profiles on GraphineOS and I am switching between wifi hotspots. I try to let Podverse save to the server the latest progress before going offline or switching profiles but it doesn't always work to resume the saved progress.
@mitchdowney I paid close attention this morning, and below is as exact a scenario as I can report.
- I was listening to some podcasts at home on WiFi this morning.
- Later, I got in my car, my phone connected to the car's Bluetooth, and I drove away from my house and was definitely out of WiFi range and on mobile data before I fired up Podverse. (I can't, however, be sure that connecting to Bluetooth didn't trigger a "resume" because I'm not 100% sure whether Podverse was completely closed or simply sleeping in the background.)
- When I started up Podverse, it picked up where I left off in the middle of an episode -- so far so good.
- I arrived at my destination after about 10 minutes, still in the middle of the same episode, and turned off the car. Podverse automatically paused like it's supposed to.
- I tossed my phone in my gym bag where it stayed while I was inside a building for ~90 minutes. I have no idea what the mobile connection is like in there, but I should not have been connected to any WiFi networks. Podverse should have been sleeping/backgrounded still because I did not explicitly exit it.
- I got back in my car for the return trip home--still on mobile data--and when I opened Podverse as I was pulling out of the parking lot, it had skipped back to the same place where it had started in step 3 as if I had not listened to it at all on my way to the gym.
- I skipped around until I got back to where I was and then listened to the same podcast episode for the rest of the ride home.
- I pulled into my driveway / garage -- at some point my phone should have reconnected to WiFi -- and I turned off my car (again, Podverse automatically paused) and I proceeded on with my day.
- It's now a couple of hours later and I checked right now and Podverse picked back up right where I left off in step 8 -- i.e. where it should. Podverse was definitely open/sleeping in the background and not completely exited.
I hope this information proves helpful.
@brandonlichtenwalner thank you this is SUPER helpful.
when I opened Podverse as I was pulling out of the parking lot
Do you know if the app was open in the background when you opened it? Or did you see the loading screen on launch?
If you saw the loading screen, it might be a server-side issue, but if you didn't then I think it's more likely the bug is with our audio player.
I'm still not sure what I can do to fix this yet, but I'm definitely going to do something for it in the next release. A lot of people are reporting this issue.
@mitchdowney
Do you know if the app was open in the background when you opened it? Or did you see the loading screen on launch?
Unfortunately, I don't know for sure, but it's very likely that I saw the loading screen. I say that because when I open Podverse I seem to get the loading screen (with the bouncing blue dots) just about every time on my device unless it's actively playing a podcast. For instance, I was listening to a podcast less than 30 minutes ago and then paused it (likely, though not certain, via the lock-screen notification), and when I picked up my phone and unlocked it just now I was greeted with the Podverse loading screen.
This behavior is somewhat new, I believe, perhaps within the last release or maybe two. At least I don't recall seeing the loading screen every time until recently, but it's possible the loading screen simply takes longer and/or is more noticeable now.
I too have been having issues with offline listening. I make sure I have a bunch of episodes queued up and downloaded. Then I get on a flight and start listening. The current episode plays until its over and then I can't play any of the other downloaded episodes. It also seems like it doesn't save all my subscriptions and podcasts locally. I tried closing and reopening the app and it didn't show even half the podcasts I am subscribed to, let alone the episodes I had downloaded. It would only show an error symbol over the play button. This was just last week on Tuesday and Wednesday. I am on version 4.12.3 for Fdroid and Calyx OS. As soon as I have network connectivity, everything is back to normal.
[Edit May 30 2023] @mitchdowney I am now on 4.12.12 from Fdroid now and the problem I described is gone! I flew today, was in and out of service and the downloaded episodes never disappeared 😁 I paid up for the year of premium and I'm loving it ❤️
I'm having similar issues as described in this thread, but I'm never offline as far as I know. Seeing issues with saving location and resuming playback within episodes. Also unable to press play when the app is resumed from background. Have to fully close the app by swiping away and open it again.
@illumiN8i there are 2 major crashes on Android right now that might cause 1) losing last playback position and 2) unable to press play when app is resumed from background.
I'm publishing hopefully a fix for those 2 in a new Beta release (should be available in 1-2 days). I'm not sure that it will fix the issue you are seeing, but it could be related. I'm curious if you'll still have the issues in v4.12.7.
Seems to be much better now. No issues yet. Thanks!
@illumiN8i hmm that's encouraging....are you on 4.12.7 build 5186 from Google Play Beta track? You can confirm by going to More > About > scroll to bottom.
We released a patch for the queue crash in build 5186, but there is a new crash, that appears like it will be fixed and published shortly. I would expect build 5186 to still have crash problems, but the cause will be different, which still might avoid some of bugs you've been running into.
Hopefully the next build will be our most stable Android release ever 🤞
Yes, play store beta 4.12.7 build 5186
It sounds like the "saving progress" feature has improved, but we do not have a perfect "sync offline progress with server" feature. That said...creating a controller to manage syncing offline after internet access is restored will be a pretty big project. There are other issues I need to focus on at this time, so I am going to unassign this issue from me for now but not close it.
Also unable to press play when the app is resumed from background. Have to fully close the app by swiping away and open it again.
The Voice audiobook app recently had that and fixed it. (not the main issue about offline behaviour, just this comment about having to fully kill the process in order to resume play) https://github.com/PaulWoitaschek/Voice/commit/bdfd84cbf441ab1e0eca1a191dda006510b9616b
@bkw777 interesting...unfortunately I don't understand the Android code in it.
Do you think that fix is related to "offline experience" like the title of this issue? Or is that a background player fix? If it's a background player fix, if you have a chance to create a Github issue documenting it, I'd appreciate it.
I uninstalled due to the login and on-line requirement. I'm not complaining or demanding, I'm simply gone.
@bkw777 just to clarify, there is no login requirement. The app will work without logging in. If you signed up for Premium, and it expired, Podverse is a value-for-value company, and we will extend anyones membership for free if they email [email protected] asking for an extension.
I'm not totally sure what you mean by "on-line requirement". There is an offline mode for downloading and playing episodes without internet connection, which appears to work on a majority of Android devices, but not all. Are you running into that bug?