Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Accessing details from play queue window breaks playback #4541

Closed
4 tasks done
pew-pew opened this issue Oct 17, 2020 · 14 comments · Fixed by #4562
Closed
4 tasks done

Accessing details from play queue window breaks playback #4541

pew-pew opened this issue Oct 17, 2020 · 14 comments · Fixed by #4562
Labels
bug Issue is related to a bug

Comments

@pew-pew
Copy link

pew-pew commented Oct 17, 2020

Thanks to @Anotherlife I was able to reproduce the issue which was annoying me for a long time (since version 20.0). Here is his comment: #4513 (comment)

Checklist

Steps to reproduce the bug

  1. Start the app with an empty play queue
  2. Enqueue a youtube video in background (for example via push-and-hold menu entry in history)
  3. Go to play queue by touching android player/notification
  4. Press and hold on current track entry and select details
  5. Try to seek to an arbitrary position in the player in the android notification panel (or by using controls in play queue window in the bottom).

Actual behaviour

Playback stopped and pause button icon changed to loading icon. Seeking to other places or playing other tracks in a queue doesn't help.

Expected behavior

Playback continues normally, as if I didn't access details from play queue.

Device info

  • Android version/Custom ROM version: Android 10, magic UI 3.1.0
  • Device model: Honor 20 (YAl-L21)

Important note

The main problem is that playback breaks even if I don't try to seek forward/backward (it's just a way to quickly reproduce the issue), it's enough just to access details once. And I have to completely wipe my play queue to get rid of frozen playback and lose all my history and queued tracks because of this.

@pew-pew pew-pew added the bug Issue is related to a bug label Oct 17, 2020
@pew-pew pew-pew changed the title Accessing details from background queue breaks playback Accessing details from play queue window breaks playback Oct 17, 2020
@VGkav
Copy link

VGkav commented Oct 17, 2020

Thanks, I will test 0.20.1 soon. Doing my typical usage of browsing around my subscriptions and enqueing videos in the popup player, while it is playing.

@VGkav
Copy link

VGkav commented Oct 17, 2020

It is the same ... very annoying :(

@opusforlife2
Copy link
Collaborator

Try to seek to an arbitrary position in the player in the android notification panel.

This requires Android 10 to test. Whoever has 10, please see this.

@pew-pew
Copy link
Author

pew-pew commented Oct 17, 2020

Try to seek to an arbitrary position in the player in the android notification panel.

This requires Android 10 to test. Whoever has 10, please see this.

Just have checked - bug can be reproduced by seeking using controls in play queue screen at the bottom too. (I'll update issue description)

@opusforlife2
Copy link
Collaborator

Ah. Confirmed. 👍

@opusforlife2
Copy link
Collaborator

@Anotherlife Is this the exact issue you were describing in your comment #4513 (comment)?

@VGkav
Copy link

VGkav commented Oct 18, 2020

@Anotherlife Is this the exact issue you were describing in your comment #4513 (comment)?

Yes, it is!

@opusforlife2
Copy link
Collaborator

Alright. Minimizing it there.

@Stypox
Copy link
Member

Stypox commented Oct 18, 2020

@avently could you look into this, please? I tried for something like two hours but couldn't understand why this happens.

@avently
Copy link
Contributor

avently commented Oct 18, 2020

@Stypox I'm traveling without my PC so can't check the code. Can only see it via phone and trying to figure out what's happening.
I was able to reproduce and it looks like the problem with

Try to comment it out and send to the user.

@pew-pew
Copy link
Author

pew-pew commented Oct 18, 2020

@Stypox I'm traveling without my PC so can't check the code. Can only see it via phone and trying to figure out what's happening.
I was able to reproduce and it looks like the problem with

Try to comment it out and send to the user.

Tried it myself - it worked! Seeking works fine with this if commented out.

UPD: it also fixes the case when you don't seek but just listen until preloaded buffer suddenly ends

@avently
Copy link
Contributor

avently commented Oct 18, 2020

@pew-pew thank you for testing this!

@Stypox looks like here
https://github.com/TeamNewPipe/NewPipe/blob/dev/app/src/main/java/org/schabi/newpipe/fragments/detail/VideoDetailFragment.java#L865
One more check needed like player.videoPlayerSelected(). I missed this possibility. With this check everything should be fine too and "disabled preloading" feature will still be functional.

@Stypox
Copy link
Member

Stypox commented Oct 18, 2020

@avently thank you! I was just about to ask you under which conditions should preloading be disabled. I'm going to do that and fix also some navigation issues I found along the way

@avently
Copy link
Contributor

avently commented Oct 18, 2020

@Stypox is #4432 has the same problem? I can't reproduce it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issue is related to a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants