TeamNewPipe / NewPipe

A libre lightweight streaming front-end for Android.
https://newpipe.net
GNU General Public License v3.0
31.01k stars 3.02k forks source link

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

Open emanuele6 opened 3 months ago

emanuele6 commented 3 months ago

Checklist

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

opusforlife2 commented 3 months ago

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