podverse-rn
podverse-rn copied to clipboard
Pausing from iOS lockscreen doesn't trigger sync with Podverse web
While listening to Podverse on iOS (version 15 and 16 tested) and hitting the pause button on the lockscreen, it doesn't seem to sync the position on the currently playing podcast with the web player. If I:
- Hit pause on the lockscreen (and don't unlock and open the Podverse app)
- Open a new tab on my computer and head to Podverse web player
- It doesn't show the same timestamp as it does on my phone's lockscreen that's showing the current playback position on my podcast currently paused
Expected behavior Podcast position is synced no matter if the app is in the background or foreground. The sync logic only seems to work while the app is active (phone is not locked).
Smartphone (please complete the following information):
- Device: iPhone 11
- OS: iOS 16.0.3 and 15.7
- App Version 4.6.9 build 1752
@jastrom85 thanks for this thorough bug report. I just tried reproducing the issue following the same steps, but it worked for me. Some questions/comments...
-
Is the iOS progress bar on the lock screen actually showing the correct timestamp for you? If you unlock it and look at the player, is it the same? (There have been chronic "iOS progress bar falling out of sync on lock screen" since iOS 14 I think. In the current app though the progress bar should snap to the actual time position on pause.)
-
I'm sure you are, but are you logged into the same account on Podverse web and mobile?
-
Could your mobile device have no internet / weak signal when you're testing?
-
If it's none of those things...then my hunch is that after some amount of time, iOS may stop allowing calls to the JavaScript runtime environment, putting it on pause while the app is in the background. That wouldn't surprise me, but I just left Podverse in the background for ~10 minutes without unlocking the screen, then tried reproducing the bug, and the website still updated on refresh as expected, so I don't have evidence that's it yet.
Any more info would be appreciated.
- I've seen the lock screen progress bar falling out of sync even on iOS 16 so it seems to persist :) But to answer your question, yes it seems to.
- Yep!
- Haven't thought of that as a variable but I'll keep an eye on it.
- Sounds plausible
I'm using the app several times every day, however not in conjunction with sittting down at the computer to check if the sync has worked. I'll continue to sample my progress with syncing, if you feel like this gets too long-winded feel free to close this issue.
@jastrom85 ok cool.
- If it's a problem where you didn't have internet connection, so the "save to server" function failed when you pressed pause...maybe we could add some retry handling.
We plan to eventually add a "save playback position to server once per minute" feature in the future (after #1179 is finished), which should at least improve the accuracy as a "fallback"...so if an on-demand save request like the pause event fails, the app should restore from within a minute of the time you left off. Not a perfect solution but...hopefully an improvement.
- If it's a problem where our JavaScript just isn't getting executed in the background anymore, then we may need to add native iOS and Android code to handle the case.