Automattic / pocket-casts-android

Pocket Casts Android 🎧
https://forums.pocketcasts.com
Mozilla Public License 2.0
2.58k stars 223 forks source link

Playing Files is less responsive compared to playing podcasts on the watch #917

Open mchowning opened 1 year ago

mchowning commented 1 year ago

Description

When playing audio from the episode screen on the watch, it takes longer for the play button to respond when playing a file (UserEpisode) compared to playing a podcast episode (PodcastEpisode).

This was noted by @ashiagr in https://github.com/Automattic/pocket-casts-android/pull/915#issuecomment-1525249151.

Step-by-step reproduction instructions

  1. Load up the watch app.
  2. From the episode screen for a file, tap play and note that there is frequently some delay before the play icon changes and play starts (this delay isn't super consistent in my testing).
  3. Switch to the episode screen for a podcast episode
  4. From the episode screen for a podcast, tap play and note that there is much less (if any) delay.

Screenshots or screen recording

https://user-images.githubusercontent.com/1405144/234818459-974093f8-f650-4fbc-ad3a-3285c0da04c7.mp4

Did you search for existing bug reports?

Device, Operating system, and Pocket Casts app version

7.38 pre-release build, Android 30 wear emulator.

mchowning commented 1 year ago

It appears that this issue comes from somewhere in the PlaybackManager because the EpisodeScreen is not doing any different handling for UserEpisodes compared to PodcastEpisodes.

I tried immediately updating the UI when taping the button to make it at least feel more responsive, but this caused the button to flicker back and forth between play and pause. Interestingly, this flicker only occurred with files, not with podcast episodes, which I think also points toward there being something about how the PlaybackManager handles files that is causing this.