NewPipe icon indicating copy to clipboard operation
NewPipe copied to clipboard

"Remove watched" with "Remove duplicates" without closing and re-opening the playlist does not work correctly

Open emanuele6 opened this issue 1 year ago • 1 comments

Checklist

  • [X] I am able to reproduce the bug with the latest version given here: CLICK THIS LINK.
  • [X] I made sure that there are no existing issues - open or closed - which I could contribute my information to.
  • [X] I have read the FAQ and my problem isn't listed.
  • [X] I have taken the time to fill in all the required details. I understand that the bug report will be dismissed otherwise.
  • [X] This issue contains only one bug.
  • [X] I have read and understood the contribution guidelines.

Affected version

0.27.0

Steps to reproduce the bug

  1. Create a new playlist with two contents, one watched, and one not watched. Also add a duplicate for each content. You should have two copies of the watched content, and two copies of the non-watched content.
  2. Open that playlist
  3. ... -> "Remove watched" -> "OK"; the two copies of the watched content should have been removed, and only the two copies of the non-watched content should remain
  4. Without exiting, ... -> "Remove duplicates" -> "OK"

Expected behavior

What should happen is that one of the two copies of the content that is left in the playlist should be removed, leaving only one copy of the non-watched content in the playlist.

Actual behavior

What actually happens is that the contents that were previously deleted by "Remove watched" are added back, and then, from the original state of the playlist (2x watched + 2x non-watched) duplicates are removed, so you are left with one copy of the watched content, and one copy of the non-watched content.

The Remove watched/Remove duplicates change is only "commited" after you exit the playlist page. You have to: ... -> "Remove watched" -> "OK" -> -> re-open playlist -> ... -> "Remove duplicates" -> "OK" to remove both watched and duplicates.

Screenshots/Screen recordings

No response

Logs

No response

Affected Android/Custom ROM version

Android 13 / One UI Core 5.1

Affected device model

Samsung Galaxy A22 5G

Additional information

No response

emanuele6 avatar Jun 06 '24 20:06 emanuele6

So certain actions should be carried out immediately, instead of waiting for the playlist to be closed/reopened before committing to the database.

opusforlife2 avatar Jun 07 '24 16:06 opusforlife2

A similar problem occurs when you use the share button to copy the list of URLs in a local playlist after deleting some videos from the playlist either manually or with "Remove duplicates"/"Remove watched". If you don't close and re-open the playlist before pressing the share button, after deleting the videos, you will copy a list of URLs that includes the videos that were deleted (the original content of the playlist.)

emanuele6 avatar Jan 01 '25 10:01 emanuele6